I have a table variable of names and points. I have another table than contains names,points and a date. I can insert all the items into the 3 col table, but I cannot seem to be able to update the other table with the values from the temp table. Simple example://This has the data to be added to the other tableDECLARE @TempPoints TABLE (UserName varchar(20),Points int )//Pretend this is a real tableDECLARE @Points TABLE (UserName varchar(20),Points int )//This is part of a large calculation - made simple - //can contain multiple linesInsert into @TempPoints (UserName,Points) VALUES ('a',5)//This is a table of 1000's of usersInsert into @Points (UserName,Points) VALUES ('a',60)Update @Points set Points = Points + ( @TempPoints.Points ) where Points.Username in (Select UserName from @TempPoints)When finished, I want Points to contain ('a',65)But it get this undefined scalar error. Please help.