SlideShare a Scribd company logo
sqlite3 Command
Reference
The sqlite3 program is a command-line interface, or shell, that allows the user to
interactively issue SQL commands and display the results.
Command-Line Options
The sqlite3 tool understands the following command-line format:
sqlite3 [options...] [database [SQL_string]]
Options are given first, followed by an optional database filename. This database will
be opened as the main database
If a database filename is given, an optional SQL string can be provided. This string may
consist of one or more SQL statements separated by semicolons.
The interactive startup sequence will attempt to locate and open the .sqliterc init file
in the current user’s home directory. If the file exists, lines will be read and executed
before any other processing (including the command-line SQL string).
Interactive Dot-Commands
This section covers the sqlite3 dot-commands. Dot-commands control the mode and
configuration of the sqlite3 utility and, in some cases, the underlying SQLite library.
Normally, any input to the sqlite3 utility is assumed to be an SQL statement and is
passed to the SQLite library for processing. To distinguish these commands from SQL
statements, all of the dot-commands start with a period, or “dot.” Hence, the name.
.backup Perform a low-level copy of a database to file
Common Usage
.backup [database_name] filename
.bail Stop if an error is encountered
Common Usage
.bail switch
.databases List all of the currently attached databases
Common Usage
.databases
Description
The .databases command generates a table of all the currently attached databases. The format
of the table is:
.dump Produce an SQL dump file
Common Usage
.dump [table-pattern ...]
.echo Turn command echoing on or off
Common Usage
.echo switch
.exit Quit and exit the sqlite3 application
Common Usage
.exit
explain Format output for EXPLAIN SQL command
Common Usage
.explain [switch]
.headers Control display of column names and headers
Common Usage
.headers switch
.help Display help
Common Usage
.help
.import Import an external data file into a table
Common Usage
.import filename table-name
.indices Display all of the indexes associated with one or more tables
Common Usage
.indices [table-pattern]
.iotrace Direct I/O trace information to a file
Common Usage
.iotrace [filename|-]
.iotrace Direct I/O trace information to a file
Common Usage
.iotrace [filename|-]
.load Load a dynamic extension
Common Usage
.load filename [entry-point]
.log Turn logging on or off
Common Usage
.log (filename|stdout|stderr|off)
.mode Set the output mode
Common Usage
.mode (column[s]|csv|html|insert|line[s]|list|tabs|tcl) [table-name]
.nullvalue Set the string used to represent a NULL output
Common Usage
.nullvalue string
.output Set the output destination
Common Usage
.output (filename|stdout)
.prompt Set the command prompt
Common Usage
.prompt main [continue]
.quit Quit and exit the sqlite3 application
Common Usage
.quit
.read Execute SQL commands from a file
Common Usage
.read filename
.restore Perform a low-level copy of a database file to a database
Common Usage
.restore [database_name] filename
.schema Display SQL creation commands for schema
Common Usage
.schema [table-pattern]
.separator Define the string used as a column separator
Common Usage
.separator string
.tables Display the list of table and view names
Common Usage
.tables [table-pattern]
Description
The .tables command displays the list of names for all of the table and view objects that are
found in the main and temp databases.
.timeout Set a lock retry timer
Common Usage
.timeout milliseconds
.timer Enable or disable CPU time measurements
Common Usage
.timer switch
.width Set the display width for each column
Common Usage
.width numb [numb ...]
SQLite SQL Command Reference
This appendix lists the SQL commands and syntax that are supported by SQLite. SQL
statements consist of a single command and any required parameters. Command statements
are separated by a semicolon. Technically, standalone statements do not need
to be terminated with a semicolon, but most interactive environments require the use
of a semicolon to indicate that the current command statement is complete and should
be executed. For example, the C API sqlite3_exec() does not require that command
statements end with a semicolon, but interactive use of sqlite3 requires ending each
statement with a semicolon.
SQLite SQL Commands
The following SQL commands and syntax are supported by SQLite
Common Usage
ALTER TABLE database_name.table_name RENAME TO new_table_name;
ALTER TABLE database_name.table_name ADD COLUMN column_def...
ANALYZE Compute index meta-data
Syntax
Common Usage
ANALYZE;
ANALYZE database_name;
ANALYZE database_name.table_name;
ATTACH DATABASE Attach a database file
Syntax
Common Usage
ATTACH DATABASE 'filename' AS database_name;
BEGIN TRANSACTION Open an explicit transaction
Syntax
Common Usage
BEGIN;
BEGIN EXCLUSIVE TRANSACTION;
COMMIT TRANSACTION Finish and commit a transaction
Syntax
Common Usage
COMMIT;
CREATE INDEX Define and create a new table index
Syntax
Common Usage
CREATE INDEX index_name ON table_name ( column_name COLLATE NOCASE );
CREATE UNIQUE INDEX database_name.index_name ON table_name ( col1, col2 ,... );
CREATE TABLE Define and create a new table
Syntax
Ad

