Need SharePoint query to find folder

Hi All,

I have a scenario, i have a SharePoint folder and i need to check for specific sub folder is available or not in that folder. I will be having more than 200+ sub folders.
I’m using graph API activities. When I use find files and folders it’s returning 200 sub folders and it’s skipping rest of those.
Can anyone help what will be better solution for this.
If query will help to solve this. Can anyone please provide me the query for this or related documentation.

@Learner007

In the sub folder give the path till where you have the required folder

And in query give the name you want to search…then it will giv eonly that folder

Subfolder - "Folder1/Folder2"
Query - "folderName"

Cheers

Hi @Anil_G can you share me the sample query. I have tried something but getting error.

@Anil_G

GET https://graph.microsoft.com/v1.0/sites/{site-id}/drives/Documents/root:/General/Test:/children?$select=myfoldernamegiven,folder

When i use this getting error.
I’m using this query in get files and folders activity

@Learner007

Can you please show the screenshot of the activity

Are you not using find files and folders activity?

cheers

Hi @Anil_G I’m using this activity and in query section I’m writing the above mentioned code.

@Learner007

you just need to write the values nothing else is needed

If you want to search for folder FolderName then just give the name in query

cheers

Ok @Anil_G let me try that.

1 Like

@Anil_G this is giving me null or giving all related folders and it’s not giving me the specified folder

@Learner007

Can you please shwo the properties of find files

cheers

@Learner007

Please give "General/Test" and I hope Ra is available in the folder name

cheers

@Anil_G it’s not working. It’s returning 0 as output. My given folder is available and I’m copying Name from SharePoint only.

Hi @Anil_G i understood one thing. If my given file is in before 200th folder the query which we have used it is working. If it’s after 200,th folder it’s giving 0 as output. Do we have any alternate solution for this.
This find files and folders activity having limitation of getting only 200 folders

@Learner007

Okay…so please try with this activity

https://docs.uipath.com/activities/other/latest/productivity/office365-for-each-file-folder

This has simple search in which you can give only name again and folder with all folders just as previous one

Cheers

@Anil_G I’m trying this. Will update you if it works.

1 Like

Hi @Anil_G am i using this correctly because I’m not getting any output with this.


@Learner007

in simple search field give the folder name you need

cheers