How to cancel an async DataExportToFile operation

Srikanth Kandula 0 Reputation points Microsoft Employee
2024-01-23T18:28:14.7+00:00

I started an operation using the syntax below. How do I cancel it? I've tried .cancel operation <operationid> but get the error message that DataExportToFile is not amenable to cancellation.

.export async to csv(
h@"<target url>;blob_access_key ")
with (
    sizeLimit=1000000000
    ,namePrefix=<tafget file name>
    ,includeHeaders=all
    ,encoding =UTF8NoBOM
    ,distributed=false
)<| <kusto_script>
Azure Data Explorer
Azure Data Explorer
An Azure data analytics service for real-time analysis on large volumes of data streaming from sources including applications, websites, and internet of things devices.
501 questions
{count} votes

1 answer

Sort by: Most helpful
  1. ShaikMaheer-MSFT 38,321 Reputation points Microsoft Employee
    2024-01-24T09:19:09.04+00:00

    Hi Srikanth Kandula, Thank you for posting query in Microsoft Q&A Platform.

    To cancel a long-running operation, you can use the .cancel operation command. However, this command is only supported for ingest from query commands, and not for canceling any other commands.

    Since you mentioned that you are using the DataExportToFile command, it is not amenable to cancellation <sup>1</sup>. Unfortunately, there is no way to cancel this operation once it has started. You will have to wait for the operation to complete or fail before you can perform any other actions. I hope this helps. Let me know if you have any other questions!


    Please consider hitting Accept Answer button. Accepted answers help community as well. Thank you.