Question: 하동군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '하동군'
ORDER BY SI.REGIST_DT DESC


Question: 7천 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 7000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 싼 집 없어?

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 3000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 목포시 빈집 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '목포시'
ORDER BY SI.REGIST_DT DESC


Question: 매물 있나

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
ORDER BY SI.REGIST_DT DESC


Question: 논산시 전세 5천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '논산시'
  AND SI.DEAL_TP = '2'
  AND SI.DEAL_PRICE <= 5000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 울산시 빈집 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '울산광역시'
ORDER BY SI.REGIST_DT DESC


Question: 순천시 전원주택 5천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '순천시'
  AND SI.DEAL_PRICE <= 5000
  AND SI.DEAL_PRICE > 0
  AND (BM.REAL_PURPS LIKE '%전원주택%' OR SI.SLS_TTL LIKE '%전원주택%')
ORDER BY SI.DEAL_PRICE ASC


Question: 광주 5천만원 이하 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '광주광역시'
  AND SI.DEAL_PRICE <= 5000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 상주시 몇 채?

SELECT COUNT(*) AS "건 수"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '상주시'


Question: 경상북도 평균 가격

SELECT
    COUNT(*) AS "총 건수",
    ROUND(AVG(SI.DEAL_PRICE)) AS "평균 가격",
    MIN(SI.DEAL_PRICE) AS "최저 가격",
    MAX(SI.DEAL_PRICE) AS "최고 가격"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE > 0
  AND PB.AS1 = '경상북도'


Question: 방금 올라온 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
ORDER BY SI.REGIST_DT DESC


Question: 4천만원 아래 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 4000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 밀양시 전세

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '밀양시'
  AND SI.DEAL_TP = '2'
ORDER BY SI.REGIST_DT DESC


Question: 고령군 월세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '고령군'
  AND SI.DEAL_TP = '3'
ORDER BY SI.REGIST_DT DESC


Question: 거제시 빈집 몇 개?

SELECT COUNT(*) AS "건 수"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '거제시'


Question: 충청남도 지역 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '충청남도'
ORDER BY SI.REGIST_DT DESC


Question: 경남 거창군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상남도'
  AND PB.AS2 = '거창군'
ORDER BY SI.REGIST_DT DESC


Question: 전라남도 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '전라남도'
ORDER BY SI.REGIST_DT DESC


Question: 3억원 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 30000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 서울 지역 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '서울특별시'
ORDER BY SI.REGIST_DT DESC


Question: 진주시 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '진주시'
ORDER BY SI.REGIST_DT DESC


Question: 금산군 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '금산군'
ORDER BY SI.REGIST_DT DESC


Question: 영양군 1억 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '영양군'
  AND SI.DEAL_PRICE <= 10000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 울진군 월세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '울진군'
  AND SI.DEAL_TP = '3'
ORDER BY SI.REGIST_DT DESC


Question: 강원도 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '강원특별자치도'
ORDER BY SI.REGIST_DT DESC


Question: 호남권 빈집 목록

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 IN ('광주광역시', '전북특별자치도', '전라남도')
ORDER BY SI.REGIST_DT DESC


Question: 청송군 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '청송군'
ORDER BY SI.REGIST_DT DESC


Question: 산청군 2억 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '산청군'
  AND SI.DEAL_PRICE <= 20000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 산청군 3천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '산청군'
  AND SI.DEAL_PRICE <= 3000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 대전시 매물 보여줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '대전광역시'
ORDER BY SI.REGIST_DT DESC


Question: 부산시 매물 보여줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '부산광역시'
ORDER BY SI.REGIST_DT DESC


Question: 전세금 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_TP = '2'
ORDER BY SI.REGIST_DT DESC


Question: 양산시 3천만원 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '양산시'
  AND SI.DEAL_PRICE <= 3000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 예안면 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND (PB.AS3 LIKE '%예안면%' OR PB.AS4 LIKE '%예안면%' OR PB.NAME LIKE '%예안면%' OR PB.NAME2 LIKE '%예안면%')
ORDER BY SI.REGIST_DT DESC


Question: 농가주택 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND (BM.REAL_PURPS LIKE '%농가주택%' OR SI.SLS_TTL LIKE '%농가주택%')
ORDER BY SI.REGIST_DT DESC