More Related Content

What's hot (15)

Les10 Creating And Managing Tables
Les10 Creating And Managing TablesLes10 Creating And Managing Tables
Les10 Creating And Managing Tables
NETsolutions Asia: NSA – Thailand, Sripatum University: SPU
 
Les11 Including Constraints
Les11 Including ConstraintsLes11 Including Constraints
Les11 Including Constraints
NETsolutions Asia: NSA – Thailand, Sripatum University: SPU
 
Oracle sql material
Oracle sql materialOracle sql material
Oracle sql material
prathap kumar
 
mySQL and Relational Databases
mySQL and Relational DatabasesmySQL and Relational Databases
mySQL and Relational Databases
webhostingguy
 
Oracle training in hyderabad
Oracle training in hyderabadOracle training in hyderabad
Oracle training in hyderabad
Kelly Technologies
 
Oracle: DML
Oracle: DMLOracle: DML
Oracle: DML
DataminingTools Inc
 
8. sql
8. sql8. sql
8. sql
khoahuy82
 
Commands of DML in SQL
Commands of DML in SQLCommands of DML in SQL
Commands of DML in SQL
Ashish Gaurkhede
 
Ado.net by Awais Majeed
Ado.net by Awais MajeedAdo.net by Awais Majeed
Ado.net by Awais Majeed
Awais Majeed
 
Sql dml & tcl 2
Sql   dml & tcl 2Sql   dml & tcl 2
Sql dml & tcl 2
Dr. C.V. Suresh Babu
 
SQL DDL
SQL DDLSQL DDL
SQL DDL
Vikas Gupta
 
Union based sql injection by Urdu Tutorials Point
Union based sql injection by Urdu Tutorials PointUnion based sql injection by Urdu Tutorials Point
Union based sql injection by Urdu Tutorials Point
Al Zarqali
 
Babitha2.mysql
Babitha2.mysqlBabitha2.mysql
Babitha2.mysql
banubabitha
 
2
22
2
gbBehere
 
Mysqlppt
MysqlpptMysqlppt
Mysqlppt
poornima sugumaran
 

Viewers also liked (20)

Python sqlite3
Python sqlite3Python sqlite3
Python sqlite3
Alexey Bovanenko
 
Python sqlite3 - flask
Python   sqlite3 - flaskPython   sqlite3 - flask
Python sqlite3 - flask
Eueung Mulyana
 
Виктор Ашик — «Командная строка Unix»
Виктор Ашик — «Командная строка Unix»Виктор Ашик — «Командная строка Unix»
Виктор Ашик — «Командная строка Unix»
Yandex
 
Виктор Ашик - Python, part 1
Виктор Ашик - Python, part 1Виктор Ашик - Python, part 1
Виктор Ашик - Python, part 1
Yandex
 
Python. Строки
Python. СтрокиPython. Строки
Python. Строки
Alexey Bovanenko
 
Обработка символов в языке C
Обработка символов в языке CОбработка символов в языке C
Обработка символов в языке C
Alexey Bovanenko
 
Виктор Ашик - Профессии в мире информационных технологий
Виктор Ашик - Профессии в мире информационных технологийВиктор Ашик - Профессии в мире информационных технологий
Виктор Ашик - Профессии в мире информационных технологий
Yandex
 
Advance sqlite3
Advance sqlite3Advance sqlite3
Advance sqlite3
Raghu nath
 
(140625) #fitalk sq lite 소개와 구조 분석
(140625) #fitalk   sq lite 소개와 구조 분석(140625) #fitalk   sq lite 소개와 구조 분석
(140625) #fitalk sq lite 소개와 구조 분석
INSIGHT FORENSIC
 
SQLite3
SQLite3SQLite3
SQLite3
cltru
 
SQLite Techniques
SQLite TechniquesSQLite Techniques
SQLite Techniques
joaopmaia
 
Aula 06 - TEP - Introdução SQLite
Aula 06 - TEP - Introdução SQLiteAula 06 - TEP - Introdução SQLite
Aula 06 - TEP - Introdução SQLite
Anderson Fabiano Dums
 
Sqlite
SqliteSqlite
Sqlite
Raghu nath
 
SQLite
SQLiteSQLite
SQLite
Fabio Colan Wong
 
Sqlite
SqliteSqlite
Sqlite
juan david santacruz
 
Fun with Python
Fun with PythonFun with Python
Fun with Python
Narong Intiruk
 
SQLite 3
SQLite 3SQLite 3
SQLite 3
Scott MacVicar
 
SQLite: Light, Open Source Relational Database Management System
SQLite: Light, Open Source Relational Database Management SystemSQLite: Light, Open Source Relational Database Management System
SQLite: Light, Open Source Relational Database Management System
Tanner Jessel
 
SQLite - Overview
SQLite - OverviewSQLite - Overview
SQLite - Overview
Emanuele Bartolesi
 
Begin with Python
Begin with PythonBegin with Python
Begin with Python
Narong Intiruk
 
Python sqlite3 - flask
Python   sqlite3 - flaskPython   sqlite3 - flask
Python sqlite3 - flask
Eueung Mulyana
 
Виктор Ашик — «Командная строка Unix»
Виктор Ашик — «Командная строка Unix»Виктор Ашик — «Командная строка Unix»
Виктор Ашик — «Командная строка Unix»
Yandex
 
Виктор Ашик - Python, part 1
Виктор Ашик - Python, part 1Виктор Ашик - Python, part 1
Виктор Ашик - Python, part 1
Yandex
 
Обработка символов в языке C
Обработка символов в языке CОбработка символов в языке C
Обработка символов в языке C
Alexey Bovanenko
 
Виктор Ашик - Профессии в мире информационных технологий
Виктор Ашик - Профессии в мире информационных технологийВиктор Ашик - Профессии в мире информационных технологий
Виктор Ашик - Профессии в мире информационных технологий
Yandex
 
Advance sqlite3
Advance sqlite3Advance sqlite3
Advance sqlite3
Raghu nath
 
(140625) #fitalk sq lite 소개와 구조 분석
(140625) #fitalk   sq lite 소개와 구조 분석(140625) #fitalk   sq lite 소개와 구조 분석
(140625) #fitalk sq lite 소개와 구조 분석
INSIGHT FORENSIC
 
SQLite3
SQLite3SQLite3
SQLite3
cltru
 
SQLite Techniques
SQLite TechniquesSQLite Techniques
SQLite Techniques
joaopmaia
 
SQLite: Light, Open Source Relational Database Management System
SQLite: Light, Open Source Relational Database Management SystemSQLite: Light, Open Source Relational Database Management System
SQLite: Light, Open Source Relational Database Management System
Tanner Jessel
 
Ad

Similar to Sqlite3 command reference (20)

Module 3
Module 3Module 3
Module 3
cs19club
 
Adbms
AdbmsAdbms
Adbms
jass12345
 
The sqlite3 commnad line tool
The sqlite3 commnad line toolThe sqlite3 commnad line tool
The sqlite3 commnad line tool
punu_82
 
Introduction4 SQLite
Introduction4 SQLiteIntroduction4 SQLite
Introduction4 SQLite
Stanley Huang
 
Sql tutorial
Sql tutorialSql tutorial
Sql tutorial
Rumman Ansari
 
Mysqlppt
MysqlpptMysqlppt
Mysqlppt
poornima sugumaran
 
Sqlapi0.1
Sqlapi0.1Sqlapi0.1
Sqlapi0.1
jitendral
 
Dynamic websites lec3
Dynamic websites lec3Dynamic websites lec3
Dynamic websites lec3
Belal Arfa
 
DBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptx
DBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptxDBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptx
DBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptx
universalcomputer1
 
SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3
SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3
SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3
Dan D'Urso
 
Data Definition Language Commands - Examples
Data Definition Language Commands - ExamplesData Definition Language Commands - Examples
Data Definition Language Commands - Examples
Deena38
 
Sql lite android
Sql lite androidSql lite android
Sql lite android
Dushyant Nasit
 
Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...
Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...
Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...
TAISEEREISA
 
