I currently confused at how to set wildcards for long values when using select in databases. Currently I have:
preparedstatement= conn.prepareStatement("SELECT * FROM database WHERE LONGVALUES LIKE ? ");
preparedstatement.setLong(1, aLongValue);
I am currently confused on how to use a wild card to get the results that I want. What I want to select is all values from that database whose LONGVALUES
column contains the number aLongValue
. So if 52
is in the database entering 5
or 2
would select it.