Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to define array dynamic within local datatable in Kusto kernel #3729

Open
3 of 17 tasks
pshelton-skype opened this issue Oct 27, 2024 · 0 comments
Open
3 of 17 tasks
Labels
Area-SQL / data querying bug Something isn't working

Comments

@pshelton-skype
Copy link

Describe the bug

Running the following code in a Kusto kernel results in

let x = datatable(column1:string, column2:dynamic) 
[ 
  '1', '[1]',
  '2', '[2]'
];
x
Error: StreamJsonRpc.RemoteInvocationException: SQL Execution error: A fatal error occurred.
Incorrect syntax was encountered while [
'1', '[1]',
'2', '[2]'
];
x
was being parsed.
at StreamJsonRpc.JsonRpc.InvokeCoreAsync[TResult](RequestId id, String targetName, IReadOnlyList`1 arguments, IReadOnlyList`1 positionalArgumentDeclaredTypes, IReadOnlyDictionary`2 namedArgumentDeclaredTypes, CancellationToken cancellationToken, Boolean isParameterObject)
at Microsoft.DotNet.Interactive.SqlServer.ToolsServiceClient.ExecuteQueryStringAsync(Uri ownerUri, String queryString, CancellationToken contextCancellationToken)
at Microsoft.DotNet.Interactive.SqlServer.ToolsServiceKernel.Microsoft.DotNet.Interactive.IKernelCommandHandler<Microsoft.DotNet.Interactive.Commands.SubmitCode>.HandleAsync(SubmitCode command, KernelInvocationContext context)
at Microsoft.DotNet.Interactive.Kernel.HandleAsync(KernelCommand command, KernelInvocationContext context) in D:\a\_work\1\s\src\Microsoft.DotNet.Interactive\Kernel.cs:line 330
at Microsoft.DotNet.Interactive.KernelCommandPipeline.<BuildPipeline>b__6_0(KernelCommand command, KernelInvocationContext context, KernelPipelineContinuation _) in D:\a\_work\1\s\src\Microsoft.DotNet.Interactive\KernelCommandPipeline.cs:line 60
at Microsoft.DotNet.Interactive.KernelCommandPipeline.SendAsync(KernelCommand command, KernelInvocationContext context) in D:\a\_work\1\s\src\Microsoft.DotNet.Interactive\KernelCommandPipeline.cs:line 41

Note that the following both work:

let x = datatable (hello:string, goodbye:string ) ['hello', 'goodbye'];
x
let x = datatable(a:string, b:dynamic ) ['hello', '{122}'];
x

This is of course completely valid in Kusto Explorer:
Image

Please complete the following:

Which version of .NET Interactive are you using? (In a notebook, run the #!about magic command. ):
.NET Interactive
© 2020 Microsoft Corporation
Version: 1.0.522904+cdfa48b2ea1a27dfe0f545c42a34fd3ec7119074
Library version: 1.0.0-beta.24229.4+cdfa48b2ea1a27dfe0f545c42a34fd3ec7119074
Build date: 2024-10-27T19:31:09.0232372Z

  • OS
    • Windows 11
    • Windows 10
    • macOS
    • Linux (Please specify distro)
    • iOS
    • Android
  • Browser
    • Chrome
    • Edge
    • Firefox
    • Safari
  • Frontend
    • Jupyter Notebook
    • Jupyter Lab
    • nteract
    • Visual Studio Code
    • Visual Studio Code Insiders
    • Visual Studio
    • Other (please specify)

Screenshots

If applicable, add screenshots to help explain your problem.

Image

@jonsequitur jonsequitur added bug Something isn't working Area-SQL / data querying labels Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-SQL / data querying bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants