Let’s say I have four table (A,B,C,D), empId is common in all.
After running some complex query I get list of eligible empIds.
Now I need to run Select .... from ..... where empId IN LIST.
I want to store this list of empIds in some variable so that I don’t have run complex query every time to get list of empIds.
Is there anyway to store empIds in some temporary space?
This way I can cut down in running this complex query every time.
You could create a table in memory using the syntax:
Now you can access the contents of the table #tmp.