Skip to main content
Question

Deleted record but related records still have a reference to it

  • October 5, 2017
  • 0 replies
  • 95 views

Hi,

I have two tables "A" and "B" where "A" has a field that is a numeric reference to "B". 

I have an "A" record, "a", that contains a reference to a "B" record, "b", but when I delete "b", "a" still contains the id of "b" in the reference field when I do a query on "a" (e.g. via API_GetRecordInfo).  However, "a" appears correct via the web interface and doesn't display a reference to "b" at all.

I was wondering if this is expected behavior?  I also noticed that "a" didn't get an updated update_id after I deleted "b".  Is there any way for changes like this to automatically propagate to related records?

Thanks!
This topic has been closed for replies.

  • Quickbase Alumni
  • October 5, 2017
QuickBase does not support "Cascade Delete" behavior so this is the expected behavior. But it would not be difficult to implement this behavior in script with or without using a Service Worker (there are two entirely different solutions one of which would use a SW). Either way automatically deleting records might cause other issues if the records in question had yet other relationships to other tables.

  • Quickbase Alumni
  • October 5, 2017
What is the reason you are using the API to see if record B has a number in the reference field?

If you are looking to find connected or not connected values for some query?  If so, and that the GetRecordInfo is causing issues.  You can use a lookup field from the relationship that is always populated to filter your results.