Skip to content

How to insert " and ' in one sentence of sql at the same time? #3774

Closed

Description

@limeng32

We know that single quotation marks (') can be inserted in double quotation marks, and double quotation marks (") can be inserted in single quotation marks. However, if an indicator has both single quotation marks (') and double quotation marks (") in the same time, how to insert it?

Activity

  1. Alima777 commented on Aug 19, 2021

    @Alima777
    Contributor

    Can you give one example?

  2. limeng32 commented on Aug 19, 2021

    @limeng32
    ContributorAuthor

    I can Use:
    insert into root.ln.wf01.wt01 (timestamp,asd) values(now()," ' ");
    To add a single quote record, I can also use:
    insert into root.ln.wf01.wt01 (timestamp,asd) values(now(),' " ');
    To add a double quote record, but I can’t add a record with both single quotes and double quotes, because there is no escape mechanism;

  3. locked and limited conversation to collaborators on Aug 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions