Per BOL
Parameters of all SQL Trace stored procedures (sp_trace_xx) are strictly typed. If these parameters are not called with the correct input parameter data types, as specified in the argument description, the stored procedure will return an error.
when you call it with 10 I beleive that is being passed as an int, when you use a variable declared as a bigint, it is passed as a bigint.
The 10 would probably work if you did this...
declare @trace_handle int
EXEC sp_trace_create @trace_handle OUTPUT, 2, N'c:\traces\trace', convert(bigint, 10)
To help us help you read this[/url]For better help with performance problems please read this[/url]