• 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

run query in the same time

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi..

i have a question..

is it possible to run query insert, update, delete in the same time in java?

if its possible could you please give me the example..

thanks & regards
 
Marshal
Posts: 28226
95
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What does "in the same time" mean?
 
author
Posts: 4335
39
jQuery Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you mean as a single update, yes, you can chain them together in a single string if your driver supports batch queries. Although usually when you perform a batch operating all the queries are the same type. Having a batch operation of multiple different type (Select, insert, update) would create output akin to apples and oranges, as in its hard for the driver to know what to return. A lot of times it might just return the information from the last operation, so hopefully that's where you put the select.
 
Yudi Ono
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
@Paul, i want to perform batch operating all query(insert, delete, update) in to one transaction, the purpose is to identified which query is fall and when it's fall i just have to rollback the transaction.

@Scott

Having a batch operation of multiple different type (Select, insert, update) would create output akin to apples and oranges , as in its hard for the driver to know what to return



hi scott is it possible to change the multiple different type query and turn it into atomic query and hold them in one transaction and it also check if one query fall, it will return error, and automatically the rollback transaction run?
 
Yudi Ono
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Yudi Ono wrote:hi..

i have a question..

is it possible to run query insert, update, delete at the same time in java?

if its possible could you please give me the example..

thanks & regards

 
Yudi Ono
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Yudi Ono wrote:hi..

i have a question..

is it possible to run query insert, update, delete at the same time in java?

if its possible could you please give me the example..

thanks & regards

 
Yudi Ono
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Yudi Ono wrote:hi..

i have a question..

is it possible to run query insert, update, delete at the same time in java?

if its possible could you please give me the example..

thanks & regards

 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic