ソースコード
Copy
  1. select
  2. ifnull(it.ITEM_CODE, ith.ITEM_CODE) as CODE
  3. ,ifnull(it.ITEM_NAME, ith.ITEM_NAME) as NAME
  4. ,case
  5. when ith.ITEM_CODE is null then 'ADDED'
  6. when it.ITEM_CODE is null then 'DELETED'
  7. else 'UPDATED'
  8. end as COMP_RSLT
  9. from ITEM it
  10. full outer join ITEM_HISTORY ith
  11. on it.ITEM_CODE = ith.ITEM_CODE
  12. where
  13. ith.ITEM_CODE is null
  14. or it.ITEM_CODE is null
  15. or it.USER_UPDATE_DATETIME <> ith.USER_UPDATE_DATETIME
  16. order by CODE desc
提出情報
提出日時2024/04/23 12:32:05
コンテスト第12回 SQLコンテスト
問題データ操作履歴
受験者ckoga
状態 (詳細)AC
(Accepted: 正答)
メモリ使用量84 MB
メッセージ
テストケース(通過数/総数)
3/3
状態
メモリ使用量
データパターン1
AC
84 MB
データパターン2
AC
83 MB
データパターン3
AC
83 MB