SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Other Forums
 Other Topics
 missing expression PLEASE HELP
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

fahim1234
Starting Member

Afghanistan
7 Posts

Posted - 01/04/2011 :  12:48:33  Show Profile  Reply with Quote
can u check whats wrong with this code database experts

INSERT INTO TIME_DIM (TIME_ID) VALUES ('3') (SELECT COLUMN5 FROM SPREADSHEET2 WHERE TIME_ID = '1');

the error is missing expression

thanks

PLEASE HELP ASAP

GilaMonster
Flowing Fount of Yak Knowledge

South Africa
4507 Posts

Posted - 01/04/2011 :  14:00:41  Show Profile  Visit GilaMonster's Homepage  Reply with Quote
You're mixing the two forms of insert.

Insert is either
INSERT INTO ...
VALUES ...

Or

INSERT INTO ...
SELECT ...

Not a mixture of both,

--
Gail Shaw
SQL Server MVP
Go to Top of Page

fahim1234
Starting Member

Afghanistan
7 Posts

Posted - 01/05/2011 :  06:37:06  Show Profile  Reply with Quote
Fanq very much 4 ur help :D

tyutyu
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.12 seconds. Powered By: Snitz Forums 2000