I am a first time poster, but have been a reader of this forums for some time now. I have search the forums for a solution, and have found many solution to the issues I had, but I can't find a solution to this issue I am having:
I have a problem inserting an encrypted base64encode picture into a sqlite db:
The following was tested and it is working:
base64encode and base64decode of picture - works - picuture is shown in new img object.(SAME CARD, no db).
aes encryption and decryption of base64encode data - works - picuture is shown in new img object. (SAME CARD, no db).
insert command to db of only base64encoded data and select command from db of base64encode data, and the decode of it - works - picture is shown in new img object.
The issue can be with the insert or the select(decrypt and decode) of the data, and I don't know where to look anymore (including forums and other resources). I have used the *b for the insert of the encrypted data,
but can't decrypt and decode it into the img field.
Break down of code:
//Encode
put base64encode(url("binfile:" & "pathtopicture")) into id_image
//Encrypt
encrypt id_image using "aes256" with password tPassword and salt tSalt
put it into id_image
//Insert
revExecuteSQL tDatabaseID, "INSERT INTO cust_load (picture) VALUES (:1)","*bid_image" (have tried *bvariablename and only variable name)
//select and display
put "SELECT picture from cust_load" into tSQL
put revQueryDatabase(tDatabaseID, tSQL) into tCursorID
put revDatabaseColumnNamed(tCursorID, "picture", "tImageData") into tErrorMsg
put tImageData into field "enc_image" --put encrypted data into a field to show the encrypted data
decrypt tImageData using "aes256" with password tPassword and salt tSalt -- decrypting the data
put it into test
put test into field "base64code" -- put the decrypted data into a field (should be the base64encoded data)
put base64decode(tImageData) into img "picture" --decode the data and put into image object
Please help!!!

Thank so far for all the tips, tricks and solutions on this Forum.