*** DRAFT ***

SQLite Requirement Matrix Details
lang_attach.html

Index Summary Markup Original


R-64211-14083-15394-12432-42545-02985-25108-50644 tcl slt th3 src

Canonical usage: syntax/attach-stmt.html

/* IMP: R-64211-14083 */
# EVIDENCE-OF: R-64211-14083 -- syntax diagram attach-stmt

R-63282-43996-47481-25333-53243-51474-00238-17595 tcl slt th3 src

Canonical usage: syntax/expr.html

/* IMP: R-63282-43996 */
# EVIDENCE-OF: R-63282-43996 -- syntax diagram expr

R-10696-30084-53665-51146-23084-19397-22440-65131 tcl slt th3 src

Canonical usage: syntax/filter.html

/* IMP: R-10696-30084 */
# EVIDENCE-OF: R-10696-30084 -- syntax diagram filter

R-31509-35291-02084-41894-63319-63663-58586-07091 tcl slt th3 src

Canonical usage: syntax/literal-value.html

/* IMP: R-31509-35291 */
# EVIDENCE-OF: R-31509-35291 -- syntax diagram literal-value

R-60581-03341-52039-04890-58008-25772-53660-37704 tcl slt th3 src

Canonical usage: syntax/raise-function.html

/* IMP: R-60581-03341 */
# EVIDENCE-OF: R-60581-03341 -- syntax diagram raise-function

R-61628-17125-33025-56567-55142-03215-04610-55795 tcl slt th3 src

Canonical usage: syntax/select-stmt.html

/* IMP: R-61628-17125 */
# EVIDENCE-OF: R-61628-17125 -- syntax diagram select-stmt

R-47013-63517-59451-29791-27627-32329-00299-29666 tcl slt th3 src

Canonical usage: syntax/common-table-expression.html

/* IMP: R-47013-63517 */
# EVIDENCE-OF: R-47013-63517 -- syntax diagram common-table-expression

R-21508-23055-03544-43069-03700-52529-28655-04212 tcl slt th3 src

Canonical usage: syntax/compound-operator.html

/* IMP: R-21508-23055 */
# EVIDENCE-OF: R-21508-23055 -- syntax diagram compound-operator

R-23545-53633-60682-12631-15952-36070-08340-26441 tcl slt th3 src

Canonical usage: syntax/join-clause.html

/* IMP: R-23545-53633 */
# EVIDENCE-OF: R-23545-53633 -- syntax diagram join-clause

R-46541-20938-58372-53058-01043-12045-25030-53791 tcl slt th3 src

Canonical usage: syntax/join-constraint.html

/* IMP: R-46541-20938 */
# EVIDENCE-OF: R-46541-20938 -- syntax diagram join-constraint

R-27408-41206-06272-65057-49531-23299-28505-37113 tcl slt th3 src

Canonical usage: syntax/join-operator.html

/* IMP: R-27408-41206 */
# EVIDENCE-OF: R-27408-41206 -- syntax diagram join-operator

R-16212-04751-50585-08411-35285-00447-20753-02198 tcl slt th3 src

Canonical usage: syntax/ordering-term.html

/* IMP: R-16212-04751 */
# EVIDENCE-OF: R-16212-04751 -- syntax diagram ordering-term

R-62030-13484-53274-47431-56373-62021-33007-11272 tcl slt th3 src

Canonical usage: syntax/result-column.html

/* IMP: R-62030-13484 */
# EVIDENCE-OF: R-62030-13484 -- syntax diagram result-column

R-28724-59332-25400-14786-42579-47587-28356-56547 tcl slt th3 src

Canonical usage: syntax/table-or-subquery.html

/* IMP: R-28724-59332 */
# EVIDENCE-OF: R-28724-59332 -- syntax diagram table-or-subquery

R-31272-00274-62255-43298-23904-43777-05391-16185 tcl slt th3 src

Canonical usage: syntax/type-name.html

/* IMP: R-31272-00274 */
# EVIDENCE-OF: R-31272-00274 -- syntax diagram type-name

R-10061-51853-18488-63481-25877-45384-53744-51666 tcl slt th3 src

Canonical usage: syntax/signed-number.html

/* IMP: R-10061-51853 */
# EVIDENCE-OF: R-10061-51853 -- syntax diagram signed-number

R-27989-13151-39943-32082-13046-13205-21280-24214 tcl slt th3 src

Canonical usage: syntax/window-defn.html

/* IMP: R-27989-13151 */
# EVIDENCE-OF: R-27989-13151 -- syntax diagram window-defn

R-16609-30688-17519-40340-07426-24422-28783-40081 tcl slt th3 src

Canonical usage: syntax/frame-spec.html

/* IMP: R-16609-30688 */
# EVIDENCE-OF: R-16609-30688 -- syntax diagram frame-spec

R-16212-04751-50585-08411-35285-00447-20753-02198 tcl slt th3 src

Canonical usage: syntax/ordering-term.html

/* IMP: R-16212-04751 */
# EVIDENCE-OF: R-16212-04751 -- syntax diagram ordering-term

R-35371-58843-38332-21753-13618-41551-34238-06657 tcl slt th3 src

The ATTACH DATABASE statement adds another database file to the current database connection.

th3/req1/attach01.test:18

