Re: No support for multiple statements via JDBC?

2002-03-20 Thread Anvar Hussain K.M.
Hi Allon, Only one query can be sent to server at a time. But your particular case can be handled with the single query Insert Into orders (Number) select Max(Number) FROM Orders; Anvar. At 04:45 PM 19/03/2002 -0800, you wrote: Hi All- We are using the mm driver for MySQL and multiple

Re: Re: No support for multiple statements via JDBC?

2002-03-20 Thread Anvar Hussain K.M.
sql,Mysql Hi Allon, Sorry. It wont work. I didn't notice that you were inserting to the same table as the select. Anvar. - Before posting, please check: http://www.mysql.com/manual.php (the manual)

Re: No support for multiple statements via JDBC?

2002-03-20 Thread Allon Bendavid
Thanks Anvar- But I guess you didn't really follow this thread. We started with the statement you are suggesting because we are porting from another datasource. As it turns out, you cannot do a Insert ... Select from the same table in MySQL. It's supported in other databases, so I was

Re: No support for multiple statements via JDBC?

2002-03-19 Thread Paul DuBois
At 16:45 -0800 3/19/02, Allon Bendavid wrote: Hi All- We are using the mm driver for MySQL and multiple statements in one connection do not seem to be supported: No. Multiple statements in one *string* are not supported, in the MM.MySQL or any other API. The client-server protocol supports

Re: No support for multiple statements via JDBC?

2002-03-19 Thread Allon Bendavid
Thanks Paul for all of the clarifications Actually what I was saying was this: I obviously didn't assume that sticking a semi-colon between statements creates a transaction. I was leaving out the transaction/table lock statements but I meant to illustrate that for instance: LOCK TABLES Orders

Re: No support for multiple statements via JDBC?

2002-03-19 Thread Paul DuBois
At 18:37 -0800 3/19/02, Allon Bendavid wrote: Thanks Paul for all of the clarifications Actually what I was saying was this: I obviously didn't assume that sticking a semi-colon between statements creates a transaction. I was leaving out the transaction/table lock statements but I meant to