Question: 당진시 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '당진시'
ORDER BY SI.REGIST_DT DESC


Question: 사천시 3천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '사천시'
  AND SI.DEAL_PRICE <= 3000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 창녕군 빈집 몇 개?

SELECT COUNT(*) AS "건 수"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '창녕군'


Question: 남해군 월세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '남해군'
  AND SI.DEAL_TP = '3'
ORDER BY SI.REGIST_DT DESC


Question: 서천군 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '서천군'
ORDER BY SI.REGIST_DT DESC


Question: 다가구주택 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND (BM.REAL_PURPS LIKE '%다가구주택%' OR SI.SLS_TTL LIKE '%다가구주택%')
ORDER BY SI.REGIST_DT DESC


Question: 경상남도 평균 가격

SELECT
    COUNT(*) AS "총 건수",
    ROUND(AVG(SI.DEAL_PRICE)) AS "평균 가격",
    MIN(SI.DEAL_PRICE) AS "최저 가격",
    MAX(SI.DEAL_PRICE) AS "최고 가격"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE > 0
  AND PB.AS1 = '경상남도'


Question: 포천시 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '포천시'
ORDER BY SI.REGIST_DT DESC


Question: 울산 빈집 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '울산광역시'
ORDER BY SI.REGIST_DT DESC


Question: 양산시 월세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '양산시'
  AND SI.DEAL_TP = '3'
ORDER BY SI.REGIST_DT DESC


Question: 1억5천만원 아래 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 15000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 안동시 평균 가격

SELECT
    COUNT(*) AS "총 건수",
    ROUND(AVG(SI.DEAL_PRICE)) AS "평균 가격",
    MIN(SI.DEAL_PRICE) AS "최저 가격",
    MAX(SI.DEAL_PRICE) AS "최고 가격"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE > 0
  AND PB.AS2 = '안동시'


Question: 울진군 3천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '울진군'
  AND SI.DEAL_PRICE <= 3000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 충남 빈집 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '충청남도'
ORDER BY SI.REGIST_DT DESC


Question: 8천만원 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 8000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 경남 합천군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상남도'
  AND PB.AS2 = '합천군'
ORDER BY SI.REGIST_DT DESC


Question: 대전 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '대전광역시'
ORDER BY SI.REGIST_DT DESC


Question: 남해군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '남해군'
ORDER BY SI.REGIST_DT DESC


Question: 대전 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '대전광역시'
ORDER BY SI.REGIST_DT DESC


Question: 하동군 전세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '하동군'
  AND SI.DEAL_TP = '2'
ORDER BY SI.REGIST_DT DESC


Question: 3천만원 넘는 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE >= 3000
ORDER BY SI.DEAL_PRICE ASC


Question: 경북 칠곡군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상북도'
  AND PB.AS2 = '칠곡군'
ORDER BY SI.REGIST_DT DESC


Question: 완주군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '완주군'
ORDER BY SI.REGIST_DT DESC


Question: 곡성군 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '곡성군'
ORDER BY SI.REGIST_DT DESC


Question: 안동시 매매 5천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '안동시'
  AND SI.DEAL_TP = '1'
  AND SI.DEAL_PRICE <= 5000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 문경시 빈집 몇 개?

SELECT COUNT(*) AS "건 수"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '문경시'


Question: 울진군 2억 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '울진군'
  AND SI.DEAL_PRICE <= 20000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 진주시 월세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '진주시'
  AND SI.DEAL_TP = '3'
ORDER BY SI.REGIST_DT DESC


Question: 담양군 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '담양군'
ORDER BY SI.REGIST_DT DESC


Question: 이천시 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '이천시'
ORDER BY SI.REGIST_DT DESC


Question: 최근 올라온 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
ORDER BY SI.REGIST_DT DESC


Question: 보성군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '보성군'
ORDER BY SI.REGIST_DT DESC


Question: 부산에 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '부산광역시'
ORDER BY SI.REGIST_DT DESC


Question: 거창군 빈집 싼 순

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '거창군'
ORDER BY SI.DEAL_PRICE ASC


Question: 100평 이상 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND BM.TOT_AREA >= 330
ORDER BY BM.TOT_AREA DESC NULLS LAST


