I am not sure what you mean by placing it in a "variable". You can assign table columns/names as aliases. Then the alias can be used throughout the rest of the query to shorten joins. Aliases are good for tables which you want to link to themselves (unary relationships) but treat as if they were two separate tables.
select sometable.ProductID, sometable.VendorID
from sometable.ProductVendor pv1 //<-- Notice alias
inner join sometable.ProductVendor pv2 // Notice other alias (both to same table column)
on pv1.ProductID = pv2.ProductID // Can use aliases in joins etc
and pv1.VendorID <> pv2.VendorID
I think this is what you might mean when you are saying variable.
That is what Entity Framework does. It creates a strongly typed Class that is your table and properties that are your fields. It encompasses all constraints and rules that are applied in the DB. You can use Stored Procedures and Views as well. So, your DB looks and feels like variables. Excellent for LINQ and lambda expressions. Better binding with ASPX imo!