freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Ian Ashley <iashley AT picdar.com>
- To: FreeTDS Mailing List <freetds AT lists.ibiblio.org>
- Subject: [freetds] Binary columns problem
- Date: Wed, 06 Oct 2004 09:23:30 +0100
I am having a problem updating binary fields using SQLBindParameter. I use
the following code
char buf[6] = "\x12\x34\x56\x78\x90"
SQLPrepare(stmtHandle, ³UPDATE P_SIMPLE SET P_BINARY = ? WHERE P__URN = 1²,
SQL_NTS)
SQLBindParameter(stmtHandle, 1, SQL_PARAM_INPUT, SQL_C_BINARY, SQL_BINARY,
5, 0, buf, 0, NULL)
SQLExecute(stmtHandle)
Only the first byte of the value at buf gets stored, the remaining 4 get set
to 0.
Again any ideas. I have tried using the BufferLength and StrLen_or_IndPtr
parameters to no avail.
Thanks in advance,
Ian
-
[freetds] Binary columns problem,
Ian Ashley, 10/06/2004
- <Possible follow-up(s)>
-
RE: [freetds] Binary columns problem,
ZIGLIO, Frediano, VF-IT, 10/06/2004
- Re: [freetds] Binary columns problem, Ian Ashley, 10/06/2004
- Re: [freetds] Binary columns problem, Ian Ashley, 10/06/2004
Archive powered by MHonArc 2.6.24.