SQLBindParameter with a hexadecimal containing one '00' like x'420000F3'

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pooloo
    New Member
    • Mar 2014
    • 1

    SQLBindParameter with a hexadecimal containing one '00' like x'420000F3'

    Issue is the '00' in the hexadecimal input value, because in the input it is consider like a end of line, even if the buffer size is 8 only the 42 is written in the DB.

    char* hexaValue= new char[9];
    strcpy(hexaValu e, "420000F3") ;


    cliRC = SQLBindParamete r(statementHand le, 1, SQL_PARAM_INPUT , SQL_C_DEFAULT, SQL_VARCHAR, 8, 0, hexaValue, 0, NULL);

    what are the proper option to end up with x'420000F3' written in the DB not just x'42'
Working...