Subject Re: Binary columns
From Boris Borzic <bb>
Date Mon, 1 Apr 2019 16:02:24 +0200
Newsgroups sqlexpress

Raffaele Lafratta <raffaele.lafratta@gmail.com> wrote in
news:6208jopz8qoknal.310320192246@daz17:

> I use a prepared statement to insert into a sql server table
>
> oStmt:New("INSERT INTO MYTABLE NAME,UUID VALUES (?,?)"
> oStmt:prepare()
>
> .....
>
> cBin:=UUIdCreate()
> oStmt:Execute ( {"Raf", cBin} )
>
> UUID is binary
>
> The execute fails with "implicit conversion from char to binary is not
> allowed. Use CONVERT function

You need to pass the UUID value as an SQLValue object where
SQLType = SQL_BINARY

--
Best regards,
Boris Borzic

http://xb2.net
http://sqlexpress.net
industrial strength Xbase++ development tools

Recent messages in this thread
 
-# Binary columns Raffaele Lafratta 31-Mar-2019 09:46 pm
.-# Re: Binary columns (Current message) Boris Borzic <bb> 01-Apr-2019 03:02 pm
..\# Re: Binary columns Raffaele Lafratta 01-Apr-2019 04:55 pm