I have a Java application which uses a MySQL select query i want to use java array elements for In condition.for eg

select * from table where shortcode IN (aray[]);

is it posible to use java array in mysql

You have to convert the array content to string literals. Like in

SELECT * FROM table WHERE shortcode IN ('a','b','c');
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.