Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-4583

TRUE by itself is not accepted in WHERE

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 10.5.3.0
    • 10.7.1.1
    • SQL
    • None
    • n/a
    • Deviation from standard

    Description

      A SELECT query with a literal boolean value in its WHERE clause results in a syntax error.

      How to reproduce:

      CREATE TABLE list (value VARCHAR(10));

      Given this table, the following queries result in a syntax error.

      SELECT * FROM list WHERE TRUE;
      SELECT * FROM list WHERE FALSE;
      SELECT * FROM list WHERE value='A' OR TRUE;

      Why is TRUE/FALSE not a boolean expression?

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            rhillegas Richard N. Hillegas
            wowtor Wouter
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment