8000 searchWithQ() returning "General exception while processing" · Issue #1674 · microsoftgraph/msgraph-sdk-php · GitHub
[go: up one dir, main page]

Skip to content

searchWithQ() returning "General exception while processing" #1674

@r3ganbr0wn

Description

@r3ganbr0wn

I am trying to use the search for DriveItems within a SharePoint drive using the searchWithQ() method of this msgraph-sdk-php package.

$filename = "File_1.txt";
$result = $graphServiceClient->drives()->byDriveId('insert-drive-id-here')->items()->byDriveItemId('child-driveitem-id-here')->searchWithQ($filename)->get()->wait();

The library is returning an ApiException with message "General exception while processing". I cannot find any examples of how to search for DriveItems using this searchWithQ() method, and the Microsoft Graph official example looks incomplete:

<?php
use Microsoft\Graph\GraphServiceClient;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$result = $graphServiceClient->drives()->byDriveId('drive-id')->items()->byDriveItemId('driveItem-id')->searchWithQ('{q}', )->get()->wait();

Is there an official working example of the searchWithQ() functionality?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0