Forum Discussion

Patrick Naughton's avatar
Patrick Naughton
Brass Contributor
May 11, 2018

calling scalar functions in datatable array

This works as expected:

datatable (TimeGenerated:datetime, Success:bool) [ datetime("2018-05-11T17:50:01.665"), true ]


But this fails because the array does not allow scalar functions to be called?

datatable (TimeGenerated:datetime, Success:bool) [ now(), true ]


According to this documentation, datetime() and now() are both "datetime literals"

 

Could we add support for this?

  • Hi Patrick,

    It appears datatable expects only constant scalar values, whereas now() is an expression.

    So that explains it..

    I've mentioned support for it is requested.

     

    HTH,

    Noa

  • This seems like a bug. I've report it to the language team and awaiting their answer.

Resources