BCP: --- Invalid Descriptor Index Error ... need help

BCP: --- Invalid Descriptor Index Error ... need help

Post by RSB » Sat, 03 May 2003 00:52:04



Hi Everyone,

i was using the following bcp command in the past and it was working and
today as there was a change in our data file so i end up changing the table
and the format file. and once i ran it i am getting this error "Invalid
Descriptor Index" and i am not able to resolve it..

any help?

here is the command and the Error message...

bcp myTable in ..\..\upload\mydataFile -f ..\format\myFormatfile.fmt -e
..\..\logs\bcp\mylog.bcp -F 1 -U myuser -S myserver -P mypass -a 8192

SQLState = S1002, NativeError = 0

Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index

please help

Thanks

RSB

 
 
 

BCP: --- Invalid Descriptor Index Error ... need help

Post by Erland Sommarsko » Sat, 03 May 2003 07:30:57



> i was using the following bcp command in the past and it was working and
> today as there was a change in our data file so i end up changing the
> table and the format file. and once i ran it i am getting this error
> "Invalid Descriptor Index" and i am not able to resolve it.. >

> here is the command and the Error message...
>...
> bcp myTable in ..\..\upload\mydataFile -f ..\format\myFormatfile.fmt -e
> ..\..\logs\bcp\mylog.bcp -F 1 -U myuser -S myserver -P mypass -a 8192
>...
> SQLState = S1002, NativeError = 0

> Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index

Would need this, to be able find out what is going on:

*  CREATE TABLE statement.
*  Format file.
*  Sample data file which results in this error.
*  Which version of SQL Server and BCP you are using (including service    
   pack).

All I can say know is that the error occurs in the BCP program itself,
or more precisely in the ODBC driver. It sort of smells of an internal
error, but that is just a guess.

--

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp

 
 
 

BCP: --- Invalid Descriptor Index Error ... need help

Post by Erland Sommarsko » Sat, 03 May 2003 00:30:57



> i was using the following bcp command in the past and it was working and
> today as there was a change in our data file so i end up changing the
> table and the format file. and once i ran it i am getting this error
> "Invalid Descriptor Index" and i am not able to resolve it.. >

> here is the command and the Error message...
>...
> bcp myTable in ..\..\upload\mydataFile -f ..\format\myFormatfile.fmt -e
> ..\..\logs\bcp\mylog.bcp -F 1 -U myuser -S myserver -P mypass -a 8192
>...
> SQLState = S1002, NativeError = 0

> Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index

Would need this, to be able find out what is going on:

*  CREATE TABLE statement.
*  Format file.
*  Sample data file which results in this error.
*  Which version of SQL Server and BCP you are using (including service    
   pack).

All I can say know is that the error occurs in the BCP program itself,
or more precisely in the ODBC driver. It sort of smells of an internal
error, but that is just a guess.

--

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp

 
 
 

BCP: --- Invalid Descriptor Index Error ... need help

Post by oj » Sat, 03 May 2003 17:12:47


This error typically occurs when the format file has a wrong definition
(i.e. assigning the wrong column position).
e.g.
create table t(i int identity, c1 varchar(10), c2 varchar(20))
go
/* --txt.txt
abc def
*/
/* --fmt.fmt
8.0
2
1 SQLCHAR 0 10 "\t" 2 c1 ""
2 SQLCHAR 0 10 "\r\n" 4 c2 ""
*/
/* --result
C:\>bcp "northwind..t" in "txt.txt" -f"fmt.fmt" -T
SQLState = S1002, NativeError = 0
Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index
*/

If you fix line#2 in this format file by changing 4->3, the error would go
away.

--
-oj
RAC v2.1 & QALite!
http://www.rac4sql.net


Quote:> Hi Everyone,

> i was using the following bcp command in the past and it was working and
> today as there was a change in our data file so i end up changing the
table
> and the format file. and once i ran it i am getting this error "Invalid
> Descriptor Index" and i am not able to resolve it..

> any help?

> here is the command and the Error message...

> bcp myTable in ..\..\upload\mydataFile -f ..\format\myFormatfile.fmt -e
> ..\..\logs\bcp\mylog.bcp -F 1 -U myuser -S myserver -P mypass -a 8192

> SQLState = S1002, NativeError = 0

> Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index

> please help

> Thanks

> RSB

 
 
 

BCP: --- Invalid Descriptor Index Error ... need help

Post by RSB » Sun, 04 May 2003 04:33:21


Thanks OJ

that helped....

RSB


This error typically occurs when the format file has a wrong definition
(i.e. assigning the wrong column position).
e.g.
create table t(i int identity, c1 varchar(10), c2 varchar(20))
go
/* --txt.txt
abc def
*/
/* --fmt.fmt
8.0
2
1 SQLCHAR 0 10 "\t" 2 c1 ""
2 SQLCHAR 0 10 "\r\n" 4 c2 ""
*/
/* --result
C:\>bcp "northwind..t" in "txt.txt" -f"fmt.fmt" -T
SQLState = S1002, NativeError = 0
Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index
*/

If you fix line#2 in this format file by changing 4->3, the error would go
away.

--
-oj
RAC v2.1 & QALite!
http://www.rac4sql.net


Quote:> Hi Everyone,

> i was using the following bcp command in the past and it was working and
> today as there was a change in our data file so i end up changing the
table
> and the format file. and once i ran it i am getting this error "Invalid
> Descriptor Index" and i am not able to resolve it..

> any help?

> here is the command and the Error message...

> bcp myTable in ..\..\upload\mydataFile -f ..\format\myFormatfile.fmt -e
> ..\..\logs\bcp\mylog.bcp -F 1 -U myuser -S myserver -P mypass -a 8192

> SQLState = S1002, NativeError = 0

> Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index

> please help

> Thanks

> RSB

 
 
 

BCP: --- Invalid Descriptor Index Error ... need help

Post by RSB » Sat, 03 May 2003 21:33:21


Thanks OJ

that helped....

RSB


This error typically occurs when the format file has a wrong definition
(i.e. assigning the wrong column position).
e.g.
create table t(i int identity, c1 varchar(10), c2 varchar(20))
go
/* --txt.txt
abc def
*/
/* --fmt.fmt
8.0
2
1 SQLCHAR 0 10 "\t" 2 c1 ""
2 SQLCHAR 0 10 "\r\n" 4 c2 ""
*/
/* --result
C:\>bcp "northwind..t" in "txt.txt" -f"fmt.fmt" -T
SQLState = S1002, NativeError = 0
Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index
*/

If you fix line#2 in this format file by changing 4->3, the error would go
away.

--
-oj
RAC v2.1 & QALite!
http://www.rac4sql.net


Quote:> Hi Everyone,

> i was using the following bcp command in the past and it was working and
> today as there was a change in our data file so i end up changing the
table
> and the format file. and once i ran it i am getting this error "Invalid
> Descriptor Index" and i am not able to resolve it..

> any help?

> here is the command and the Error message...

> bcp myTable in ..\..\upload\mydataFile -f ..\format\myFormatfile.fmt -e
> ..\..\logs\bcp\mylog.bcp -F 1 -U myuser -S myserver -P mypass -a 8192

> SQLState = S1002, NativeError = 0

> Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index

> please help

> Thanks

> RSB

 
 
 

1. BCP: --- Invalid Descriptor Index Error ... need help

Hi Everyone,
i was using the following bcp command in the past and it was working and
today as there was a change in our data file so i end up changing the table
and the format file. and once i ran it i am getting this error  "Invalid
Descriptor Index" and i am not able to resolve it..

any help?

here is the command and the Error message...

bcp myTable in ..\..\upload\mydataFile -f ..\format\myFormatfile.fmt -e
..\..\logs\bcp\mylog.bcp -F 1 -U myuser -S myserver -P mypass -a 8192

SQLState = S1002, NativeError = 0
Error = [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index

please help

Thanks

RSB

2. BCP utility to copy data

3. [ODBC SQL Server Driver]Invalid Descriptor Index ERROR

4. Remote Backup Failing

5. Invalid Descriptor Index error

6. DTS Library difference between SQL 7 and SQL 2000

7. Error - Invalid descriptor index

8. ct-lib 10.0.2 with MS SQL Server

9. Making a new Index: Invalid Index Descriptor (CDX)

10. Please help - invalid descriptor index

11. Invalid descriptor index

12. Invalid Descriptor Index

13. Invalid Descriptor Index exception