Data storage--sqlite Database storage--sql Statement--DQL data Query Language

Source: Internet
Author: User
Tags sqlite sqlite database

I. WHERE query criteria

1. Operators

(1) is null/is NOT NULL to determine control/non-null

(2) Like fuzzy comparison string

① wildcard characters

1)% any number of characters

2) _ Single character

② usage

1) Like '% condition% '

2) Like '% condition '

3) Like ' condition% '

4) Like ' _ Condition _ '

5) Like ' _ Condition '

6) Like ' condition _ '

(3) In judging if it is within the list of merits

① and equivalent to a single field or operation

② usage

1) field name in (value 1, value 2,... )

2) field name in (subquery statement)

(4) between and between the start and end values

①between start value and end value

② are included before and after

③ equivalent to field >= start value and field <= end value

④ used in numerical, time

⑤ Start value <= End value

(5) operator

2. Features

(1) Add filter condition to result set, return record of compound condition

(2) followed by the From table name

Two. Order by sort

1. Usage

①order by field 1 asc/desc, Field 2 ...

②order by Field ordinal (starting from 1)

③order by Field Alias

④order by field op-expression

2.ASC Ascending:

Default value

3.desc Descending

4. Sorting principle:

Top priority, if the previous data is consistent, sort by the following fields

Three. GROUP BY group

Usage: ①group by field List ②having filter records on a group basis

Data storage--sqlite Database storage--sql Statement--DQL data Query Language

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.