User Defined Table Types between different databases

Asked

Viewed 101 times

3

I created a User Defined Table Type in a DB1 database. Trying to declare such a variable in a BD2 database procedure gives me the following error:

The type name 'BLABLA' contains more than the Maximum number of prefixes.

Since I couldn’t solve it this way, I tried to create the same kind of data in both databases. The statement did not give error, but when trying to send the type of data created in the DB2 database to a DB1 procedure gives the following error:

"Operant type Clash"

Is there any way to send a data table from a DB2 database procedure to a DB1 database procedure?

  • Have you tried replicating the UDT in DB2 ?

  • yes, I already did that and gives me this error tbm "Operant type Clash".

  • According to this OS question this is not possible: http://stackoverflow.com/questions/9531769/passing-table-valued-parameter-to-stored-procedure-across-different-databases/9532187#9532187

1 answer

1

The message

Operand Type Clash

means that you have declared the two types in different databases and they possess some difference between them which makes the database get lost.

There’s an article where Microsoft clarifies how this works, as well as recommends a number of precautions when dealing with User Defined Types.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.