Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 6251 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

That escapes me =(

Trying to have the contents of one field ( contactid) in a contacts db copied into the same field in db called products. According to the function reference guide, the function to use is the set field. The syntax for this is "Set field[ product::contactid; contacts::contactID]. Here is the problem... no issue with using the specify target field to create "set field[product::contactid" portion, but cannot figure out how to add the remaining portion (the value or formula according the function reference manual). This is probably too obvious but it is late at night. What am I overlooking?

TIA.

Jack

P.S. dbs are linked by a contact id relationship

Posted

I am afraid it won't work that way. Not because of your difficulty with Set Field[] step, but for another reason: when you move to the products table, the expression "contacts::contactID" refers to the first RELATED record in the contacts. But there is no related record in contacts yet - after all, the purpose of the script is to create such link.

The way to do this is to set a variable to the contactID value at the beginning of the script (while still in the contacts table). Then use Set Field[] to set the field in products to the variable.

BTW, I am puzzled why would you want to link products directly to contacts. Are these contacts the vendors/makers of the related products?

Posted

Comment,

See my previous posts in the forums (topic 188997) in regards in what I'm ultimately hoping to achieve. Based on Sorens generous help & comments, the appropriate method to find the necessary info has been determined. Fyi, I'm working on a copy of the FM BPS solution which contains 5 or so separate files (not optimum- aware it's based on an old version & not up to current DB practices/theory etc but still usable for my needs ;) ). I'm thinking that 1 problem resolution will solve the majority of my problems. That is: how to copy the contents of a clientID field from one file ("clients") & paste it into the clientID field in another file ("bookings"). I envision this will place any required related information (i.e. birthdate) from the "client" db into the appropriate field (i.e.birthdate) if there is a relationship between the 2 files based on the "clientId". I've tried via a script copying contents of "clientID" field from client db & pasting into the associated "client ID" field in the bookings db to no avail (the rest of the script works though). I know the relationship is fine;when I manually enter the clientID value from the client db into the clientID field in the booking db, any related fields are populated. Any thoughts on how to do this? (newbie terms please)

Your assistance is definitely appreciated.

Jack

This topic is 6251 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.