Hello.
I´m trying to execute an PreparedStatement that contains a SQL instruction
like this:
"SELECT COUNT(*) FROM USERS WHERE NAME LIKE ? "
I'm putting as parameter a String, for example "David".
In the data-base there is a record which NAME field contains "David", but
when I execute the PreparedStament it recovers 0 otherwise if I use an
normal Statement that contains "SELECT COUNT(*) FROM USERS WHERE NAME LIKE
'David' " or if I use '=' in place of 'LIKE', it runs OK.
Someone can say me why this happen ?
Thanks
David Mellado
[EMAIL PROTECTED]
PD:(I'm sorry because of my english, I recognize that it isn't very good
:,-I )
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets