storing binary into a altSQLite DB
Christian Langers
christian.langers at education.lu
Sun Oct 15 14:26:56 EDT 2006
Thanks for your reply !
Hmm, I tried everything, but I always get an syntax error from the
database....
I tried this :
answer file ""
put "'"&"*b"&URL ("binfile:"&it)&"'" into tRowData
--> CONSTRUCT SQL
put "INSERT INTO Fotos(FotoID,FotoData)" &" VALUES(null," &
tRowData & ")" into tSQL
--> EXECUTE SQL
put revdb_execute(gConID,tSQL) into tTmp
handleRevDBerror tTmp
or
answer file ""
put "'"&URL ("binfile:"&it)&"'" into tRowData
--> CONSTRUCT SQL
put "INSERT INTO Fotos(FotoID,FotoData)" &" VALUES(null," &
tRowData & ")" into tSQL
--> EXECUTE SQL
put revdb_execute(gConID,tSQL, "*b"&"tRowData") into tTmp
handleRevDBerror tTmp
... and it always resulted in the syntax error...
Where is the problem ? I still can base64encode my data and then pass
it to the database, but this is not the way I would like to store
data...
Is there anything else I did not see or know ?
Thanks,
Christian L.
Le 15 oct. 06 à 17:05, Shao Sean a écrit :
> If you look in the documentation for "revDB_execute" you'll see
> that you need to add "*b" as the first 2 characters of your binary
> data..
>
More information about the use-livecode
mailing list