cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Problems with dates retrieved from SQL Query and updating item

I have a workflow that runs a SQL Query to pull back several columns of information and update the current SharePoint item.  Everything works correctly - with the exception of the one date column that produces the following error: "Coercion Failed: Unable to transform the input lookup data into the requested type."

 

I've attempted to update the item using both the date received directly from SQL and also as a string where I reformatted it back to  MM/dd/yyyy via a 'Build String' action. (fn-FormatDate({WorkflowVariable:date_item01_invoicedate}, MM/dd/yyyy  ))

 

Below is an example of the date when I logged both strings prior to attempting the update.

 

Workflow Messages

 

TimeEventMessageOutcome
7/21/2015 1:34 PMWorkflow CommentFrom SQL: 6/26/2015 12:00 AM

 

Formatted: 06/26/2015
7/21/2015 1:34 PMErrorCoercion Failed: Unable to transform the input lookup data into the requested type.

 

Does anyone have any suggestions on the best way to handle this type of thing?

Labels: (1)
0 Kudos
Reply
1 Reply
Workflow Hero

Re: Problems with dates retrieved from SQL Query and updating item

Try using a Convert Value action to convert the Text date time into a DateTime variable and use that in the Create Item action.

cheers,

Vadim

0 Kudos
Accept as Solution Reply