List:General Discussion« Previous MessageNext Message »
From:Eric Bergen Date:December 4 2004 4:51am
Subject:Re: a query to insert values into two different tables using mySQL Server
View as plain text  
Isn't that technically multiple queries? 

In mysql an insert inserts into one table. That's it. 

-Eric


On Wed, 1 Dec 2004 15:50:15 +0100, ***ADI*** <adi@stripped> wrote:
> in MS SQL u can do it by the following query:
> 
> declare @transool varchar(20)
> set @transool = 'opcofficelink'
> begin transaction @transool
> insert into Table1 (Sine_20_Sec, Sine_30_Sec) values (@Sine_20_Sec,
> @Sine_30_Sec)
> insert into Table2 (Sine_20_Sec, Sine_30_Sec) values (@Sine_20_Sec,
> @Sine_30_Sec)
> commit transaction @transool
> 
> is there any similar query that can be used in mySQL?
> what i want to get is insert into Table1 and update row in Table2 the same
> values.
> i can't use two querries =/
> 
> thanx for ANY help,
> ADI
> 
> --
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe:    http://lists.mysql.com/mysql?unsub=1
> 
> 


-- 
Eric Bergen
eric.bergen@stripped
bleated.com
Thread
a query to insert values into two different tables using mySQL Server***ADI***1 Dec
  • Re: a query to insert values into two different tables using mySQL ServerEric Bergen4 Dec