Date parsed: 21/10/2007 08:31:42
Date: Sun, 21 Oct 2007 13:31:42 -0500
> I tried RPC:Starting in Profiler -
> doesn't give anything. Looks like this sort of validation hapens before
> RPC:Starting event (error messages I do see in Profiler - via "Exception"
> and
> "User Error Message" events). So how can I trace this error to particular
> sp_executesql statement? Who returns this error: SQL Server or Native
> Client
> provider?
TDS parameter validation occurs before the RPC starting event so I don't
think there's a way to get the parameterized statement using a SQL Trace.
If the application doesn't log exception context, you might try a network
trace to capture the bad TDS packet. The parameterized statement of the
problem call will be visible in the packet(s).
--
Hope this helps.
Dan Guzman
SQL Server MVP
"Michael Zilberstein" <MichaelZilberstein@discussions.microsoft.com> wrote
in message news:E50EAB09-B148-4EED-8F43-912732527595@microsoft.com...
> Good day!
> My client has some application that works with database via combining
> lenghty parametrized queries and executing them from application via
> sp_executesql. Suddely (after upgrade to SQL2005 - the error is Native
> Client's one) at some reports they started to get the following error
> message:
>
> sql server error the incoming tabular data stream (TDS) remote procedure
> call (RPC) is incorrect. Parameter 9 (""): the supplied value is not a
> valid
> instance of data type float. Check the source data for invalid values.
>
> OK, some statement with 9+ parameters receives 9th parameter that should
> be
> float but the value is apparantly is not. I need to trace this error to
> the
> particular sp_executesql statement and give it to application developers -
> they will fix it in the application. I tried RPC:Starting in Profiler -
> doesn't give anything. Looks like this sort of validation hapens before
> RPC:Starting event (error messages I do see in Profiler - via "Exception"
> and
> "User Error Message" events). So how can I trace this error to particular
> sp_executesql statement? Who returns this error: SQL Server or Native
> Client
> provider?
> ------------------
> Michael Zilberstein
> DBArt
> Senior Consultant
>
> ------------------
> My blog:
http://sqljunkies.com/WebLog/mz1313