Is there a boolean literal in SQLite?

前端 未结 12 1842
逝去的感伤
逝去的感伤 2020-12-04 20:43

I know about the boolean column type, but is there a boolean literal in SQLite? In other languages, this might be true

12条回答
  •  一整个雨季
    2020-12-04 21:21

    There is no boolean data type. There are only 5 types, listed here. Integers can be stored with various widths on disk, the smallest being 1 byte. However, this is an implementation detail:

    "But as soon as INTEGER values are read off of disk and into memory for processing, they are converted to the most general datatype (8-byte signed integer)."

    Given that, it is not surprising there are no boolean literals.

提交回复
热议问题