In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Database is widely used in all major operating systems such as Java, Android, IOS, Windows and so on.
Although SQLite is a lightweight small engine, it can support databases up to 2TB size. It exists in the form of a single file and is stored on disk in the form of B-Tree data structure. It has the characteristics of lightweight, independence, isolation, cross-platform, multi-language and interface, security and so on.
Multiple processes can read data from the consolidated database at a unified time, but only one can write data
About SQLite data types: SQlite supports NULL (null), INTEGER (× × value), REAL (floating point value), TEXT (string value) and BLOB (binary object) data types
Dynamic data type (weak reference): when a value is inserted into the database, SQLite will check its type. If the type does not match the associated column, SQLite will try to convert the value to the type of the column. If it cannot be converted, the value will be stored as its own type.
Database (database): equivalent to an excel file, it is the carrier of several data tables, and there can be several data tables inside.
Data sheet (table): equivalent to a worksheet in an excel file, used to store data
Column / field (column): that is, a vertical row
Row: that is, a horizontal row
Related English: design: design, unique: unique, execute: execution, insert: insert, into: to. Inside, delete: delete, auto: automatic, increment: grow / add, primary: primary, primary key: primary key, version: version
The statement of SQL is a series of fixed statements with specified format, which is used to manage all the contents of the database.
Then there is the use of SQLite.
SQLite has two main classes: 1.SQLiteDatabase 2.SQLiteOpenHelper
1.SQLiteDatabase: provides classes for managing SQLite databases, methods for creating, deleting, modifying, executing SQL commands, and performing other common database management tasks
These are the main additions, deletions, deletions and corrections.
[create data Table]
Syntax: create table table name (field design list)
Field design list syntax: field name field data type field constraint
The fields are separated by commas in English
Example: create table teachers (name varchar (8) not null unique, tel varchar (16), email varchar (50)) / / the number in parentheses is limited to the maximum number of words entered
Note that there must be a space between each attribute and the attribute above
[add data]
Syntax: insert into table name (field list) values (values list)
Example:
Insert into teachers (name, tel, email) values ('Wang Wu', '13800138001,' wangwu@tedu.cn')
Insert into teachers (email, name, tel) values ('lisi@tedu.cn',' Li Si', '13800138006')
Insert into teachers (name) values ('Zhang San')
[delete data]
Syntax: delete from table name [where clause]
Syntax of the where clause: where field conditional operator value [relational operator field conditional operator value]
Conditional operator: = > =
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.