After adding a copy activity
, and specifying a stored procedure to use - I want to add a stored procedure parameter:
Running the activity, I get an error saying that there is no value specified for the stored procedure parameter projectId
.
Looking at the generated JSON code for the copy activity
, I can indeed see that there is no value set for the parameter:
"sink": {
"type": "SqlSink",
"writeBatchSize": 10000,
"sqlWriterStoredProcedureName": "[dbo].[CreateAllocation]",
"sqlWriterTableType": "AllocationType",
"storedProcedureParameters": {
"projectId": {
"type": "String"
}
}
},
"enableStaging": false,
"cloudDataMovementUnits": 0
Setting the value of the parameter by clicking the Advanced
tab on the copy activity
, and pasting the following JSON makes it work:
"sink": {
"type": "SqlSink",
"writeBatchSize": 10000,
"sqlWriterStoredProcedureName": "[dbo].[CreateAllocation]",
"sqlWriterTableType": "AllocationType",
"storedProcedureParameters": {
"projectId": {
"type": "String",
"value": "200"
}
}
},
"enableStaging": false,
"cloudDataMovementUnits": 0
I've also tried to connect the data factory to git, and making a commit that sets the value of the stored procedure parameter - but no luck. As soon as the copy activity has loaded, it seems like it strips out the value set for the parameter.
How come that I can't set the value of the stored procedure parameter, without using the Advanced
tab to override the activity template?