Search code examples
azure-data-factory

Azure Data Factory Expression Builder string formatting Error: unrecognised token (new line)


I have a Mapping Data Flow, where I want to use a custom SQL query for the Source, but I cannot break it on multiple lines, I get an error stating:

token recognition error at: ''

If I remove the newline and put the whole query on a single line it works, but it looks bearly readable. I would like to preserve the query formatting.

Does anyone have an idea how to do this?

LE the same happens with a simple statement like

select
1

enter image description here

This is how it looks in ADF: enter image description here enter image description here


Solution

  • You can enter a query directly into the SQL Query box as multi-lines (see image). You only need to use the expression builder or dynamic content if you are going to use expressions or parameters.

    enter image description here