[email protected] wrote: > I just realized that I never before used updatable views where more than one > table needed to be updated. I now see that the joinable fields do not get > automatically filled (to maintain the JOIN). > > In the example below, I need to update all fields except 3: The two PKs (they > are AutoInc) and HsgUnit.fk_address (I won't know the value until > Address.pk_address gets auto-filled when a record is added to Address). > > SELECT Address.pk_address, (some ADDRESS fields), ; > Hsgunit.pk_hsgunit, Hsgunit.fk_address, (some HSGUNIT fields) ; > FROM LOCVIEW!ADDRESS ; > INNER JOIN LOCVIEW!HSGUNIT ON Address.pk_address = Hsgunit.fk_address > > Considering that the view is JOINed by the pk_adress-fk_address, I would have > expected HsgUnit.fk_address to get populated on save. > > What am I missing? > > Thx > > Henry
Try to avoid using a single view to update multiple tables via the native view means. The problem comes with the primary keys....if the view doesn't have a primary key for a table, how will it know which record(s) to update? You might have to resort to using explicit code to do the updates. -- Mike Babcock, MCP MB Software Solutions, LLC President, Chief Software Architect http://mbsoftwaresolutions.com http://fabmate.com http://twitter.com/mbabcock16 _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/[email protected] ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

