ErrorCode=InvalidParameter,'Type=Microsoft.DataTransfer.Common.Shared.HybridDeliveryException,Message=The value of the property 'columns' is invalid: 'Value cannot be null. Parameter name: columns'.,Source=,''Type=System.ArgumentNullException,Message=Val

Abhinandan Shrestha 20 Reputation points
2023-11-02T09:59:42.7333333+00:00

i used lookup activity before foreach
for each Items:

@activity('Lookup1').output.value
{
	"count": 10,
	"value": [
		{
			"Id": 1,
			"OrderNumber": "20-0509-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		},
		{
			"Id": 3,
			"OrderNumber": "20-0163-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		},
		{
			"Id": 6,
			"OrderNumber": "20-0181-000000",
			"LocationId": 100,
			"DeliveryBoyId": 1765
		},
		{
			"Id": 7,
			"OrderNumber": "20-0610-000000",
			"LocationId": 100,
			"DeliveryBoyId": 1765
		},
		{
			"Id": 10,
			"OrderNumber": "20-0500-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		},
		{
			"Id": 11,
			"OrderNumber": "20-0495-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		},
		{
			"Id": 13,
			"OrderNumber": "20-0500-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		},
		{
			"Id": 17,
			"OrderNumber": "20-0087-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		},
		{
			"Id": 18,
			"OrderNumber": "20-0283-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		},
		{
			"Id": 19,
			"OrderNumber": "20-0521-000000",
			"LocationId": 100,
			"DeliveryBoyId": null
		}
	],
	"effectiveIntegrationRuntime": "AutoResolveIntegrationRuntime (Southeast Asia)",
	"billingReference": {
		"activityType": "PipelineActivity",
		"billableDuration": [
			{
				"meterType": "AzureIR",
				"duration": 0.016666666666666666,
				"unit": "Hours"
			}
		],
		"totalBillableDuration": [
			{
				"meterType": "AzureIR",
				"duration": 0.016666666666666666,
				"unit": "Hours"
			}
		]
	},
	"durationInQueue": {
		"integrationRuntimeQueue": 0
	}
}

In foreach i used lookup activity:

UPDATE "Order"

SET

"LocationId" = CAST(COALESCE(@{item().LocationId}, 0) AS integer),

"DeliveryBoyId" = CAST(COALESCE(@{item().DeliveryBoyId}, 0) AS integer)

WHERE "Id" = CAST(@{item().Id} AS bigint)

I'm getting this error

ErrorCode=InvalidParameter,'Type=Microsoft.DataTransfer.Common.Shared.HybridDeliveryException,Message=The value of the property 'columns' is invalid: 'Value cannot be null.

Parameter name: columns'.,Source=,''Type=System.ArgumentNullException,Message=Value cannot be null.

Parameter name: columns,Source=Microsoft.DataTransfer.Common,'

Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
4,696 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
10,196 questions
{count} votes

Accepted answer
  1. Suba Balaji 11,206 Reputation points
    2023-11-02T15:59:49.02+00:00

    Hi,

    I believe your sink is an oracle table. Please correct if my understanding is wrong.

    In order to fix the issue, next to your update statement, please add the below code

    SELECT 1 MyCol FROM DUAL;

    Data factory needs atleast one column value returned from the query being used in lookup activity.

    Alternatively, you can try using script activity too where you dont have to return a dummy record

    Here is an SO thread where a similar solution is provided. You could take a look.

    Please try and let us know how it goes


0 additional answers

Sort by: Most helpful