What are names of patients who made an appointment?
CREATE TABLE appointment (patient VARCHAR); CREATE TABLE patient (ssn VARCHAR)
SELECT name FROM appointment AS T1 JOIN patient AS T2 ON T1.patient = T2.ssn
<s>[INST] Write mssql query to answer the following question given the database schema. Schema: CREATE TABLE appointment (patient VARCHAR); CREATE TABLE patient (ssn VARCHAR) Question: What are names of patients who made an appointment? [/INST] SELECT name FROM appointment AS T1 JOIN patient AS T2 ON T1.patient = T2.ssn </s>