Hey there folks--
So I was able to accomplish part 1 of what I need to do via this thread., but now I would like to write an image back into a Blob field in the backend table. From what little I've learned about ADO and OLEDB in the past couple hours, I have the following code so far..
on the "Value = FILETOSTR(...)" line, I get a "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if availble. No work was done..." error.
i'm not ashamed to say that I have no idea what that means.. is this the way to write an image into a blob field? or is there some other technique i haven't found yet?
any help is appreciated.
thanks
--frank~
So I was able to accomplish part 1 of what I need to do via this thread., but now I would like to write an image back into a Blob field in the backend table. From what little I've learned about ADO and OLEDB in the past couple hours, I have the following code so far..
Code:
LOCAL loc as ADODB.Connection, loRS as ADODB.RecordSet
loc = CREATEOBJECT('adodb.connection')
loRS = CREATEOBJECT('adodb.recordset')
loc.ConnectionString = "Provider=Advantage OLE DB Provider; Data Source=c:\localalta; ServerType=ADS_LOCAL_SERVER"
loc.Open()
loRS.Open("SELECT * FROM data23 WHERE [patient] = 'TEST000001'",loc,1,3,1)
IF loRS.Fields("patient").Value == 'TEST000001'
loRS.Fields("picture").Value = FILETOSTR("temp.jpg")
loRS.Update()
ELSE
=MESSAGEBOX('not found')
ENDIF
lors.Close
loc.Close
RELEASE lors, loc
on the "Value = FILETOSTR(...)" line, I get a "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if availble. No work was done..." error.
i'm not ashamed to say that I have no idea what that means.. is this the way to write an image into a blob field? or is there some other technique i haven't found yet?
any help is appreciated.
thanks
--frank~