Hi,
I'm connecting to sqlServer with oledb or Odbc. The connection mode is optional .
When I try SqlSetParameterAll ( hcursor, DBP_LONGBUFFER , 3000000, '', TRUE ) the function return TRUE with ODBC AND FALSE with OLEDB
I'm making changes in my code for connect via ODBC or OLEDB. Some of my clients require OLDB connections.
All work fine except with this command.
For us is a no go situation. This statement is widely used throughout the code
Any suggestions?
Thanks
Enrique
SqlSetParameterAll with DBP_LONGBUFFER Not working on OLEDB connection with SqlServer
-
- Site Admin
- Posts: 313
- Joined: 05 Mar 2017, 20:57
- Location: Tauranga, New Zealand <--> Stroud, England
Re: SqlSetParameterAll with DBP_LONGBUFFER Not working on OLEDB connection with SqlServer
.
You don't need DBP_LONGBUFFER with SS OLEdB . That's why it fails - there's no such thing required.
The following test works just fine with OLEdB and Inserts as much as you can throw at it , but certainly truncates with ODBC :
With OLEdB , you just ignore the fact that SqlSetParameterAll() fails - or bypass it altogether.
You don't need DBP_LONGBUFFER with SS OLEdB . That's why it fails - there's no such thing required.
The following test works just fine with OLEdB and Inserts as much as you can throw at it , but certainly truncates with ODBC :
With OLEdB , you just ignore the fact that SqlSetParameterAll() fails - or bypass it altogether.
You do not have the required permissions to view the files attached to this post.
Greetings from New Zealand
Steve Leighton
Bankside Systems Ltd.
UK ♦ Australia ♦ New Zealand
www.banksidesystems.co.uk

Steve Leighton
Bankside Systems Ltd.
UK ♦ Australia ♦ New Zealand
www.banksidesystems.co.uk

Re: SqlSetParameterAll with DBP_LONGBUFFER Not working on OLEDB connection with SqlServer
Thanks Steeve. I just ignore the return whith OLEBD and works fine.
Kind regards.
Enrique
Kind regards.
Enrique
Who is online
Users browsing this forum: No registered users and 0 guests