Skip to content
+1-888-319-3663

COMMUNITY FORUM

Error when trying to use SQL stored procedure as a Source

PROY asked 10 years ago
Use bulk data load and an ODBC connection to SQL I am getting an error.

I typed this into the SQL window
exec IS_APSelectAmountsandGLaccountsforsmartconnect

and received this error
ERROR [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]Incorrect syntax near the keyword 'top'.

It previews ok but doesn't validate and can't select key fields.  Any idea why and how I can fix it?
Answers
Best Answer
Lorren answered 10 years ago
Hey Proy,  You are using a SQL Reserved word of 'Select' in your procedure name.  When the system tries to parse that out it throws the error.  Rename your stored procedure to not include any SQL reserved words and you should be good.
Proy replied 10 years ago

Thanks for the response.  We figured out the solution before you posted the response by trial and error.  It is good to get confirmation that using a reserved word is not allowed in stored procedures used by smart connect.


If you would like to submit an answer or comment, please sign in to the eOne portal.