This week's book giveaway is in the OCAJP 8 forum.
We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes How to execute insert ,select and delete statemeents at once in JDBC ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA Java SE 8 Programmer I Study Guide this week in the OCAJP 8 forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "How to execute insert ,select and delete statemeents at once in JDBC ?" Watch "How to execute insert ,select and delete statemeents at once in JDBC ?" New topic
Author

How to execute insert ,select and delete statemeents at once in JDBC ?

Raghavendra ReddyI
Greenhorn

Joined: Sep 10, 2012
Posts: 8
This is a code snippet





plzz suggest me the right coding
Thanks in advance
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 20132
    
  30

Raghavendra ReddyI wrote:plzz suggest me the right coding

Please UseRealWords.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6 - OCEJPAD 6
How To Ask Questions How To Answer Questions
Tim Cooke
Sheriff

Joined: Mar 28, 2008
Posts: 2246
    
102

Yes real words are preferable.

But also, "right coding" for what? I don't see a question.


Tim Driven Development
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 32633
    
215

The question is in the subject. (Try not to do that, as you noticed - people miss it)

For the last two, you can use executeBatch() to do them in one trip to the database. The first query doesn't go together - you do a query and ignore the results?


[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to execute insert ,select and delete statemeents at once in JDBC ?
 
It's not a secret anymore!