Skip to main content

Notifications

Calling Actions from Copilot Studio
Unanswered

Using Dataverse table to give me how many 'products' a user has via phone input

Posted on by 13

Whoever thought of Oquery and Dataverse connections on Power Automate needs to be fired from Microsoft. Its just such a headache to do simple things. 

OK: I want for a user to be able to go on PVA and say they have an issue with their product. We have THREE products. The idea of the flow would be 

Ask user for their phone number: 

After the input the system should look in the table and look for the user's Product (on the Table as 'Traps'). Table will look like this,: 
trapping.PNG

 

 So if the user looks up: 44444444 their number, then I want it to give me the value of the 'Traps' column. After this if (its a multiple choice list) user has more than one trap I would then do a condition in PVA to ask which one their having issues with. 

My problem is I can't figure out how to use a phone to get the value from the traps column. I've read Microsoft articles and seen videos but no one quite explains it correctly that doesn't leave me confused and stuck. 

 

Categories:
  • Redbird Profile Picture
    Redbird 23 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    Maybe the transform between the array length (number) and the returned traps (text), is failing?

  • Pstork1 Profile Picture
    Pstork1 1,997 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    From your screenshot this is the action that returns a value to the bot.

    image.png

    The right side of the action is blank.  That will return a null value to the bot.  You need to add some dynamic content to the action to actually return a value to the bot.

  • InsectMan Profile Picture
    InsectMan 13 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    What do you mean there isn't a return value? What exactly on the flow isn't correct? I'm confused. The action is for Phone Tex to get the value from Phone in the table and output the value of the Traps? Am I missing something? 

  • Pstork1 Profile Picture
    Pstork1 1,997 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    The screenshot of the flow you posted doesn't actually return a value.  The field you return isn't filled in.  That would cause this kind of error.

  • InsectMan Profile Picture
    InsectMan 13 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    Any one can give me help on why i'm getting this error?

  • InsectMan Profile Picture
    InsectMan 13 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    Well I have to be doing something else wrong because the bot itself gives me an error 

    notright.PNG

  • Pstork1 Profile Picture
    Pstork1 1,997 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    You're close.  The point of using the First() function is to avoid having it stick an apply to each loop around the output.  But you have to insert the function using the expressions tab in the dynamic content dialog.  You can't just type it in.  Add a Compose right after the List rows action.  Then use the dynamic content dialog to insert First function around the value from the list rows.  

  • InsectMan Profile Picture
    InsectMan 13 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    Hey Pstork1,

    I really appreciate the help and sorry if I'm frustrating with my lack of knowledge. I'm working on it! 

    PVA1.pngPVA2.png

  • Pstork1 Profile Picture
    Pstork1 1,997 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    Can you show a screenshot of the flow you are using?  Then I can give you a better idea of where to insert the actions.  But to provide some context.

    • List rows is an action that will output an array of 0, 1 or more records. 
    • You need a property of one record, not the array. So you can use a Compose action after the list rows to isolate the first record of the array returned by list rows. 
  • InsectMan Profile Picture
    InsectMan 13 on at
    Re: Using Dataverse table to give me how many 'products' a user has via phone input

    Where would I put that? You're steps arent really telling me where to put anything, just to put first() and get trap array. I have no idea what you're asking me to do. Where would I put this compose action? In the List rows advance options? Is there a link I can get something that breaks it down better? 

     

Helpful resources

Quick Links

Exciting News for Copilot Studio Communi…

Get ready to experience a whole new level of engagement with the Copilot Studio…

Celebrating the May Super User of the…

LaurensM is an exceptional contributor to the Power Platform Community…

Check out the Copilot Studio Cookbook…

We are excited to announce our new Copilot Cookbook Gallery in the Community…

Leaderboard

#1
renatoromao Profile Picture

renatoromao 6,459

#2
Pstork1 Profile Picture

Pstork1 1,997

#3
Expiscornovus Profile Picture

Expiscornovus 1,708

Leaderboard

Featured topics