Concepts of NonStop SQL/MX: Part 3 - Introduction to Metadata
Concepts of NonStop SQL/MX: Part 3 - Introduction to MetadataConcepts of NonStop SQL/MX: Part 3 - Introduction to Metadata
Concepts of NonStop SQL/MX: Part 3 - Introduction to Metadata
Frans Jongma
 
SQL commands
SQL commandsSQL commands
SQL commands
GirdharRatne
 
Database programming
Database programmingDatabase programming
Database programming
Shree M.L.Kakadiya MCA mahila college, Amreli
 
My sql.ppt
My sql.pptMy sql.ppt
My sql.ppt
MAGNA COLLEGE OF ENGINEERING
 
Cursors, triggers, procedures
Cursors, triggers, proceduresCursors, triggers, procedures
Cursors, triggers, procedures
Vaibhav Kathuria
 
My lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptx
My lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptxMy lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptx
My lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptx
EliasPetros
 
MySQL and its basic commands
MySQL and its basic commandsMySQL and its basic commands
MySQL and its basic commands
Bwsrang Basumatary
 
The sqlite3 commnad line tool
The sqlite3 commnad line toolThe sqlite3 commnad line tool
The sqlite3 commnad line tool
punu_82
 
Introduction4 SQLite
Introduction4 SQLiteIntroduction4 SQLite
Introduction4 SQLite
Stanley Huang
 
Dynamic websites lec3
Dynamic websites lec3Dynamic websites lec3
Dynamic websites lec3
Belal Arfa
 
DBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptx
DBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptxDBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptx
DBMS week 2 hjghg hvgfhgf,3 BSCS 6th.pptx
universalcomputer1
 
SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3
SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3
SQL202.3 Accelerated Introduction to SQL Using SQL Server Module 3
Dan D'Urso
 
Data Definition Language Commands - Examples
Data Definition Language Commands - ExamplesData Definition Language Commands - Examples
Data Definition Language Commands - Examples
Deena38
 
Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...
Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...
Chapter 3.pptx Oracle SQL or local Android database setup SQL, SQL-Lite, codi...
TAISEEREISA
 
Concepts of NonStop SQL/MX: Part 3 - Introduction to Metadata
Concepts of NonStop SQL/MX: Part 3 - Introduction to MetadataConcepts of NonStop SQL/MX: Part 3 - Introduction to Metadata
Concepts of NonStop SQL/MX: Part 3 - Introduction to Metadata
Frans Jongma
 
Cursors, triggers, procedures
Cursors, triggers, proceduresCursors, triggers, procedures
Cursors, triggers, procedures
Vaibhav Kathuria
 
My lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptx
My lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptxMy lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptx
My lablkxjlkxjcvlxkcjvlxckjvlxck ppt.pptx
EliasPetros
 
Ad

More from Raghu nath (20)

Mongo db
Mongo dbMongo db
Mongo db
Raghu nath
 
Ftp (file transfer protocol)
Ftp (file transfer protocol)Ftp (file transfer protocol)
Ftp (file transfer protocol)
Raghu nath
 
MS WORD 2013
MS WORD 2013MS WORD 2013
MS WORD 2013
Raghu nath
 
Msword
MswordMsword
Msword
Raghu nath
 
Ms word
Ms wordMs word
Ms word
Raghu nath
 
Javascript part1
Javascript part1Javascript part1
Javascript part1
Raghu nath
 
Regular expressions
Regular expressionsRegular expressions
Regular expressions
Raghu nath
 
Selection sort
Selection sortSelection sort
Selection sort
Raghu nath
 
Binary search
Binary search Binary search
Binary search
Raghu nath
 
JSON(JavaScript Object Notation)
JSON(JavaScript Object Notation)JSON(JavaScript Object Notation)
JSON(JavaScript Object Notation)
Raghu nath
 
Stemming algorithms
Stemming algorithmsStemming algorithms
Stemming algorithms
Raghu nath
 
Step by step guide to install dhcp role
Step by step guide to install dhcp roleStep by step guide to install dhcp role
Step by step guide to install dhcp role
Raghu nath
 
Network essentials chapter 4
Network essentials  chapter 4Network essentials  chapter 4
Network essentials chapter 4
Raghu nath
 
Network essentials chapter 3
Network essentials  chapter 3Network essentials  chapter 3
Network essentials chapter 3
Raghu nath
 
Network essentials chapter 2
Network essentials  chapter 2Network essentials  chapter 2
Network essentials chapter 2
Raghu nath
 
Network essentials - chapter 1
Network essentials - chapter 1Network essentials - chapter 1
Network essentials - chapter 1
Raghu nath
 
Python chapter 2
Python chapter 2Python chapter 2
Python chapter 2
Raghu nath
 
python chapter 1
python chapter 1python chapter 1
python chapter 1
Raghu nath
 
Linux Shell Scripting
Linux Shell ScriptingLinux Shell Scripting
Linux Shell Scripting
Raghu nath
 
Perl
PerlPerl
Perl
Raghu nath
 
Ftp (file transfer protocol)
Ftp (file transfer protocol)Ftp (file transfer protocol)
Ftp (file transfer protocol)
Raghu nath
 
Javascript part1
Javascript part1Javascript part1
Javascript part1
Raghu nath
 
Regular expressions
Regular expressionsRegular expressions
Regular expressions
Raghu nath
 
Selection sort
Selection sortSelection sort
Selection sort
Raghu nath
 
Binary search
Binary search Binary search
Binary search
Raghu nath
 
JSON(JavaScript Object Notation)
JSON(JavaScript Object Notation)JSON(JavaScript Object Notation)
JSON(JavaScript Object Notation)
Raghu nath
 
Stemming algorithms
Stemming algorithmsStemming algorithms
Stemming algorithms
Raghu nath
 
Step by step guide to install dhcp role
Step by step guide to install dhcp roleStep by step guide to install dhcp role
Step by step guide to install dhcp role
Raghu nath
 
Network essentials chapter 4
Network essentials  chapter 4Network essentials  chapter 4
Network essentials chapter 4
Raghu nath
 
Network essentials chapter 3
Network essentials  chapter 3Network essentials  chapter 3
Network essentials chapter 3
Raghu nath
 
Network essentials chapter 2
Network essentials  chapter 2Network essentials  chapter 2
Network essentials chapter 2
Raghu nath
 
Network essentials - chapter 1
Network essentials - chapter 1Network essentials - chapter 1
Network essentials - chapter 1
Raghu nath
 
Python chapter 2
Python chapter 2Python chapter 2
Python chapter 2
Raghu nath
 
python chapter 1
python chapter 1python chapter 1
python chapter 1
Raghu nath
 
Linux Shell Scripting
Linux Shell ScriptingLinux Shell Scripting
Linux Shell Scripting
Raghu nath
 

Recently uploaded (20)

MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2
LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2
LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2
LDM & Mia eStudios
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
Nguyen Thanh Tu Collection
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptxU3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
Mayuri Chavan
 
COPA Apprentice exam Questions and answers PDF
COPA Apprentice exam Questions and answers PDFCOPA Apprentice exam Questions and answers PDF
COPA Apprentice exam Questions and answers PDF
SONU HEETSON
 
libbys peer assesment.docx..............
libbys peer assesment.docx..............libbys peer assesment.docx..............
libbys peer assesment.docx..............
19lburrell
 
Unit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptx
Unit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptxUnit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptx
Unit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptx
Mayuri Chavan
 
Bipolar Junction Transistors (BJTs): Basics, Construction & Configurations
Bipolar Junction Transistors (BJTs): Basics, Construction & ConfigurationsBipolar Junction Transistors (BJTs): Basics, Construction & Configurations
Bipolar Junction Transistors (BJTs): Basics, Construction & Configurations
GS Virdi
 
INDIA QUIZ FOR SCHOOLS | THE QUIZ CLUB OF PSGCAS | AUGUST 2024
INDIA QUIZ FOR SCHOOLS | THE QUIZ CLUB OF PSGCAS | AUGUST 2024INDIA QUIZ FOR SCHOOLS | THE QUIZ CLUB OF PSGCAS | AUGUST 2024
INDIA QUIZ FOR SCHOOLS | THE QUIZ CLUB OF PSGCAS | AUGUST 2024
Quiz Club of PSG College of Arts & Science
 
How to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 PurchaseHow to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 Purchase
Celine George
 
INSULIN.pptx by Arka Das (Bsc. Critical care technology)
INSULIN.pptx by Arka Das (Bsc. Critical care technology)INSULIN.pptx by Arka Das (Bsc. Critical care technology)
INSULIN.pptx by Arka Das (Bsc. Critical care technology)
ArkaDas54
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
Search Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo SlidesSearch Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo Slides
Celine George
 
