Reputation: 31
I use the user-defined table parameter to track the keyed in values and pass it to a stored procedure. Syntax works fine. No problem with it.
Question:
Requirement:
Alternate: if the UDT is not supporting multi instance, I am planning to get the User input in concatenated values and split it by list inside the stored procedure
Upvotes: 0
Views: 94
Reputation: 72229
If by User Defined Table you mean a Table Valued Parameter, then yes, it is not just per session but per request.
They are stored in tempdb
similar to temp tables, under a random name, but as soon as the request finishes and it goes out of scope then it is dropped. You cannot access it from another scope. Their names begin with @
.
If you mean temp tables then it depends. While they are stored under a random name, sometimes they can be shared.
#
.##
.Upvotes: 0