Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Incorrect Syntax Near... Fine in QA not in Access

Author  Topic 

mgraser
Starting Member

4 Posts

Posted - 2008-04-04 : 16:54:16
I created a couple of stored procedures. One of them (let's call it SP1) dumps information into a table and then calls another stored procedure (SP2) to put the info in a temp table in crosstab format. SP1 then displays the info from the temp table.

When I execute SP1 from Query Editor, everything works perfectly. No errors are returned and my data is displayed just as expected.

When I try to execute SP1 from MS Access's pass-through query, I get the following error:

[Microsoft][ODBC SQL Server Driver][SQL Server]Incorrect syntax near ','.(#102)[Microsoft][ODBC SQL Server Driver][SQL Server]Incorrect syntax near 'A'(#102)

I've found that the error occurs when the SP2 is called from within SP1. If it's working fine in Query Editor, shouldn't it work from MS Access? Any insights?

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2008-04-04 : 17:01:50
This is SQL serve Forum. you have to put MSAccess forum.
Go to Top of Page

mgraser
Starting Member

4 Posts

Posted - 2008-04-04 : 17:14:35
I see that there is one here as well. Sorry about that, I will do so.
Go to Top of Page
   

- Advertisement -