Anh_Tran Posted September 12, 2002 Posted September 12, 2002 Dear All, I have a big problems which I could not figure out. I have 2 database Number One ( A) and number Two ( in A , I have Year (Text) : nil, No. (text) : 12 . Unique key : nil12 In B, I have YearB( Text): nil, No.B(text) :12 Unique key: YearB & No.B So when I go from A to B , I create a record in B, so Unique key in B will be nil12 So when I change in A Year: 12 and no. = 12 so it will go to B and change B as unique key Year : 12 and No.B = 12 When I duplicate in A as Year = 12 and No. = 12 , I would like to duplicate in B also as YearB = 12 and No.B = 12 when I change in A No. = 20 ..so Unique key will be : 1220 How can I go to related B as unique key will be : 1220 ( a duplicate of 1212) Somebody could help me with this. If I am not too clear about this I will write more or I could call you to explain more. When you duplicate one record and change unique key ...can it go to the same related record with the same unique key from the first database? Thanks for your help.
LiveOak Posted September 12, 2002 Posted September 12, 2002 Most of that went by me. If you are trying to create a script in File B that will create a new record and set it's key to the key of the current record in File A, this is one approach: Create fields in File A: gKeyTemp (global, text) One (calculation, number, indexed) = 1 Create a field in File B: One (calculation, number, indexed) = 1 Create a relationship in File B to File A, call it "ConstRel", with One <---> One. New Record Script in File A: Set Field(gKeyTemp, FileAKey) Perform Script(external, File B, New Record) New Record Script in File B: New Record/Request SetField(Key, ConstRel::gKeyTemp) I don't like the Duplicate Record approach, what if there are no related records in File B? If there is so much data to be duplicated from record to records in B, it should be stored in another related file. -bd
Recommended Posts
This topic is 8177 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now