I'm trying to pass a variable through a variable to get multiple values for a single parameter. I've tried everything to figure it out. I'd like to gather all the work orders from a single Job Master on a table that is driven by a work order constraint. This table is used everywhere and I can't alter it to run via Job.
DECLARE @WorkOrder varchar(MAX)
DECLARE @Job varchar (MAX)
SET @Job = '10000'
SET @WorkOrder =(SELECT WorkOrder FROM JcoWorkOrder WHERE JcoWorkOrder.JobLink = @Job)