cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
SzymonBochniak
Frequent Visitor

SharePoint Get Items problem with Site address in Variable

Hello,

 

I'm using SharePoint Get Items action to retrieve data from another SharePoint list using ODATA Filtering.

 

Action works perfectly well in the case of the manual setup of Site Address and List name.

In case I will use Variable - String - containing the same site address I receive the error:

 

Error.jpg

 

There's a problem

Cannot evaluate the parameter 'path.$.dataset' at design-time; it is empty or has a runtime expression.

 

Maybe you can advise if this is a bug, or I need to use a different format of the data.

 

9 REPLIES 9
ArchitectMadhan
Super User
Super User

Hi @SzymonBochniak ,

I have created a variable that has the SharePoint List name in it and its assigned to the SharePoint Get Items action properties, its working fine for me. In the variable the formula used is : string('Task Tracker').

ArchitectMadhan_1-1627307835079.png

 

Here is the Flow history showing successful execution.

ArchitectMadhan_2-1627307984182.png

 

If you find my solution helpful for resolving the issue, then please consider giving thumbs up and Accept it as the solution to help the other members find it more quickly.

- Architect Madhan

Please click the "Accept as Solution" button and give thumbs up, if it is helpful to you.

@ArchitectMadhan In your case, you did choose a site from the dropdown. I'm trying also to set the site using Variable. I checked your solution it does not work. Same error.

2021-07-26_16h18_37.jpg

In my scenario, both parameters Site Address and List Name should be set by Variable.

ArchitectMadhan
Super User
Super User

Hi @SzymonBochniak ,

 

Could you show how you are setting the SharePoint url in the variable as value .

 

 

- Architect Madhan

Please click the "Accept as Solution" button and give thumbs up, if it is helpful to you.

The address is to OneDrive space: https://COMPANY.sharepoint.com/personal/sbochniak_COMPANY

 

This format works perfectly well for the actions:

  • HTTP request to SharePoint
  • SharePoint Delete item
ArchitectMadhan
Super User
Super User

Hi @SzymonBochniak,

I think you are missing the string function while Initializing the variable. Its working for me with the variable used for storing the SharePoint URL also. Please use

string('https://COMPANY.sharepoint.com/personal/sbochniak_COMPANY') while initializing the variable.
 
ArchitectMadhan_1-1627311195759.png

 

ArchitectMadhan_0-1627311068075.png

If you find my solution helpful for resolving the issue, then please consider giving thumbs up and Accept it as the solution to help the other members find it more quickly.

- Architect Madhan

Please click the "Accept as Solution" button and give thumbs up, if it is helpful to you.

Nope. Adding the string function to the initialization of the variable does not change anything in my case.

 

But I'm testing it a different way. I'm setting the site address and try to retrieve the available lists and then I'm getting the error.

2021-07-26_17h00_05.jpg2021-07-26_17h01_20.jpg2021-07-26_17h01_50.jpg

 

Hi @SzymonBochniak ,

 

You are doing it in wrong way. Please use the expression builder and provide the url within the string function. Don't type the formula directly in the set variable value textbox. If you use the expression builder you will see the pink field with fx....

 

If you find my solution helpful for resolving the issue, then please consider giving thumbs up and Accept it as the solution to help the other members find it more quickly.

- Architect Madhan

Please click the "Accept as Solution" button and give thumbs up, if it is helpful to you.

@ArchitectMadhan thank for your support, but still the same error 😉

Hi @SzymonBochniak ,

I think you are trying to assign the Site URL variable in the place of SharePoint Site and tried to click the List name drop down, expecting to show the SharePoint Lists from that Site. If this is your expectation, it will not work because, During the design time with the Site URL variable it can not get the Site Context. So the solution is https://powerusers.microsoft.com/t5/General-Power-Automate/SharePoint-Get-Items-problem-with-Site-ad...

ArchitectMadhan_0-1627384754592.png

If you find my solution helpful for resolving the issue, then please consider giving thumbs up and Accept it as the solution to help the other members find it more quickly.

 

 

 

- Architect Madhan

Please click the "Accept as Solution" button and give thumbs up, if it is helpful to you.

Helpful resources

Announcements
Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Users online (3,236)