Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Error with BCP

95 views
Skip to first unread message

Colin

unread,
May 23, 2002, 1:41:00 PM5/23/02
to
I am getting the error, "Function sequence error" (
SQLState = S1010, Native error = 0 ) when I run a batch
file from the command prompt. Any help is greatly
appreciated. Thanks.

Andrew Petrochuk [MS]

unread,
May 23, 2002, 2:00:18 PM5/23/02
to
Can you send more info? Like query, SQL server version etc.
--
This posting is provided "AS IS" with no warranties, and confers no rights

"Colin" <skop...@cci-maximus.com> wrote in message
news:7c6501c20281$00ac6510$35ef2ecf@TKMSFTNGXA11...

Colin

unread,
May 23, 2002, 2:11:20 PM5/23/02
to
>.

>Here is the query I am running.
E:\> bcp "EXEC database..proc_name parameter, ... "
queryout output.txt -c -Sserver_name -Uuser_name -
Ppass_word

SQL Server version is 7.0 on Windows 2000

exact error message
SQLState = S1010, NativeError = 0
Error = [Microsoft][ODBC SQL Server Driver]Function
sequence error

Thanks,
Colin

Andrew Petrochuk [MS]

unread,
May 23, 2002, 2:44:07 PM5/23/02
to
Can you execute same stored procedure without bcp? In Query Analizer for
example.

--
This posting is provided "AS IS" with no warranties, and confers no rights

"Colin" <skop...@cci-maximus.com> wrote in message

news:65e601c20285$3d9f4830$2ae2...@hosting.microsoft.com...

Colin

unread,
May 23, 2002, 3:03:06 PM5/23/02
to
I can execute it using query analyzer, but it would be
very convenient to run it from BCP.

>.
>

lindawie

unread,
May 23, 2002, 10:59:44 PM5/23/02
to
Colin,

What exactly is your stored procedure doing?
Is the batch file doing anything else besides bcp?

Some things to check:

1. Make sure you have SET NOCOUNT ON as the first statement.
2. Remove any print statements in the procedure.
3. No OUTPUT parameters.

Linda


0 new messages