Skip to Content
avatar image
Former Member

Assignment

Hi,

I am working on Assignments.

I have to assign a value to a field based on taxonomy field.For eg: IF say category we have

Category

_Tools

_Hand Tools

_ Machine Tools

|_SERVICE

|_ Repair

|_ Maintenance

Now if Category is SERVICE then field S1 shud be Service item else no.

What can be the Assignment expression since SERVICE is a intermediate node

Regards

Nisha

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Jun 27, 2008 at 07:02 AM

    Hi,

    i am assuming Service Item is a value for your Field S1 of type text.

    you want for maintable record when you select category = SERVICE your field S1 get Populated with Service Item.

    It is achievable in two ways:

    1. using Attribute

    you need to associate(link) your Category SERVICE with Attribute of type Text having Name say S1 and in Attribute Detail Add Text Service Item.

    so in this way you dnt need to create extra field say S1 in you maintable, Evertime when you select category = SERVICE Attribute link with it S1 comes automatically in Record Detail from where you can select value Service Item

    2. using Assignments Create Assignment having anyname with Table Field Property = S1, in assignment expression write expression as:

    IF(FIND(Category.Name, "SERVICE"),"Service Item", "")

    Hope it will Help you,

    Please mark the Thread as Answered if your query solved....

    Mandeep Saini

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi,

      In this case SERVICE is not the leaf node .IT has two child node say repair & maintenance below it.

      Then there are two ways of doing it:

      you can write Assignment Expression as:

      IF(FIND(Category.Name, "repair") OR FIND(Category.Name, "maintenanace"),"Service Item", "")

      OR

      IF(FIND(Category..Name, "SERVICE"),"Service Item", "")

      Both the Assignments are working fine on my side.

      Please rewards for Helpful answers to motivate SDN Users.

      Hope it will Help you,

      Mandeep Saini