0

difference in the result when executing a script between a button and the action after updating a field

Hello,

we have a script execution problem when updating the field.

The script works fine when launched from a button, however the script doesn't work when activated by the update field action.

Have you had similar problems or is there a different logic when creating a script executable by button or by update of the field?

8 replies

null
    • Sean
    • 3 yrs ago
    • Reported - view

    Not all actions can be run in a trigger. What are you trying to do?

    • NICOLAS
    • 3 yrs ago
    • Reported - view

    Hello sean, thank you for your quick intervention :-)
    we use the "like" function to find an element in a text field

    Ex: in table 1 we want to find the field corresponding to the value "XYA" in a text field of table 2 "KOI - XYA - VYU".

    the term we are looking for is sometimes alone or in a random sequence

    • Sean
    • 3 yrs ago
    • Reported - view

    Hi Nicolas, I'm sorry I didn't see your response yesterday. Have you tried the contains() function? I don't use "like" in a query because it doesn't always return the result I expect. I'm not aware of a like() function, but considering the state of Ninox documentation that's unsurprising.

    • NICOLAS
    • 3 yrs ago
    • Reported - view

    thank you for this answer sean, i will try with this function 

    • yohan
    • 3 yrs ago
    • Reported - view

    Hi Sean

    I'm a colleague of Nicolas

    We are not using a like() function, but a SQL request :

    let v2 := first(select 'NATCODE / LISTE GLOBALE OPTION' where idporsche like v and nt = text(natcode));

     

    This is one is working on a button (on click)

    but not on a trigger in a field

     

    Thanks for your help

    • Sean
    • 3 yrs ago
    • Reported - view

    Hi Yohan,

    The only explanation I have for the field trigger not working is the information is not changing in the field where the trigger code is. If you can provide more information, I do what I can to help.

    • yohan
    • 3 yrs ago
    • Reported - view

    Sean

    Thank you for your response,

    can we exchange by mail for the code ?, i prefer not copy all the code on the forum

    Thank you

    • Sean
    • 3 yrs ago
    • Reported - view

    Yohan,

    You can send it to studiouschimp. It's a gmail account. I'll look at it when I get a chance.

Content aside

  • 3 yrs agoLast active
  • 8Replies
  • 799Views