What is the color of the grape whose wine products has the highest average price?
CREATE TABLE GRAPES (Color VARCHAR, Grape VARCHAR); CREATE TABLE WINE (Grape VARCHAR)
SELECT TOP 1 T1.Color FROM GRAPES AS T1 JOIN WINE AS T2 ON T1.Grape = T2.Grape GROUP BY T2.Grape ORDER BY AVG(Price) DESC
<s>[INST] Write mssql query to answer the following question given the database schema. Schema: CREATE TABLE GRAPES (Color VARCHAR, Grape VARCHAR); CREATE TABLE WINE (Grape VARCHAR) Question: What is the color of the grape whose wine products has the highest average price? [/INST] SELECT TOP 1 T1.Color FROM GRAPES AS T1 JOIN WINE AS T2 ON T1.Grape = T2.Grape GROUP BY T2.Grape ORDER BY AVG(Price) DESC </s>