CA Service Management

  • 1.  Data Partition Query on Call_Req

    Posted Nov 03, 2016 02:01 AM

    Hi Team,

     

    I am working on creating data partition constraints. Recently I created a constraint in which I restricted the ticket view based on the location of customer using the following query:

    customer.location=@root.location

    After this, the user is able to see the tickets where the location of customer is same as user.

    It is working fine.

     

    Now I want to create the constraint in which the user is able to see the tickets belonging to all the locations of customers in his site.

     

    What will be the query for this constraint? Kindly suggest.

     

    Thanks & Regards,

    Balram Singh Deswal



  • 2.  Re: Data Partition Query on Call_Req

    Posted Nov 03, 2016 02:42 AM

    Hi, have you tried

    customer.location.site = @root.location.site



  • 3.  Re: Data Partition Query on Call_Req

    Posted Nov 03, 2016 02:51 AM

    Hi Gutis,

     

    Thanks for your response.

     

    Yes I have tried it. It is giving the following error during save:

    AHD05800:Bad where clause. invalid constraint. Check data types of referenced attributes

     

    Regards,

    Balram



  • 4.  Re: Data Partition Query on Call_Req

    Posted Nov 03, 2016 05:12 AM

    HI.

    I think this is not possible. The @root syntax only support direct attribute names of the logged in user, but not any srel references, like in @root.location.site.

    One possible solution, which I used in the past, is to replicate the site value of the referenced location into a customized attribute of the contact record, lets say "zloc_site SREL site;".

    It is relatively easy to implement a mechanism ,which, whenever the location of a contact gets changed, replicates the site value of the new location into the contact records zloc_site attribute.

    A bit more is to be done , to handle the case ,that,  whenever the site of a location gets changed, alle contacts of this location gets updated with the new site value.

    I think enhacing this capability, so  that @root references can also use joins,would be a perfect idea. I'll create one....

    Regards

    .............Michael



  • 5.  Re: Data Partition Query on Call_Req