HiIn a procedure I have a number of table variables:DECLARE @tbl_s TABLE (ID int IDENTITY(1,1), colorID int NOT NULL)DECLARE @tbl_e TABLE (ID int IDENTITY(1,1), eventID int NOT NULL)DECLARE @tbl_u TABLE (ID int IDENTITY(1,1), userID int NOT NULL)DECLARE @tbl_l TABLE (ID int IDENTITY(1,1), uLevel numeric(5,2) NOT NULL)DECLARE @tbl_dur TABLE (ID int IDENTITY(1,1), duration INT)DECLARE @tbl_dates TABLE (ID int IDENTITY(1,1), dates datetime NOT NULL)
In order for the procedure to function after data entry into these variables, each table variable MUST have the same number of rows (as they are inner joined later). Is there a quick way of checking that this is true? Or, do I need to run a COUNT against each one in turn??Thanks!