Show the budget type code and description and the corresponding document id.
CREATE TABLE Ref_budget_codes (budget_type_code VARCHAR, budget_type_description VARCHAR); CREATE TABLE Documents_with_expenses (document_id VARCHAR, budget_type_code VARCHAR)
SELECT T2.budget_type_code, T2.budget_type_description, T1.document_id FROM Documents_with_expenses AS T1 JOIN Ref_budget_codes AS T2 ON T1.budget_type_code = T2.budget_type_code
<s>[INST] Write mssql query to answer the following question given the database schema. Schema: CREATE TABLE Ref_budget_codes (budget_type_code VARCHAR, budget_type_description VARCHAR); CREATE TABLE Documents_with_expenses (document_id VARCHAR, budget_type_code VARCHAR) Question: Show the budget type code and description and the corresponding document id. [/INST] SELECT T2.budget_type_code, T2.budget_type_description, T1.document_id FROM Documents_with_expenses AS T1 JOIN Ref_budget_codes AS T2 ON T1.budget_type_code = T2.budget_type_code </s>