Forum Discussion

AbbasG's avatar
AbbasG
Icon for Memorable Member rankMemorable Member
4 years ago
Solved

Cannot Convert value of type text to type true false (While setting up rls)

Hello there,

 

I have a sales report, wherein I have defined RLS for each salesperson.

 

Now, One of the salespeople is on leave, and I want to give access to his report to another salesperson.

 

I am trying to revise the RLS as below

 

[Salesperson_Code] = "AB" && [Salesperson_Code] = "AS"

 

But then it shows the below error. Please help in fixing it.

 

 

  • Hello AbbasG

    Can the salespeson have two codes at same time? 

    could be an OR ? 

    [Salesperson_Code] = "AB"  ||  [Salesperson_Code] = "AS" 

     

    Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! ;-
    Best Regards
    BC

  • Hi AbbasG !

     

    I'm not sure if this is correlated but [Salesperson_Code] can't be two values at once.

    I believe it has to be:

    [Salesperson_Code] = "AB" || [Salesperson_Code] = "AS"

     Does this solve the issue?

     

    If not than could you give us the type of of [Salesperson_Code]?

     

    Kind regards,

    OD

5 Replies

  • onurbmiguel_'s avatar
    onurbmiguel_
    Icon for Power Participant rankPower Participant

    Hello AbbasG

    Can the salespeson have two codes at same time? 

    could be an OR ? 

    [Salesperson_Code] = "AB"  ||  [Salesperson_Code] = "AS" 

     

    Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! ;-
    Best Regards
    BC

      • onurbmiguel_'s avatar
        onurbmiguel_
        Icon for Power Participant rankPower Participant

        Hi again

        Can you also accept my answer , i send you first the solution.

         

        BR 

        Bruno 

  • Hi AbbasG !

     

    I'm not sure if this is correlated but [Salesperson_Code] can't be two values at once.

    I believe it has to be:

    [Salesperson_Code] = "AB" || [Salesperson_Code] = "AS"

     Does this solve the issue?

     

    If not than could you give us the type of of [Salesperson_Code]?

     

    Kind regards,

    OD