Question: 빈집 상위 3개

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
ORDER BY SI.REGIST_DT DESC
FETCH FIRST 3 ROWS ONLY


Question: 8천만원 미만 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 8000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 사천시 2억 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '사천시'
  AND SI.DEAL_PRICE <= 20000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 안동시 최근 3개월 매물

SELECT
    SI.SLS_ID,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    SI.SLS_TTL,
    SI.DEAL_PRICE,
    BM.ETC_ADDR,
    SI.REGIST_DT
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '안동시'
  AND SI.REGIST_DT >= ADD_MONTHS(SYSDATE, -3)
ORDER BY SI.REGIST_DT DESC


Question: 경남 지역 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상남도'
ORDER BY SI.REGIST_DT DESC


Question: 익산시 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '익산시'
ORDER BY SI.REGIST_DT DESC


Question: 진주시 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '진주시'
ORDER BY SI.REGIST_DT DESC


Question: 고령군 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '고령군'
ORDER BY SI.REGIST_DT DESC


Question: 4천 넘는 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE >= 4000
ORDER BY SI.DEAL_PRICE ASC


Question: 봉화군 농가주택

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '봉화군'
  AND (BM.REAL_PURPS LIKE '%농가주택%' OR SI.SLS_TTL LIKE '%농가주택%')
ORDER BY SI.REGIST_DT DESC


Question: 무안군 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '무안군'
ORDER BY SI.REGIST_DT DESC


Question: 보성군 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '보성군'
ORDER BY SI.REGIST_DT DESC


Question: 경남 진주시 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상남도'
  AND PB.AS2 = '진주시'
ORDER BY SI.REGIST_DT DESC


Question: 군산시 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '군산시'
ORDER BY SI.REGIST_DT DESC


Question: 안성시 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '안성시'
ORDER BY SI.REGIST_DT DESC


Question: 충주시 빈집 있나요

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '충주시'
ORDER BY SI.REGIST_DT DESC


Question: 거창 싸고 좋은 집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '거창군'
  AND SI.DEAL_PRICE <= 5000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 여주시 빈집 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '여주시'
ORDER BY SI.REGIST_DT DESC


Question: 전라북도 빈집 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '전북특별자치도'
ORDER BY SI.REGIST_DT DESC


Question: 대구 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '대구광역시'
ORDER BY SI.REGIST_DT DESC


Question: 빈집 구경

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
ORDER BY SI.REGIST_DT DESC


Question: 함양군 빈집 수

SELECT COUNT(*) AS "건 수"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '함양군'


Question: 경남 남해군 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상남도'
  AND PB.AS2 = '남해군'
ORDER BY SI.REGIST_DT DESC


Question: 창고 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND (BM.REAL_PURPS LIKE '%창고%' OR SI.SLS_TTL LIKE '%창고%')
ORDER BY SI.REGIST_DT DESC


Question: 합천군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '합천군'
ORDER BY SI.REGIST_DT DESC


Question: 창원시 빈집 몇 개?

SELECT COUNT(*) AS "건 수"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '창원시'


Question: 양산시 전원주택

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '양산시'
  AND (BM.REAL_PURPS LIKE '%전원주택%' OR SI.SLS_TTL LIKE '%전원주택%')
ORDER BY SI.REGIST_DT DESC


Question: 영양군 빈집 몇 개?

SELECT COUNT(*) AS "건 수"
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '영양군'


Question: 1천만원 이상 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE >= 1000
ORDER BY SI.DEAL_PRICE ASC


Question: 남해군 3천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '남해군'
  AND SI.DEAL_PRICE <= 3000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 평창군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '평창군'
ORDER BY SI.REGIST_DT DESC


Question: 1천 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 1000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 5천만원까지 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 5000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 경북 구미시 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상북도'
  AND PB.AS2 = '구미시'
ORDER BY SI.REGIST_DT DESC


Question: 고령군 매매

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '고령군'
  AND SI.DEAL_TP = '1'
ORDER BY SI.REGIST_DT DESC


Question: 경남 김해시 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상남도'
  AND PB.AS2 = '김해시'
ORDER BY SI.REGIST_DT DESC


Question: 울산 1억 이하 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '울산광역시'
  AND SI.DEAL_PRICE <= 10000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 하동군 전세

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '하동군'
  AND SI.DEAL_TP = '2'
