Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

"if else if" like condition in data formula in Scribe

Posted on by 13,756

Hi Experts, 

I hope we have many scribe experts here in the community.

I am very new to Scribe - i am in a situation where i have to check three field values which can either be 0 or 1 or null. if all source fields are "0" i have to set target to "0", if all are "1" i have to set target to "1". otherwise if any field is null or not matching is criteria it has to be null.

 

I am able to check something like below :

IF(AND(S1=0, S2=0,S3=0),"0","")

 

but how do it check other value from these fields? Like and IF , Else IF condition? 

your help is much appreciated.

*This post is locked for comments

  • NK Bhairi Profile Picture
    NK Bhairi 240 on at
    RE: "if else if" like condition in data formula in Scribe

    Hi,

    Just wondering if this is right approach,

    I am trying to set an optionset(State) value based on other optionsetvalue(Country)

    If Country is 77 set state as 18 else if country is 3 set state as 180 else null

    IF((S1=77),18,IF((S1=3),180,null)).

    This is failing with error incorrect number of function parameters, incorrect function parameter type. Any help with this?

  • RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: "if else if" like condition in data formula in Scribe

    Do confirm if it works.

  • Rawish Kumar Profile Picture
    Rawish Kumar 13,756 on at
    RE: "if else if" like condition in data formula in Scribe

    Hi Ravi,

    Wow. I have entered this formula and scribe didn't complain about anything. Looks like its going to work :)

    Marked as verified for now. Thanks for your help.

  • Verified answer
    RaviKashyap Profile Picture
    RaviKashyap 55,410 on at
    RE: "if else if" like condition in data formula in Scribe

    Hi Rawish,

    I have tried this but may be this would work-

    IF(AND(S1=0, S2=0,S3=0),"0",IF(AND(S1=1, S2=1,S3=1),"1",null))

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,253 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,188 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans