display job ID for those jobs that were done by two or more for more than 300 days.
CREATE TABLE job_history (job_id VARCHAR, end_date VARCHAR, start_date VARCHAR)
SELECT job_id FROM job_history WHERE end_date - start_date > 300 GROUP BY job_id HAVING COUNT(*) >= 2
<s>[INST] Write mssql query to answer the following question given the database schema. Schema: CREATE TABLE job_history (job_id VARCHAR, end_date VARCHAR, start_date VARCHAR) Question: display job ID for those jobs that were done by two or more for more than 300 days. [/INST] SELECT job_id FROM job_history WHERE end_date - start_date > 300 GROUP BY job_id HAVING COUNT(*) >= 2 </s>