Freek's Blog

SQL en .NET vraagstukken en oplossingen die ik zoal tegenkom
posts - 199, comments - 123, trackbacks - 2, articles - 7

My Links

News

Google analytics script: Locations of visitors to this page

Article Categories

Archives

Post Categories

Image Galleries

Algemene links

MSDN

vb links

t-sql: avoiding problems when using a MSDAQL query

Posted on Wednesday, July 07, 2010 10:05 AM

Running my query gives the next error statement.

The expected data length is 5, while the returned data length is 1

or in other words

'MSDASQL' returned an unexpected data length for the fixed-length column

By using: DBCC TRACEON(8765)
As first line in my query was the solution.
Don't know why but it works!!

Example:

DBCC TRACEON(8765)
Select * from openquery(Transoft, ' select field1, field2  from table)


Transsoft = driver I use

 

 

Post Comment

Title  
Name  
Url
Comment   

ATTENTION: the code you need to copy is CaSe SeNsItIvE and is required to prevent spam.
Enter the code you see: