You simply have to write code. In fact, it often turns out that despite
having RI enabled, you wind up writing a lot code anyway.
And, believe it not, there is a good number of developers that I respect
that do NOT rely on RI, but ALWAYS write their own code. And, further,
commercial products like the very popular simply accounting is actually a
ms-access file (you can open simply accounting fields with ms-access). So,
Simply Accounting while a ms-access file did NOT rely on RI..but actually
wrote their own code.
So, the simply answer is that a good many developers and commercial
products based on the ms-access format do indeed write their own RI.
An good example would be cascade deletes. I always written my own delete
routines (but, I do use RI and cascade deletes in my applications). However,
lets assume you have to roll your own delete code. You also of course has to
assume form level code. So, the code behind the button to delete the record
could be:
dim strSql as string
dim lngID as string
lngID = me.ContactID
strSql = "delete * from Contacts where Contactid = " & lngID
If MsgBox("Do you really want to delete this record" & vbCrLf & _
" (you can not un-do this operaton)", _
vbCritical + vbYesNo + vbDefaultButton2, "Delete record") =
vbYes Then
CurrentDb.Execute strSql
' now child reocrds
strSql = "delete * from tblInvoices where ContactID = " & lngID
CurrentDB.Execute strSql
DoCmd.Close acForm, Me.Name
end if