Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

declare table variable sql

DECLARE @TableVariable TABLE (Id INT)

INSERT INTO @TableVariable
SELECT Id
FROM TableName
WHERE....

SELECT *
FROM TableName
WHERE Id IN ( SELECT Id FROM @TableVariable)
Source by www.sqlservertutorial.net #
 
PREVIOUS NEXT
Tagged: #declare #table #variable #sql
ADD COMMENT
Topic
Name
1+9 =