Asked By Burrows
20-Nov-09 10:23 AM
Hi all I was just writing a quick insert INTO and got an error
Msg 156, Level 15, State 1, Line 15
Incorrect syntax near the keyword 'ORDER'.
INSERT INTO [Test].[dbo].[address1]
(
[ID] ,
[customerId] ,
[line1] ,
[line2]
)
( SELECT
[ID] ,
[customerId] ,
[line1] ,
[line2]
FROM
[dbo].[address]
ORDER BY
[customerId]
)
the funny thing is if I remove the brackets from around the select
statement it works fine any one know why this is the case???