Skip to content

Instantly share code, notes, and snippets.

@KimSoungRyoul
Last active September 13, 2019 14:00
Show Gist options
  • Save KimSoungRyoul/c0096f9c5b0f6d2663848fd74c86e634 to your computer and use it in GitHub Desktop.
Save KimSoungRyoul/c0096f9c5b0f6d2663848fd74c86e634 to your computer and use it in GitHub Desktop.
내가 원했던 쿼리
SELECT `orm_practice_app_company`.`id`,
`orm_practice_app_company`.`name`,
`orm_practice_app_company`.`tel_num`,
`orm_practice_app_company`.`address`
FROM `orm_practice_app_company`
WHERE `orm_practice_app_company`.`name` = 'company_name1';
SELECT "orm_practice_app_product"."id", "orm_practice_app_product"."name", "orm_practice_app_product"."price", "orm_practice_app_product"."product_owned_company_id"
FROM "orm_practice_app_product"
WHERE "orm_practice_app_product"."product_owned_company_id" IN (1)
-- 이런식으로 조건절이 붙기를 기대함 >>> -- AND name = 'product_name3';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment