Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within Groovy
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Jeanne Boyarsky
Ron McLeod
Paul Clapham
Liutauras Vilda
Sheriffs:
paul wheaton
Rob Spoor
Devaka Cooray
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Carey Brown
Frits Walraven
Tim Moores
Bartenders:
Mikalai Zaikin
Forum:
Groovy
PreparedStatement with sql.eachRow()
Chetan Parekh
Ranch Hand
Posts: 3640
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Following is a code snippet of current implementation:
xq.message[0] = new XmlFactory([ACT_NS], ACT_NS).build { STUDENTDATA{ STUDENTS{ sql.eachRow( query as String ) { row -> STUDENT() { FIRSTNAME( row.FIRST_NAME ) LASTNAME( row.LAST_NAME ) DATEOFBIRTH( row.DATE_OF_BIRTH ) } } } } }
We want to use PreparedStatement to prevent SQL injection. How to use PreparedStatement with sql.eachRow()?
My blood is tested +ve for Java.
Gregg Bolinger
Ranch Hand
Posts: 15304
6
I like...
posted 12 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
According to the API, you can't.
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
storing date in database
error of missing values
inserting string values with an apostrophe
Storing special characters(') into oracle
Update query
More...