Altering account_id with Workflow Manager

I have created a person-to-contact-form with a hidden field (comp_id) that contains the account_id of a certain company.
This field is saved in contacts under comp_id.

With Workflow Manager I want to copy the comp_id to account_id in a way that the contact is now a member of the account.

For what I have seen until now, it is not possible to have the account_id immediately in the person-to-contact-form. I thought it was possible to make a many to many relationship between contacts:accounts, but it failed in my try-outs.

I have been trying for days now, but my trial-and-error learning is not working. Can anyone help me with a step-by-step, I have become to tired to think for myself at this point.

Working with SuiteCRM 8.8.0

Hi, welcome to the Community! :tada:

Have you tried simply naming the field account_id in the online form?

I am not sure it will work, but it’s worth a try.

Hello @ahofstede

that can be a bit special / tricky since it’s a related field.
However, your approach sounds correct.
The CRM will take an “ID as the account name” and relate the contact to the account.

This is working (I’ve used the description as parameter - you’d use your comp_id as parameter).

Check out my video on calculated fields for more details:

@pgr
I didn’t know that it is not working - just tried it as well (with account_id and the - from the form builder - available account_name, tested with name and ID).
So that workaround via the workflow is probably the easiest way to go.

1 Like

@pgr This was actually the first thing I tried. Didn’t work. But thank you for thinking with me on this “problem”.

Wow. This is the solution! I thought I had to do something in the relationships in Studio.
BTW I love the video’s, I have already seen many of them in the last couple of weeks, but missed out on this one.

Thank you so much for your help!

1 Like

Yeah i was about to say this as well, been thought it for days as well but eventually figured it out. can you mark Bastian answer as a Solution so if anyone encounters this thread finds a Solution faster. Also Bastian Videos helped me a lot through my journey, also recommend @pstevens Videos :smiley:
Wish you a Great Day

2 Likes