Re: SQL Native Client Incorrect syntax near Error
- From: "Bob Barrows [MVP]" <reb01501@xxxxxxxxxxxxxxx>
- Date: Wed, 26 Sep 2007 07:21:36 -0400
RolyMaz wrote:
Hi,
When i run a trace i see the following syntax error on a stored
procedure:
E000 exec dbo.Lead_UpdateLeadContactOutcome
@Username=N'SBHU328',@COGroup=N'No Contact',@CODetail=N'Voice
Mail',@LeadStatus=N'Retry',@VelocitiCallOutcome=N'Not
Pitchable',@ClientCallOutcome=N'Good
Data',@LastContactDate=''2007-09-25
17:49:21:260'',@RetryDate=''2007-09-26
17:49:21:260'',@ContactCounter=3,@CurrentNoOfRetry=3,@ContactType=NULL,@VelocitiLeadID=996078
1 [Microsoft][SQL Native Client][SQL Server]Incorrect syntax near
'2007'.
This stored procedure is called from a VB.NET application, using the
VS 2005
Data Designer.
The reason for the error is clear - the date values are enclosed in
double (2 x ) apostrophes. I cannot work out why this is happening?
Without seeing the code that generated this, I suspect everyone else will be
mystified as well.
BTW, are you sure the quotes are the problem? Have you tested this in SSMS?
There was no way for you to know it (except maybe by browsing through some
of the previous questions in this newsgroup before posting yours - always a
recommended practice) , but this is a classic ADO newsgroup. ADO.Net bears
very little resemblance to classic ADO so, while you may be lucky enough to
find a dotnet-knowledgeable person here who can answer your question, you
can eliminate the luck factor by posting your question to a group where
those dotnet-knowledgeable people hang out. I suggest
microsoft.public.dotnet.framework.adonet.
--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"
.
- Prev by Date: Re: ODBC Connection returns no Data
- Next by Date: Re: ODBC Connection returns no Data
- Previous by thread: ODBC Connection returns no Data
- Next by thread: Re: Trouble getting just one scalar value into a VBA variable...
- Index(es):
Relevant Pages
|
|