Select to view content in your preferred language

"The operation is not supported by this implementation" error in CoreHost

1784
3
Jump to solution
10-31-2023 10:48 AM
KonstantinKorchakov
Occasional Contributor

Hello! I am observing strange behavior of Pro SDK when running CoreHost application. The application worked before but one day started throwing an error "The operation is not supported by this implementation" on table.DeleteRows() function. Here is a simplified version of the app:

 

try
{
    Host.Initialize();
    ArcGISSignOn.Instance.SignInWithCredentials(new Uri("https://server.com/portal"), "user", "password", out string refer, out string token);

    string fsUrl = "https://server.com/server/rest/services/FS01/FeatureServer";
    using (Geodatabase gdb = new Geodatabase(new ServiceConnectionProperties(new Uri(fsUrl))))
    {
        gdb.ApplyEdits(() =>
        {
            using (Table table = gdb.OpenDataset<Table>("L1Lines"))
            {                            
                string whereclause = "versionid = 347";
                table.DeleteRows(new QueryFilter() { WhereClause = whereclause });
            }
        });
    }
}
catch (Exception ex)
{
    Console.WriteLine(ex);
}

Console.WriteLine("Finished");

 

And this what the error looks like:

System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
ArcGIS.Core.Data.Exceptions.GeodatabaseGeneralException: The operation is not supported by this implementation.
System.Runtime.InteropServices.COMException (0x80040203): A syntax error occurred trying to evaluate a query string (0x80040203)
at ArcGIS.Core.Internal.ITableIOP.Table_DeleteRows(IntPtr tableHandle, IntPtr filterHandle)
at ArcGIS.Core.Data.Table.DeleteRows(QueryFilter queryFilter)

Query string is valid, I can run rowcursor with this query with no issue.

I assume something has changed in the environment, i.e. Windows update, or local credentials cache got expired, or domain policy applied, etc.. but I am just guessing really because I don't know what exactly has changed. Thing is, it is a third server that suffered from the issue, previously we would just move application to another server but this time it is my dev box and I would like to figure out how to fix it going forward in case it happens again. All three servers behaved in the same manner - application runs on schedule multiple times a day for months but one day the application starts throwing the error. We observed it with Pro version 2.9 before, and now in Pro 3.1. When application copy-pasted to another machine it works.

Things that did not help so far: reinstalling Pro, running as admin, extending app folder and Pro/bin folder permissions, adding Pro/bin/ to PATH.

I know it is probably a shot in the dark but any ideas are appreciated.

Thanks!

0 Kudos
1 Solution

Accepted Solutions
KonstantinKorchakov
Occasional Contributor

I figured it out, deleted the garbage from C:\Users\<username>\AppData\Local\Temp folder and application works again.

View solution in original post

3 Replies
KonstantinKorchakov
Occasional Contributor

I figured it out, deleted the garbage from C:\Users\<username>\AppData\Local\Temp folder and application works again.

MetralAlexis
Regular Contributor

My good, thank you thank you thank you Konstantin. I had exactly the same issue and wasn't expecting to find a solution here. I'll add a piece of code to flush that folder when running my script.

0 Kudos
BWest_DOT
New Contributor

Life saver - I was having the exact same issue and this fixed everything. Thank you for following-up with the solution you found to your own problem!

Have not run into this issue previously. Running ArcGIS Pro 3.2 and it seems to have a fair share of idiosyncrasies I hope are fixed in 3.3. 

0 Kudos