/* IMP: R-35371-58843 */
# EVIDENCE-OF: R-35371-58843 The ATTACH DATABASE statement adds another
# database file to the current database connection.

R-02612-37947-62500-41847-13282-34946-09245-20088 tcl slt th3 src

The filename for the database to be attached is the value of the expression that occurs before the AS keyword.

th3/req1/attach01.test:21

/* IMP: R-02612-37947 */
# EVIDENCE-OF: R-02612-37947 The filename for the database to be
# attached is the value of the expression that occurs before the AS
# keyword.

R-57724-31954-10264-24402-01814-32974-35251-10420 tcl slt th3 src

The filename of the database follows the same semantics as the filename argument to sqlite3_open() and sqlite3_open_v2(); the special name ":memory:" results in an in-memory database and an empty string results in a new temporary database.

th3/req1/attach03.test:10

/* IMP: R-57724-31954 */
# EVIDENCE-OF: R-57724-31954 The filename of the database follows the
# same semantics as the filename argument to sqlite3_open() and
# sqlite3_open_v2(); the special name ":memory:" results in an in-memory
# database and an empty string results in a new temporary database.

R-00402-11496-45496-40393-08263-15231-62727-28991 tcl slt th3 src

The filename argument can be a URI filename if URI filename processing is enable on the database connection.

th3/cov1/sharedcache03.test:236

/* IMP: R-00402-11496 */
# EVIDENCE-OF: R-00402-11496 The filename argument can be a URI filename
# if URI filename processing is enable on the database connection.

R-40602-24566-60725-06279-09295-25327-26293-64572 tcl slt th3 src

The schema-names 'main' and 'temp' refer to the main database and the database used for temporary tables.

th3/req1/attach01.test:30

/* IMP: R-40602-24566 */
# EVIDENCE-OF: R-40602-24566 The schema-names 'main' and 'temp' refer to
# the main database and the database used for temporary tables.

R-43455-30330-13340-63618-42639-11266-34972-33026 tcl slt th3 src

The main and temp databases cannot be attached or detached.

th3/req1/attach01.test:38

/* IMP: R-43455-30330 */
# EVIDENCE-OF: R-43455-30330 The main and temp databases cannot be
# attached or detached.

R-04549-59621-55549-18042-51558-13572-61866-18080 tcl slt th3 src

Tables in an attached database can be referred to using the syntax schema-name.table-name.

th3/req1/attach01.test:105

/* IMP: R-04549-59621 */
# EVIDENCE-OF: R-04549-59621 Tables in an attached database can be
# referred to using the syntax schema-name.table-name.

R-38412-06710-13373-27041-27382-60302-02109-00077 tcl slt th3 src

If the name of the table is unique across all attached databases and the main and temp databases, then the schema-name prefix is not required.

th3/req1/attach01.test:168

/* IMP: R-38412-06710 */
# EVIDENCE-OF: R-38412-06710 If the name of the table is unique across
# all attached databases and the main and temp databases, then the
# schema-name prefix is not required.

R-55636-16561-36868-23956-09727-21947-00276-50271 tcl slt th3 src

If two or more tables in different databases have the same name and the schema-name prefix is not used on a table reference, then the table chosen is the one in the database that was least recently attached.

th3/req1/attach01.test:143

/* IMP: R-55636-16561 */
# EVIDENCE-OF: R-55636-16561 If two or more tables in different
# databases have the same name and the schema-name prefix is not used on
# a table reference, then the table chosen is the one in the database
# that was least recently attached.

R-10872-35808-62525-46404-48063-22154-06728-34056 tcl slt th3 src

Transactions involving multiple attached databases are atomic, assuming that the main database is not ":memory:" and the journal_mode is not WAL.

th3/req1/attach02.test:11   th3/stress/crash002.test:14   th3/stress/crash003.test:12

/* IMP: R-10872-35808 */
# EVIDENCE-OF: R-10872-35808 Transactions involving multiple attached
# databases are atomic, assuming that the main database is not
# ":memory:" and the journal_mode is not WAL.

R-34979-54336-33279-53576-25867-30233-28350-04331 tcl slt th3 src

If the main database is ":memory:" or if the journal_mode is WAL, then transactions continue to be atomic within each individual database file. But if the host computer crashes in the middle of a COMMIT where two or more database files are updated, some of those files might get the changes where others might not.

th3/req1/attach02.test:15

/* IMP: R-34979-54336 */
# EVIDENCE-OF: R-34979-54336 If the main database is ":memory:" or if
# the journal_mode is WAL, then transactions continue to be atomic
# within each individual database file. But if the host computer crashes
# in the middle of a COMMIT where two or more database files are
# updated, some of those files might get the changes where others might
# not.

R-06367-56981-61813-52742-22421-22635-19629-30966 tcl slt th3 src

There is a limit, set using sqlite3_limit() and SQLITE_LIMIT_ATTACHED, to the number of databases that can be simultaneously attached to a single database connection.

th3/req1/attach01.test:207

/* IMP: R-06367-56981 */
# EVIDENCE-OF: R-06367-56981 There is a limit, set using sqlite3_limit()
# and SQLITE_LIMIT_ATTACHED, to the number of databases that can be
# simultaneously attached to a single database connection.