VBinaryLink delete bug

Ernesto Giannotta ernestogiannotta at tiscalinet.it
Sun Jun 14 20:41:18 CDT 2009


Hi Ruslan,

I have a many to many Binary link set like this:

   //  make the link
   mCatNotesLink = new VBinaryLink("Link_Categories_Notes",  
mCategories, mNotes, EVLinkType.kMany, EVLinkType.kMany,  
EVOnDelete.kSetNull)

Now when I delete the last record in the mCategories table (which is  
the owner of the link) like this:

   dim SqlString as String

   SqlString = "Delete From " + me.Name
   SqlString = SqlString + " Where Recid = " + Str(inRecid)

   Call me.Database.SqlExecute(SqlString)

also all the linked records of the mNotes table are deleted!

This happens only if I delete the last record of the owner table

Workaround is to unlink all records before deleting the last owner's  
record

I'll try to make a simple demo to submit via Mantis.


Cool Runnings,
Erne.


More information about the Valentina mailing list