Maximo

Maximo

Come for answers, stay for best practices. All we're missing is you.

 View Only
  • 1.  PUSH Notifications - Subscriptions - Use Conditión

    Posted 9 days ago

    We have a notification configured to be sent to SRMOBILE with the Apply To Condition value :OWNER IS NOT NULL.

    We want to send a push notification when the owner changes.

    Then we have several users subscribed to the notification, and we don't want to send this notification to all users. We only want the changed user to be sent, but we're trying to use the "User condition" field with these values, and nothing works.

    1. OWNER='T0003MX1'
    2. :OWNER='T0003MX1'
    3. OWNER=:&USERNAME&
    4. :OWNER=:&USERNAME&
    5. :OWNER
    6. We also entered the value of a conditional expression, and it had the previous values.

    I understand this can be done before creating as many notifications as we have users.



    ------------------------------
    Sergio Vela
    ------------------------------


  • 2.  RE: PUSH Notifications - Subscriptions - Use Conditión

    Posted 2 days ago

    Hmm,

    You're on the right track, I guess.

    I'd try using :OWNER = :&PERSONID& in the User Condition. OWNER usually stores the Person ID, not the login, so :&PERSONID& should match correctly. That way, only the new OWNER gets the push - no need to create a notification per user.



    ------------------------------
    Arthur G
    IS Engineer
    ------------------------------



  • 3.  RE: PUSH Notifications - Subscriptions - Use Conditión

    Posted 2 days ago
    Thank you very much for your response, Arthur. If you put this ":OWNER = :&PERSONID&" in the "User condition" field when assigning an owner, it gives this error:
    BMXAA3761E - The event has failed. Ensure that the event is registered correctly. See the log file in the APP HOME directory for more details about the error. null
    That's why, and if I put it as a conditional expression, the same thing happens.
    Does it work for you?


    ------------------------------
    Sergio Vela
    ------------------------------
    -------------------------------------------
    Mensaje original:
    Enviado: Wed June 25, 2025 05:38 AM
    De: Arthur G
    Sujeto: PUSH Notifications - Subscriptions - Use Conditión

    Hmm,

    You're on the right track, I guess.

    I'd try using :OWNER = :&PERSONID& in the User Condition. OWNER usually stores the Person ID, not the login, so :&PERSONID& should match correctly. That way, only the new OWNER gets the push - no need to create a notification per user.



    ------------------------------
    Arthur G
    IS Engineer



  • 4.  RE: PUSH Notifications - Subscriptions - Use Conditión

    Posted 2 days ago

    Thanks for the update, Sergio.

    I remember testing something similar for learning purposes, and I think I got OWNER = :&PERSONID& working - but honestly, I don't remember the exact syntax or setup that worked. It likely took a bit of trial and error with the condition formatting.

    I'd suggest experimenting a bit with small syntax changes (like with or without colons) and maybe verifying the logic first through a saved query to confirm how OWNER is stored.

    Let me know if you crack it - I'll also try to re-test it when I get a chance!



    ------------------------------
    Arthur G
    IS Engineer
    ------------------------------



  • 5.  RE: PUSH Notifications - Subscriptions - Use Conditión

    Posted 2 days ago

    I tried the following and it didn't work, so I just verified it.

    OWNER=:&USERNAME&
    :OWNER=:&USERNAME&
    OWNER=:&PERSONID&
    :OWNER=:&PERSONID&
    OWNER='USER_VALUE'
    :OWNER='USER_VALUE'

    Thank you very much for the help.



    ------------------------------
    Sergio Vela
    ------------------------------
    -------------------------------------------
    Mensaje original:
    Enviado: Wed June 25, 2025 07:39 AM
    De: Arthur G
    Sujeto: PUSH Notifications - Subscriptions - Use Conditión

    Thanks for the update, Sergio.

    I remember testing something similar for learning purposes, and I think I got OWNER = :&PERSONID& working - but honestly, I don't remember the exact syntax or setup that worked. It likely took a bit of trial and error with the condition formatting.

    I'd suggest experimenting a bit with small syntax changes (like with or without colons) and maybe verifying the logic first through a saved query to confirm how OWNER is stored.

    Let me know if you crack it - I'll also try to re-test it when I get a chance!



    ------------------------------
    Arthur G
    IS Engineer