I know this is a really basic question but can someone please send me asample script defining a table variable with DECLARE and then using it.ThanksCraig BerkoMS Sql Server LazyDBA home page