Please help...an ADF Bug in Final Testing - Making a Query in a Lookup Activity with a Variable Failing

Mike Kiser 1,531 Reputation points
2021-03-06T02:53:16.537+00:00

Hello!
@Nasreen Akter @HimanshuSinha-msft @MartinJaffer-MSFT

We have a bug in Final Testing. I am trying to make the following Query in a LookUp Activity:

SELECT ShortName, EEOXrefCode FROM [MercerStagingDev].[MILKY-WAYTEST\AppSQLVST4DotNetDev-R].[Copy of Battelle Work Assignment Fields Jobs]
WHERE XRefCode = @variables('JobXRefCode')

I have the Set Variable showing the correct String 'JobXrefCode' but am getting a crazy error. Please help; I must figure out how to do this "syntax" this weekend.
Thanks!!
Mike Kiser

Error code
2100
Troubleshooting guide
Failure type
User configuration issue
Details
Failure happened on 'Source' side. ErrorCode=SqlOperationFailed,'Type=Microsoft.DataTransfer.Common.Shared.HybridDeliveryException,Message=A database operation failed with the following error: 'Must declare the scalar variable "@variables".',Source=,''Type=System.Data.SqlClient.SqlException,Message=Must declare the scalar variable "@variables".,Source=.Net SqlClient Data Provider,SqlErrorNumber=137,Class=15,ErrorCode=-2146232060,State=2,Errors=[{Class=15,Number=137,State=2,Message=Must declare the scalar variable "@variables".,},],'

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
9,579 questions
0 comments No comments
{count} votes

Accepted answer
  1. Nasreen Akter 10,751 Reputation points
    2021-03-06T03:28:28.11+00:00

    Hi @Mike Kiser ,

    Please try

    @{variables('JobXRefCode')}
    or for string
    '@{variables('JobXRefCode')}'

    Thanks! :)

    3 people found this answer helpful.

0 additional answers

Sort by: Most helpful