ORDER BY SI.REGIST_DT DESC


Question: 계룡시 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '계룡시'
ORDER BY SI.REGIST_DT DESC


Question: 전원생활 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
ORDER BY SI.REGIST_DT DESC


Question: 경북 청송군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '경상북도'
  AND PB.AS2 = '청송군'
ORDER BY SI.REGIST_DT DESC


Question: 고성군 빈집 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '고성군'
ORDER BY SI.REGIST_DT DESC


Question: 남해군 전세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '남해군'
  AND SI.DEAL_TP = '2'
ORDER BY SI.REGIST_DT DESC


Question: 사려는 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_TP = '1'
ORDER BY SI.REGIST_DT DESC


Question: 통영시 5천만원 이하

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '통영시'
  AND SI.DEAL_PRICE <= 5000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 김제시 빈집 찾아줘

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '김제시'
ORDER BY SI.REGIST_DT DESC


Question: 봉화군 월세 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '봉화군'
  AND SI.DEAL_TP = '3'
ORDER BY SI.REGIST_DT DESC


Question: 충청북도 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '충청북도'
ORDER BY SI.REGIST_DT DESC


Question: 영양군 매매 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '영양군'
  AND SI.DEAL_TP = '1'
ORDER BY SI.REGIST_DT DESC


Question: 거창군 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '거창군'
ORDER BY SI.REGIST_DT DESC


Question: 울산시 지역 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '울산광역시'
ORDER BY SI.REGIST_DT DESC


Question: 충주시 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '충주시'
ORDER BY SI.REGIST_DT DESC


Question: 4천까지 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 4000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 충청북도에 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '충청북도'
ORDER BY SI.REGIST_DT DESC


Question: 충주시 최근 3개월 매물

SELECT
    SI.SLS_ID,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    SI.SLS_TTL,
    SI.DEAL_PRICE,
    BM.ETC_ADDR,
    SI.REGIST_DT
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS2 = '충주시'
  AND SI.REGIST_DT >= ADD_MONTHS(SYSDATE, -3)
ORDER BY SI.REGIST_DT DESC


Question: 2억 이하 매물

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 20000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 3억 이하 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.DEAL_PRICE <= 30000
  AND SI.DEAL_PRICE > 0
ORDER BY SI.DEAL_PRICE ASC


Question: 충북 제천시 빈집

SELECT
    SI.SLS_ID,
    SI.SLS_TTL,
    SI.DEAL_TP,
    CASE SI.DEAL_TP
      WHEN '1' THEN '매매'
      WHEN '2' THEN '전세'
      WHEN '3' THEN '월세'
      WHEN '4' THEN '년세'
    END AS DEAL_TP_NM,
    SI.DEAL_PRICE,
    SI.REGIST_DT,
    SI.SOLD_YN,
    BM.ETC_ADDR,
    BM.TOT_AREA,
    BM.PLAT_AREA,
    BM.PRIV_AREA,
    BM.USEAPR_DT,
    BM.GRND_FLR_CNT,
    BM.UGRND_FLR_CNT,
    BM.X,
    BM.Y,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    PB.AS3 AS EMD,
    PB.AS4 AS RI
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND PB.AS1 = '충청북도'
  AND PB.AS2 = '제천시'
ORDER BY SI.REGIST_DT DESC


Question: 이번 달 신규 매물

SELECT
    SI.SLS_ID,
    PB.AS1 AS SIDO,
    PB.AS2 AS SIGUNGU,
    SI.SLS_TTL,
    SI.DEAL_PRICE,
    BM.ETC_ADDR,
    SI.REGIST_DT
FROM BIS_WEB.SLS_INFO SI
INNER JOIN BIS_WEB.BIS_MASTER_NOTICE BM ON SI.BIS_MASTER_SEQ = BM.SEQ
INNER JOIN PUBLICS.BJDHIST PB ON BM.SREG = PB.REG AND BM.SEUB = PB.EUB
WHERE SI.INFO_AGREE_YN = 'Y'
  AND SI.SOLD_YN = 'N'
  AND SI.DEL_YN = 'N'
  AND SI.REGIST_DT >= TRUNC(SYSDATE, 'MM')
ORDER BY SI.REGIST_DT DESC