Module_2_Types_and_Approaches_of_Research (2).pptx
Module_2_Types_and_Approaches_of_Research (2).pptxModule_2_Types_and_Approaches_of_Research (2).pptx
Module_2_Types_and_Approaches_of_Research (2).pptx
drroxannekemp
 
Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............
19lburrell
 
Final Evaluation.docx...........................
Final Evaluation.docx...........................Final Evaluation.docx...........................
Final Evaluation.docx...........................
l1bbyburrell
 
INQUISITORS School Quiz Prelims 2025.pptx
INQUISITORS School Quiz Prelims 2025.pptxINQUISITORS School Quiz Prelims 2025.pptx
INQUISITORS School Quiz Prelims 2025.pptx
SujatyaRoy
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
parmarjuli1412
 
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2
LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2
LDMMIA Reiki Yoga S6 Free Workshop Money Pt 2
LDM & Mia eStudios
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
Nguyen Thanh Tu Collection
 
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales moduleHow To Maximize Sales Performance using Odoo 18 Diverse views in sales module
How To Maximize Sales Performance using Odoo 18 Diverse views in sales module
Celine George
 
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptxU3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
U3 ANTITUBERCULAR DRUGS Pharmacology 3.pptx
Mayuri Chavan
 
COPA Apprentice exam Questions and answers PDF
COPA Apprentice exam Questions and answers PDFCOPA Apprentice exam Questions and answers PDF
COPA Apprentice exam Questions and answers PDF
SONU HEETSON
 
libbys peer assesment.docx..............
libbys peer assesment.docx..............libbys peer assesment.docx..............
libbys peer assesment.docx..............
19lburrell
 
Unit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptx
Unit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptxUnit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptx
Unit 5 ACUTE, SUBACUTE,CHRONIC TOXICITY.pptx
Mayuri Chavan
 
Bipolar Junction Transistors (BJTs): Basics, Construction & Configurations
Bipolar Junction Transistors (BJTs): Basics, Construction & ConfigurationsBipolar Junction Transistors (BJTs): Basics, Construction & Configurations
Bipolar Junction Transistors (BJTs): Basics, Construction & Configurations
GS Virdi
 
How to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 PurchaseHow to Manage Amounts in Local Currency in Odoo 18 Purchase
How to Manage Amounts in Local Currency in Odoo 18 Purchase
Celine George
 
INSULIN.pptx by Arka Das (Bsc. Critical care technology)
INSULIN.pptx by Arka Das (Bsc. Critical care technology)INSULIN.pptx by Arka Das (Bsc. Critical care technology)
INSULIN.pptx by Arka Das (Bsc. Critical care technology)
ArkaDas54
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
Search Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo SlidesSearch Matching Applicants in Odoo 18 - Odoo Slides
Search Matching Applicants in Odoo 18 - Odoo Slides
Celine George
 
Module_2_Types_and_Approaches_of_Research (2).pptx
Module_2_Types_and_Approaches_of_Research (2).pptxModule_2_Types_and_Approaches_of_Research (2).pptx
Module_2_Types_and_Approaches_of_Research (2).pptx
drroxannekemp
 
Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............Peer Assesment- Libby.docx..............
Peer Assesment- Libby.docx..............
19lburrell
 
Final Evaluation.docx...........................
Final Evaluation.docx...........................Final Evaluation.docx...........................
Final Evaluation.docx...........................
l1bbyburrell
 
INQUISITORS School Quiz Prelims 2025.pptx
INQUISITORS School Quiz Prelims 2025.pptxINQUISITORS School Quiz Prelims 2025.pptx
INQUISITORS School Quiz Prelims 2025.pptx
SujatyaRoy
 
Module 1: Foundations of Research
Module 1: Foundations of ResearchModule 1: Foundations of Research
Module 1: Foundations of Research
drroxannekemp
 
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
Mental Health Assessment in 5th semester bsc. nursing and also used in 2nd ye...
parmarjuli1412
 

