in_ansi_dict.sql 977 B

123456789101112131415161718192021
  1. /* syntax version 1 */
  2. /* postgres can not */
  3. PRAGMA AnsiInForEmptyOrNullableItemsCollections;
  4. SELECT
  5. 1 IN AsDict((2, "x"), (3, "y"), (null, "z")), -- Nothing<Bool?>
  6. null IN DictCreate(Int32, String?), -- false?
  7. null IN AsDict((null, "foo")), -- Nothing<Bool?>
  8. null IN AsDict((1, "bar")), -- Nothing<Bool?>
  9. (1, null) IN AsDict(((1, 1), null), ((2, 2), "foo")), -- Nothing<Bool?>
  10. (1, null) IN AsDict(((2, 2), "foo"), ((3, 3), "bar")), -- false?
  11. (1, 2) IN AsDict(((1, null), "foo"), ((2, 2), "bar")), -- Nothing<Bool?>
  12. (1, 2) IN AsDict(((null, 1), "foo"), ((2, 1), null)), -- false?
  13. (1, 2) IN AsDict(((1, null), "foo"), ((2, 1), "bar")), -- Nothing<Bool?>
  14. ;
  15. SELECT
  16. Just(1) IN AsDict((1, "foo"), (2, "bar"), (3, null)), -- true?
  17. 1 IN AsDict((Just(2), null), (Just(3), "bar")), -- false?
  18. ;