Marco Bambini replied:

You can do something like this:

Dim rs as Recordset = myDB.SQLSelect("SELECT * FROM xBlobs WHERE Docid='" + myID + "'")
...
rs.Edit
rs.BlobColumn("blob1") = updatedPic1
rs.BlobColumn("blob2") = updatedPic2
rs.Update
db.Commit

---
Marco Bambini
http://www.sqlabs.net
http://www.sqlabs.net/blog/

Hi Marco,

  thanks for your answer.
  I experimented  with  what you suggested with no success.
  The compiler complains that there is no such Method or Property.

  Any other suggestion?

  Cheers,
  Peter
  TI PowerBook G4, 1GHz, 1GB RAM, OSX 10.3.9, RB2006r3 Pro


On Sep 16, 2006, at 6:30 AM, [EMAIL PROTECTED] wrote:

For all my database work I have been using SQL statements for inserting and updating records. This has served me well.

Now, besides lots of document records I need to handle picture files, mostly Jpegs. I try to avoid doing a EncodeBase64 of the picture and then storing it into a VarChar column. So - For this I have now BLOB columns. To create new records with BLOB data I am using the usual

     Dim rec As New DatabaseRecord
     rec.BlobColumn("blob1") = pic1
     rec.BlobColumn("blob2") = pic2
     myDB.InsertRecord ("xBlobs", rec)
     myDB.Commit

All this works OK. -- Now I need to update various BLOB fields in existing Records. Thus I cannot use the line myDB.InsertRecord ("xBlobs", rec) because this adds a new record.

   Question: How do I make updates using DatabaseRecords?

   I tried to bring the desired record into a Recordset like so:

dim rs as Recordset = myDB.SQLSelect("SELECT * FROM xBlobs WHERE Docid='" + myID + "'")
     rs.Edit

    Now, how do I link the DatabaseRecord rec to the active record in rs?

    Thanks for any help
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>


--

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to