microsoft / Kusto-Query-Language

Kusto Query Language is a simple and productive language for querying Big Data.
Apache License 2.0
510 stars 97 forks source link

workspace function parameter with "int/real/long/decimal" datatype can't have a negative value #138

Closed JiTmun closed 4 months ago

JiTmun commented 4 months ago

Hello,

I tried to save a workspace function with a int default value set to -1. When I try to save the workspace function, I get the following error:

Error saving function. Error code: InvalidOperationArgument. Error message: Invalid function parameters string. Encountered possible syntax errors: 'Missing expression (11,11)', 'Expected: ')' (12,14)', 'Expected: '{' (12,14)', 'Expected: '}' (14,16)'. Please see relevant documentation 'https://docs.microsoft.com/en-us/azure/kusto/query/'.

Nota: I tried to change the type of the param without success "int/real/long/decimal". replacing -1 by 1 allow to save the function.

image

sloutsky commented 4 months ago

It's not clear what is the UX you're using to edit the function, or what is the error you're getting - but it doesn't seem like coming from KQL parser.