DECLARE @FIDs VARCHAR(8000) SELECT @FIDs = COALESCE(@FIDs + ', ', '') + CAST(FID AS VARCHAR(10))
FROM CCC_TADetail
WHERE AppointId=1600
SELECT @FIDs as FIDs
DECLARE @FIDs VARCHAR(8000) SELECT @FIDs = COALESCE(@FIDs + ', ', '') + CAST(FID AS VARCHAR(10))
FROM CCC_TADetail
WHERE AppointId=1600
SELECT @FIDs as FIDs