Hi,
I'm quite new to AwareIM so please bare with me if I oversee an obvious solution.
I'm having an object members and an object member category. One member category can have many members but a member can only belong to one category.
Currently all my relations work correctly.
I have a rule defined that says the age of a member is above 60, the member category should change to 'Senior Member'
I have defined the action as members.category.name = 'Senior Member'
When the rule executes I get an error stating that the category 'Senior Member' already exists.
How do I change the member category for this member from 'Normal Member' to 'Senior Member'
Thanks for any help.
Gert.[/i]
Newbie Help - Changing Relationships
-
- Posts: 7532
- Joined: Sun Apr 24, 2005 12:36 am
- Contact:
Yes indeed, I have a rule that checks the uniqueness of the category. I've studied the log and still cannot figure out what I am doing wrong.
As I understand it, my rule sets a new value to the member object. It just needs to link to another categorie. I am not updating the category object, so why does it execute the category uniqueness rule?
Am I doing something wrong or should I change the relationship in a different way?
Regards,
Gert.
As I understand it, my rule sets a new value to the member object. It just needs to link to another categorie. I am not updating the category object, so why does it execute the category uniqueness rule?
Am I doing something wrong or should I change the relationship in a different way?
Regards,
Gert.
The reason why your origianl rule did not work
According to your first post above, your original action was:
This code will update the name attribute in the current category object that is referenced in the members object. Since a category object already exists with the name attribute set to 'Senior Member', you got the "category 'Senior Member' already exists" error.
Code: Select all
members.category.name = 'Senior Member'
Bob