Article View: comp.sys.mac.databases
Article #29Re: 4th D File Relationships
From: ST25370
Date: Sun, 01 Nov 1992 17:34
Date: Sun, 01 Nov 1992 17:34
34 lines
1562 bytes
1562 bytes
In article <8ew_OQy00UhW88KlpV@andrew.cmu.edu> Jason Andrew Herman <jh62+@andrew.cmu.edu> writes: >Hello all: > >Normally when you set up an automatic relation between two files, 4th D >asks you in the middle of your parent layout if you want to create the >related field or try again. Now the question is, is there a way to have >4th D automatically make the new related file without prompting the >user?? > >Many thanks in advance, > >Jason Through code, yes. Make the relation manual, and execute: relate one ([File]Field]) if (records in selection([related file])=0) create record([related file]) /* insert values */ save record([related file]) end if from the object in question. Of course, this will require that you 'fix' all the code that depends on the automatic relation by executing the relate one or many whenever you need the relation active. You will also have to support the automatic lookup I assume you are using through code as well, but this is tedious rather than difficult. Bill Jamison rwj@engr.latech.edu st25370@vm.cc.latech.edu
Technical Details
Message-ID:
<16892A2BC.ST25370@VM.CC.LATECH.EDU>Path:
arc1-ca.pugleaf.net!sparky!uunet!ukma!darwin.sura.net!newshost.LaTech.edu!VM.CC.LATECH.EDU!ST25370References:
<8ew_OQy00UhW88KlpV@andrew.cmu.edu>Show Full Headers
Complete Article Headers
Newsgroups: comp.sys.mac.databases Path: arc1-ca.pugleaf.net!sparky!uunet!ukma!darwin.sura.net!newshost.LaTech.edu!VM.CC.LATECH.EDU!ST25370 From: ST25370@VM.CC.LATECH.EDU Subject: Re: 4th D File Relationships Message-ID: <16892A2BC.ST25370@VM.CC.LATECH.EDU> Sender: usenet@engr.latech.edu Nntp-Posting-Host: vm.cc.latech.edu Organization: Louisiana Tech University References: <8ew_OQy00UhW88KlpV@andrew.cmu.edu> Date: Sun, 01 Nov 92 11:34:12 CST Lines: 34