Sqlite3 command reference

  • 2. The sqlite3 program is a command-line interface, or shell, that allows the user to interactively issue SQL commands and display the results.
  • 3. Command-Line Options The sqlite3 tool understands the following command-line format: sqlite3 [options...] [database [SQL_string]] Options are given first, followed by an optional database filename. This database will be opened as the main database
  • 4. If a database filename is given, an optional SQL string can be provided. This string may consist of one or more SQL statements separated by semicolons.
  • 5. The interactive startup sequence will attempt to locate and open the .sqliterc init file in the current user’s home directory. If the file exists, lines will be read and executed before any other processing (including the command-line SQL string).
  • 6. Interactive Dot-Commands This section covers the sqlite3 dot-commands. Dot-commands control the mode and configuration of the sqlite3 utility and, in some cases, the underlying SQLite library. Normally, any input to the sqlite3 utility is assumed to be an SQL statement and is passed to the SQLite library for processing. To distinguish these commands from SQL statements, all of the dot-commands start with a period, or “dot.” Hence, the name.
  • 7. .backup Perform a low-level copy of a database to file Common Usage .backup [database_name] filename
  • 8. .bail Stop if an error is encountered Common Usage .bail switch .databases List all of the currently attached databases Common Usage .databases Description The .databases command generates a table of all the currently attached databases. The format of the table is:
  • 9. .dump Produce an SQL dump file Common Usage .dump [table-pattern ...] .echo Turn command echoing on or off Common Usage .echo switch
  • 10. .exit Quit and exit the sqlite3 application Common Usage .exit explain Format output for EXPLAIN SQL command Common Usage .explain [switch]
  • 11. .headers Control display of column names and headers Common Usage .headers switch .help Display help Common Usage .help
  • 12. .import Import an external data file into a table Common Usage .import filename table-name
  • 13. .indices Display all of the indexes associated with one or more tables Common Usage .indices [table-pattern]
  • 14. .iotrace Direct I/O trace information to a file Common Usage .iotrace [filename|-]
  • 15. .iotrace Direct I/O trace information to a file Common Usage .iotrace [filename|-]
  • 16. .load Load a dynamic extension Common Usage .load filename [entry-point]
  • 17. .log Turn logging on or off Common Usage .log (filename|stdout|stderr|off)
  • 18. .mode Set the output mode Common Usage .mode (column[s]|csv|html|insert|line[s]|list|tabs|tcl) [table-name]
  • 19. .nullvalue Set the string used to represent a NULL output Common Usage .nullvalue string
  • 20. .output Set the output destination Common Usage .output (filename|stdout)
  • 21. .prompt Set the command prompt Common Usage .prompt main [continue]
  • 22. .quit Quit and exit the sqlite3 application Common Usage .quit
  • 23. .read Execute SQL commands from a file Common Usage .read filename
  • 24. .restore Perform a low-level copy of a database file to a database Common Usage .restore [database_name] filename
  • 25. .schema Display SQL creation commands for schema Common Usage .schema [table-pattern]
  • 26. .separator Define the string used as a column separator Common Usage .separator string
  • 27. .tables Display the list of table and view names Common Usage .tables [table-pattern] Description The .tables command displays the list of names for all of the table and view objects that are found in the main and temp databases.
  • 28. .timeout Set a lock retry timer Common Usage .timeout milliseconds
  • 29. .timer Enable or disable CPU time measurements Common Usage .timer switch
  • 30. .width Set the display width for each column Common Usage .width numb [numb ...]
  • 31. SQLite SQL Command Reference This appendix lists the SQL commands and syntax that are supported by SQLite. SQL statements consist of a single command and any required parameters. Command statements are separated by a semicolon. Technically, standalone statements do not need to be terminated with a semicolon, but most interactive environments require the use of a semicolon to indicate that the current command statement is complete and should be executed. For example, the C API sqlite3_exec() does not require that command statements end with a semicolon, but interactive use of sqlite3 requires ending each statement with a semicolon.
  • 32. SQLite SQL Commands The following SQL commands and syntax are supported by SQLite
  • 33. Common Usage ALTER TABLE database_name.table_name RENAME TO new_table_name; ALTER TABLE database_name.table_name ADD COLUMN column_def...
  • 34. ANALYZE Compute index meta-data Syntax
  • 36. ATTACH DATABASE Attach a database file Syntax
  • 37. Common Usage ATTACH DATABASE 'filename' AS database_name;
  • 38. BEGIN TRANSACTION Open an explicit transaction Syntax
  • 40. COMMIT TRANSACTION Finish and commit a transaction Syntax
  • 42. CREATE INDEX Define and create a new table index Syntax
  • 43. Common Usage CREATE INDEX index_name ON table_name ( column_name COLLATE NOCASE ); CREATE UNIQUE INDEX database_name.index_name ON table_name ( col1, col2 ,... );
  • 44. CREATE TABLE Define and create a new table Syntax
  翻译: