I am having troubles combining multiple queries into one output. I am a beginner at SQL and was wondering if anyone can provide me with some feedback on how to get this done.
Here is my code:
SELECT [status], [queryno_i] as 'Query ID', [assigned_to_group] as 'Assigned To Group', [issued_date] as 'Issuing Date',
CASE
WHEN [status] = 3 THEN [mutation]
ELSE NULL
END AS 'Closing Date'
FROM tablename.[tech_query] WITH (NOLOCK)
SELECT
CASE
WHEN [status] = 3 THEN 'CLOSED'
ELSE 'OPEN'
END AS [State]
FROM tablename.[tech_query] WITH (NOLOCK)
SELECT
CASE
WHEN [status] = 3 THEN [mutation_int]-[issued_date_INT]
ELSE NULL
END AS [TAT]
FROM tablename.[tech_query] WITH (NOLOCK)
combinecan mean so many different things