0

I have an SQL stored procedure to insert data in database that take two parameter where the first is an int and the second is an UniqueIdentifier.

I have consumed the SQL schemas in my BizTalk project.

I have a webservice that sends the data to BizTalk for inserting in database. The web-service also has to parameter a int and string that contains a GUID value.

I also have an BizTalk map that map from the web-service schema to SQL schema, but when running it I get this error:

Invalid cast from 'System.String' to 'System.Guid'

Why do I get this error and how do I fix it?

Dijkgraaf
  • 9,324
  • 15
  • 34
  • 48
Balatharan
  • 115
  • 10

1 Answers1

0

It's because you can't cast from String to Guid.

You have to use Guid.Parse() or .ParseExact() to convert the string representation of a Guid to a Guid Type.

Johns-305
  • 10,704
  • 10
  • 21