• luciferofastora@feddit.org
    link
    fedilink
    arrow-up
    2
    ·
    3 days ago

    I had something similar to that with Power BI DAX where the same “intuitive” structure (a table definition) had different syntax for two similar purposes.

    The inline table constructor for a single column table is {value, value, ...}, with the column just named “value”. The constructor for a multi-column table is {(value, value, ...), (value, value, ...), ...}, and the columns are named “value1”, “value2” and so on.

    The function DATATABLE allows both specifying the column names and types for the data. The syntax for the data argument is {{value, value, ...}, ...}.

    If you can spot the difference, you will have figured out why simply transplanting my constructor into a DATATABLE didn’t work, but copying an example and replacing the values one by one did. It took me way too long.

    Maybe you just missed some nuance your brain skipped over?