Author |
Topic |
soni321
Starting Member
8 Posts |
Posted - 2011-04-21 : 14:36:17
|
insert into orders (onum,amt,odate,cnum,snum)select (3001,18.69,'10/03/1990',1007)Union Allselect (3003,767.19,'10/03/1990',2001,1001)union Allselect (3002,1900.10,'10/03/1990',2007,1004)union AllSelect (3005,5160.45,'10/3,1990',2003,1002)union Allselect (3006,1098.16,'10/3/1990',2008,1007)union Allselect(3009,1713.23,'10/04/1990',2002,1003)union Allselect (3007,75.75,'10/04/1990',2004,1002)union Allselect (3008,4723.00,'10/05/1990',2006,1002)union AllSelect(3010,1309.95,'10/06/1990',2004,1002)union Allselect(3011,9891.88,'10/06/1990',2006,1001);it give this output when i run itIncorrect syntax near ','.Msg 102, Level 15, State 1, Line 6Incorrect syntax near ','.Msg 102, Level 15, State 1, Line 8Incorrect syntax near ','.Msg 102, Level 15, State 1, Line 10Incorrect syntax near ','.Msg 102, Level 15, State 1, Line 12Incorrect syntax near ','.Msg 102, Level 15, State 1, Line 14Incorrect syntax near ','.Msg 102, Level 15, State 1, Line 16Incorrect syntax near ','.Msg 102, Level 15, State 1, Line 18Incorrect syntax near ','.Msg 102, Level 15, State 1, Line 20Incorrect syntax near ','.Bhupinder Dhatt |
|
nigelrivett
Master Smack Fu Yak Hacker
3385 Posts |
Posted - 2011-04-21 : 14:43:12
|
select 3001,18.69,'10/03/1990',1007remove the brackets from the select statements==========================================Cursors are useful if you don't know sql.SSIS can be used in a similar way.Beer is not cold and it isn't fizzy. |
 |
|
soni321
Starting Member
8 Posts |
Posted - 2011-04-21 : 15:03:43
|
sir now it shows errorMsg 208, Level 16, State 1, Line 1Invalid object name 'orders'.Bhupinder Dhatt |
 |
|
|
|
|