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
 General SQL Server Forums
 New to SQL Server Programming
 Select query question
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

daya88
Starting Member

Romania
1 Posts

Posted - 10/25/2012 :  17:02:57  Show Profile  Reply with Quote
Hello,

I'm trying to tune a basic query, but I am receiving a "Encountered unexpedted token "?"" error message. An example of the query is :

Select * from table a where a.column IN (?,?,?,?,?)
or
Select * from table a where a.column=?

Would you please explain me what does that "?" do? So I could find a solution for my error.

Thank you in advance for your cooperation.

visakh16
Very Important crosS Applying yaK Herder

India
52249 Posts

Posted - 10/25/2012 :  17:08:00  Show Profile  Reply with Quote
soiunds like you're using this query inside execute sql task or oledb command in SSIS.
'?' is placeholder for parameters. you need to map appropriate parameters in parameter mapping tab against place holders

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

nigelrivett
Flowing Fount of Yak Knowledge

United Kingdom
3383 Posts

Posted - 10/26/2012 :  05:58:17  Show Profile  Visit nigelrivett's Homepage  Reply with Quote
right(str,4)

==========================================
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.
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.03 seconds. Powered By: Snitz Forums 2000