File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes Single Quotes Around Value in criteriaFind Strin Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Professional Certification » Developer Certification (SCJD/OCMJD)
Reply Bookmark "Single Quotes Around Value in criteriaFind Strin" Watch "Single Quotes Around Value in criteriaFind Strin" New topic
Author

Single Quotes Around Value in criteriaFind Strin

David Reck
Ranch Hand

Joined: May 25, 2001
Posts: 37
In my criteriaFind method when I get to the value in the name value pair I end up having to strip off the single quotes in the search string. So that the values in "Origin='SFO',Destination='DAL'" become SFO and DAL not 'SFO' and 'DAL'. Am I missing something? Are the single quotes there for a reason?
Rick Fortier
Ranch Hand

Joined: Jun 04, 2001
Posts: 147
Originally posted by David Reck:
In my criteriaFind method when I get to the value in the name value pair I end up having to strip off the single quotes in the search string. So that the values in "Origin='SFO',Destination='DAL'" become SFO and DAL not 'SFO' and 'DAL'. Am I missing something? Are the single quotes there for a reason?

They are being used as delimiters.
 
 
subject: Single Quotes Around Value in criteriaFind Strin
 
Threads others viewed
criteria format in criteriaFind method
criteriaFind String
criteria and criteriaFind
Strange criteriaFind
getRecord Vs readRecord usage in criteriaFind()
IntelliJ Java IDE