ソースコード
SELECT
  DISTRICT_TBL.DISTRICT_CODE AS CODE,
  DISTRICT_TBL.DISTRICT_NAME AS NAME,
  DISTRICT_TBL.LATITUDE AS LAT,
  DISTRICT_TBL.LONGITUDE AS LON
FROM
  (
    SELECT
      PF_CODE,
      DISTRICT_CODE,
      LATITUDE,
      LONGITUDE,
      (
        (LATITUDE - (
          SELECT LATITUDE FROM LOCATION_TBL WHERE DISTRICT_CODE = '1101'
        )) * (LATITUDE - (
          SELECT LATITUDE FROM LOCATION_TBL WHERE DISTRICT_CODE = '1101'
        ))) + (
        (LONGITUDE - (
          SELECT LONGITUDE FROM LOCATION_TBL WHERE DISTRICT_CODE = '1101'
        )) * (LONGITUDE - (
          SELECT LONGITUDE FROM LOCATION_TBL WHERE DISTRICT_CODE = '1101'
        )))
        AS DISTANCE
    FROM
      LOCATION_TBL
    WHERE
      DISTRICT_CODE <> '1101'
  ) DISTRICT_TBL
ORDER BY
  DISTRICT_TBL.DISTANCE DESC,
  DISTRICT_TBL.DISTRICT_CODE ASC;
提出情報
提出日時2023/04/14 16:03:25
コンテスト第6回 SQLコンテスト
問題位置情報
受験者udo
状態 (詳細)RE
(Runtime Error: 実行時エラー)
メモリ使用量77 MB
メッセージ
SQLITE_ERROR: no such column: DISTRICT_TBL.DISTRICT_NAME
テストケース(通過数/総数)
0/3
状態
メモリ使用量
データパターン1
RE
77 MB
データパターン2
RE
77 MB
データパターン3
RE
77 MB