Вы находитесь на странице: 1из 2949

SQLite ADO.

NET Provider
SQLite.NET Class Library Documentation
About SQLite.NET
This class library is an ADO.NET wrapper around the popular (and free!) SQLite database engine. For
information on SQL syntax, features of SQLite and a good understanding of how it works and what it
does, I highly recommend heading over to sqlite.org and reading the documentation there.
The C# provider, the very minor C code modifications to SQLite, documentation and etc were written by
Robert Simpson, and the SourceForge project page can be found here.
The System.Data.SQLite project is currently maintained by the SQLite Development Team and the latest
source code and project information can be found here.
What's New?
Click here to see the version history of this SQLite.NET provider
Using this library
The following are links to information on various aspects of the library and how to use it in your
application(s)
How to install Visual Studio Design-Time Support
How to configure and enumerate SQLite.NET through the DbProviderFactories object
Getting the best performance out of SQLite
Limitations of the SQLite.NET provider and the SQLite engine (compared to other providers and engines)
SQLite.NET Provider Features
This SQLite provider implements every feature of the underlying SQLite database engine without
omission. Here's a brief summary:
Written from scratch on Visual Studio 2008 specifically for ADO.NET, implenting all the base
classes and features recently introduced in the framework, including automatic transaction
enlistment.
Supports the Full and Compact .NET Framework, as well as native C/C++ development. 100%
binary compatible with the original sqlite3.dll.
Full support for Mono via a "managed only" provider that runs against the official SQLite 3.6.1 or
higher library.
Full Entity Framework support (ADO.NET 3.5 SP1)
On the Compact Framework, it is faster than Sql Server Mobile. SQLite's installed size is a
fraction of Sql Mobile's. It uses less memory at runtime, runs queries faster, and has a smaller
database file size as well.
Encrypted database support. Encrypted databases are fully encrypted and support both binary
and cleartext password types.
Visual Studio 2005/2008/2010/2012/2013/2015 Design-Time Support. You can add a SQLite
database to the Servers list, design queries with the Query Designer, drag-and-drop tables onto a
Typed DataSet, etc.
Full SQLite schema editing inside Visual Studio. You can create/edit tables, views, triggers,
indexes, check constraints and foreign keys.
Available as a single file redistributable (except Compact Framework). The core sqlite3 codebase
and the ADO.NET wrapper are combined into one multi-module assembly.
Also available as separate native and managed assemblies and optionally with the Visual C++
Runtime statically linked.
Binaries included for Itanium, x64, x86 and ARM processors.
Itanium processor support not currently included.
DbProviderFactory support.
Full support for ATTACH'ed databases. Exposed as Catalogs in the schema. When cloning a
connection, all attached databases are automatically re-attached to the new connection.
DbConnection.GetSchema(...) support includes the MetaDataCollections, DataSourceInformation,
Columns, Tables, Views, ViewColumns, Catalogs, Indexes, IndexColumns, ForeignKeys and
Triggers.
Enhanced DbDataReader.GetSchemaTable() functionality returns catalog, namespace and detailed
schema information even for complex queries.
Named and unnamed parameters.
Full UTF-8 and UTF-16 support, each with optimized pipelines into the native database core.
Multiple simultaneous DataReaders (one DataReader per Command however).
Full support for user-defined scalar and aggregate functions, encapsulated into an easy-to-use
base class in which only a couple of overrides are necessary to implement new SQL functions.
Full support for user-defined collating sequences, every bit as simple to implement as user-
defined functions and uses the same base class.
Full source for the entire engine and wrapper. No copyrights. Public Domain. 100% free for
commercial and non-commercial use.
Distributing the Binaries (Desktop)
When using the mixed-mode assembly, the System.Data.SQLite.DLL file includes all the native and
managed code. In that case, this is the only DLL required to be redistributed with your SQLite.NET
application(s). When using separate native and managed assemblies, the System.Data.SQLite.DLL file
contains all the managed code and the SQLite.Interop.DLL file contains all the native code. The native
code comes in 3 flavors: Win32, Itanium and x64 (AMD64).
Itanium processor support not currently included.
Distributing the Binaries (Compact Framework)
Both the System.Data.SQLite.DLL and SQLite.Interop.XXX.DLL files must be deployed on the
Compact Framework. The XXX is the build number of the System.Data.SQLite library (e.g. "104"). The
SQLite.Interop.XXX.DLL file is a fully native assembly compiled for the ARM processor, and
System.Data.SQLite is the fully-managed Compact Framework assembly.

Send comments on this topic.


Design-Time Support
SQLite.NET Class Library Documentation
Installing SQLite Visual Studio Design-Time Support
Supporting the Visual Studio query designer and allowing you to manipulate SQLite databases from within
Visual Studio is a great time-saver. Though the support is not yet fully-implemented, there's certainly
enough there to keep you busy. You can create databases, design and execute queries, create typed
datasets and lots more all from Visual Studio.

Installation Instructions
Download and run one of the setup packages and then select the "Install the designer components
for Visual Studio 20XX." option when prompted.

Express Edition Limitations


Visual Studio design-time Support, works with all versions of Visual Studio
2005/2008/2010/2012/2013/2015. You can add a SQLite database to the Servers list, design queries
with the Query Designer, drag-and-drop tables onto a Typed DataSet, etc.
Due to Visual Studio licensing restrictions, the Express Editions can no longer be supported.

Send comments on this topic.


DbProviderFactory Support
SQLite.NET Class Library Documentation
DbProviderFactories and You
One of the great new features of ADO.NET 2.0 is the use of reflection as a means of instantiating
database providers programmatically. The information .NET uses to enumerate the available data
providers in the system is relatively simple. It merely looks in the machine.config and in your own
app.config file for some XML data to tell it what providers are installed and what assemblies those
providers are in.

Scenario 1: Version Independent (does not use the Global Assembly Cache)

This method allows you to drop any new version of the System.Data.SQLite.DLL into your application's
folder and use it without any code modifications or recompiling. Add the following code to your
app.config file:
<configuration>
<system.data>
<DbProviderFactories>
<remove invariant="System.Data.SQLite"/>
<add name="SQLite Data Provider" invariant="System.Data.SQLite"
description=".NET Framework Data Provider for SQLite"
type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite" />
</DbProviderFactories>
</system.data>
</configuration>

Scenario 2: Version Dependent, using either the DLL located in the same folder as the
application or the Global Assembly Cache

This method expands on the above XML to provide the version number and key token of the SQLite DLL
so it can be found either in the same folder as the application or looked up in the GAC. The downside to
this method is that DbProviderFactories will use this version information to only load the version
specified. This means if you update the DLL, you must also update this XML.
<configuration>
<system.data>
<DbProviderFactories>
<remove invariant="System.Data.SQLite"/>
<add name="SQLite Data Provider" invariant="System.Data.SQLite"
description=".NET Framework Data Provider for SQLite"
type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite,
Version=1.0.104.0, Culture=neutral,
PublicKeyToken=db937bc2d44ff139"/>
</DbProviderFactories>
</system.data>
</configuration>

The following C# code demonstrates instantiating SQLite through DbProviderFactories:


DbProviderFactory fact = DbProviderFactories.GetFactory("System.Data.SQLite");
using (DbConnection cnn = fact.CreateConnection())
{
cnn.ConnectionString = "Data Source=test.db3";
cnn.Open();
}

Send comments on this topic.


Environment Variables
SQLite.NET Class Library Documentation

The following special replacement tokens may be recognized and replaced with their associated
runtime value, depending on context, when setting values are being read by the native library pre-loading
subsystem. Unless otherwise stated explicitly, all of these tokens are case-sensitive and the percent
characters must be included in order for them to be recognized.
Name Description
%PreLoadSQLite_AssemblyDirectory% If this token (which is case-sensitive and must include the
percent characters) is present within a setting value being
returned, it will be replaced with the qualified name of the
directory containing the System.Data.SQLite assembly. If the
name of the directory is not available, the token will not be
replaced.
%PreLoadSQLite_TargetFramework% If this token (which is case-sensitive and must include the
percent characters) is present within a setting value being
returned, it will be replaced with an abbreviation of the target
framework attribute value for the System.Data.SQLite
assembly. If the target framework attribute value is not
available, the token will not be replaced.
%PreLoadSQLite_XmlConfigDirectory% If this token (which is case-sensitive and must include the
percent characters) is present within a setting value being
returned, it will be replaced with the qualified name of the
directory containing the XML configuration file. If the name of
the directory is not available, the token will not be replaced.
Generally, this token may only be used within the XML
configuration file itself.

These environment variables are used to control several features of the System.Data.SQLite library. All of
these environment variables are optional. If a particular environment variable is not present, the XML
configuration file "System.Data.SQLite.dll.config" in the directory containing the currently executing
assembly (i.e. the one containing all the managed components for System.Data.SQLite) will also be
consulted. If present, the XML configuration file should be structured as follows:
<?xml version="1.0"?>
<configuration>
<appSettings>
<add key="A_Setting" value="String Value" />
<add key="Another_Setting" value="%ENV_VALUE%" />
</appSettings>
</configuration>

All references to existing environment variables will be expanded to their corresponding values within the
returned settings values unless either the "No_Expand" or "No_Expand_<name>" environment variable
is set [to anything].
None of these environment variables are supported by the Compact Framework builds of
System.Data.SQLite, due to limitations imposed by the platform itself; however, the XML configuration
file mentioned above may be used instead.
Name Description
AppendManifestToken_SQLiteProviderManifest If this environment variable is set [to anything], it will be
used by the
System.Data.SQLite.Linq.SQLiteProviderManifest class
(and the
System.Data.SQLite.EF6.SQLiteProviderManifest class)
to modify future provider manifest tokens by appending
the value of the environment variable to the existing
provider manifest token, if any. Typically, in order for the
constructed provider manifest token to be syntactically
correct, the environment variable value [to be
appended] must begin with a semicolon.
DefaultFlags_SQLiteConnection If this environment variable is set [to anything], it will be
used by the System.Data.SQLite.SQLiteConnection class
as the default flags for all opened connections (i.e. when
they are not present in the connection string).
Force_SQLiteLog If this environment variable is set [to anything], the
SQLite logging subsystem may be initialized in a non-
default application domain. By default, this is not allowed
due to the potential for application domain unloading
issues.
No_PreLoadSQLite If this environment variable is set [to anything], the
native library pre-loading code will be disabled. By
default, the native library pre-loading code will attempt
to load the native SQLite library from architecture-
specific (e.g. "x86", "amd64", "x64") or platform-
specific (e.g. "Win32") directories that reside
underneath the application base directory.
No_SQLiteConnectionNewParser If this environment variable is set [to anything], the new
connection string parsing algorithm will not be used. This
environment variable is intended for use with legacy
code only.
No_SQLiteFunctions If this environment variable is set [to anything], the
initial search for types in all loaded assemblies that are
tagged with the SQLiteFunction attribute will be skipped.
Normally, this search is conducted only once per
application domain by the static constructor of the
SQLiteFunction class; however, these implementation
details are subject to change.
No_SQLiteGetSettingValue If this environment variable is set [to anything], all calls
to the GetSettingValue method will return the default
value. This will effectively prevent all other setting values
from having any effect, including those specified via
other supported environment variables or in the
associated XML configuration file.
No_SQLiteXmlConfigFile If this environment variable is set [to anything], calls to
the GetSettingValue method will never result in the XML
configuration file being read; instead, the default value
will be returned. This will effectively prevent any setting
values specified via the XML configuration file from
having any effect.
PreLoadSQLite_BaseDirectory If this environment variable is set [to anything], it will be
used instead of the application base directory by the
native library pre-loader. This environment variable can
be especially useful in ASP.NET and other hosted
environments where direct control of the location of the
managed assemblies is not under the control of the
application.
PreLoadSQLite_LibraryFileNameOnly If this environment variable is set [to anything], it will be
used as the base file name (without directory
information) for the native SQLite library to be pre-
loaded (e.g. "sqlite3.dll" or "libsqlite3.so.0").
PreLoadSQLite_ProcessorArchitecture If this environment variable is set [to anything], it will be
used instead of the processor architecture value
contained in the PROCESSOR_ARCHITECTURE
environment variable to help build the path of the native
library to pre-load.
PreLoadSQLite_NoSearchForDirectory If this environment variable is set [to anything], the
native library pre-loading code will skip conducting a
search for the native library to pre-load. By default, the
search starts in the location of the currently executing
assembly (i.e. the assembly containing all the managed
components for System.Data.SQLite) and then falls
back to the application domain base directory.
PreLoadSQLite_UseAssemblyDirectory If this environment variable is set [to anything], the
location of the currently executing assembly (i.e. the
one containing all the managed components for
System.Data.SQLite) will be used as the basis for
locating the the native library to pre-load (i.e. instead of
using the application domain base directory).
PROCESSOR_ARCHITECTURE This environment variable is normally set by the
operating system itself and should reflect the native
processor architecture of the current process (e.g. a
32-bit x86 application running on a 64-bit x64 operating
system should have the value "x86").
SQLite_ForceLogPrepare If this environment variable is set [to anything], all calls
to prepare a SQL query will be logged, regardless of the
flags for the associated connection.
TypeName_SQLiteProviderServices If this environment variable is set [to anything], it will be
used by the System.Data.SQLite.SQLiteFactory class as
the type name containing the
System.Data.Common.DbProviderServices
implementation that should be used.
Use_SQLiteConvert_DefaultDbType If this environment variable is set [to anything], it will be
used by the System.Data.SQLite.SQLiteConvert class as
the default DbType value that should be used when a
per-connection value is not available.
Use_SQLiteConvert_DefaultTypeName If this environment variable is set [to anything], it will be
used by the System.Data.SQLite.SQLiteConvert class as
the default type name that should be used when a per-
connection value is not available.

Send comments on this topic.


Optimizing for SQLite
SQLite.NET Class Library Documentation
Tips on Optimizing Your Queries
The next few paragraphs will attempt to give you a few rudimentary rules for speeding up your queries in
general, and especially how SQLite is adversely affected by the kinds of SQL behaviors you may have
taken for granted in other providers. It is by no means a complete optimization guide. For even more
details on optimizing your queries, visit sqlite.org.

The Importance of Transactions


If you are inserting data in SQLite without first starting a transaction: DO NOT PASS GO! Call
BeginTransaction() right now, and finish with Commit()! If you think I'm kidding, think again.
SQLite's A.C.I.D. design means that every single time you insert any data outside a transaction, an
implicit transaction is constructed, the insert made, and the transaction destructed. EVERY TIME. If
you're wondering why in the world your inserts are taking 100x longer than you think they should, look
no further.

Prepared Statements
Lets have a quick look at the following code and evaluate its performance:
using (SQLiteCommand mycommand = new SQLiteCommand(myconnection))
{
int n;

for (n = 0; n < 100000; n ++)


{
mycommand.CommandText = String.Format("INSERT INTO [MyTable] ([MyId]) VALUES({0})", n + 1);
mycommand.ExecuteNonQuery();
}
}

This code seems pretty tight, but if you think it performs well, you're dead wrong. Here's what's wrong
with it:
I didn't start a transaction first! This insert is dog slow!
The CLR is calling "new" implicitly 100,000 times because I am formatting a string in the loop for
every insert
Since SQLite precompiles SQL statements, the engine is constructing and deconstructing 100,000
SQL statements and allocating/deallocating their memory
All this construction and destruction is involving about 300,000 more native to managed interop
calls than an optimized insert
So lets rewrite that code slightly:
using (SQLiteTransaction mytransaction = myconnection.BeginTransaction())
{
using (SQLiteCommand mycommand = new SQLiteCommand(myconnection))
{
SQLiteParameter myparam = new SQLiteParameter();
int n;

mycommand.CommandText = "INSERT INTO [MyTable] ([MyId]) VALUES(?)";


mycommand.Parameters.Add(myparam);

for (n = 0; n < 100000; n ++)


{
myparam.Value = n + 1;
mycommand.ExecuteNonQuery();
}
}
mytransaction.Commit();
}

Now this is a blazing fast insert for any database engine, not just SQLite. The SQL statement is prepared
one time -- on the first call to ExecuteNonQuery(). Once prepared, it never needs re-evaluating.
Furthermore, we're allocating no memory in the loop and doing a very minimal number of interop
transitions. Surround the entire thing with a transaction, and the performance of this insert is so far and
away faster than the original that it merits a hands-on-the-hips pirate-like laugh.
Every database engine worth its salt utilizes prepared statements. If you're not coding for this, you're
not writing optimized SQL, and that's the bottom line.

Send comments on this topic.


Provider Limitations
SQLite.NET Class Library Documentation
Limitations of this ADO.NET SQLite Data Provider
As providers go, this one doesn't have many restrictions. SQLite has no support for row-level or table-
level locks. When a connection locks the database for writing, no other connection or process may read
or write to the database until the write operation is complete. The SQLite.NET provider attempts to retry
internally if a database is locked, up to the CommandTimeout property of the command in question.
SQLite is inherently type-less, and only understands a few basic datatypes natively. They are (in .NET-
speak) Int64, Double, String and Blob. The SQLite.NET provider will use the database schema information
it can glean to enforce type-ness, but it is an inexact science.
Hierarchical DataReaders are not supported. In the case of transactions, any SQLiteCommand created
on a connection will (when executed) automatically join a transaction in progress, regardless of whether
that transaction was created before or after the command.
A SQLiteCommand object can be re-assigned a new SQLiteConnection object as long as no DataReaders
are active on the command.
Opening a transaction is considered a write operation, so only use them when you want to write to the
database! If you hold open an "immediate" transaction, all readers on other connections will be blocked
until the transaction is closed!

Thread Safety
Multi-threading in SQLite must be done carefully. Here are the restrictions:
You May Clone() a SQLiteConnection object in one thread and pass the cloned object to another
thread. Once passed, the other thread becomes the new owner of the cloned connection, and
the original thread must not keep a reference to the clone or call any methods on the clone.
You May create multiple threads, and those threads can create their own SQLiteConnection and
subsequent objects for accessing a database. Multiple connections on multiple threads to the
same database file are perfectly acceptable and will behave predictably.
You May NOT call methods or properties or otherwise reference any SQLite provider classes
that belong to another thread.
You May NOT pass a SQLiteCommand, SQLiteDataReader, SQLiteDataAdapter or any other
SQLite provider class except a cloned SQLiteConnection to another thread.
Understand again that SQLite has no fine-grained locking mechanisms. It is therefore your own
responsibility in a multi-threaded environment to handle potential timeouts that may occur if a long-
running query in one thread prevents a query in another thread from executing. These timeouts will only
occur if one thread is attempting to read while another thread is attempting to write. Whichever thread
got its lock first will be the one to execute, and the other thread will block until the CommandTimeout
value elapses or the other thread finishes.

Send comments on this topic.


SQLite Query Syntax

SQLite Language Reference Documentation


SQL As Understood By System.Data.SQLite
The SQLite library understands most of the standard SQL language. But it does omit some features while
at the same time adding a few features of its own. This document attempts to describe precisely what
parts of the SQL language SQLite does and does not support. A list of keywords is also provided. In all of
the syntax diagrams that follow, literal text is shown in bold blue. Non-terminal symbols are shown in
italic red. Operators that are part of the syntactic markup itself are shown in black roman. This document
is just an overview of the SQL syntax implemented by SQLite.

The SQLite core library implements the follow syntax:

SQL As Understood By SQLite

The System.Data.SQLite provider implements the follow additional syntax:

TYPES
TYPES

SQLite Language Reference Documentation


SQL As Understood By SQLite (sortof)
TYPES

sql-statement ::= TYPES [datatype name][,datatype name][,datatype name][,...] ; select-stmt


select-stmt ::= see SELECT

Use the TYPES keyword before a SELECT statement to provide the SQLite ADO.NET provider a list of
return datatypes to expect from the subsequent SELECT statement.
This is a language extension (aka hack) to SQLite specifically for the ADO.NET data provider. It is a
pseudo-statement, meaning only the ADO.NET provider understands it.

Background
Due to SQLite's typeless nature, there are certain kinds of queries for which the ADO.NET provider
cannot determine the proper return data type. Scalar and aggregate functions pose a particular problem
because there is no requirement for a given scalar or aggregate function to return any particular
datatype. As a matter of fact, scalar functions could theoretically return a different datatype for every
row or column in a query and this is perfectly legal from SQLite's point of view.
Since ADO.NET is designed around a typed system and we're shoe-horning SQLite into it, this keyword
helps the provider out in cases where the return type cannot be easily determined.
This command must be used in conjunction with a SELECT statement. It only works when both the
TYPES keyword and its value(s) are passed along with a SELECT statement as a single semi-colon
separated unit.

Examples
TYPES [bigint], [int], [smallint], [tinyint];
SELECT 1, 2, 3, 4;
The above query would return the columns as types System.Int64, System.Int32, System.Int16 and
System.Byte respectively.
TYPES [bigint], [int], , [tinyint];
SELECT 1, 2, 3, 4;
In this sample, only columns 1, 2 and 4 would have explicit typing. Column 3's datatype would pass
though the system and be discovered normally.
TYPES real;
SELECT SUM(Cost) FROM [Products];
The above query explicitly tells the provider that the SUM aggregate function returns a System.Double.

Usage Notes
You cannot use parameters in the TYPES statement.
The TYPES statement must be immediately followed by a SELECT statement.
It is legal to pass multiple TYPES and SELECT statements in a multi-statement command.
You may enclose datatypes in quotes "" or brackets [] or those `` thingies if you want.
Version History
SQLite.NET Class Library Documentation
Version History
1.0.104.0 - December 16, 2016
Updated to SQLite 3.15.2.
Add the "%PreLoadSQLite_AssemblyDirectory%", "%PreLoadSQLite_TargetFramework%", and
"%PreLoadSQLite_XmlConfigDirectory%" replacement tokens for use in configuration setting
values. Pursuant to [d4728aecb7].
Prevent the GetByte, GetChar, and GetInt16 methods of the SQLiteDataReader class from
throwing exceptions for large integer values. Pursuant to [5535448538]. ** Potentially
Incompatible Change **
Use SAVEPOINTs to properly implement nested transactions when the new
AllowNestedTransactions connection flag is used. Pursuant to [1f7bfff467].
When converting a Julian Day value to an integer, round to the nearest millisecond first. Pursuant
to [69cf6e5dc8]. ** Potentially Incompatible Change **
1.0.103.0 - September 15, 2016
Updated to SQLite 3.14.2.
Add preliminary support for the .NET Framework 4.6.2.
Change the SQLiteReadValueCallback delegate "eventArgs" parameter to be of type
SQLiteReadEventArgs. ** Potentially Incompatible Change **
Make SQLiteReadValueEventArgs and SQLiteReadArrayEventArgs derive from
SQLiteReadEventArgs. ** Potentially Incompatible Change **
Rename SQLiteReadValueEventArgs.ArrayEventArgs property to ExtraEventArgs. ** Potentially
Incompatible Change **
Add No_SQLiteGetSettingValue and No_SQLiteXmlConfigFile environment variables.
Reduce the number of calls to GetSettingValue from SQLiteConnection. Pursuant to
[25d53b48f6]. ** Potentially Incompatible Change **
Add NoVerifyTypeAffinity connection flag to disable all type affinity checking.
Add support for incremental blob I/O.
Improve support for the sqlite3_db_config() interface. Pursuant to [f64f4aee95].
1.0.102.0 - June 23, 2016
Updated to SQLite 3.13.0.
Update the SQLiteConnection.EnableExtensions method to make use of the new
SQLITE_DBCONFIG_ENABLE_LOAD_EXTENSION option, when available. ** Potentially
Incompatible Change **
Prevent the SQLiteCommand.ExecuteScalar method from throwing an exception when there are
no result columns. ** Potentially Incompatible Change **
Support per-connection customization for binding parameters and reading values, based on the
database type name.
Add TypeName property to the SQLiteParameter class.
Add VerifyOnly method to the SQLiteCommand class.
Add IsReadOnly method to the SQLiteConnection class.
1.0.101.0 - April 19, 2016
Updated to SQLite 3.12.2.
Add binary package release for Mono on POSIX.
1.0.100.0 - April 15, 2016
Updated to SQLite 3.12.1.
Support compiling and using the interop assembly on Linux and Mac OS X.
Support running the test suite under Mono on Linux and Mac OS X.
Properly handle NULL values in the "name" column of the results returned by PRAGMA
index_info(). Fix for [5251bd0878].
For column types that resolve to boolean, recognize case-insensitive prefixes of "True" and
"False". Fix for [dbd65441a5].
Add NoVerifyTextAffinity connection flag to skip type affinity checking when fetching a column
value as a string. Pursuant to [dbd65441a5].
The UnixEpoch DateTime format should use Int64 internally, not Int32. ** Potentially
Incompatible Change **
Avoid using Path.Combine with null values in the native library pre-loader. Fix for [da685c0bac].
Fix the (unsupported) legacy CryptoAPI based codec so that it no longer prevents page size
changes.
1.0.99.1 - March 31, 2016
Updated to SQLite 3.9.3.
1.0.99.0 - December 9, 2015
Updated to SQLite 3.9.2.
Add preliminary support for the .NET Framework 4.6.1.
Fix handling of sqlite3_index_info members not available with older versions of the SQLite core
library. ** Potentially Incompatible Change **
Update and improve documentation comments for the native virtual table methods.
Permit an existing registered function to be replaced. Fix for [2556655d1b].
Make GetValue work for boolean columns with textual "True" and "False" values. Fix for
[7714b60d61]. ** Potentially Incompatible Change **
Add Reset method to the SQLiteCommand class.
Add FileName property to the SQLiteConnection class.
Add experimental support for the native json1 and fts5 extensions.
Add GetDatabaseName, GetTableName, and GetOriginalName methods to the SQLiteDataReader
class.
1.0.98.0 - August 19, 2015
Updated to SQLite 3.8.11.1.
Add full support for Visual Studio 2015 and the .NET Framework 4.6.
Add support for creating custom SQL functions using delegates.
Implement the Substring method for LINQ using the "substr" core SQL function. ** Potentially
Incompatible Change **
Prevent encrypted connections from being used with the connection pool. Pursuant to
[89d3a159f1]. ** Potentially Incompatible Change **
Honor the second argument to Math.Round when using LINQ. ** Potentially Incompatible
Change **
Honor the pre-existing flags for connections during the Open method. Fix for [964063da16]. **
Potentially Incompatible Change **
Remove errant semi-colons from the SQL used by LINQ to INSERT and then SELECT rows with
composite primary keys. Fix for [9d353b0bd8].
Refactor INSERT/UPDATE handling (in the LINQ assembly) so it can handle composite and non-
integer primary keys. Fix for [41aea496e0].
Change the base type for the SQLiteConnectionFlags enumeration to long integer. ** Potentially
Incompatible Change **
Add extended return codes to the SQLiteErrorCode enumeration. Pursuant to [71bedaca19]. **
Potentially Incompatible Change **
Improve exception handling in all native callbacks implemented in the SQLiteConnection class.
Add Progress event and ProgressOps connection string property to enable raising progress
events during long-running queries.
Add "Recursive Triggers" connection string property to enable or disable the recursive trigger
capability. Pursuant to [3a82ee635b].
Add NoDefaultFlags connection string property to prevent the default connection flags from being
used. Pursuant to [964063da16].
Add VfsName connection string property to allow a non-default VFS to be used by the SQLite
core library.
Add BusyTimeout connection string property to set the busy timeout to be used by the SQLite
core library.
Add UnbindFunction and UnbindAllFunctions methods to the SQLiteConnection class.
Enable integration with the ZipVFS extension.
1.0.97.0 - May 26, 2015
Updated to SQLite 3.8.10.2.
Updated to Entity Framework 6.1.3.
Improve ADO.NET conformance of the SQLiteDataReader.RecordsAffected property. Fix for
[74542e702e]. ** Potentially Incompatible Change **
Prevent the IDataReader.GetDataTypeName method from throwing "No current row" exceptions.
Fix for [94252b9059].
When BinaryGUID handling is off, transform the LINQ parameter types as well. Fix for
[a4d9c7ee94]. ** Potentially Incompatible Change **
The IDataReader.GetDataTypeName method should always return the declared type name. **
Potentially Incompatible Change **
Add DefaultFlags_SQLiteConnection environment variable to enable customization of the default
connection flags.
Prevent calls to sqlite3_step() and sqlite3_interrupt() from being interrupted via
ThreadAbortException.
Make sure enabling UseUTF16Encoding sets the schema encoding to UTF-16. Fix for
[7c151a2f0e].
1.0.96.0 - March 5, 2015
Prevent the IDataReader.GetOrdinal method from throwing "No current row" exceptions. Fix for
[2be4298631], [abad7c577d], and [c28d7fe915].
When counting the number of tables in the GetSchemaTable method, do not include those that
have a null or empty name. Fix for [92dbf1229a].
1.0.95.0 - March 2, 2015
Updated to SQLite 3.8.8.3.
Updated to Entity Framework 6.1.2.
Modify configuration file transforms performed by the NuGet packages to allow Entity Framework
6 design-time integration to work automatically. Fix for [2be4298631], [abad7c577d], and
[417d669435].
The "System.Data.SQLite.EF6*" and "System.Data.SQLite.Linq*" NuGet packages no longer
depend on the "System.Data.SQLite.Core*" packages. ** Potentially Incompatible Change
**
The "System.Data.SQLite.MSIL*" NuGet packages no longer directly include any files; they are
now meta-packages. ** Potentially Incompatible Change **
The "System.Data.SQLite.x86*" and "System.Data.SQLite.x64*" NuGet packages now depend
on the "System.Data.SQLite.Linq" and "System.Data.SQLite.EF6" NuGet packages. **
Potentially Incompatible Change **
Make sure SQL statements generated for DbUpdateCommandTree objects are properly delimited.
Make sure SQLiteIndexOutputs.ConstraintUsages instances are created prior to calling
ISQLiteManagedModule.BestIndex. Fix for [56f511d268].
Correct marshalling of strings and blobs in the SQLiteValue class. Fix for [85b824b736].
Various minor performance enhancements to the SQLiteDataReader class. Pursuant to
[e122d26e70].
Defer disposing of connections created by the static SQLiteCommand.Execute method when a
data reader is returned. Fix for [daeaf3150a].
Wrap SELECT statements in parenthesis if they have an ORDER BY, LIMIT, or OFFSET clause and a
compound operator is involved. Fix for [0a32885109].
In the SQLiteDataReader.VerifyType method, remove duplicate "if" statement for the
DbType.SByte value and move the remaining "if" to the Int64 affinity. Fix for [c5cc2fb334]. **
Potentially Incompatible Change **
Handle Julian Day values that fall outside of the supported range for OLE Automation dates. Fix
for [3e783eecbe]. ** Potentially Incompatible Change **
Make sure the interop files are copied when publishing a project that refers to a NuGet package
containing them. Fix for [e796ac82c1]. ** Potentially Incompatible Change **
Make sure the interop files are copied before the PostBuildEvent. Fix for [f16c93a932]. **
Potentially Incompatible Change **
Modify GetSchemaTable method to avoid setting SchemaTableColumn.IsKey column to true when
more than one table is referenced. Fix for [47c6fa04d3]. ** Potentially Incompatible Change
**
Add AppendManifestToken_SQLiteProviderManifest environment variable to enable better
integration between LINQ and the underlying store connection.
Add SQLite_ForceLogPrepare environment variable to force logging of all prepared SQL regardless
of the flags for the associated connection.
Honor the DateTimeFormat, DateTimeKind, DateTimeFormatString, BinaryGUID connection string
and/or provider manifest token properties from within the LINQ assembly. Fix for
[8d928c3e88]. ** Potentially Incompatible Change **
Add PrepareRetries connection string property to allow the maximum number of retries when
preparing a query to be overridden. Fix for [647d282d11].
Add BindDateTimeWithKind connection flag to force DateTime parameter values to match the
DateTimeKind associated with the connection, if applicable. Fix for [a7d04fb111].
1.0.94.0 - September 9, 2014
Updated to SQLite 3.8.6.
Updated to Entity Framework 6.1.1.
Refactor and simplify NuGet packages in order to support per-solution SQLite interop assembly
files. ** Potentially Incompatible Change **
Add RefreshFlags method to the SQLiteDataReader class to forcibly refresh its connection flags.
Improve automatic detection and handling of the Entity Framework 6 assembly by the design-
time components installer. Pursuant to [e634e330a6]. ** Potentially Incompatible Change
**
Improve SQLiteDataReader performance slightly by caching the connection flags. ** Potentially
Incompatible Change **
Add ClearCachedSettings method to the SQLiteConnection class.
Add NoConvertSettings connection flag to disable querying of runtime configuration settings from
within the SQLiteConvert class. Pursuant to [58ed318f2f].
Minimize usage of the "Use_SQLiteConvert_DefaultDbType" and
"Use_SQLiteConvert_DefaultTypeName" settings. Fix for [58ed318f2f]. ** Potentially
Incompatible Change **
1.0.93.0 - June 23, 2014
Updated to SQLite 3.8.5.
Updated to Entity Framework 6.1.
Add support for mapping transaction isolation levels to their legacy default values. Pursuant to
[56b42d99c1].
Add support for setting the default DbType and type name used for mappings on a per-
connection basis. Pursuant to [3c00ec5b52].
Add DetectTextAffinity and DetectStringType connection flags to enable automatic detection of
column types, when necessary. Pursuant to [3c00ec5b52].
Add SetChunkSize method to the SQLiteConnection class. Pursuant to [d1c008fa0a].
Add SharedFlags static property to the SQLiteConnection class.
Make the ISQLiteSchemaExtensions interface public. ** Potentially Incompatible Change **
Have the SQLiteProviderFactory class (in the System.Data.SQLite.Linq assembly) implement the
IServiceProvider interface.
Fix bug in documentation generator automation that prevented some internal documentation
links from working.
Fix DateTime constant handling in the LINQ assembly. Fix for [da9f18d039]. ** Potentially
Incompatible Change **
1.0.92.0 - March 19, 2014
Updated to SQLite 3.8.4.1.
Update the list of keywords returned by SQLiteConnection.GetSchema("ReservedWords"). **
Potentially Incompatible Change **
Raise the static SQLiteConnection.Changed event when any SQLiteCommand or
SQLiteDataReader object is closed or disposed.
Add the SQLiteDataReader.StepCount property to return the number of rows seen so far.
Add StickyHasRows connection flag to cause the SQLiteDataReader.HasRows property to return
non-zero if there were ever any rows in the associated result sets.
When the TraceWarning connection flag is set, issue warnings about possibly malformed UNC
paths. Pursuant to [283344397b].
Convert the primary NuGet package, "System.Data.SQLite", into a meta-package.
Enhancements to the NuGet packages, including the new "modular" packages.
1.0.91.0 - February 12, 2014
Updated to SQLite 3.8.3.1.
Refresh all included SQLite core library documentation (e.g. SQL syntax).
Add support for Entity Framework 6.
Add support for per-connection mappings between type names and DbType values. Pursuant to
[e87af1d06a].
Modify the namespace used for all internal classes in the System.Data.SQLite.Linq assembly. **
Potentially Incompatible Change **
Add SQLiteCompileOptions and InteropCompileOptions properties to the SQLiteConnection class
to return the compile-time options for the SQLite core library and interop assembly, respectively.
Add BindInvariantText and ConvertInvariantText connection flags to force the invariant culture to
be used when converting parameter values to/from strings.
Add NoConnectionPool and UseConnectionPool connection flags to disable or enable connection
pooling by default.
Modify handling of the design-time components installer to run Visual Studio devenv.exe /setup
after installing the package. This appears to be necessary in some circumstances for Visual Studio
2013. Pursuant to [a47eff2c71].
Modify the native library pre-loader to support reading settings from an XML configuration file and
to be capable of checking more than one directory. Persuant to [f0246d1817].
Support detecting when the native library pre-loader should use the CodeBase property instead
of the Location property as the basis for locating the interop assembly.
Change the default behavior for the native library pre-loader so it first searches the executing (i.e.
System.Data.SQLite) assembly directory and then the application domain directory. Pursuant to
[f0246d1817]. ** Potentially Incompatible Change **
Include DbType.AnsiString in the list of types that need special ColumnSize handling. Fix for
[0550f0326e].
1.0.90.0 - December 23, 2013
Updated to SQLite 3.8.2.
Add Visual Studio 2013 support to all the applicable solution/project files, their associated
supporting files, and the test suite.
Add Visual Studio 2013 support to the redesigned designer support installer.
Add support for Windows Embedded Compact 2013.
Add experimental support for the native regexp extension.
Never create a new connection wrapper in the SQLiteConnection.Shutdown method. **
Potentially Incompatible Change **
Add experimental GetMemoryStatistics, ReleaseMemory, and Shutdown methods to the
SQLiteConnection class.
Add memory leak detection to the test project for the .NET Compact Framework.
Add SQLITE_ENABLE_MEMORY_MANAGEMENT compile-time option to the interop assembly.
Use current isolation level when enlisting into an existing transaction. Fix for [56b42d99c1].
Better handling of non-error log messages from the SQLite core library. Pursuant to
[44df10ea90].
Add TraceWarning connection flag to enable tracing of type mapping failures and disable tracing of
them by default. Pursuant to [6d45c782e4].
Use 32-bit values to keep track of numeric precision and scale when building the schema table for
a query. Fix for [ef2216192d].
1.0.89.0 - October 28, 2013
Updated to SQLite 3.8.1.
Add AutoCommit property to the SQLiteConnection class. Fix for [9ba9346f75].
Use declared column sizes for the AnsiStringFixedLength and StringFixedLength mapped database
types. Fix for [3113734605].
Check the result of sqlite3_column_name function against NULL.
Return false for the SQLiteParameterCollection.IsSynchronized property because it is not thread-
safe.
Raise the static SQLiteConnection.Changed event when any SQLiteCommand, SQLiteDataReader,
or CriticalHandle derived object instance is created. Fix for [aba4549801].
Add SQLiteCommand.Execute, SQLiteCommand.ExecuteNonQuery, and
SQLiteCommand.ExecuteScalar method overloads that take a CommandBehavior parameter.
Revise how the extra object data is passed to the static SQLiteConnection.Changed event. **
Potentially Incompatible Change **
Make sure the database cannot be changed by a query when the CommandBehavior.SchemaOnly
flag is used. Fix for [f8dbab8baf]. ** Potentially Incompatible Change **
Fix bug in NDoc3 that was preventing some of the MSDN documentation links from working.
Include the XML documentation files in the NuGet packages. Fix for [5970d5b0a6].
Add InteropVersion, InteropSourceId, ProviderVersion, and ProviderSourceId properties to the
SQLiteConnection class.
Add experimental support for interfacing with the authorizer callback in the SQLite core library.
Add experimental support for the native totype extension.
1.0.88.0 - August 7, 2013
Various fixes to managed virtual table integration infrastructure.
Implement workaround for an incorrect PROCESSOR_ARCHITECTURE being reported. Fix for
[9ac9862611].
Modify classes that implement the IDisposable pattern to set the disposed flag after their base
classes have been disposed.
When automatically registering custom functions, use the executing assembly (i.e.
System.Data.SQLite) for reference detection. Fix for [4e49a58c4c].
1.0.87.0 - July 8, 2013
Add all the necessary infrastructure to allow virtual tables to be implemented in managed code.
Fix for [9a544991be].
The DbType to type name translation needs to prioritize the Entity Framework type names. Fix
for [47f4bac575].
Add DateTimeFormatString connection string property to allow the DateTime format string used
for all parsing and formatting to be overridden.
Add NoFunctions connection flag to skip binding functions registered in the application domain.
Add several data-types for compatibility purposes. Fix for [fe50b8c2e8].
Add SQLiteConnection.BindFunction method to facilitate adding custom functions on a per-
connection basis.
When reading a DateTime value, avoid unnecessary string conversions. Fix for [4d87fbc742].
Modify the index introspection code so that it does not treat PRAGMA table_info "pk" column
values as boolean. Fix for [f2c47a01eb].
Disable use of the new connection string parsing algorithm when the
No_SQLiteConnectionNewParser environment variable is set. Pursuant to [bbdda6eae2].
Rename the ReturnCode property of the SQLiteException class to ResultCode. ** Potentially
Incompatible Change **
1.0.86.0 - May 23, 2013
Updated to SQLite 3.7.17.
Disable use of the AllowPartiallyTrustedCallers attribute when compiled for the .NET Framework
4.0/4.5. ** Potentially Incompatible Change **
Allow semi-colons in the data source file name. Fix for [e47b3d8346]. ** Potentially
Incompatible Change **
NULL values should be reported as type "object", not "DBNull". Fix for [48a6b8e4ca].
1.0.85.0 - April 18, 2013
Updated to SQLite 3.7.16.2.
Properly handle embedded NUL characters in parameter and column values. Fix for
[3567020edf].
Make use of the sqlite3_prepare_v2 function when applicable.
Check for a valid row in the SQLiteDataReader.GetValue method.
Implement processor architecture detection when running on the .NET Compact Framework (via
P/Invoke).
Support automated testing when running on the .NET Compact Framework 2.0.
Skip checking loaded assemblies for types tagged with the SQLiteFunction attribute when the
No_SQLiteFunctions environment variable is set. Pursuant to [e4c8121f7b].
Add HexPassword connection string property to work around the inability to include a literal
semicolon in a connection string property value. Pursuant to [1c456ae75f].
Add static Execute method to the SQLiteCommand class.
Support custom connection pool implementations by adding the ISQLiteConnectionPool interface,
the static SQLiteConnection.ConnectionPool property, and the static CreateHandle method in
addition to modifying the SQLiteConnectionPool class. Pursuant to [393d954be0].
Add public constructor to the SQLiteDataAdapter class that allows passing the
parseViaFramework parameter to the SQLiteConnection constructor.
When built with the CHECK_STATE compile-time option, skip throwing exceptions from the
SQLiteDataReader class when the object is being disposed.
Support automatic value conversions for columns with a declared type of BIGUINT, INTEGER8,
INTEGER16, INTEGER32, INTEGER64, SMALLUINT, TINYSINT, UNSIGNEDINTEGER,
UNSIGNEDINTEGER8, UNSIGNEDINTEGER16, UNSIGNEDINTEGER32, UNSIGNEDINTEGER64,
INT8, INT16, INT32, INT64, UINT, UINT8, UINT16, UINT32, UINT64, or ULONG.
Add BindUInt32AsInt64 connection flag to force binding of UInt32 values as Int64 instead.
Pursuant to [c010fa6584].
Add BindAllAsText and GetAllAsText connection flags to force binding and returning of all values as
text.
Remove AUTOINCREMENT from the column type name map. ** Potentially Incompatible
Change **
Avoid throwing overflow exceptions from the SQLite3.GetValue method for integral column
types. Partial fix for [c010fa6584]. ** Potentially Incompatible Change **
Use the legacy connection closing algorithm when built with the INTEROP_LEGACY_CLOSE
compile-time option.
Support using the directory containing the primary managed-only assembly as the basis for
native library pre-loading.
Still further enhancements to the build and test automation.
1.0.84.0 - January 9, 2013
Updated to SQLite 3.7.15.2.
Explicitly dispose of all SQLiteCommand objects managed by the DbDataAdapter class. Fix for
[6434e23a0f].
Add Cancel method to the SQLiteConnection class to interrupt a long running query.
Improve thread safety of the SQLiteLog.LogMessage method.
1.0.83.0 - December 29, 2012
Updated to SQLite 3.7.15.1.
Add Visual Studio 2012 support to all the applicable solution/project files, their associated
supporting files, and the test suite.
Add Visual Studio 2012 support to the redesigned designer support installer.
Allow opened connections to skip adding the extension functions included in the interop assembly
via the new NoExtensionFunctions connection flag.
Support loading of SQLite extensions via the new EnableExtensions and LoadExtension methods
of the SQLiteConnection class. Pursuant to [17045010df].
Remove one set of surrounding single or double quotes from property names and values parsed
from the connection string. Fix for [b4cc611998].
Modify parsing of connection strings to allow property names and values to be quoted. **
Potentially Incompatible Change **
Add ParseViaFramework property to the SQLiteConnection class to allow the built-in (i.e.
framework provided) connection string parser to be used when opening a connection. Pursuant
to [b4cc611998].
Add notifications before and after any connection is opened and closed, as well as other related
notifications, via the new static Changed event.
Add an overload of the SQLiteLog.LogMessage method that takes a single string parameter.
Add an overload of the SQLiteConnection.LogMessage method that takes a SQLiteErrorCode
parameter.
All applicable calls into the SQLite core library now return a SQLiteErrorCode instead of an integer
error code.
Make sure the error code of the SQLiteException class gets serialized.
Make the test project for the .NET Compact Framework more flexible.
When available, the new sqlite3_errstr function from the core library is used to get the error
message for a specific return code.
The SetMemoryStatus, Shutdown, ResultCode, ExtendedResultCode, and SetAvRetry methods of
the SQLiteConnection class now return a SQLiteErrorCode instead of an integer error code. **
Potentially Incompatible Change **
The public constructor for the SQLiteException now takes a SQLiteErrorCode instead of an
integer error code. ** Potentially Incompatible Change **
The ErrorCode property of the SQLiteException is now an Int32, to allow the property inherited
from the base class to be properly overridden. ** Potentially Incompatible Change **
The ErrorCode field of the LogEventArgs is now an object instead of an integer. ** Potentially
Incompatible Change **
The names and messages associated with the SQLiteErrorCode enumeration values have been
normalized to match those in the SQLite core library. ** Potentially Incompatible Change **
Implement more robust locking semantics for the CriticalHandle derived classes when compiled
for the .NET Compact Framework.
Cache column indexes as they are looked up when using the SQLiteDataReader to improve
performance.
Prevent the SQLiteConnection.Close method from throwing non-fatal exceptions during its
disposal.
Rename the interop assembly functions sqlite3_cursor_rowid, sqlite3_context_collcompare,
sqlite3_context_collseq, sqlite3_cursor_rowid, and sqlite3_table_cursor to include an "_interop"
suffix. ** Potentially Incompatible Change **
Prevent the LastInsertRowId, MemoryUsed, and MemoryHighwater connection properties from
throwing NotSupportedException when running on the .NET Compact Framework. Fix for
[dd45aba387].
Improve automatic detection of the sqlite3_close_v2 function when compiled to use the
standard SQLite library.
Add protection against ThreadAbortException asynchronously interrupting native resource
initialization and finalization.
Add native logging callback for use with the sqlite3_log function to the interop assembly, enabled
via the INTEROP_LOG preprocessor definition.
Add various diagnostic messages to the interop assembly, enabled via flags in the
INTEROP_DEBUG preprocessor definition.
Further enhancements to the build and test automation.
Add test automation for the Windows CE binaries.
1.0.82.0 - September 3, 2012
Updated to SQLite 3.7.14.
Properly handle quoted data source values in the connection string. Fix for [8c3bee31c8].
The primary NuGet package now supports x86 / x64 and the .NET Framework 2.0 / 4.0 (i.e. in a
single package).
Change the default value for the Synchronous connection string property to Full to match the
default used by the SQLite core library itself. ** Potentially Incompatible Change **
Add the ability to skip applying default connection settings to opened databases via the new
SetDefaults connection string property.
Add the ability to skip expanding data source file names to their fully qualified paths via the new
ToFullPath connection string property.
Fix the database cleanup ordering in the tests for ticket [343d392b51].
Add support for the sqlite3_close_v2 function from the SQLite core library.
Add support for URI file names via the new FullUri connection string property.
Improve support for the standard SQLite core library in the LINQ assembly and the test suite.
Add SetMemoryStatus static method to the SQLiteConnection class.
Improve threaded handling of the delegate used by the SQLiteLog class.
Add define constants to support enabling or disabling individual groups of trace statements.
1.0.81.0 - May 27, 2012
Updated to SQLite 3.7.12.1.
Support compiling the interop assembly without support for the custom extension functions and
the CryptoAPI based codec.
Add DefineConstants property to the SQLiteConnection class to return the list of define constants
used when compiling the core managed assembly.
Add release archive verification tool to the release automation.
Fix NullReferenceException when calling the SQLiteDataAdapter.FillSchema method on a query
that returns multiple result sets. Fix for [3aa50d8413].
Fix subtle race condition between threads fetching connection handles from the connection pool
and any garbage collection (GC) threads that may be running. Fix for [996d13cd87].
Add missing call to SetTimeout in the SQLite3_UTF16.Open method.
Add checks to prevent the SQLiteConnectionPool.Remove method from returning any connection
handles that are closed or invalid.
Modify static SQLiteBase helper methods to prevent them from passing IntPtr.Zero to the SQLite
native library.
Remove static locks from the static helper methods in the SQLiteBase class, replacing them with
a lock on the connection handle instance being operated upon.
Revise CriticalHandle derived classes to make them more thread-safe.
Add connection pool related diagnostic messages when compiled with the DEBUG define
constant.
Add PoolCount property to the SQLiteConnection class to return the number of pool entries for
the file name associated with the connection.
Rename internal SQLiteLastError methods to GetLastError.
Add assembly file test constraints to all tests that execute the "test.exe" or "testlinq.exe" files.
1.0.80.0 - April 1, 2012
Updated to SQLite 3.7.11.
In the SQLiteFunction class, when calling user-provided methods from a delegate called by native
code, avoid throwing exceptions, optionally tracing the caught exceptions. Fix for [8a426d12eb].
Add Visual Studio 2005 support to all the applicable solution/project files, their associated
supporting files, and the test suite.
Add Visual Studio 2005 support to the redesigned designer support installer.
Add experimental support for "pre-loading" the native SQLite library based on the processor
architecture of the current process. This feature is now enabled by default at compile-time.
Add support for the native SQLite Online Backup API. Fix for [c71846ed57].
Acquire and hold a static data lock while checking if the native SQLite library has been initialized to
prevent a subtle race condition that can result in superfluous error messages. Fix for
[72905c9a77].
Support tracing of all parameter binding activity and use the connection flags to control what is
traced.
When converting a DateTime instance of an "Unspecified" kind to a string, use the same kind as
the connection, if available.
Add overload of the SQLiteDataReader.GetValues method that returns a NameValueCollection.
Add static ToUnixEpoch method to the SQLiteConvert class to convert a DateTime value to the
number of whole seconds since the Unix epoch.
In the implicit conversion operators (to IntPtr) for both the SQLiteConnectionHandle and
SQLiteStatementHandle classes, return IntPtr.Zero if the instance being converted is null.
Write warning message to the active trace listeners (for the Debug build configuration only) if a
column type or type name cannot be mapped properly. See [4bbf851fa5].
When tracing SQL statements to be prepared, bypass the internal length limit of the sqlite3_log
function by using the SQLiteLog class directly instead. Also, detect null and/or empty strings and
emit a special message in that case.
For the setup, the Visual Studio task should only be initially checked if the GAC task is available
and vice-versa.
Improve compatibility with custom command processors by using __ECHO instead of _ECHO in
batch tools.
Add OpenAndReturn method to the SQLiteConnection class to open a connection and return it.
Add missing CheckDisposed calls to the SQLiteConnection class.
Add missing throw statement to the SQLiteConnection class.
Make sure the interop project uses /fp:precise for Windows CE.
Regenerate package load key to support loading the designer package into Visual Studio 2008
without having the matching SDK installed.
Modify transaction object disposal so that it can never cause an exception to be thrown.
1.0.79.0 - January 28, 2012
Use the WoW64 registry keys when installing the VS designer components on 64-bit Windows.
Fix for [d8491abd0b].
Correct resource name used by the LINQ assembly to locate several key string resources. Fix for
[fbebb30da9].
1.0.78.0 - January 27, 2012
Updated to SQLite 3.7.10.
Redesign the VS designer support installer and integrate it into the setup packages.
When emitting SQL for foreign keys in the VS designer, be sure to take all returned schema rows
into account. Remainder of fix for [b226147b37].
Add Flags connection string property to control extra behavioral flags for the connection.
Refactor all IDisposable implementations to conform to best practices, potentially eliminating
leaks in certain circumstances.
Even more enhancements to the build and test automation.
Support parameter binding to more primitive types, including unsigned integer types.
Recognize the TIMESTAMP column data type as the DateTime type. Fix for [bb4b04d457].
Prevent logging superfluous messages having to do with library initialization checking. Fix for
[3fc172d1be].
Support the DateTimeKind and BaseSchemaName connection string properties in the
SQLiteConnectionStringBuilder class. Fix for [f3ec1e0066].
Overloads of the SQLiteConvert.ToDateTime and SQLiteConvert.ToJulianDay methods that do not
require an instance should be static. Partial fix for [4bbf851fa5]. ** Potentially Incompatible
Change **
1.0.77.0 - November 28, 2011
Updated to SQLite 3.7.9.
More enhancements to the build and test automation.
Plug native memory leak when closing a database connection containing a statement that cannot
be finalized for some reason.
The SQLite3 class should always attempt to dispose the contained SQLiteConnectionHandle, even
when called via the finalizer.
When compiled with DEBUG defined, emit diagnostic information related to resource cleanup to
any TraceListener objects that may be registered.
Stop characterizing all log messages as errors. From now on, if the errorCode is zero, the
message will not be considered an error.
Never attempt to configure the native logging interface if the SQLite core library has already been
initialized for the process. Fix for [2ce0870fad].
Allow the SQLiteLog class to be used for logging messages without having an open connection.
Support building the core System.Data.SQLite assemblies using the .NET Framework 4.0 Client
Profile. Fix for [566f1ad1e4].
When generating the schema based on the contents of a SQLiteDataReader, skip flagging
columns as unique if the data reader is holding the result of some kind of multi-table construct
(e.g. a cross join) because we must allow duplicate values in that case. Fix for [7e3fa93744].
When returning schema information that may be used by the .NET Framework to construct
dynamic SQL, use a fake schema name (instead of null) so that the table names will be properly
qualified with the catalog name (i.e. the attached database name). Partial fix for [343d392b51].
Add SQLiteSourceId property to the SQLiteConnection class to return the SQLite source identifier.
Add MemoryUsed and MemoryHighwater properties to the SQLiteConnection class to help
determine the memory usage of SQLite.
Add DateTimeKind connection string property to control the DateTimeKind of parsed DateTime
values. Partial fix for [343d392b51]. ** Potentially Incompatible Change **
Improve the robustness of the SQLiteLog class when it will be initialized and unloaded multiple
times.
Fix the name of the interop assembly for Windows CE. Add unit tests to prevent this type of
issue from happening again. Fix for [737ca4ff74].
Formally support the SQL type name BOOLEAN in addition to BOOL. Fix for [544dba0a2f].
Make sure the SQLiteConvert.TypeNameToDbType method is thread-safe. Fix for [84718e79fa].
1.0.76.0 - October 4, 2011
Prevent the domain unload event handler in SQLiteLog from being registered multiple times. Fix
for [0d5b1ef362].
Stop allowing non-default application domains to initialize the SQLiteLog class. Fix for
[ac47dd230a].
1.0.75.0 - October 3, 2011
Updated to SQLite 3.7.8.
More enhancements to the build system.
Add official NuGet packages for x86 and x64.
Add Changes and LastInsertRowId properties to the connection class.
Support more formats when converting data from/to the DateTime type.
Make all the assembly versioning attributes consistent.
Add unit testing infrastructure using Eagle.
Integrate all legacy unit tests, including the "testlinq" project, into the new test suite.
Add projects to build the interop assembly statically linked to the Visual C++ runtime. Fix for
[53f0c5cbf6].
Add SQLITE_ENABLE_STAT2 compile-time option to the interop assembly. Fix for [74807fbf27].
Fix mutex issues exposed when running the test suite with the debug version of SQLite.
Fix transaction enlistment when repeated attempts are made to enlist in the same transaction.
Fix for [ccfa69fc32].
Support the SQLITE_FCNTL_WIN32_AV_RETRY file control to mitigate the impact of file sharing
violations caused by external processes.
Refactor the logging interface to be thread-safe and self-initializing.
Shutdown the SQLite native interface when the AppDomain is being unloaded. Fix for
[b4a7ddc83f].
Support Skip operation for LINQ using OFFSET. Fix for [8b7d179c3c].
Support EndsWith operation for LINQ using SUBSTR. Fix for [59edc1018b].
Support all SQLite journal modes. Fix for [448d663d11].
Do not throw exceptions when disposing SQLiteDataReader. Fix for [e1b2e0f769].
The REAL type should be mapped to System.Double. Fix for [2c630bffa7] and [b0a5990f48].
Minor optimization to GetParamValueBytes(). Fix for [201128cc88].
Support the ON UPDATE, ON DELETE, and MATCH clause information when generating schema
metadata for foreign keys. Partial fix for [b226147b37]. VS designer changes are not yet tested.
Fix incorrect resource name for SR.resx in the mixed-mode assembly.
Reduce the number of String.Compare() calls in the hot path for
SQLiteCommand.ExecuteReader().
1.0.74.0 - July 4, 2011
Updated to SQLite 3.7.7.1.
Fix incorrect hard-coded .NET Framework version information SQLiteFactory_Linq.cs that was
causing IServiceProvider.GetService to fail when running against the .NET Framework 3.5.
Fix all XML documentation warnings.
Restore support for the mixed-mode assembly (i.e. the one that can be registered in the Global
Assembly Cache).
Restore support for the Compact Framework.
Remove unused "using" statements from the System.Data.SQLite and System.Data.SQLite.Linq
projects.
Remove hard-coded System.Data.SQLite.Linq version from SQLiteFactory_Linq.cs
Modify the setup to support bundled packages (i.e. with the mixed-mode assembly) and
standard packages (i.e. with the managed assembly separate from the native interop library).
Disable the ability to register with the Global Assembly Cache in the standard setup package (i.e.
it is available in the bundled setup only).
Remove PATH modification from the setup.
Modify the naming scheme for the source, setup, and binary packages to allow for the necessary
variants.
In the build automation, attempt to automatically detect if Visual Studio 2008 and/or 2010 are
installed and support building binaries for both at once, when available.
Add release automation to build the source, setup, and binary packages in all supported build
variants.
Add the testlinq project to the new build system and make it work properly with Visual Studio
2008 and 2010.
1.0.73.0 - June 2, 2011
Updated to SQLite 3.7.6.3.
Minor optimization to GetBytes(). Fix for [8c1650482e].
Update various assembly information settings.
Correct System.Data.SQLite.Linq version and resource information. Fix for [6489c5a396] and
[133daf50d6].
Moved log handler from SQLiteConnection object to SQLiteFactory object to prevent if from
being prematurely GCed.
We should block x64 installs on x86 and we should install native only if the setup package itself is
native. Fix for [e058ce156e].
1.0.72.0 - May 1, 2011
Add the correct directory to the path. Fix for [50515a0c8e].
1.0.71.0 - April 27, 2011
Updated to SQLite 3.7.6+ [1bd1484cd7] to get additional Windows error logging.
Updated setup to optionally add install directory to PATH if GAC option selected.
1.0.70.0 - April 22, 2011
Added support for sqlite3_extended_result_codes(), sqlite3_errcode(), and
sqlite3_extended_errcode() via SetExtendedResultCodes(), ResultCode(), and
ExtendedResultCode().
Added support for SQLITE_CONFIG_LOG via SQLiteLogEventHandler().
1.0.69.0 - April 12, 2011
Code merge with SQLite 3.7.6.
New VS2008 and VS2010 solution files.
Build and packaging automation.
New Inno Setup files.
Designer support currently not ready for release.
1.0.68.0 - February 2011
Code merge with SQLite 3.7.5.
Continuing work on supporting Visual Studio 2010.
1.0.67.0 - January 3, 2011
Code merge with SQLite 3.7.4.
Continuing work on supporting Visual Studio 2010.
1.0.66.1 - August 1, 2010
Code merge with SQLite 3.7.0.1
Re-enabled VS2005 designer support, broken in previous versions during the 2008 transition
Implemented new forms of Take/Skip in the EF framework courtesy jlsantiago
Added "Foreign Keys" to the connection string parameters
Added the Truncate option to the Journal Modes enumeration
1.0.66.0 - April 18, 2010
Code merge with SQLite 3.6.23.1
Fixed a bug in the installer that accidentally modified the machine.config on .NET versions prior to
2.0, invaliding the config file.
Fixed INTERSECT and EXCEPT union query generation in EF
Fixed an out of memory error in the trigger designer in cases where a WHEN clause is used in the
trigger
1.0.65.0 - July 26, 2009
Fixed a bug in the encryption module to prevent a double free() when rekeying a database.
Fixed a bug in the encryption module when ATTACHing an encrypted database.
Incorporated the WinCE locking fix from ticket #3991
Added "bigint" to the dropdown in the table designer, plus other minor table designer bugfixes.
1.0.64.0 - July 9, 2009
Fixed the missing resources problem from the 63 release.
Added preliminary support for the Visual Studio 2010 beta.
Fixed a bug in SQLiteCommand that threw a null reference exception when setting the
Transaction object to null.
If SQLiteConnection.EnlistTransaction is called multiple times for the same transaction scope, just
return without throwing an error.
1.0.63.0 - June 29, 2009
Code merge with SQLite 3.6.16
Check the autocommit mode of the connection to which a transaction is bound during the
disposal of the transaction. If autocommit is enabled, then the database has already rolled back
the transaction and we don't need to do it during dispose, and can quietly ignore the step without
throwing an error.
Eliminated the mergebin step altogether. It was developed primarily to merge the Compact
Framework binaries together, but since we're not doing that anymore, its use is limited. Its non-
standard method of merging a binary on the desktop framework is redundant as well. The
desktop binary now hard-links to MSCOREE, but as of Windows XP, this was redundant as well
since XP and beyond automatically attempt to load MSCOREE on startup when a DLL has a .NET
header.
More improvements to the test.exe program for running the tests against Sql Server for
comparison purposes.
1.0.62.0 - June 20, 2009
Code merge with SQLite 3.6.15
Fixed the decimal reading bug in the SQLiteDataReader
Changed Join()'s to Sleep()'s in the statement retry code to prevent message pumping
Fixed a bad pointer conversion when retrieving blobs using GetBytes() in 64-bit land
Several changes to the Test program that comes with the provider. Tests can now be individually
disabled, and the test program can run against several provider back-ends
1.0.61.0 - April 28, 2009
Code merge with SQLite 3.6.13. The new backup features are as yet unimplemented in the
provider, but will be forthcoming in a subsequent release
Fixed the default-value lookups in SQLiteConnectionStringBuilder when accessing properties
Lock the SQLiteTransaction object during dispose to avoid potential race condition during cleanup
Fixed SQLiteDataReader.GetDecimal() processing and parsing of decimal values for cases when
SQLite returns things like "1.0e-05" instead of "0.0001"
1.0.60.0 - October 3, 2008
Throw a NotSupported exception in the EF Sql Gen code instead of parsing illegal SQL during an
update/insert/delete where no primary key is defined.
Fixed the Compact Framework interop library. Since the linker flag /subsystem had no version
specified, it was causing a problem for many CE-based platforms.
Incorporated SQLite patch for ticket #3387 and reverted out the vfs override code I added in
build 59 to work around this problem.
Fixed a designer issue when creating a new table from the Server Explorer. After initially saving it,
if you then continued to edit it and tried to save it again, it would generate the change SQL using
the old temporary table name rather than the new name.
1.0.59.0 - September 22, 2008
Code merge with SQLite 3.6.3. Solves a couple different EF issues that were either giving
inconsistent results or crashing the engine.
Fixed the parsing of literal binaries in the EF SqlGen code. SQLite now passes nearly all the
testcases in Microsoft's EF Query Samples application -- the exception being the datetimeoffset
and time constants tests, and tests that use the APPLY keyword which are unsupported for now.
Revamped the Compact Framework mixed-mode assembly. Tired of playing cat and mouse with
the Compact Framework's support for mixed-mode assemblies. The CF build now requires that
you distribute both the System.Data.SQLite library and the paired SQLite.Interop.XXX library.
The XXX denotes the build number of the library.
Implemented a workaround for Vista's overzealous caching by turning off
FILE_FLAG_RANDOM_ACCESS for OS versions above XP. This is implemented as a custom
(default override) VFS in the interop.c file, so no changes are made to the SQLite source code.
Fixed some registry issues in the designer install.exe, which prevented some design-time stuff
from working on the Compact Framework when .NET 3.5 was installed.
1.0.58.0 - August 30, 2008
Code merge with SQLite 3.6.2. If only I'd waited one more day to release 57! Several LINQ
issues have been resolved with this engine release relating to deeply-nested subqueries that the
EF SqlGen creates.
Fixed the Rollback SQLiteConnection event to not require a connection be opened first.
1.0.57.0 - August 29, 2008
Compiled against 3.6.1 with checkin #3300 resolved, which fixes an Entity Framework bug I was
seeing. I currently have 3 other tickets out on the engine, which are not yet resolved and relate
to EF.
Fixed decimal types to store and fetch using InvariantCulture. If you're using decimal datatypes
in your database and were affected by the 56 release, please issue an UPDATE <table> SET
<column> = REPLACE(<column>, ',', '.'); to fix the decimal separators. Apologies for not
testing that more thoroughly before releasing 56.
Too many LINQ fixes to list. Fixed views so they generate, fixed the LIMIT clause, implemented
additional functionality and removed unnecessary code.
Fixed foreign key names in the designer so viewing the SQL script on a new unsaved table after
renaming it in the properties toolwindow will reflect in the script properly.
Fixed the Update and Commit events on SQLiteConnection so they don't require the connection
to be opened first.
Fixed userdef aggregate functions so they play nice with each other when appearing multiple
times in the same statement.
Fixed the editing and saving of default values in the table designer.
Fixed ForeignKeys schema to support multi-column foreign keys. Also hacked support for them
in the table designer, provided two foreign keys in the designer have the same name and
reference the same foreign table and different columns. Will implement first-class support for this
in the next release.
1.0.56.0 - August 11, 2008
Fixed a bug in the table designer when designing new tables, wherein you had to save the table
first before being able to create indexes and foreign keys.
Tweaks to decimal type handling. The 'decimal' type can't be represented by Int64 or Double
(without loss of precision) in SQLite, so we have to fudge it by treating it like a string and
converting it back and forth in the provider. Unfortunately backing it to the db as a string causes
sorting problems. See this post for details on using a custom collation sequence to overcome
the sorting issue arising from this patch.
Minor tweaks and bugfixes to the test program and the provider.
More adjustments to make the managed-only version of the provider run and pass all tests on
Mono.
LINQ to Entities bits heavily updated and compiled against VS2008 SP1 RTM. SQLite LINQ
support is still considered beta.
1.0.55.0 - August 6, 2008
Code merge with SQLite 3.6.1
Added support for the user-contributed extension-functions at https://www.sqlite.org/contrib.
Feel free to override any of them with your own implementation. The new functions are: acos,
asin, atan, atn2, atan2, acosh, asinh, atanh, difference, degrees, radians, cos, sin, tan, cot, cosh,
sinh, tanh, coth, exp, log, log10, power, sign, sqrt, square, ceil, floor, pi, replicate, charindex,
leftstr, rightstr, reverse, proper, padl, padr, padc, strfilter, and aggregates stdev, variance,
mode, median, lower_quartile, upper_quartile.
Moved the last_rows_affected() function to the C extension library.
Added a new class, SQLiteFunctionEx which extends SQLiteFunction and adds the ability for a
user-defined function to get the collating sequence during the Invoke/Step methods. User-
defined functions can use the collating sequence as a helper to compare values.
When registering user-defined collation sequences and functions, the provider will now register
both a UTF8 and a UTF16 version instead of just UTF8.
Revamped connection pooling and added static ClearPool() and ClearAllPools() functions to
SQLiteConnection. Behavior of the pool and its clearing mechanics match SqlClient.
Fixed connections going to the pool so that any unfinalized lingering commands from un-collected
datareaders are automatically reset and any lurking transactions made on the connection are
rolled back.
Transaction isolation levels are now partially supported. Serializable is the default, which obtains
read/write locks immediately -- this is compatible with previous releases of the provider.
Unspecified will default to whatever the default isolation mode is set to, and ReadCommitted will
cause a deferred lock to be obtained. No other values are legal.
Revamped the test.exe program. It's now an interactive GUI application. Easier for me to add
tests now.
Tweaks to the VS designer package and installer.
More adjustments to the internal SQLite3.Prepare() method to account for both kinds of lock
errors when retrying.
Stripped a lot of unnecessary interop() calls and replaced with base sqlite calls. Revamped most
of UnsafeNativeMethods to make it easier to port the code.
Rerigged internal callbacks for userdef functions and other native to managed callbacks. More
portable this way.
Source can now can be compiled with the SQLITE_STANDARD preprocessor symbol to force the
wrapper to use the stock sqlite3 library. Some functionality is missing, but its minimal. None of
the precompiled binaries are compiled using this setting, but its useful for testing portability.
Added "boolean" and a couple other missing datatypes to the "DataTypes" schema xml file. Used
by the VS designer when displaying tables and querying.
Added a new connection string option "Read Only". When set to True, the database will be
opened in read-only mode.
Added a new connection string option "Max Pool Size" to set the maximum size of the
connection pool for a given db file connection.
Added a new connection string option "Default IsolationLevel" to set the default isolation level of
transactions. Possible values are Serializable and ReadCommitted.
Added a new connection string option "URI" as an optional parameter for compatibility with other
ports of the provider.
1.0.54.0 - July 25, 2008
Fixed the setup project, which somehow "forgot" to include all the binaries in the 53 release.
Fixed a crash in the table designer when creating a new table and tabbing past the "Allow Nulls"
cell in the grid while creating a new column.
Fixed a mostly-benign bug in SQLiteDataReader's GetEnumerator, which failed to pass along a
flag to the underyling DbEnumerator it creates. This one's been around since day 1 and nobody's
noticed it in all these years.
Added a new connection string parameter "Journal Mode" that allows you to set the SQLite
journal mode to Delete, Persist or Off.
1.0.53.0 - July 24, 2008
Enabled sqlite_load_extension
Added retry/timeout code to SQLite3.Prepare() when preparing statements for execution and a
SQLITE_BUSY error occurs.
Added a new schema to SQLiteConnection.GetSchema() called Triggers. Used to retrieve the
trigger(s) associated with a database and/or table/view.
Extensive updates to table/view editing capabilities inside Visual Studio's Server Explorer. The
program now parses and lets you edit CHECK constraints and triggers on a table, as well as
define triggers on views. Experimental still, so e-mail me if you have issues.
Minor bugfix to the ViewColumns schema to return the proper base column name for a view that
aliases a column.
Fixed the insert/update/delete DML support in the Linq module.
Changed the behavior of SQLiteCommand to allow a transaction to be set even if the command
hasn't been associated with a connection yet.
1.0.52.0 - July 16, 2008
Code merge with SQLite 3.6.0
Added a lot of previously-missing exports to the DEF file for the native library.
Fixed SQLiteDataReader to check for an invalid connection before operating on an open cursor.
Implemented the Cancel() function of SQLiteCommand to cancel an active reader.
Added beta table and view designers to the Visual Studio Server Explorer. You can now
edit/create tables and views, manage indexes and foreign keys from Visual Studio. This feature is
still undergoing testing so use at your own risk!
Fixed the Server Explorer so VS2005 users can once again right-click tables and views and open
the table data.
Added some new interop code to assist in returning more metadata not normally available
through the SQLite API. Specifically, index column sort modes and collating sequences. Also
added code to detect (but not parse) CHECK constraints, so the table designer can pop up a
warning when editing a table with these constraints. Since I can't currently parse them.
Lots of LINQ SQL generation improvements and fixes.
Made some progress cleaning up and fixing up the schema definitions and manifests for EdmGen.
Added a built-in SQLiteFunction called last_rows_affected() which can be called from SQL to get
the number of rows affected by the last update/insert operation on the connection. This is
roughly equivalent to Sql Server's @@ROWCOUNT variable.
1.0.51.0 - July 1, 2008
VS2008 SP1 Beta1 LINQ Support
Added experimental Entity Framework support in a new library, System.Data.SQLite.Linq. Some
things work, some don't. I haven't finished rigging everything up yet. The core library remains
stable. All LINQ-specific code is completely separate from the core.
Added some columns to several existing schemas to support some of the EDM framework stuff.
Minor tweaks to the factory to better support dynamic loading of the Linq extension library for
SQLite.
SQLite's busy handler was interfering with the provider's busy handling mechanism, so its been
disabled.
1.0.50.0 - June 27, 2008
Fixed some lingering dispose issues and race conditions when some objects were finalized.
Fixed the SQLiteConvert.Split() routine to be a little smarter when splitting strings, which solves
the quoted data source filename problem.
Enhanced the mergebin utility to work around the strong name validation bug on the Compact
Framework. The old workaround kludged the DLL and caused WM6.1 to fail to load it. This new
solution is permanent and no longer kludges the DLL.
1.0.49.0 - May 28, 2008
Code merge with SQLite 3.5.9
Fixed schema problems when querying the TEMP catalog.
Changed BLOB datatype schema to return IsLong = False instead of True. This was preventing
DbCommandBuilder from using GUID's and BLOB's as primary keys.
Fix rollover issue with SQLite3.Reset() using TickCount.
Fixed SQLiteDataReader to dispose of its command (if called for) before closing the connection
(when flagged to do so) instead of the other way around.
Fixed a DbNull error when retrieving items not backed by a table schema.
Fixed foreign key constraint parsing bug.
Added FailIfMissing property to the SQLiteConnectionStringBuilder.
Converted the source projects to Visual Studio 2008.
1.0.48.0 - December 28, 2007
Code merge with SQLite 3.5.4
Calling SQLiteDataReader.GetFieldType() on a column with no schema information and whos first
row is initially NULL now returns type Object instead of type DbNull.
Added support for a new DateTime type, JulianDay. SQLite uses Julian dates internally.
Added a new connection string parameter "Default Timeout" and a corresponding method on the
SQLiteConnection object to change the default command timeout. This is especially useful for
changing the timeout on transactions, which use SQLiteCommand objects internally and have no
ADO.NET-friendly way to adjust the command timeout on those commands.
FTS1 and FTS2 modules were removed from the codebase. Please upgrade all full-text indexes
to use the FTS3 module.
1.0.47.2 - December 10, 2007
Fixed yet one more bug when closing a database with unfinalized command objects
Fixed the DataReader's GetFieldType function when dealing with untyped SQLite affinities
1.0.47.1 - December 5, 2007
Fixed a leftover bug from the codemerge with SQLite 3.5.3 that failed to close a database.
Fixed the broken Compact Framework distribution binary.
SQLite 3.5.x changed some internal infrastructure pieces in the encryption interface which I didn't
catch initially. Fixed.
1.0.47.0 - December 4, 2007
Code merge with SQLite 3.5.3
Added installer support for Visual Studio 2008. Code is still using the VS2005 SDK so one or two
bells and whistles are missing, but nothing significant.
This is the last version that the FTS1 and FTS2 extensions will appear. Everyone should rebuild
their fulltext indexes using the new FTS3 module. FTS1 and FTS2 suffer from a design flaw that
could cause database corruption with certain vacuum operations.
Fixed pooled connections so they rollback any outstanding transactions before going to the pool.
Fixed the unintended breaking of the TYPES keyword, and mis-typing of untyped or indeterminate
column types.
Assert a FileIOPermission() requirement in the static SQLiteFunction constructor.
The CE-only SQLiteFunction.RegisterFunction() is now available on the desktop platform for
dynamic registration of functions. You must still close and re-open a connection in order for the
new function to be seen by a connection.
Fixed the "database is locked" errors by implementing behavioral changes in the interop.c file for
SQLite. Closing a database force-finalizes any prepared statements on the database to ensure
the connection is fully closed. This was rather tricky because the GC thread could still be finalizing
statements itself.
Modifed the mergebin utility to help circumvent a long-standing strong name verification bug in
the Compact Framework.
1.0.46.0 - September 30, 2007
Fixed faulty logic in type discovery code when using SQLiteDataReader.GetValue().
Fixed Connection.Open() bug when dealing with :memory: databases.
Fixed SQLiteCommand.ExecuteScalar() to return a properly-typed value.
Added support for SQLiteParameter.ResetDbType().
Added test cases for rigid and flexible type testing.
1.0.45.0 - September 25, 2007
Breaking change in GetSchema("Indexes") -- MetaDataCollections restrictions and identifier
parts counts were wrong for this schema and I was using the wrong final parameter as the final
restriction. Meaning, if you use the Indexes schema and are querying for a specific index the
array should now be {catalog, null, table, index } instead of {catalog, null, table, null, index}
Fixed some errors in the encryption module, most notably when a non-default page size is
specified in the connection string.
Fixed SQLiteDataReader to better handle type-less usage scenarios, which also fixes problems
with null values and datetimes.
Fixed the leftover temp files problem on WinCE
Added connection pooling. The default is disabled for now, but may change in the future. Set
"Pooling=True" in the connection string to enable it.
Sped up SQLiteConnection.Open() considerably.
Added some more robust cleanup code regarding SQLiteFunctions.
Minor additions to the code to allow for future LINQ integration into the main codebase.
Fixed a long-standing bug in the Open() command of SQLiteConnection which failed to honor the
documented default behavior of the SQLite.NET provider to open the database in
"Synchronous=Normal" mode. The default was "Full".
If Open() fails, it no longer sets the connection state to Broken. It instead reverts back to
Closed, and cleans up after itself.
Added several new parameters to the ConnectionString for setting max page count, legacy file
format, and another called FailIfMissing to raise an error rather than create the database file
automatically if it does not already exist.
Fixed some designer toolbox references to the wrong version of the SQLite.Designer
Fixed a bug in the mergebin utility with regards to COR20 metadata rowsize computations.
Minor documentation corrections
1.0.44.0 - July 21, 2007
Code merge with SQLite 3.4.1
Fixed a bug in SQLiteConnection.Open() which threw the wrong kind of error in the wrong kind of
way when a database file could not be opened or created.
Small enhancements to the TYPES keyword, and added documentation for it in the help file.
Hopefully fixed the occasional SQLITE_BUSY errors that cropped up when starting a transaction.
Usually occurred in high-contention scenarios, and the underlying SQLite engine bypasses the
busy handler in this scenario to return immediately.
1.0.43.0 - June 21, 2007
Code merge with SQLite 3.4.0
Fixed a reuse bug in the SQLiteDataAdapter in conjunction with the SQLiteCommandBuilder. It's
been there unnoticed for more than a year, so it looks like most folks never encountered it.
Fixed an event handler bug in SQLiteCommandBuilder in which it could fail to unlatch from the
DataAdapter when reused. Relates to the previous bugfix.
Fixed a double-dispose bug in SQLiteStatement that triggered a SQLiteException.
1.0.42.0 - June 1, 2007
Code merge with SQLite 3.3.17
Changed the SQLiteFunction static constructor so it only enumerates loaded modules that have
referenced the SQLite assembly, which hopefully should cut down dramatically the time it takes
for that function to execute.
Added the FTS2 full-text search extension to the project. Look for FTS1 to disappear within the
next couple of revisions.
Fixed a bug introduced with the finalizers that triggered an error when statements ended with a
semi-colon or had other non-parsable comments at the end of a statement
Fixed an intermittent multi-threaded race condition between the garbage collector thread and the
main application thread which lead to an occasional SQLITE_MISUSE error.
Fixed another issue relating to SQLite's inherent typelessness when dealing with aggregate
functions which could return Int64 or Double or even String for a given row depending on what
was aggregated.
Remembered to recompile the DDEX portion of the engine this time, so Compact Framework
users can once again use the design-time functionality
1.0.41.0 - April 23, 2007
Code merge with SQLite 3.3.16
Second go at implementing proper finalizers to cleanup after folks who've forgotten to Dispose()
of the SQLite objects
Enhanced GetSchema(IndexColumns) to provide numeric scale and precision values
Fixed the column ordinals in GetSchema(IndexColumns) to report the ordinal of the column in
the index, not the table
Fixed a bug whereby parameters named with an empty string (such as String.Empty) were
treated like a named parameter instead of an unnamed parameter
1.0.40.0 - January 31, 2007
Code merge with SQLite 3.3.12
Lots of new code to handle misuse of the library. Implemented finalizers where it made sense,
fixed numerous garbage collector issues when objects are not disposed properly, fixed some
object lifetime issues, etc.
A failed Commit() on a transaction no longer leaves the transaction in an unusable state.
1.0.39.1 - January 11, 2007
Fixed a really dumb mistake that for some reason didn't trigger any errors in the testcases,
whereby commands when associated with a connection were not adding or removing
themselves from an internal list of commands for that connection -- causing a "database is
locked" error when trying to close the connection.
1.0.39.0 - January 10, 2007
Code merge with SQLite 3.3.10
Fixed a multi-threaded race condition bug in the garbage collector when commands and/or
connections are not properly disposed by the user.
Switched the encryption's internal deallocation code to use sqlite's built-in aux functions instead
of modifying the pager.c source to free the crypt block. This eliminates the last of the code
changes the provider makes to the original sqlite engine sources. Props to Ralf Junker for
pointing that out.
1.0.38.0 - November 22, 2006
Fixed a bug when using CommandBehavior.KeyInfo whereby integer primary key columns may be
duplicated in the results.
Enhanced the CommandBuilder so that update/delete statements are optimized when the
affected table contains unique constraints and a primary key is present.
Fixed a bug in the DataReader when used in conjunction with
CommandBehavior.CloseConnection.
1.0.37.0 - November 19, 2006
Added support for CommandBehavior.KeyInfo. When specified in a query, additional column(s)
will be returned describing the key(s) defined for the table(s) selected in the query. This is
optimized when INTEGER PRIMARY KEY is set for the given tables, but does additional work for
other kinds of primary keys.
Removed the default values from SQLiteDataReader.GetTableSchema(), to better follow Sql
Server's pattern and suppress schema errors when loading the records into a dataset/datatable.
Allow integers to implicitly convert to double/decimal/single.
1.0.36.1 - October 25, 2006
Added support for LONGVARCHAR, SMALLDATE and SMALLDATETIME. These were actually added
in 1.0.36.0 but were undocumented.
Fixed the embedded helpfile which was accidentally built from old sources.
Fixed an unfortunate re-entry of a bug in the .36 codebase that caused the provider to "forget"
about commands on a connection under certain circumstances.
1.0.36.0 - October 23, 2006
Code merge with SQLite 3.3.8, including support for full-text search via the FTS1 extension.
Fixed a bug retrieving data types when UseUtf16Encoding is true. Side-effect of further merging
the common code between the two base classes.
Fixed a bug with System.Transactions whereby a connection closed/disposed within a transaction
scope is rolled back and cannot be committed.
Added more error checking and reporting to transactions to help user's isolate the source of
transaction failures.
Implemented a workaround for a Compact Framework issue regarding strong-named assemblies
containing a PE section with a raw size less than the virtual size.
1.0.35.1 - September 12, 2006
Fixed the TYPES keyword to work when UseUTF16Encoding is true.
Fix another bug revealed in 1.0.35.0 regarding infinite loops when the 2nd or subsequent
statements of a semi-colon separated command cannot be parsed.
Updated the help documentation.
1.0.35.0 - September 10, 2006
Fixed an infinite loop bug in SQLiteCommand caused when multiple semi-colon separated
statements in a single command are executed via datareader and one of the statements
contains a syntax error preventing it from being prepared.
Added the TYPES preparser keyword to be placed before a SELECT statement to aid the wrapper
in converting expressions in a subsequent select clause into more robust types. Documentation
yet to be integrated, but available on the forums.
Added a new connectionstring parameter "BinaryGUID=true/false" (default is "true"). When true,
guid types are stored in the database as binary blobs to save space. Binary has been the default
format since 1.0.32.0 but this parameter eases backward compatibility.
1.0.34.0 - September 4, 2006
Fixed a bug in SQLiteParameterCollection.RemoveAt(namedparam)
Fixed a bug in SQLiteDataReader introduced in 1.0.30 that broke DateTimes using the Ticks
option in the connection string.
Fixed a bug in the recent changes to guid behavior wherein using a datareader's indexer to fetch
a guid from a column containing both binary and text guids would sometimes return a byte array
instead of a guid.
Enacted a workaround involving typed datasets in Compact Framework projects in which it took
an excessive amount of time to open a form and generated a lot of temporary files in the user's
Local Settings\Application Data\Microsoft\VisualStudio\8.0\Assembly References folder.
1.0.33.0 - August 21, 2006
Code merge with SQLite 3.3.7
Fixed a bug in SQLiteConnection that caused it to "forget" about commands bound to it and
occasionally throw an error when a database is closed and opened repeatedly.
1.0.32.0 - August 6, 2006
Added AllowPartiallyTrustedCallers attribute to the assembly
Added the missing "nchar" type
Added support for binary Guid's. Guids are now stored as binary by default when using
parameterized queries. Text guids are still fully supported.
Fixed a TransactionScope() error that caused the transaction not to be completed.
Enhanced parameter names so that if they are added to the Parameters collection without their
prefix character (@ : or $) they are still properly mapped.
1.0.31.0 - July 16, 2006
Re-applied the view parsing bugfix in 1.0.29.0 that was accidentally reverted out of the 30 build.
Fixed SQLiteCommand.ExecuteScalar() to return null instead of DbNull.Value when no rows were
returned.
Design-time installer now installs the package-based designer on full Visual Studio versions.
Express editions continue to use the packageless designer.
In Visual Studio (not Express), you can now right-click a SQLite connection in the Server Explorer
and vacuum the database and change the encryption password.
1.0.30.1 - July 2, 2006
Code merge with SQLite 3.3.6
Added support for the |DataDirectory| keyword in the Data Source filename string.
Added hook notification support to SQLiteConnection. Specifically, there are three new events on
the SQLiteConnection object which are raised when an update/insert/delete occurs and when
transactions are committed and rolled back.
Changed SQLiteTransaction to default to BEGIN IMMEDIATE instead of just BEGIN, which solves a
multithreaded race condition.
Changed SQLiteDataReader to better support SQLite's typelessness. The data reader no longer
caches column affinity, but re-evaluates it for each column/row.
Fixed a bug in Prepare() which caused an intermittant fault due to the code accessing the
memory of an unpinned variable.
Fixed a multithreaded lock-retry bug in in SQLiteConnection.Open() and in SQLiteTransaction,
which failed to use a command timeout before giving up.
1.0.29.0 - May 16, 2006
Fixed a bug in the Views schema information which caused multi-line view definition statements
not to be parsed
Fixed a parsing bug in SQLiteDataReader.GetSchemaTable() to account for numeric(x,y)
datatypes with specified precision and scale
Fixed a bug in SQLiteConnection.Open() which tried to automatically enlist in an ambient
transaction but had not yet set the state of the database to Opened, thereby causing a
transaction fault
Changed SQLiteException to inherit from DbException on the full framework
1.0.28.0 - April 14, 2006
Code merge with SQLite 3.3.5
You can now specify a relative path in the Compact Framework's "Data Source" by prefixing the
file with ".\". i.e. "Data Source=.\\mydb.db3"
Several more changes and enhancements to schemas for better compatibility.
Fixed several bugs with the 64-bit builds of the provider. The x64 binary is now optimized.
Design-time installer now tries to install the 64-bit builds into the GAC along with the 32-bit build.
Fixed a bug in the SQLiteDataReader.GetSchemaTable() function when used with tables containing
apostrophes.
Fixed an XSD-related bug whereby the XSD utility was unable to locate the provider and could not
generate typed datasets.
Added NTEXT and STRING datatypes to the list of recognized keywords (used for schema
retrieval).
Due to the XSD bug and other potential problems related to external build utilities, changes to the
installation of the designer have had to be made. The installer used to write the
DbProviderFactories XML into the devenv.exe.config file and its express cousins, but now has to
write instead to the machine.config.
Installer writes to both the 32-bit machine.config and the 64-bit machine.config if it exists.
1.0.27.1 - February 28, 2006
Fixed a bug when doing data binding in Compact Framework projects that prevented you from
assigning a typed dataset to a bindingsource. It turns out, the CF version of the SQLite provider
needs to be flagged as retargetable so it'll work in the design-time desktop environment. No
changes were made to the desktop build, but the revision was bumped on all libraries anyway in
order to keep them sync'd.
1.0.27.0 - February 27, 2006
Many optimizations and a few more minor adjustments to schemas and schema retrieval
performance.
Lots of design-time attributes added to the code. The DbDataAdapter, DbCommand, and
DbConnection objects now have greatly enhanced design-time capabilities when added to the
toolbox and dropped on a form.
Lots of Server Explorer enhancements.
Binaries are now distributed in a setup program for easier administration and configuration of the
provider.
1.0.26.2 - February 15, 2006
Yet another bugfix to index schemas, which was incorrectly marking most indexes as primary key
indexes.
Fixed GetSchema() to accept a null string array.
Fixed a misspelled export in the core C library that prevented databases opened with
UTF16Encoding from getting schema information and would likely cause an error if attempted.
1.0.26.1 - February 14, 2006
Fixed even more minor schema bugs having to do with indexes.
Added two missing pieces in the SQLite designer which were preventing it from being used from
within VS Express editions.
Several bugfixes to the design-time installer program, including supporting 64-bit environments.
1.0.26.0 - February 11, 2006
Code merge with SQLite 3.3.4
Fixed an encryption bug when changing the password of databases over 1gb in size.
Fixed various designer issues related to construction of named parameters.
Retooled the GetSchema() method of SQLiteDataReader to use the new 3.3.4 API functions, and
made several enhancements and fixes to schemas.
Implemented the SourceColumnNullMapping property of SQLiteParameter to fix a
DbCommandBuilder code generation bug.
Removed the runtime dependency on MSVCR80.DLL. File size is somewhat larger for the varying
desktop versions, but the Compact Framework version remains the same.
Created an install program to manage installation and uninstallation of the SQLite design-time
support.
Designer support now works for all Visual Studio editions, including all Express Editions.
Design-time installer will now remove (if present) the machine.config SQLite entries in favor of
installing the xml code into the devenv.exe.config file (or any of the variations for express
editions). The officially-accepted behavior of using DbProviderFactories is to add the code to
your app.config file, and the machine.config file should not be touched.
1.0.25.0 - January 31, 2006
Code merge with SQLite 3.3.3
Added automatic distributed transaction enlistment and implemented the
DbConnection.EnlistTransaction method for manual enlistment.
Nested transactions are now supported.
Rearranged the timing of SetPassword(), which now must be called before the database is
opened instead of afterwards. Optionally, the password can be supplied in the ConnectionString.
Fixed a bug in SQLiteFunction that caused a failure when an empty resultset was returned and a
custom user aggregate function was used in the query.
The designer has had another round of cleanup applied, in preparation for moving to a VS
package.
Added SQLiteMetaDataCollectionNames class.
1.0.24.6 beta - January 23, 2006
This beta is built from sqlite.org's 3.3.2 beta.
Eliminated the static linking of mscoree from all binaries. Native projects can now use the library
without any dependencies on the .NET Framework, while managed projects continue to be able
to use the library normally.
1.0.24.5 beta - January 20, 2006
This beta is built from sqlite.org's 3.3.1 alpha and contains development-in-progress code.
Therefore no guarantees can be made regarding its suitability for production use.
You no longer need to distribute 2 files on the CompactFramework. You can delete
SQLite.Interop.DLL entirely. I wrote a custom tool called "mergebin" (available in the source
zip file) which combines the two libraries and gets around a glaring defect in the VS2005 linker for
ARM processors which doesn't allow you to link netmodules.
x64 and ia64 builds now use the same strong name as the x86 build. This means
breaking backward compatibility, but it was necessary in order to allow you to drop any of those
3 builds onto a PC and have your .NET program run properly. Prior to this, you'd get an error if
you built your program using the x86 build, and then installed the x64 version on a target
machine and tried to run your program against it.
The entire source project has been gone over top to bottom. A debug build no longer combines
the binaries into a single module, which was preventing proper debugging.
1.0.24.4 beta - January 16, 2006
This beta is built from sqlite.org's 3.3.1 alpha and contains development-in-progress code.
Therefore no guarantees can be made regarding its suitability for production use.
Fixed a bug in the UTF-16 handling code for preparing statements due to a behavioral change in
SQLite 3.3.0.
Added pager.c code necessary to cleanup after an encrypted file is closed.
Fixed an encryption bug that caused a fault when an encrypted file was rolled back.
Modified the testcase code to take advantage of optimizations regarding the use of a
DbCommandBuilder. DataAdapter insert speed increased dramatically as a result.
1.0.24.3 beta - January 10, 2006
This beta is built from sqlite.org's CVS HEAD (as it appeared at of the date of this beta) and
contains development-in-progress code. Therefore no guarantees can be made regarding its
suitability for production use.
Added support for database encryption at the pager level. Databases are encrypted using a 128-
bit RC4 stream algorithm. To open an existing encrypted database, you may now specify a
"Password={password}" text in the ConnectionString, or you may call the
SQLiteConnection.SetPassword() function to set the password on an open connection. To
encrypt existing non-encrypted databases or to change the password on an encrypted database,
you must use the SQLiteConnection.ChangePassword() function. If you use SetPassword()
instead of specifying a password in the connection string, or call ChangePassword() you may use
a binary byte array or a text string as the password.
Rewrote the locking implementation for the Compact Framework. It is now more robust and
incorporates into the SQLite codebase more efficiently than the previous CE adaptation.
Moved some of the embedded schema XML data into a resource file to ease code readability.
Automated the fixup of the original sqlite codebase's source prior to compiling, to ease merging
with sqlite.org's source.
1.0.24.2 - December 30, 2005
Fixed the SQLiteDataReader.HasRows property to return the proper value.
Implemented the inadvertently neglected RecordsAffected property on SQLiteDataReader.
SQLiteFunction static constructor was changed to pre-filter classes with only the
SQLiteFunctionAttribute. The code was throwing an exception when certain assemblies were
referenced in a project.
Fixed the SQLiteDataAdapter OnRowUpdated event, which was using the wrong variable to find
the attached event handler and subsequently not raising the event.
Small optimizations and fixes to SQLiteDataReader.NextResult().
1.0.24.1 - December 19, 2005
Update core SQLite engine to 3.2.8
1.0.24 - December 9, 2005
Fixed the Catalogs schema bug that caused attached databases not to be re-attached to a
cloned connection
Enhanced transactions to allow for a deferred or immediate writelock.
SQLiteConnection.BeginTransaction() now has an additional overload to support it
Commands are now prepared as they are executed instead of beforehand. This fixes a bug
whereby a multi-statement command that alters the database and subsequently references the
altered data would fail during Prepare().
Tightened up the SQLiteDataReader to prevent reading columns before calling the first Read() and
to prevent reading columns after the last Read().
A more descriptive error is thrown if there aren't enough parameters in the command to satisfy
the parameters required by the statement(s).
1.0.23 - November 21, 2005
Named parameters may now begin with @ to ease portability of the provider. SQLite's named
parameters are ordinarily prefixed with a : or $. The designer will still use the $ prefix however,
since its more compatible with the default SQLite engine.
Added several alternate ISO8601 date/time formats to SQLiteConvert.cs to increase
compatibility.
Relaxed coersion restrictions to work better with SQLite's inherent typelessenss.
1.0.22 - November 11, 2005
Fixed some globalization issues which resulted in incorrect case-insensitive comparisons
Fixed a bug in the routine that finds all user-defined functions in a loaded assembly. It would
throw an exception if any of the types in the assembly could not be loaded. The exception is
now caught and handled appropriately.
1.0.21 - November 4, 2005
Fixed a designer bug when creating typed datasets with parameterized queries.
The above fix then exposed another bug in the datareader's ability to query schema information
on parameterized commands, which was also fixed.
Compiled against the RTM version of VS2005.
Rewrote the design-time install script to use the XML DOM objects when writing to the
machine.config and to automatically register the DLL in the GAC.
Made changes to the app.config descriptions and help file to improve version-independent factory
support.
1.0.20 - October 19, 2005
Fixed a shortcut in SQLiteBase.GetValue which was insufficient for international environments.
The shortcut was removed and the "proper" procedure put in.
1.0.19 - October 5, 2005
Code merge with SQLite 3.2.7
Fixed bugs in the CE port code (os_wince.c) which were brought to light by recent changes in the
SQLite engine.
Recompiled and modified to be compatible with the September VS2005 Release Candidate.
Beta 2 users should continue to use 1.0.18.1
1.0.18.1 - September 19, 2005
Code merge with SQLite 3.2.6
1.0.18 - September 1, 2005
Added type-specific method calls when using the various SQLite classes that would've normally
returned a a generic Db base class, which aligns the code better with the Microsoft-supplied data
providers.
1.0.17 - August 26, 2005
Code merge with SQLite 3.2.5
Added Itanium and x64 build settings to the project (needs testing)
Bugfixes and enhancements to several schema types
Additional design-time support to include index and foreign key enumerations. Requires re-
registering the designer using INSTALL.CMD. The new designer code now allows the VS query
designer and typed datasets to automatically link up foreign keys, use indexes, and automatically
generate relationships from the schema.
Additional static methods on SQLiteConnection to create a database file, encrypt a file using the
Encrypted File System (EFS) on NTFS (requires NT 2K or above) and NTFS file compression
1.0.16 - August 24, 2005
Code merge with SQLite 3.2.4 with the large delete bugfix in CVS (which will become 3.2.5 soon)
Added new GetSchema() types: IndexColumns, ViewColumns, ForeignKeys
1.0.15 - August 22, 2005
Code merge with SQLite 3.2.3
Minor updates for better design-time experience. More design-time code to follow in subsequent
releases.
1.0.14 - August 16, 2005
Fixed a bug in the SQLiteDataAdapter due to insufficient implementation of the class. The
RowUpdating and RowUpdated events are now properly implemented, but unfortunately inserting
and updating data in a DataTable or DataSet is now much slower. This is the proper design
however, so the changes are here to stay.
Lots of schema changes to support Visual Studio's Data Designer architecture.
Added Designer support for the provider. It's not 100%, but you can design queries, add typed
datasets and perform quite a number of tasks all within Visual Studio now.
1.0.13 - August 8, 2005
Fixed a named parameter bug in the base SQLite_UTF16 class, which of course only showed up
when a database connection was opened using the UseUTF16Encoding=True parameter.
Fixed a performance issue in SQLite_UTF16 involving string marshaling.
1.0.12 - August 5, 2005
Full support for the Compact Framework. Each build (Debug/Release) now has a platform, either
Win32 or Compact Framework. The correct projects are built accordingly. See the Distributing
SQLite section for information on what files need to be distributed for each platform.
Modified SQLite3.Reset() and Step() functions to transparently handle timeouts while waiting on
the database to become available (typically when a writer is waiting on a reader to finish, or a
reader is waiting on a writer to finish).
Lots of code cleanup as suggested by the Code Analyzer (FxCop).
Lots of updates to the helpfile (as you can see).
Statements were already prepared lazily in a SQLiteCommand, but now its even more lazy.
Statements are now only prepared if the statements haven't been previously prepared and a
Prepare() function is called (and the command is associated with a connection) or just prior to
the command being executed.
1.0.11 - August 1, 2005
For everything except the Compact Framework, System.Data.SQLite.DLL is now the
only DLL required to use this provider! The assembly is now a multi-module assembly,
containing both the native SQLite3 codebase and the C# classes built on top of it. The Compact
Framework version (when completed) will not be able to support this feature, so backwards
compatibility with the Compact Framework has been preserved for the future.
Fixed a bug in SQLiteCommand.ExecuteScalar() that caused it to stop executing commands once
it obtained the first column of the first row-returning resultset. Any remaining statements after
the row-returning statement was ignored.
1.0.10 - June 10, 2005
Fixed a bug in the SQLite3.cs Prepare() function that created a statement even when the SQLite
engine returned a NULL pointer. Typically this occurs when multiple statements are processed and
there are trailing comments at the end of the statement.
Fixed a bug in SQLiteStatement.cs that retrieved parameter names for a parameterized query.
SQLite's parameters are 1-based, and the function was starting at 0. This was fine when all
parameters were unnamed, but for named parameters it caused the parameters to be out of
whack.
1.0.09a - May 25, 2005
Fixed a broken helpfile and corrected some obsolete help remarks in SQLiteFunction.cs
Added a version resource to the SQLite.Interop.DLL.
1.0.09 - May 24, 2005
Code merge with the latest 3.21 version of SQLite.
Removed obsolete methods and properties for Whidbey Beta 2
1.0.08 Refresh - Mar 24, 2005
Code merge with the latest 3.20 version of SQLite.
Recompiled the help file to fix a build error in it.
1.0.08 - Mar 11, 2005
Added additional #if statements to support the old beta 1 edition of VS2005.
Code merged the SQLite 3.14 source.
1.0.07 - Mar 5, 2005
Made more optimizations to frequently-called functions, resulting in significant performance gains
in all tests.
Recompiled the binaries using the latest VS2005 February CTP, resulting in yet more significant
speed gains. The 100k insert test used to take 3.5 seconds and the insertwithidentity took
almost 8 seconds. With the above two changes, those tests are now executing in 1.9 and 4.9
seconds respectively.
1.0.06 - Mar 1, 2005
Speed-ups to SQLiteDataReader. It was interop'ing unnecessarily every time it tried to fetch a
field due to a logic error.
Changed/Added some code to SQLiteConvert's internal DbType, Type and TypeAffinity functions.
Fixed the SQLiteDataReader to obey the flags set in the optional CommandBehavior flag from
SQLiteCommand.ExecuteReader().
Changed the default page size to 1024 to reflect the defaults of SQLite. Ignores the "Page Size"
connection string option for memory databases, as tests revealed that changing it resulted in
memory corruption errors.
Performance enhancements to the SQLiteCommand and SQLiteStatement classes which reduced
the 100,000 row insert execution time as well as the various Function execution times
significantly.
1.0.05 - Feb 25, 2005
Fixed the SQLite3 C# class step/reset functions to accomodate schema changes that invalidate a
prepared statement. Statements are recompiled transparently.
Moved all native DLL declarations to an UnsafeNativeMethods class.
Split several classes into their own modules for readability.
Renamed many internal variables, reviewed access to variables marked as internal and altered
their protection levels accordingly.
Due to the presence of the altered sqlite3 codebase and so many added interop functions, I
decided to rename the sqlite3 C project and the DLL to SQLite.Interop.DLL. This is the same core
sqlite3 codebase but designed specifically for this ADO.NET provider. This eliminates any
possibility of someone dropping another build of sqlite3.dll into the system and rendering the
provider inoperable. In the future if the folks at sqlite.org finally introduce a method of retrieving
column usage for an arbitrary prepared statement, I'll retool this library to be a lightweight
function call wrapper around the core binary distribution.
Added [SuppressUnmanagedCodeSecurity] attribute to the UnsafeNativeMethods class which
brings VS2005 November CTP execution speeds inline with the December CTP.
Added a bin directory to the project root where pre-compiled binaries can be found.
Added a doc directory where preliminary documentation on the class library can be found.
Documented a lot more of the classes internally.
1.0.04 - Feb 24, 2005
Removed the SQLiteContext class and revamped the way UserFunctions work to simplify the
imlementation.
Fixed a counting bug in the TestCases class, specifically in the function tests where I wasn't
resetting the counter and it was consequently reporting intrinsic and raw select calls as being
much much faster than they actually were. The numbers are now much closer to what I
expected for performance, with .NET user-functions still being the slowest, but only by a small
margin.
Small performance tweaks to SQLiteDataReader.
Added PageSize to the SQLiteConnectionStringBuilder and subsequently to the SQLiteConnection
Added a PRAGMA encoding=XXX execution statement to the SQLiteConnection after opening a
connection.
1.0.03 - Feb 23, 2005
Fixed up SQLiteCommandBuilder to correct implementation errors, which resulted in an
enormous performance boost in the InsertMany test. 10,000 row insert that executed in
1500ms now executes in 500ms.
Fixed several errors in the SQLite3_UTF16 class. ToString() was working incorrectly and the
Open() method failed to register user defined functions and collations.
Fixed a bug in SQLiteCommand.ClearCommands() whereby only the first statement was being
properly cleaned up.
Fixed a bug in SQLiteDataReader whereby calling NextResult() would not properly reset the
previously-executed command in the sequence.
Added an InsertManyWithIdentityFetch test, which appends a select clause to populate the ID of
the last inserted row into the InsertCommand, demonstrating ADO.NET's ability to auto-fetch
identity columns on insert.
1.0.02 - Feb 21, 2005
Tweaks to the xxx_interop functions that return char *'s, so they also return the length. Saves
an interop call to get the UTF-8 string length during conversion to a .NET string.
Reworked the whole interop.c thing into interop.h and reduced the code required to merge the
main sqlite3 codebase.
Added support for user-defined collations.

Send comments on this topic.


Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
SQLite understands most of the standard SQL language.
But it does omit some features while at the same time
adding a few features of its own. This document
attempts to describe precisely what parts of the SQL
language SQLite does and does not support. A list of
SQL keywords is also provided. The SQL language
syntax is described by syntax diagrams.

The following syntax documentation topics are


available:

The routines sqlite3_prepare_v2(), sqlite3_prepare(),


sqlite3_prepare16(), sqlite3_prepare16_v2(),
sqlite3_exec(), and sqlite3_get_table() accept an SQL
statement list (sql-stmt-list) which is a semicolon-
separated list of statements.

sql-stmt-list:

Each SQL statement in the statement list is an instance


of the following:

sql-stmt:
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
Aggregate Functions
The aggregate functions shown below are available by
default. Additional aggregate functions written in C
may be added using the sqlite3_create_function() API.

In any aggregate function that takes a single


argument, that argument can be preceded by the
keyword DISTINCT. In such cases, duplicate elements
are filtered before being passed into the aggregate
function. For example, the function "count(distinct X)"
will return the number of distinct values of column X
instead of the total number of non-null values in
column X.

avg(X)

The avg() function returns the average value of all


non-NULL X within a group. String and BLOB values
that do not look like numbers are interpreted as 0.
The result of avg() is always a floating point value
as long as at there is at least one non-NULL input
even if all inputs are integers. The result of avg() is
NULL if and only if there are no non-NULL inputs.

count(X)
count(*)

The count(X) function returns a count of the number


of times that X is not NULL in a group. The count(*)
function (with no arguments) returns the total
number of rows in the group.

group_concat(X)
group_concat(X,Y)

The group_concat() function returns a string which


is the concatenation of all non-NULL values of X. If
parameter Y is present then it is used as the
separator between instances of X. A comma (",") is
used as the separator if Y is omitted. The order of
the concatenated elements is arbitrary.

max(X)

The max() aggregate function returns the maximum


value of all values in the group. The maximum value
is the value that would be returned last in an ORDER
BY on the same column. Aggregate max() returns
NULL if and only if there are no non-NULL values in
the group.

min(X)

The min() aggregate function returns the minimum


non-NULL value of all values in the group. The
minimum value is the first non-NULL value that
would appear in an ORDER BY of the column.
Aggregate min() returns NULL if and only if there are
no non-NULL values in the group.

sum(X)
total(X)

The sum() and total() aggregate functions return


sum of all non-NULL values in the group. If there are
no non-NULL input rows then sum() returns NULL
but total() returns 0.0. NULL is not normally a
helpful result for the sum of no rows but the SQL
standard requires it and most other SQL database
engines implement sum() that way so SQLite does it
in the same way in order to be compatible. The non-
standard total() function is provided as a convenient
way to work around this design problem in the SQL
language.

The result of total() is always a floating point value.


The result of sum() is an integer value if all non-
NULL inputs are integers. If any input to sum() is
neither an integer or a NULL then sum() returns a
floating point value which might be an
approximation to the true sum.

Sum() will throw an "integer overflow" exception if


all inputs are integers or NULL and an integer
overflow occurs at any point during the computation.
Total() never throws an integer overflow.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
ALTER TABLE

alter-table-stmt: hide

column-def: show

SQLite supports a limited subset of ALTER TABLE. The


ALTER TABLE command in SQLite allows the user to
rename a table or to add a new column to an existing
table.

The RENAME TO syntax changes the name of table-


name to new-table-name . This command cannot be
used to move a table between attached databases, only
to rename a table within the same database.

If the table being renamed has triggers or indices, then


these remain attached to the table after it has been
renamed. However, if there are any view definitions, or
statements executed by triggers that refer to the table
being renamed, these are not automatically modified to
use the new table name. If this is required, the triggers
or view definitions must be dropped and recreated to
use the new table name by hand.
Important Note: The 'ALTER TABLE ... RENAME TO ...' command does not
update action statements within triggers or SELECT statements within
views. If the table being renamed is referenced from within triggers or
views, then those triggers and views must be dropped and recreated
separately by the application.

If foreign key constraints are enabled when a table is


renamed, then any REFERENCES clauses in any table
(either the table being renamed or some other table)
that refer to the table being renamed are modified to
refer to the renamed table by its new name.

The ADD COLUMN syntax is used to add a new column


to an existing table. The new column is always
appended to the end of the list of existing columns. The
column-def rule defines the characteristics of the new
column. The new column may take any of the forms
permissible in a CREATE TABLE statement, with the
following restrictions:

The column may not have a PRIMARY KEY or


UNIQUE constraint.
The column may not have a default value of
CURRENT_TIME, CURRENT_DATE,
CURRENT_TIMESTAMP, or an expression in
parentheses.
If a NOT NULL constraint is specified, then the
column must have a default value other than NULL.
If foreign key constraints are enabled and a column
with a REFERENCES clause is added, the column
must have a default value of NULL.
Note also that when adding a CHECK constraint, the
CHECK constraint is not tested against preexisting rows
of the table. This can result in a table that contains
data that is in violation of the CHECK constraint. Future
versions of SQLite might change to validate CHECK
constraints as they are added.

The execution time of the ALTER TABLE command is


independent of the amount of data in the table. The
ALTER TABLE command runs as quickly on a table with
10 million rows as it does on a table with 1 row.

After ADD COLUMN has been run on a database, that


database will not be readable by SQLite version 3.1.3
(2005-02-20) and earlier.

Making Other Kinds Of Table Schema Changes

The only schema altering commands directly supported


by SQLite are the "rename table" and "add column"
commands shown above. However, applications can
make other arbitrary changes to the format of a table
using a simple sequence of operations. The steps to
make arbitrary changes to the schema design of some
table X are as follows:

1. If foreign key constraints are enabled, disable them


using PRAGMA foreign_keys=OFF.

2. Start a transaction.

3. Remember the format of all indexes and triggers


associated with table X. This information will be
needed in step 8 below. One way to do this is to run
a query like the following: SELECT type, sql FROM
sqlite_master WHERE tbl_name='X'.

4. Use CREATE TABLE to construct a new table "new_X"


that is in the desired revised format of table X. Make
sure that the name "new_X" does not collide with
any existing table name, of course.

5. Transfer content from X into new_X using a


statement like: INSERT INTO new_X SELECT ...
FROM X.

6. Drop the old table X: DROP TABLE X.

7. Change the name of new_X to X using: ALTER TABLE


new_X RENAME TO X.

8. Use CREATE INDEX and CREATE TRIGGER to


reconstruct indexes and triggers associated with
table X. Perhaps use the old format of the triggers
and indexes saved from step 3 above as a guide,
making changes as appropriate for the alteration.

9. If any views refer to table X in a way that is affected


by the schema change, then drop those views using
DROP VIEW and recreate them with whatever
changes are necessary to accommodate the schema
change using CREATE VIEW.

0. If foreign key constraints were originally enabled


then run PRAGMA foreign_key_check to verify that
the schema change did not break any foreign key
constraints.

1. Commit the transaction started in step 2.

2. If foreign keys constraints were originally enabled,


reenable them now.

The procedure above is completely general and will


work even if the schema change causes the information
stored in the table to change. So the full procedure
above is appropriate for dropping a column, changing
the order of columns, adding or removing a UNIQUE
constraint or PRIMARY KEY, adding CHECK or FOREIGN
KEY or NOT NULL constraints, or changing the datatype
for a column, for example. However, a simpler and
faster procedure can optionally be used for some
changes that do no affect the on-disk content in any
way. The following simpler procedure is appropriate for
removing CHECK or FOREIGN KEY or NOT NULL
constraints, renaming columns, or adding or removing
or changing default values on a column.

1. Start a transaction.

2. Run PRAGMA schema_version to determine the


current schema version number. This number will be
needed for step 6 below.

3. Activate schema editing using PRAGMA


writable_schema=ON.
4. Run an UPDATE statement to change the definition
of table X in the sqlite_master table: UPDATE
sqlite_master SET sql=... WHERE type='table' AND
name='X';

Caution: Making a change to the sqlite_master table


like this will render the database corrupt and
unreadable if the change contains a syntax error. It
is suggested that careful testing of the UPDATE
statement be done on a separate blank database
prior to using it on a database containing important
data.

5. If the change to table X also affects other tables or


indexes or triggers are views within schema, then
run UPDATE statements to modify those other tables
indexes and views too. For example, if the name of a
column changes, all FOREIGN KEY constraints,
triggers, indexes, and views that refer to that
column must be modified.

Caution: Once again, making changes to the


sqlite_master table like this will render the database
corrupt and unreadable if the change contains an
error. Carefully test of this entire procedure on a
separate test database prior to using it on a
database containing important data and/or make
backup copies of important databases prior to
running this procedure.

6. Increment the schema version number using


PRAGMA schema_version=X where X is one more
than the old schema version number found in step 2
above.

7. Disable schema editing using PRAGMA


writable_schema=OFF.

8. (Optional) Run PRAGMA integrity_check to verify


that the schema changes did not damage the
database.

9. Commit the transaction started on step 1 above.

If some future version of SQLite adds new ALTER TABLE


capabilities, those capabilities will very likely use one
of the two procedures outlined above.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
ANALYZE

analyze-stmt: hide

The ANALYZE command gathers statistics about tables


and indices and stores the collected information in
internal tables of the database where the query
optimizer can access the information and use it to help
make better query planning choices. If no arguments
are given, all attached databases are analyzed. If a
schema name is given as the argument, then all tables
and indices in that one database are analyzed. If the
argument is a table name, then only that table and the
indices associated with that table are analyzed. If the
argument is an index name, then only that one index is
analyzed.

The default implementation stores all statistics in a


single table named "sqlite_stat1". If SQLite is compiled
with the SQLITE_ENABLE_STAT3 option and without the
SQLITE_ENABLE_STAT4 option, then additional
histogram data is collected and stored in sqlite_stat3.
If SQLite is compiled with the SQLITE_ENABLE_STAT4
option, then additional histogram data is collected and
stored in sqlite_stat4. Older versions of SQLite would
make use of the sqlite_stat2 table when compiled with
SQLITE_ENABLE_STAT2 but all recent versions of
SQLite ignore the sqlite_stat2 table. Future
enhancements may create additional internal tables
with the same name pattern except with final digit
larger than "4". All of these tables are collectively
referred to as "statistics tables".

The content of the statistics tables can be queried


using SELECT and can be changed using the DELETE,
INSERT, and UPDATE commands. The DROP TABLE
command works on statistics tables as of SQLite
version 3.7.9. (2011-11-01) The ALTER TABLE
command does not work on statistics tables.
Appropriate care should be used when changing the
content of the statistics tables as invalid content can
cause SQLite to select inefficient query plans.
Generally speaking, one should not modify the content
of the statistics tables by any mechanism other than
invoking the ANALYZE command. See "Manual Control
Of Query Plans Using SQLITE_STAT Tables" for further
information.

Statistics gathered by ANALYZE are not automatically


updated as the content of the database changes. If the
content of the database changes significantly, or if the
database schema changes, then one should consider
rerunning the ANALYZE command in order to update the
statistics.

The query planner loads the content of the statistics


tables into memory when the schema is read. Hence,
when an application changes the statistics tables
directly, SQLite will not immediately notice the
changes. An application can force the query planner to
reread the statistics tables by running ANALYZE
sqlite_master.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
ATTACH DATABASE

attach-stmt: hide

expr: show

The ATTACH DATABASE statement adds another


database file to the current database connection.
Database files that were previously attached can be
removed using the DETACH DATABASE command.

The filename for the database to be attached is the


value of the expression that occurs before the AS
keyword. 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. The filename argument can be a URI
filename if URI filename processing is enable on the
database connection. The default behavior is for URI
filenames to be disabled, however that might change in
a future release of SQLite, so application developers
are advised to plan accordingly.

The name that occurs after the AS keyword is the name


of the database used internally by SQLite. The schema-
names 'main' and 'temp' refer to the main database
and the database used for temporary tables. The main
and temp databases cannot be attached or detached.

Tables in an attached database can be referred to using


the syntax schema-name.table-name. 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. 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.

Transactions involving multiple attached databases are


atomic, assuming that the main database is not
":memory:" and the journal_mode is not WAL. 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.

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.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
comment

comment-syntax: hide

Comments are not SQL commands, but can occur


within the text of SQL queries passed to
sqlite3_prepare_v2() and related interfaces. Comments
are treated as whitespace by the parser. Comments can
begin anywhere whitespace can be found, including
inside expressions that span multiple lines.

SQL comments begin with two consecutive "-"


characters (ASCII 0x2d) and extend up to and including
the next newline character (ASCII 0x0a) or until the
end of input, whichever comes first.

C-style comments begin with "/*" and extend up to and


including the next "*/" character pair or until the end of
input, whichever comes first. C-style comments can
span multiple lines.

Comments can appear anywhere whitespace can occur,


including inside expressions and in the middle of other
SQL statements. Comments do not nest.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
ON CONFLICT clause

conflict-clause: hide

The ON CONFLICT clause is not a separate SQL


command. It is a non-standard clause that can appear
in many other SQL commands. It is given its own
section in this document because it is not part of
standard SQL and therefore might not be familiar.

The syntax for the ON CONFLICT clause is as shown


above for the CREATE TABLE command. For the INSERT
and UPDATE commands, the keywords "ON CONFLICT"
are replaced by "OR" so that the syntax reads more
naturally. For example, instead of "INSERT ON
CONFLICT IGNORE" we have "INSERT OR IGNORE". The
keywords change but the meaning of the clause is the
same either way.

The ON CONFLICT clause applies to UNIQUE, NOT


NULL, CHECK, and PRIMARY KEY constraints. The ON
CONFLICT algorithm does not apply to FOREIGN KEY
constraints. There are five conflict resolution algorithm
choices: ROLLBACK, ABORT, FAIL, IGNORE, and
REPLACE. The default conflict resolution algorithm is
ABORT. This is what they mean:

ROLLBACK

When an applicable constraint violation occurs, the


ROLLBACK resolution algorithm aborts the current
SQL statement with an SQLITE_CONSTRAINT error
and rolls back the current transaction. If no
transaction is active (other than the implied
transaction that is created on every command) then
the ROLLBACK resolution algorithm works the same
as the ABORT algorithm.

ABORT

When an applicable constraint violation occurs, the


ABORT resolution algorithm aborts the current SQL
statement with an SQLITE_CONSTRAINT error and
backs out any changes made by the current SQL
statement; but changes caused by prior SQL
statements within the same transaction are
preserved and the transaction remains active. This is
the default behavior and the behavior specified by
the SQL standard.

FAIL

When an applicable constraint violation occurs, the


FAIL resolution algorithm aborts the current SQL
statement with an SQLITE_CONSTRAINT error. But
the FAIL resolution does not back out prior changes
of the SQL statement that failed nor does it end the
transaction. For example, if an UPDATE statement
encountered a constraint violation on the 100th row
that it attempts to update, then the first 99 row
changes are preserved but changes to rows 100 and
beyond never occur.

IGNORE

When an applicable constraint violation occurs, the


IGNORE resolution algorithm skips the one row that
contains the constraint violation and continues
processing subsequent rows of the SQL statement as
if nothing went wrong. Other rows before and after
the row that contained the constraint violation are
inserted or updated normally. No error is returned
when the IGNORE conflict resolution algorithm is
used.

REPLACE

When a UNIQUE or PRIMARY KEY constraint violation


occurs, the REPLACE algorithm deletes pre-existing
rows that are causing the constraint violation prior
to inserting or updating the current row and the
command continues executing normally. If a NOT
NULL constraint violation occurs, the REPLACE
conflict resolution replaces the NULL value with the
default value for that column, or if the column has
no default value, then the ABORT algorithm is used.
If a CHECK constraint violation occurs, the REPLACE
conflict resolution algorithm always works like
ABORT.

When the REPLACE conflict resolution strategy


deletes rows in order to satisfy a constraint, delete
triggers fire if and only if recursive triggers are
enabled.

The update hook is not invoked for rows that are


deleted by the REPLACE conflict resolution strategy.
Nor does REPLACE increment the change counter.
The exceptional behaviors defined in this paragraph
might change in a future release.

The algorithm specified in the OR clause of an INSERT


or UPDATE overrides any algorithm specified in a
CREATE TABLE. If no algorithm is specified anywhere,
the ABORT algorithm is used.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
Core Functions
The core functions shown below are available by
default. Date & Time functions, aggregate functions,
and JSON functions are documented separately. An
application may define additional functions written in C
and added to the database engine using the
sqlite3_create_function() API.

abs(X)

The abs(X) function returns the absolute value of the


numeric argument X. Abs(X) returns NULL if X is
NULL. Abs(X) returns 0.0 if X is a string or blob that
cannot be converted to a numeric value. If X is the
integer -9223372036854775808 then abs(X) throws
an integer overflow error since there is no
equivalent positive 64-bit two complement value.

changes()

The changes() function returns the number of


database rows that were changed or inserted or
deleted by the most recently completed INSERT,
DELETE, or UPDATE statement, exclusive of
statements in lower-level triggers. The changes()
SQL function is a wrapper around the
sqlite3_changes() C/C++ function and hence follows
the same rules for counting changes.
char(X1,X2,...,XN)

The char(X1,X2,...,XN) function returns a string


composed of characters having the unicode code
point values of integers X1 through XN, respectively.

coalesce(X,Y,...)

The coalesce() function returns a copy of its first


non-NULL argument, or NULL if all arguments are
NULL. Coalesce() must have at least 2 arguments.

glob(X,Y)

The glob(X,Y) function is equivalent to the


expression "Y GLOB X". Note that the X and Y
arguments are reversed in the glob() function
relative to the infix GLOB operator. If the
sqlite3_create_function() interface is used to
override the glob(X,Y) function with an alternative
implementation then the GLOB operator will invoke
the alternative implementation.

hex(X)

The hex() function interprets its argument as a BLOB


and returns a string which is the upper-case
hexadecimal rendering of the content of that blob.

ifnull(X,Y)

The ifnull() function returns a copy of its first non-


NULL argument, or NULL if both arguments are
NULL. Ifnull() must have exactly 2 arguments. The
ifnull() function is equivalent to coalesce() with two
arguments.

instr(X,Y)

The instr(X,Y) function finds the first occurrence of


string Y within string X and returns the number of
prior characters plus 1, or 0 if Y is nowhere found
within X. Or, if X and Y are both BLOBs, then
instr(X,Y) returns one more than the number bytes
prior to the first occurrence of Y, or 0 if Y does not
occur anywhere within X. If both arguments X and Y
to instr(X,Y) are non-NULL and are not BLOBs then
both are interpreted as strings. If either X or Y are
NULL in instr(X,Y) then the result is NULL.

last_insert_rowid()

The last_insert_rowid() function returns the ROWID


of the last row insert from the database connection
which invoked the function. The last_insert_rowid()
SQL function is a wrapper around the
sqlite3_last_insert_rowid() C/C++ interface
function.

length(X)

For a string value X, the length(X) function returns


the number of characters (not bytes) in X prior to
the first NUL character. Since SQLite strings do not
normally contain NUL characters, the length(X)
function will usually return the total number of
characters in the string X. For a blob value X,
length(X) returns the number of bytes in the blob. If
X is NULL then length(X) is NULL. If X is numeric
then length(X) returns the length of a string
representation of X.

like(X,Y)
like(X,Y,Z)

The like() function is used to implement the "Y LIKE


X [ESCAPE Z]" expression. If the optional ESCAPE
clause is present, then the like() function is invoked
with three arguments. Otherwise, it is invoked with
two arguments only. Note that the X and Y
parameters are reversed in the like() function
relative to the infix LIKE operator. The
sqlite3_create_function() interface can be used to
override the like() function and thereby change the
operation of the LIKE operator. When overriding the
like() function, it may be important to override both
the two and three argument versions of the like()
function. Otherwise, different code may be called to
implement the LIKE operator depending on whether
or not an ESCAPE clause was specified.

likelihood(X,Y)

The likelihood(X,Y) function returns argument X


unchanged. The value Y in likelihood(X,Y) must be a
floating point constant between 0.0 and 1.0,
inclusive. The likelihood(X) function is a no-op that
the code generator optimizes away so that it
consumes no CPU cycles during run-time (that is,
during calls to sqlite3_step()). The purpose of the
likelihood(X,Y) function is to provide a hint to the
query planner that the argument X is a boolean that
is true with a probability of approximately Y. The
unlikely(X) function is short-hand for
likelihood(X,0.0625). The likely(X) function is short-
hand for likelihood(X,0.9375).

likely(X)

The likely(X) function returns the argument X


unchanged. The likely(X) function is a no-op that the
code generator optimizes away so that it consumes
no CPU cycles at run-time (that is, during calls to
sqlite3_step()). The purpose of the likely(X) function
is to provide a hint to the query planner that the
argument X is a boolean value that is usually true.
The likely(X) function is equivalent to
likelihood(X,0.9375). See also: unlikely(X).

load_extension(X)
load_extension(X,Y)

The load_extension(X,Y) function loads SQLite


extensions out of the shared library file named X
using the entry point Y. The result of
load_extension() is always a NULL. If Y is omitted
then the default entry point name is used. The
load_extension() function raises an exception if the
extension fails to load or initialize correctly.

The load_extension() function will fail if the


extension attempts to modify or delete an SQL
function or collating sequence. The extension can
add new functions or collating sequences, but cannot
modify or delete existing functions or collating
sequences because those functions and/or collating
sequences might be used elsewhere in the currently
running SQL statement. To load an extension that
changes or deletes functions or collating sequences,
use the sqlite3_load_extension() C-language API.

For security reasons, extension loaded is turned off


by default and must be enabled by a prior call to
sqlite3_enable_load_extension().

lower(X)

The lower(X) function returns a copy of string X with


all ASCII characters converted to lower case. The
default built-in lower() function works for ASCII
characters only. To do case conversions on non-
ASCII characters, load the ICU extension.

ltrim(X)
ltrim(X,Y)

The ltrim(X,Y) function returns a string formed by


removing any and all characters that appear in Y
from the left side of X. If the Y argument is omitted,
ltrim(X) removes spaces from the left side of X.

max(X,Y,...)

The multi-argument max() function returns the


argument with the maximum value, or return NULL if
any argument is NULL. The multi-argument max()
function searches its arguments from left to right for
an argument that defines a collating function and
uses that collating function for all string
comparisons. If none of the arguments to max()
define a collating function, then the BINARY collating
function is used. Note that max() is a simple
function when it has 2 or more arguments but
operates as an aggregate function if given only a
single argument.

min(X,Y,...)

The multi-argument min() function returns the


argument with the minimum value. The multi-
argument min() function searches its arguments
from left to right for an argument that defines a
collating function and uses that collating function for
all string comparisons. If none of the arguments to
min() define a collating function, then the BINARY
collating function is used. Note that min() is a
simple function when it has 2 or more arguments
but operates as an aggregate function if given only a
single argument.
nullif(X,Y)

The nullif(X,Y) function returns its first argument if


the arguments are different and NULL if the
arguments are the same. The nullif(X,Y) function
searches its arguments from left to right for an
argument that defines a collating function and uses
that collating function for all string comparisons. If
neither argument to nullif() defines a collating
function then the BINARY is used.

printf(FORMAT,...)

The printf(FORMAT,...) SQL function works like the


sqlite3_mprintf() C-language function and the
printf() function from the standard C library. The first
argument is a format string that specifies how to
construct the output string using values taken from
subsequent arguments. If the FORMAT argument is
missing or NULL then the result is NULL. The %n
format is silently ignored and does not consume an
argument. The %p format is an alias for %X. The %z
format is interchangeable with %s. If there are too
few arguments in the argument list, missing
arguments are assumed to have a NULL value, which
is translated into 0 or 0.0 for numeric formats or an
empty string for %s.

quote(X)

The quote(X) function returns the text of an SQL


literal which is the value of its argument suitable for
inclusion into an SQL statement. Strings are
surrounded by single-quotes with escapes on interior
quotes as needed. BLOBs are encoded as
hexadecimal literals. Strings with embedded NUL
characters cannot be represented as string literals in
SQL and hence the returned string literal is
truncated prior to the first NUL.

random()

The random() function returns a pseudo-random


integer between -9223372036854775808 and
+9223372036854775807.

randomblob(N)

The randomblob(N) function return an N-byte blob


containing pseudo-random bytes. If N is less than 1
then a 1-byte random blob is returned.

Hint: applications can generate globally unique


identifiers using this function together with hex()
and/or lower() like this:

hex(randomblob(16))
lower(hex(randomblob(16)))

replace(X,Y,Z)

The replace(X,Y,Z) function returns a string formed


by substituting string Z for every occurrence of
string Y in string X. The BINARY collating sequence
is used for comparisons. If Y is an empty string then
return X unchanged. If Z is not initially a string, it is
cast to a UTF-8 string prior to processing.

round(X)
round(X,Y)

The round(X,Y) function returns a floating-point


value X rounded to Y digits to the right of the
decimal point. If the Y argument is omitted, it is
assumed to be 0.

rtrim(X)
rtrim(X,Y)

The rtrim(X,Y) function returns a string formed by


removing any and all characters that appear in Y
from the right side of X. If the Y argument is
omitted, rtrim(X) removes spaces from the right side
of X.

soundex(X)

The soundex(X) function returns a string that is the


soundex encoding of the string X. The string "?000"
is returned if the argument is NULL or contains no
ASCII alphabetic characters. This function is omitted
from SQLite by default. It is only available if the
SQLITE_SOUNDEX compile-time option is used when
SQLite is built.
sqlite_compileoption_get(N)

The sqlite_compileoption_get() SQL function is a


wrapper around the sqlite3_compileoption_get()
C/C++ function. This routine returns the N-th
compile-time option used to build SQLite or NULL if
N is out of range. See also the compile_options
pragma.

sqlite_compileoption_used(X)

The sqlite_compileoption_used() SQL function is a


wrapper around the sqlite3_compileoption_used()
C/C++ function. When the argument X to
sqlite_compileoption_used(X) is a string which is the
name of a compile-time option, this routine returns
true (1) or false (0) depending on whether or not
that option was used during the build.

sqlite_source_id()

The sqlite_source_id() function returns a string that


identifies the specific version of the source code that
was used to build the SQLite library. The string
returned by sqlite_source_id() is the date and time
that the source code was checked in followed by the
SHA1 hash for that check-in. This function is an SQL
wrapper around the sqlite3_sourceid() C interface.

sqlite_version()

The sqlite_version() function returns the version


string for the SQLite library that is running. This
function is an SQL wrapper around the
sqlite3_libversion() C-interface.

substr(X,Y,Z)
substr(X,Y)

The substr(X,Y,Z) function returns a substring of


input string X that begins with the Y-th character and
which is Z characters long. If Z is omitted then
substr(X,Y) returns all characters through the end of
the string X beginning with the Y-th. The left-most
character of X is number 1. If Y is negative then the
first character of the substring is found by counting
from the right rather than the left. If Z is negative
then the abs(Z) characters preceding the Y-th
character are returned. If X is a string then
characters indices refer to actual UTF-8 characters.
If X is a BLOB then the indices refer to bytes.

total_changes()

The total_changes() function returns the number of


row changes caused by INSERT, UPDATE or DELETE
statements since the current database connection
was opened. This function is a wrapper around the
sqlite3_total_changes() C/C++ interface.

trim(X)
trim(X,Y)

The trim(X,Y) function returns a string formed by


removing any and all characters that appear in Y
from both ends of X. If the Y argument is omitted,
trim(X) removes spaces from both ends of X.

typeof(X)

The typeof(X) function returns a string that indicates


the datatype of the expression X: "null", "integer",
"real", "text", or "blob".

unicode(X)

The unicode(X) function returns the numeric unicode


code point corresponding to the first character of the
string X. If the argument to unicode(X) is not a
string then the result is undefined.

unlikely(X)

The unlikely(X) function returns the argument X


unchanged. The unlikely(X) function is a no-op that
the code generator optimizes away so that it
consumes no CPU cycles at run-time (that is, during
calls to sqlite3_step()). The purpose of the
unlikely(X) function is to provide a hint to the query
planner that the argument X is a boolean value that
is usually not true. The unlikely(X) function is
equivalent to likelihood(X, 0.0625).

upper(X)

The upper(X) function returns a copy of input string


X in which all lower-case ASCII characters are
converted to their upper-case equivalent.

zeroblob(N)

The zeroblob(N) function returns a BLOB consisting


of N bytes of 0x00. SQLite manages these zeroblobs
very efficiently. Zeroblobs can be used to reserve
space for a BLOB that is later written using
incremental BLOB I/O. This SQL function is
implemented using the sqlite3_result_zeroblob()
routine from the C/C++ interface.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
CREATE INDEX

create-index-stmt: hide

expr: show

indexed-column: show

The CREATE INDEX command consists of the keywords


"CREATE INDEX" followed by the name of the new
index, the keyword "ON", the name of a previously
created table that is to be indexed, and a parenthesized
list of table column names and/or expressions that are
used for the index key. If the optional WHERE clause is
included, then the index is a "partial index".

Each column name or expression can be followed by


one of the "ASC" or "DESC" keywords to indicate sort
order. The sort order may or may not be ignored
depending on the database file format, and in particular
the schema format number. The "legacy" schema
format (1) ignores index sort order. The descending
index schema format (4) takes index sort order into
account. Only versions of SQLite 3.3.0 (2006-01-11)
and later are able to understand the descending index
format. For compatibility, version of SQLite between
3.3.0 and 3.7.9 use the legacy schema format by
default. The newer schema format is used by default in
version 3.7.10 (2012-01-16) and later. The
legacy_file_format pragma can be used to change set
the specific behavior for any version of SQLite.

The COLLATE clause optionally following each column


name or expression defines a collating sequence used
for text entries in that column. The default collating
sequence is the collating sequence defined for that
column in the CREATE TABLE statement. Or if no
collating sequence is otherwise defined, the built-in
BINARY collating sequence is used.

Expressions in an index may not reference other tables


and may not use subqueries nor functions whose result
might change (ex: random() or sqlite_version()).
Expressions in an index may only refer to columns in
the table that is being indexed. Indexes on expression
will not work with versions of SQLite prior to version
3.9.0 (2015-10-14). See the Indexes On Expressions
document for additional information about using
general expressions in CREATE INDEX statements.

There are no arbitrary limits on the number of indices


that can be attached to a single table. The number of
columns in an index is limited to the value set by
sqlite3_limit(SQLITE_LIMIT_COLUMN,...).

If the UNIQUE keyword appears between CREATE and


INDEX then duplicate index entries are not allowed.
Any attempt to insert a duplicate entry will result in an
error. For the purposes of unique indices, all NULL
values are considered to different from all other NULL
values and are thus unique. This is one of the two
possible interpretations of the SQL-92 standard (the
language in the standard is ambiguous) and is the
interpretation followed by PostgreSQL, MySQL, Firebird,
and Oracle. Informix and Microsoft SQL Server follow
the other interpretation of the standard.

If the optional IF NOT EXISTS clause is present and


another index with the same name already exists, then
this command becomes a no-op.

Indexes are removed with the DROP INDEX command.


Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
CREATE TABLE

create-table-stmt: hide

column-def: show

select-stmt: show

table-constraint: show

The "CREATE TABLE" command is used to create a new


table in an SQLite database. A CREATE TABLE command
specifies the following attributes of the new table:

The name of the new table.

The database in which the new table is created.


Tables may be created in the main database, the
temp database, or in any attached database.
The name of each column in the table.

The declared type of each column in the table.

A default value or expression for each column in the


table.

A default collation sequence to use with each


column.

Optionally, a PRIMARY KEY for the table. Both single


column and composite (multiple column) primary
keys are supported.

A set of SQL constraints for each table. SQLite


supports UNIQUE, NOT NULL, CHECK and FOREIGN
KEY constraints.

Whether the table is a WITHOUT ROWID table.

Every CREATE TABLE statement must specify a name


for the new table. Table names that begin with "sqlite_"
are reserved for internal use. It is an error to attempt
to create a table with a name that starts with "sqlite_".

If a schema-name is specified, it must be either


"main", "temp", or the name of an attached database.
In this case the new table is created in the named
database. If the "TEMP" or "TEMPORARY" keyword
occurs between the "CREATE" and "TABLE" then the
new table is created in the temp database. It is an
error to specify both a schema-name and the TEMP or
TEMPORARY keyword, unless the schema-name is
"temp". If no schema name is specified and the TEMP
keyword is not present then the table is created in the
main database.

It is usually an error to attempt to create a new table


in a database that already contains a table, index or
view of the same name. However, if the "IF NOT
EXISTS" clause is specified as part of the CREATE
TABLE statement and a table or view of the same name
already exists, the CREATE TABLE command simply has
no effect (and no error message is returned). An error
is still returned if the table cannot be created because
of an existing index, even if the "IF NOT EXISTS"
clause is specified.

It is not an error to create a table that has the same


name as an existing trigger.

Tables are removed using the DROP TABLE statement.

CREATE TABLE ... AS SELECT Statements

A "CREATE TABLE ... AS SELECT" statement creates and


populates a database table based on the results of a
SELECT statement. The table has the same number of
columns as the rows returned by the SELECT
statement. The name of each column is the same as
the name of the corresponding column in the result set
of the SELECT statement. The declared type of each
column is determined by the expression affinity of the
corresponding expression in the result set of the
SELECT statement, as follows:

Expression Affinity Column Declared Type


TEXT "TEXT"
NUMERIC "NUM"
INTEGER "INT"
REAL "REAL"
NONE "" (empty string)

A table created using CREATE TABLE AS has no


PRIMARY KEY and no constraints of any kind. The
default value of each column is NULL. The default
collation sequence for each column of the new table is
BINARY.

Tables created using CREATE TABLE AS are initially


populated with the rows of data returned by the SELECT
statement. Rows are assigned contiguously ascending
rowid values, starting with 1, in the order that they are
returned by the SELECT statement.

Column Definitions

Unless it is a CREATE TABLE ... AS SELECT statement, a


CREATE TABLE includes one or more column definitions,
optionally followed by a list of table constraints. Each
column definition consists of the name of the column,
optionally followed by the declared type of the column,
then one or more optional column constraints. Included
in the definition of "column constraints" for the
purposes of the previous statement are the COLLATE
and DEFAULT clauses, even though these are not really
constraints in the sense that they do not restrict the
data that the table may contain. The other constraints -
NOT NULL, CHECK, UNIQUE, PRIMARY KEY and
FOREIGN KEY constraints - impose restrictions on the
tables data, and are are described under SQL Data
Constraints below.

Unlike most SQL databases, SQLite does not restrict


the type of data that may be inserted into a column
based on the columns declared type. Instead, SQLite
uses dynamic typing. The declared type of a column is
used to determine the affinity of the column only.

The DEFAULT clause specifies a default value to use for


the column if no value is explicitly provided by the user
when doing an INSERT. If there is no explicit DEFAULT
clause attached to a column definition, then the default
value of the column is NULL. An explicit DEFAULT
clause may specify that the default value is NULL, a
string constant, a blob constant, a signed-number, or
any constant expression enclosed in parentheses. A
default value may also be one of the special case-
independent keywords CURRENT_TIME, CURRENT_DATE
or CURRENT_TIMESTAMP. For the purposes of the
DEFAULT clause, an expression is considered constant if
it does contains no sub-queries, column or table
references, bound parameters, or string literals
enclosed in double-quotes instead of single-quotes.

Each time a row is inserted into the table by an INSERT


statement that does not provide explicit values for all
table columns the values stored in the new row are
determined by their default values, as follows:

If the default value of the column is a constant


NULL, text, blob or signed-number value, then that
value is used directly in the new row.

If the default value of a column is an expression in


parentheses, then the expression is evaluated once
for each row inserted and the results used in the
new row.

If the default value of a column is CURRENT_TIME,


CURRENT_DATE or CURRENT_TIMESTAMP, then the
value used in the new row is a text representation of
the current UTC date and/or time. For
CURRENT_TIME, the format of the value is
"HH:MM:SS". For CURRENT_DATE, "YYYY-MM-DD".
The format for CURRENT_TIMESTAMP is "YYYY-MM-
DD HH:MM:SS".

The COLLATE clause specifies the name of a collating


sequence to use as the default collation sequence for
the column. If no COLLATE clause is specified, the
default collation sequence is BINARY.

The number of columns in a table is limited by the


SQLITE_MAX_COLUMN compile-time parameter. A
single row of a table cannot store more than
SQLITE_MAX_LENGTH bytes of data. Both of these
limits can be lowered at runtime using the
sqlite3_limit() C/C++ interface.

SQL Data Constraints

Each table in SQLite may have at most one PRIMARY


KEY. If the keywords PRIMARY KEY are added to a
column definition, then the primary key for the table
consists of that single column. Or, if a PRIMARY KEY
clause is specified as a table-constraint, then the
primary key of the table consists of the list of columns
specified as part of the PRIMARY KEY clause. The
PRIMARY KEY clause must contain only column names
the use of expressions in an indexed-column of a
PRIMARY KEY is not supported. An error is raised if
more than one PRIMARY KEY clause appears in a
CREATE TABLE statement. The PRIMARY KEY is optional
for ordinary tables but is required for WITHOUT ROWID
tables.

If a table has a single column primary key and the


declared type of that column is "INTEGER" and the
table is not a WITHOUT ROWID table, then the column
is known as an INTEGER PRIMARY KEY. See below for a
description of the special properties and behaviors
associated with an INTEGER PRIMARY KEY.

Each row in a table with a primary key must have a


unique combination of values in its primary key
columns. For the purposes of determining the
uniqueness of primary key values, NULL values are
considered distinct from all other values, including
other NULLs. If an INSERT or UPDATE statement
attempts to modify the table content so that two or
more rows have identical primary key values, that is a
constraint violation.

According to the SQL standard, PRIMARY KEY should


always imply NOT NULL. Unfortunately, due to a bug in
some early versions, this is not the case in SQLite.
Unless the column is an INTEGER PRIMARY KEY or the
table is a WITHOUT ROWID table or the column is
declared NOT NULL, SQLite allows NULL values in a
PRIMARY KEY column. SQLite could be fixed to conform
to the standard, but doing so might break legacy
applications. Hence, it has been decided to merely
document the fact that SQLite allowing NULLs in most
PRIMARY KEY columns.

A UNIQUE constraint is similar to a PRIMARY KEY


constraint, except that a single table may have any
number of UNIQUE constraints. For each UNIQUE
constraint on the table, each row must contain a unique
combination of values in the columns identified by the
UNIQUE constraint. For the purposes of UNIQUE
constraints, NULL values are considered distinct from
all other values, including other NULLs. As with
PRIMARY KEYs, a UNIQUE table-constraint clause must
contain only column names the use of expressions in
an indexed-column of a UNIQUE table-constraint is not
supported.
In most cases, UNIQUE and PRIMARY KEY constraints
are implemented by creating a unique index in the
database. (The exceptions are INTEGER PRIMARY KEY
and PRIMARY KEYs on WITHOUT ROWID tables.) Hence,
the following schemas are logically equivalent:

1. CREATE TABLE t1(a, b UNIQUE);

2. CREATE TABLE t1(a, b PRIMARY KEY);

3. CREATE TABLE t1(a, b);


CREATE UNIQUE INDEX t1b ON t1(b);

A CHECK constraint may be attached to a column


definition or specified as a table constraint. In practice
it makes no difference. Each time a new row is inserted
into the table or an existing row is updated, the
expression associated with each CHECK constraint is
evaluated and cast to a NUMERIC value in the same
way as a CAST expression. If the result is zero (integer
value 0 or real value 0.0), then a constraint violation
has occurred. If the CHECK expression evaluates to
NULL, or any other non-zero value, it is not a constraint
violation. The expression of a CHECK constraint may
not contain a subquery.

A NOT NULL constraint may only be attached to a


column definition, not specified as a table constraint.
Not surprisingly, a NOT NULL constraint dictates that
the associated column may not contain a NULL value.
Attempting to set the column value to NULL when
inserting a new row or updating an existing one causes
a constraint violation.

Exactly how a constraint violation is dealt with is


determined by the constraint conflict resolution
algorithm. Each PRIMARY KEY, UNIQUE, NOT NULL and
CHECK constraint has a default conflict resolution
algorithm. PRIMARY KEY, UNIQUE and NOT NULL
constraints may be explicitly assigned a default conflict
resolution algorithm by including a conflict-clause in
their definitions. Or, if a constraint definition does not
include a conflict-clause or it is a CHECK constraint, the
default conflict resolution algorithm is ABORT. Different
constraints within the same table may have different
default conflict resolution algorithms. See the section
titled ON CONFLICT for additional information.

ROWIDs and the INTEGER PRIMARY KEY

Except for WITHOUT ROWID tables, all rows within


SQLite tables have a 64-bit signed integer key that
uniquely identifies the row within its table. This integer
is usually called the "rowid". The rowid value can be
accessed using one of the special case-independent
names "rowid", "oid", or "_rowid_" in place of a column
name. If a table contains a user defined column named
"rowid", "oid" or "_rowid_", then that name always
refers the explicitly declared column and cannot be
used to retrieve the integer rowid value.

The rowid (and "oid" and "_rowid_") is omitted in


WITHOUT ROWID tables. WITHOUT ROWID tables are
only available in SQLite version 3.8.2 (2013-12-06)
and later. A table that lacks the WITHOUT ROWID
clause is called a "rowid table".

The data for rowid tables is stored as a B-Tree structure


containing one entry for each table row, using the
rowid value as the key. This means that retrieving or
sorting records by rowid is fast. Searching for a record
with a specific rowid, or for all records with rowids
within a specified range is around twice as fast as a
similar search made by specifying any other PRIMARY
KEY or indexed value.

With one exception noted below, if a rowid table has a


primary key that consists of a single column and the
declared type of that column is "INTEGER" in any
mixture of upper and lower case, then the column
becomes an alias for the rowid. Such a column is
usually referred to as an "integer primary key". A
PRIMARY KEY column only becomes an integer primary
key if the declared type name is exactly "INTEGER".
Other integer type names like "INT" or "BIGINT" or
"SHORT INTEGER" or "UNSIGNED INTEGER" causes the
primary key column to behave as an ordinary table
column with integer affinity and a unique index, not as
an alias for the rowid.

The exception mentioned above is that if the


declaration of a column with declared type "INTEGER"
includes an "PRIMARY KEY DESC" clause, it does not
become an alias for the rowid and is not classified as
an integer primary key. This quirk is not by design. It is
due to a bug in early versions of SQLite. But fixing the
bug could result in backwards incompatibilities. Hence,
the original behavior has been retained (and
documented) because odd behavior in a corner case is
far better than a compatibility break. This means that
the following three table declarations all cause the
column "x" to be an alias for the rowid (an integer
primary key):

CREATE TABLE t(x INTEGER PRIMARY KEY ASC, y, z);


CREATE TABLE t(x INTEGER, y, z, PRIMARY KEY(x ASC));
CREATE TABLE t(x INTEGER, y, z, PRIMARY KEY(x DESC));

But the following declaration does not result in "x"


being an alias for the rowid:

CREATE TABLE t(x INTEGER PRIMARY KEY DESC, y, z);

Rowid values may be modified using an UPDATE


statement in the same way as any other column value
can, either using one of the built-in aliases ("rowid",
"oid" or "_rowid_") or by using an alias created by an
integer primary key. Similarly, an INSERT statement
may provide a value to use as the rowid for each row
inserted. Unlike normal SQLite columns, an integer
primary key or rowid column must contain integer
values. Integer primary key or rowid columns are not
able to hold floating point values, strings, BLOBs, or
NULLs.
If an UPDATE statement attempts to set an integer
primary key or rowid column to a NULL or blob value,
or to a string or real value that cannot be losslessly
converted to an integer, a "datatype mismatch" error
occurs and the statement is aborted. If an INSERT
statement attempts to insert a blob value, or a string or
real value that cannot be losslessly converted to an
integer into an integer primary key or rowid column, a
"datatype mismatch" error occurs and the statement is
aborted.

If an INSERT statement attempts to insert a NULL value


into a rowid or integer primary key column, the system
chooses an integer value to use as the rowid
automatically. A detailed description of how this is done
is provided separately.

The parent key of a foreign key constraint is not


allowed to use the rowid. The parent key must used
named columns only.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
CREATE TRIGGER

create-trigger-stmt: hide

delete-stmt: show

expr: show

insert-stmt: show
select-stmt: show

update-stmt: show

The CREATE TRIGGER statement is used to add triggers


to the database schema. Triggers are database
operations that are automatically performed when a
specified database event occurs.

A trigger may be specified to fire whenever a DELETE,


INSERT, or UPDATE of a particular database table
occurs, or whenever an UPDATE occurs on on one or
more specified columns of a table.

At this time SQLite supports only FOR EACH ROW


triggers, not FOR EACH STATEMENT triggers. Hence
explicitly specifying FOR EACH ROW is optional. FOR
EACH ROW implies that the SQL statements specified in
the trigger may be executed (depending on the WHEN
clause) for each database row being inserted, updated
or deleted by the statement causing the trigger to fire.

Both the WHEN clause and the trigger actions may


access elements of the row being inserted, deleted or
updated using references of the form "NEW.column-
name" and "OLD.column-name", where column-name is
the name of a column from the table that the trigger is
associated with. OLD and NEW references may only be
used in triggers on events for which they are relevant,
as follows:
INSERT NEW references are valid
UPDATE NEW and OLD references are valid
DELETE OLD references are valid

If a WHEN clause is supplied, the SQL statements


specified are only executed for rows for which the
WHEN clause is true. If no WHEN clause is supplied,
the SQL statements are executed for all rows.

The BEFORE or AFTER keyword determines when the


trigger actions will be executed relative to the
insertion, modification or removal of the associated
row.

An ON CONFLICT clause may be specified as part of an


UPDATE or INSERT action within the body of the trigger.
However if an ON CONFLICT clause is specified as part
of the statement causing the trigger to fire, then
conflict handling policy of the outer statement is used
instead.

Triggers are automatically dropped when the table that


they are associated with (the table-name table) is
dropped. However if the trigger actions reference other
tables, the trigger is not dropped or modified if those
other tables are dropped or modified.

Triggers are removed using the DROP TRIGGER


statement.

Syntax Restrictions On UPDATE, DELETE, and


INSERT Statements Within Triggers
The UPDATE, DELETE, and INSERT statements within
triggers do not support the full syntax for UPDATE,
DELETE, and INSERT statements. The following
restrictions apply:

The name of the table to be modified in an UPDATE,


DELETE, or INSERT statement must be an
unqualified table name. In other words, one must
use just "tablename" not "database.tablename"
when specifying the table. The table to be modified
must exist in the same database as the table or view
to which the trigger is attached.

The "INSERT INTO table DEFAULT VALUES" form of


the INSERT statement is not supported.

The INDEXED BY and NOT INDEXED clauses are not


supported for UPDATE and DELETE statements.

The ORDER BY and LIMIT clauses on UPDATE and


DELETE statements are not supported. ORDER BY
and LIMIT are not normally supported for UPDATE or
DELETE in any context but can be enabled for top-
level statements using the
SQLITE_ENABLE_UPDATE_DELETE_LIMIT compile-
time option. However, that compile-time option only
applies to top-level UPDATE and DELETE statements,
not UPDATE and DELETE statements within triggers.

Common table expression are not supported for


statements inside of triggers.
INSTEAD OF triggers

Triggers may be created on views, as well as ordinary


tables, by specifying INSTEAD OF in the CREATE
TRIGGER statement. If one or more ON INSERT, ON
DELETE or ON UPDATE triggers are defined on a view,
then it is not an error to execute an INSERT, DELETE or
UPDATE statement on the view, respectively. Instead,
executing an INSERT, DELETE or UPDATE on the view
causes the associated triggers to fire. The real tables
underlying the view are not modified (except possibly
explicitly, by a trigger program).

Note that the sqlite3_changes() and


sqlite3_total_changes() interfaces do not count
INSTEAD OF trigger firings, but the count_changes
pragma does count INSTEAD OF trigger firing.

Some Example Triggers

Assuming that customer records are stored in the


"customers" table, and that order records are stored in
the "orders" table, the following UPDATE trigger
ensures that all associated orders are redirected when
a customer changes his or her address:
CREATE TRIGGER update_customer_address UPDATE OF address
BEGIN
UPDATE orders SET address = new.address WHERE custom
END;

With this trigger installed, executing the statement:


UPDATE customers SET address = '1 Main St.' WHERE name =

causes the following to be automatically executed:


UPDATE orders SET address = '1 Main St.' WHERE customer_

For an example of an INSTEAD OF trigger, consider the


following schema:
CREATE TABLE customer(
cust_id INTEGER PRIMARY KEY,
cust_name TEXT,
cust_addr TEXT
);
CREATE VIEW customer_address AS
SELECT cust_id, cust_addr FROM customer;
CREATE TRIGGER cust_addr_chng
INSTEAD OF UPDATE OF cust_addr ON customer_address
BEGIN
UPDATE customer SET cust_addr=NEW.cust_addr
WHERE cust_id=NEW.cust_id;
END;

With the schema above, a statement of the form:


UPDATE customer_address SET cust_addr=$new_address WHERE

Causes the customer.cust_addr field to be updated for a


specific customer entry that has customer.cust_id equal
to the $cust_id parameter. Note how the values
assigned to the view are made available as field in the
special "NEW" table within the trigger body.

Cautions On The Use Of BEFORE triggers


If a BEFORE UPDATE or BEFORE DELETE trigger
modifies or deletes a row that was to have been
updated or deleted, then the result of the subsequent
update or delete operation is undefined. Furthermore, if
a BEFORE trigger modifies or deletes a row, then it is
undefined whether or not AFTER triggers that would
have otherwise run on those rows will in fact run.

The value of NEW.rowid is undefined in a BEFORE


INSERT trigger in which the rowid is not explicitly set
to an integer.

Because of the behaviors described above,


programmers are encouraged to prefer AFTER triggers
over BEFORE triggers.

The RAISE() function

A special SQL function RAISE() may be used within a


trigger-program, with the following syntax

raise-function:

When one of RAISE(ROLLBACK,...), RAISE(ABORT,...) or


RAISE(FAIL,...) is called during trigger-program
execution, the specified ON CONFLICT processing is
performed the current query terminates. An error code
of SQLITE_CONSTRAINT is returned to the application,
along with the specified error message.

When RAISE(IGNORE) is called, the remainder of the


current trigger program, the statement that caused the
trigger program to execute and any subsequent trigger
programs that would have been executed are
abandoned. No database changes are rolled back. If the
statement that caused the trigger program to execute is
itself part of a trigger program, then that trigger
program resumes execution at the beginning of the
next step.

TEMP Triggers on Non-TEMP Tables

A trigger normally exists in the same database as the


table named after the "ON" keyword in the CREATE
TRIGGER statement. Except, it is possible to create a
TEMP TRIGGER on a table in another database. Such a
trigger will only fire when changes are made to the
target table by the application that defined the trigger.
Other applications that modify the database will not be
able to see the TEMP trigger and hence cannot run the
trigger.

When defining a TEMP trigger on a non-TEMP table, it is


important to specify the database holding the non-
TEMP table. For example, in the following statement, it
is important to say "main.tab1" instead of just "tab1":
CREATE TEMP TRIGGER ex1 AFTER INSERT ON main.tab1 BEGIN
Failure to specify the schema name on the target table
could result in the TEMP trigger being reattached to a
table with the same name in another database
whenever any schema change occurs.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
CREATE VIEW

create-view-stmt: hide

select-stmt: show

The CREATE VIEW command assigns a name to a pre-


packaged SELECT statement. Once the view is created,
it can be used in the FROM clause of another SELECT in
place of a table name.

If the "TEMP" or "TEMPORARY" keyword occurs in


between "CREATE" and "VIEW" then the view that is
created is only visible to the database connection that
created it and is automatically deleted when the
database connection is closed.

If a schema-name is specified, then the view is


created in the specified database. It is an error to
specify both a schema-name and the TEMP keyword on
a VIEW, unless the schema-name is "temp". If no
schema name is specified, and the TEMP keyword is not
present, the VIEW is created in the main database.
You cannot DELETE, INSERT, or UPDATE a view. Views
are read-only in SQLite. However, in many cases you
can use an INSTEAD OF trigger on the view to
accomplish the same thing. Views are removed with
the DROP VIEW command.

If a column-name list follows the view-name , then


that list determines the names of the columns for the
view. If the column-name list is omitted, then the
names of the columns in the view are derived from the
names of the result-set columns in the select-stmt.
Note that the column-name list syntax is only
supported in SQLite versions 3.9.0 (2015-10-14) and
later.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
CREATE VIRTUAL TABLE

create-virtual-table-stmt: hide

A virtual table is an interface to an external storage or


computation engine that appears to be a table but does
not actually store information in the database file.

In general, you can do anything with a virtual table


that can be done with an ordinary table, except that
you cannot create indices or triggers on a virtual table.
Some virtual table implementations might impose
additional restrictions. For example, many virtual
tables are read-only.

The module-name is the name of an object that


implements the virtual table. The module-name must
be registered with the SQLite database connection
using sqlite3_create_module() or
sqlite3_create_module_v2() prior to issuing the
CREATE VIRTUAL TABLE statement. The module takes
zero or more comma-separated arguments. The
arguments can be just about any text as long as it has
balanced parentheses. The argument syntax is
sufficiently general that the arguments can be made to
appear as column definitions in a traditional CREATE
TABLE statement. SQLite passes the module arguments
directly to the xCreate and xConnect methods of the
module implementation without any interpretation. It is
the responsibility of the module implementation to
parse and interpret its own arguments.

A virtual table is destroyed using the ordinary DROP


TABLE statement. There is no DROP VIRTUAL TABLE
statement.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
Date And Time Functions
SQLite supports five date and time functions as follows:

1. date(timestring, modifier, modifier, ...)


2. time(timestring, modifier, modifier, ...)
3. datetime(timestring, modifier, modifier, ...)
4. julianday(timestring, modifier, modifier, ...)
5. strftime(format, timestring, modifier, modifier, ...)

All five date and time functions take a time string as an


argument. The time string is followed by zero or more
modifiers. The strftime() function also takes a format
string as its first argument.

The date and time functions use a subset of IS0-8601


date and time formats. The date() function returns the
date in this format: YYYY-MM-DD. The time() function
returns the time as HH:MM:SS. The datetime() function
returns "YYYY-MM-DD HH:MM:SS". The julianday()
function returns the Julian day - the number of days
since noon in Greenwich on November 24, 4714 B.C.
(Proleptic Gregorian calendar). The strftime() routine
returns the date formatted according to the format
string specified as the first argument. The format string
supports the most common substitutions found in the
strftime() function from the standard C library plus two
new substitutions, %f and %J. The following is a
complete list of valid strftime() substitutions:

%d day of month: 00
%f fractional seconds: SS.SSS
%H hour: 00-24
%j day of year: 001-366
%J Julian day number
%m month: 01-12
%M minute: 00-59
%s seconds since 1970-01-01
%S seconds: 00-59
%w day of week 0-6 with Sunday==0
%W week of year: 00-53
%Y year: 0000-9999
%% %

Notice that all other date and time functions can be


expressed in terms of strftime():

Function Equivalent strftime()


date(...) strftime('%Y-%m-%d', ...)
time(...) strftime('%H:%M:%S', ...)
datetime(...) strftime('%Y-%m-%d %H:%M:%S', ...)
julianday(...) strftime('%J', ...)

The only reasons for providing functions other than


strftime() is for convenience and for efficiency.

Time Strings

A time string can be in any of the following formats:

1. YYYY-MM-DD
2. YYYY-MM-DD HH:MM
3. YYYY-MM-DD HH:MM:SS
4. YYYY-MM-DD HH:MM:SS.SSS
5. YYYY-MM-DDTHH:MM
6. YYYY-MM-DDTHH:MM:SS
7. YYYY-MM-DDTHH:MM:SS.SSS
8. HH:MM
9. HH:MM:SS
0. HH:MM:SS.SSS
1. now
2. DDDDDDDDDD

In formats 5 through 7, the "T" is a literal character


separating the date and the time, as required by ISO-
8601. Formats 8 through 10 that specify only a time
assume a date of 2000-01-01. Format 11, the string
'now', is converted into the current date and time as
obtained from the xCurrentTime method of the
sqlite3_vfs object in use. The 'now' argument to date
and time functions always returns exactly the same
value for multiple invocations within the same
sqlite3_step() call. Universal Coordinated Time (UTC)
is used. Format 12 is the Julian day number expressed
as a floating point value.

Formats 2 through 10 may be optionally followed by a


timezone indicator of the form "[+-]HH:MM" or just
"Z". The date and time functions use UTC or "zulu" time
internally, and so the "Z" suffix is a no-op. Any non-
zero "HH:MM" suffix is subtracted from the indicated
date and time in order to compute zulu time. For
example, all of the following time strings are
equivalent:

2013-10-07 08:23:19.120
2013-10-07T08:23:19.120Z
2013-10-07 04:23:19.120-04:00
2456572.84952685

In formats 4, 7, and 10, the fractional seconds value


SS.SSS can have one or more digits following the
decimal point. Exactly three digits are shown in the
examples because only the first three digits are
significant to the result, but the input string can have
fewer or more than three digits and the date/time
functions will still operate correctly. Similarly, format
12 is shown with 10 significant digits, but the
date/time functions will really accept as many or as
few digits as are necessary to represent the Julian day
number.

Modifiers

The time string can be followed by zero or more


modifiers that alter date and/or time. Each modifier is a
transformation that is applied to the time value to its
left. Modifiers are applied from left to right; order is
important. The available modifiers are as follows.

1. NNN days
2. NNN hours
3. NNN minutes
4. NNN.NNNN seconds
5. NNN months
6. NNN years
7. start of month
8. start of year
9. start of day
0. weekday N
1. unixepoch
2. localtime
3. utc

The first six modifiers (1 through 6) simply add the


specified amount of time to the date and time specified
by the preceding timestring and modifiers. The 's'
character at the end of the modifier names is optional.
Note that "NNN months" works by rendering the
original date into the YYYY-MM-DD format, adding the
NNN to the MM month value, then normalizing the
result. Thus, for example, the data 2001-03-31
modified by '+1 month' initially yields 2001-04-31, but
April only has 30 days so the date is normalized to
2001-05-01. A similar effect occurs when the original
date is February 29 of a leapyear and the modifier is
N years where N is not a multiple of four.

The "start of" modifiers (7 through 9) shift the date


backwards to the beginning of the current month, year
or day.

The "weekday" modifier advances the date forward to


the next date where the weekday number is N. Sunday
is 0, Monday is 1, and so forth.

The "unixepoch" modifier (11) only works if it


immediately follows a timestring in the DDDDDDDDDD
format. This modifier causes the DDDDDDDDDD to be
interpreted not as a Julian day number as it normally
would be, but as Unix Time - the number of seconds
since 1970. If the "unixepoch" modifier does not follow
a timestring of the form DDDDDDDDDD which
expresses the number of seconds since 1970 or if other
modifiers separate the "unixepoch" modifier from prior
DDDDDDDDDD then the behavior is undefined. Due to
precision limitations imposed by the implementations
use of 64-bit integers, the "unixepoch" modifier only
works for dates between 0000-01-01 00:00:00 and
5352-11-01 10:52:47 (unix times of -62167219200
through 106751991167).

The "localtime" modifier (12) assumes the time string


to its left is in Universal Coordinated Time (UTC) and
adjusts the time string so that it displays localtime. If
"localtime" follows a time that is not UTC, then the
behavior is undefined. The "utc" modifier is the
opposite of "localtime". "utc" assumes that the string to
its left is in the local timezone and adjusts that string
to be in UTC. If the prior string is not in localtime, then
the result of "utc" is undefined.

Examples

Compute the current date.

SELECT date('now');

Compute the last day of the current month.


SELECT date('now','start of month','+1 month','-1
day');

Compute the date and time given a unix timestamp


1092941466.

SELECT datetime(1092941466, 'unixepoch');

Compute the date and time given a unix timestamp


1092941466, and compensate for your local timezone.

SELECT datetime(1092941466, 'unixepoch',


'localtime');

Compute the current unix timestamp.

SELECT strftime('%s','now');

Compute the number of days since the signing of the


US Declaration of Independence.

SELECT julianday('now') - julianday('1776-07-04');

Compute the number of seconds since a particular


moment in 2004:

SELECT strftime('%s','now') - strftime('%s','2004-


01-01 02:34:56');

Compute the date of the first Tuesday in October for the


current year.
SELECT date('now','start of year','+9
months','weekday 2');

Compute the time since the unix epoch in seconds (like


strftime('%s','now') except includes fractional part):

SELECT (julianday('now') - 2440587.5)*86400.0;

Caveats And Bugs

The computation of local time depends heavily on the


whim of politicians and is thus difficult to get correct
for all locales. In this implementation, the standard C
library function localtime_r() is used to assist in the
calculation of local time. The localtime_r() C function
normally only works for years between 1970 and 2037.
For dates outside this range, SQLite attempts to map
the year into an equivalent year within this range, do
the calculation, then map the year back.

These functions only work for dates between 0000-01-


01 00:00:00 and 9999-12-31 23:59:59 (julidan day
numbers 1721059.5 through 5373484.5). For dates
outside that range, the results of these functions are
undefined.

Non-Vista Windows platforms only support one set of


DST rules. Vista only supports two. Therefore, on these
platforms, historical DST calculations will be incorrect.
For example, in the US, in 2007 the DST rules changed.
Non-Vista Windows platforms apply the new 2007 DST
rules to all previous years as well. Vista does
somewhat better getting results correct back to 1986,
when the rules were also changed.

All internal computations assume the Gregorian


calendar system. It is also assumed that every day is
exactly 86400 seconds in duration.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
DELETE

delete-stmt: hide

expr: show

qualified-table-name: show

with-clause: show

The DELETE command removes records from the table


identified by the qualified-table-name.

If the WHERE clause is not present, all records in the


table are deleted. If a WHERE clause is supplied, then
only those rows for which the WHERE clause boolean
expression is true are deleted. Rows for which the
expression is false or NULL are retained.

Restrictions on DELETE Statements Within


CREATE TRIGGER

The following restrictions apply to DELETE statements


that occur within the body of a CREATE TRIGGER
statement:
The table-name specified as part of a DELETE
statement within a trigger body must be unqualified.
In other words, the schema-name. prefix on the
table name is not allowed within triggers. If the
table to which the trigger is attached is not in the
temp database, then DELETE statements within the
trigger body must operate on tables within the same
database as it. If the table to which the trigger is
attached is in the TEMP database, then the
unqualified name of the table being deleted is
resolved in the same way as it is for a top-level
statement (by searching first the TEMP database,
then the main database, then any other databases in
the order they were attached).

The INDEXED BY and NOT INDEXED clauses are not


allowed on DELETE statements within triggers.

The LIMIT and ORDER BY clauses (described below)


are unsupported for DELETE statements within
triggers.

Optional LIMIT and ORDER BY clauses

If SQLite is compiled with the


SQLITE_ENABLE_UPDATE_DELETE_LIMIT compile-time
option, then the syntax of the DELETE statement is
extended by the addition of optional ORDER BY and
LIMIT clauses:

delete-stmt-limited:
If a DELETE statement has a LIMIT clause, the
maximum number of rows that will be deleted is found
by evaluating the accompanying expression and casting
it to an integer value. If the result of the evaluating the
LIMIT clause cannot be losslessly converted to an
integer value, it is an error. A negative LIMIT value is
interpreted as "no limit". If the DELETE statement also
has an OFFSET clause, then it is similarly evaluated
and cast to an integer value. Again, it is an error if the
value cannot be losslessly converted to an integer. If
there is no OFFSET clause, or the calculated integer
value is negative, the effective OFFSET value is zero.

If the DELETE statement has an ORDER BY clause, then


all rows that would be deleted in the absence of the
LIMIT clause are sorted according to the ORDER BY. The
first M rows, where M is the value found by evaluating
the OFFSET clause expression, are skipped, and the
following N, where N is the value of the LIMIT
expression, are deleted. If there are less than N rows
remaining after taking the OFFSET clause into account,
or if the LIMIT clause evaluated to a negative value,
then all remaining rows are deleted.

If the DELETE statement has no ORDER BY clause, then


all rows that would be deleted in the absence of the
LIMIT clause are assembled in an arbitrary order before
applying the LIMIT and OFFSET clauses to determine
the subset that are actually deleted.

The ORDER BY clause on a DELETE statement is used


only to determine which rows fall within the LIMIT. The
order in which rows are deleted is arbitrary and is not
influenced by the ORDER BY clause.

The Truncate Optimization

When the WHERE is omitted from a DELETE statement


and the table being deleted has no triggers, SQLite
uses an optimization to erase the entire table content
without having to visit each row of the table
individually. This "truncate" optimization makes the
delete run much faster. Prior to SQLite version 3.6.5
(2008-11-12), the truncate optimization also meant
that the sqlite3_changes() and sqlite3_total_changes()
interfaces and the count_changes pragma will not
actually return the number of deleted rows. That
problem has been fixed as of version 3.6.5 (2008-11-
12).

The truncate optimization can be permanently disabled


for all queries by recompiling SQLite with the
SQLITE_OMIT_TRUNCATE_OPTIMIZATION compile-time
switch.

The truncate optimization can also be disabled at


runtime using the sqlite3_set_authorizer() interface. If
an authorizer callback returns SQLITE_IGNORE for an
SQLITE_DELETE action code, then the DELETE
operation will proceed but the truncate optimization
will be bypassed and rows will be deleted one by one.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
DETACH DATABASE

detach-stmt: hide

This statement detaches an additional database


connection previously attached using the ATTACH
statement. When not in shared cache mode, it is
possible to have the same database file attached
multiple times using different names, and detaching
one connection to a file will leave the others intact.

In shared cache mode, attempting to attach the same


database file more than once results in an error.

This statement will fail if SQLite is in the middle of a


transaction.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
DROP INDEX

drop-index-stmt: hide

The DROP INDEX statement removes an index added


with the CREATE INDEX statement. The index is
completely removed from the disk. The only way to
recover the index is to reenter the appropriate CREATE
INDEX command.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
DROP TABLE

drop-table-stmt: hide

The DROP TABLE statement removes a table added with


the CREATE TABLE statement. The name specified is the
table name. The dropped table is completely removed
from the database schema and the disk file. The table
can not be recovered. All indices and triggers
associated with the table are also deleted.

The optional IF EXISTS clause suppresses the error that


would normally result if the table does not exist.

If foreign key constraints are enabled, a DROP TABLE


command performs an implicit DELETE FROM command
before removing the table from the database schema.
Any triggers attached to the table are dropped from the
database schema before the implicit DELETE FROM is
executed, so this cannot cause any triggers to fire. By
contrast, an implicit DELETE FROM does cause any
configured foreign key actions to take place. If the
implicit DELETE FROM executed as part of a DROP
TABLE command violates any immediate foreign key
constraints, an error is returned and the table is not
dropped. If the implicit DELETE FROM causes any
deferred foreign key constraints to be violated, and the
violations still exist when the transaction is committed,
an error is returned at the time of commit.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
DROP TRIGGER

drop-trigger-stmt: hide

The DROP TRIGGER statement removes a trigger


created by the CREATE TRIGGER statement. Once
removed, the trigger definition is no longer present in
the sqlite_master (or sqlite_temp_master) table and is
not fired by any subsequent INSERT, UPDATE or DELETE
statements.

Note that triggers are automatically dropped when the


associated table is dropped.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
DROP VIEW

drop-view-stmt: hide

The DROP VIEW statement removes a view created by


the CREATE VIEW statement. The view definition is
removed from the database schema, but no actual data
in the underlying base tables is modified.

The view to drop is identified by the view-name and


optional schema-name specified as part of the DROP
VIEW statement. This reference is resolved using the
standard procedure for object resolution.

If the specified view cannot be found and the IF EXISTS


clause is not present, it is an error. If the specified view
cannot be found and an IF EXISTS clause is present in
the DROP VIEW statement, then the statement is a no-
op.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
EXPLAIN
sql-stmt:

An SQL statement can be preceded by the keyword


"EXPLAIN" or by the phrase "EXPLAIN QUERY PLAN".
Either modification causes the SQL statement to
behave as a query and to return information about how
the SQL statement would have operated if the EXPLAIN
keyword or phrase had been omitted.

The output from EXPLAIN and EXPLAIN QUERY PLAN is


intended for interactive analysis and troubleshooting
only. The details of the output format are subject to
change from one release of SQLite to the next.
Applications should not use EXPLAIN or EXPLAIN
QUERY PLAN since their exact behavior is variable and
only partially documented.

When the EXPLAIN keyword appears by itself it causes


the statement to behave as a query that returns the
sequence of virtual machine instructions it would have
used to execute the command had the EXPLAIN
keyword not been present. When the EXPLAIN QUERY
PLAN phrase appears, the statement returns high-level
information regarding the query plan that would have
been used. The EXPLAIN QUERY PLAN command is
described in more detail here.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
expression

expr: hide
literal-value: show

raise-function: show

select-stmt: show

type-name: show

This section is different from the others. Most other


sections of this document talks about a particular SQL
command. This section does not talk about a
standalone command but about "expressions" which
are subcomponents of most other commands.

Operators

SQLite understands the following binary operators, in


order from highest to lowest precedence:
||
* / %
+ -
<< >> & |
< <= > >=
= == != <> IS IS NOT IN LIKE GLOB MAT
AND
OR

Supported unary prefix operators are these:


- + ~ NOT
The COLLATE operator is a unary postfix operator that
assigns a collating sequence to an expression. The
COLLATE operator has a higher precedence (binds more
tightly) than any binary operator and any unary prefix
operator except "~". (COLLATE and "~" are associative
so their binding order does not matter.) The collating
sequence set by the COLLATE operator overrides the
collating sequence determined by the COLLATE clause
in a table column definition. See the detailed
discussion on collating sequences in the Datatype In
SQLite3 document for additional information.

The unary operator + is a no-op. It can be applied to


strings, numbers, blobs or NULL and it always returns a
result with the same value as the operand.

Note that there are two variations of the equals and not
equals operators. Equals can be either = or ==. The
non-equals operator can be either != or <>. The ||
operator is "concatenate" - it joins together the two
strings of its operands. The operator % outputs the
value of its left operand modulo its right operand.

The result of any binary operator is either a numeric


value or NULL, except for the || concatenation operator
which always evaluates to either NULL or a text value.

The IS and IS NOT operators work like = and != except


when one or both of the operands are NULL. In this
case, if both operands are NULL, then the IS operator
evaluates to 1 (true) and the IS NOT operator evaluates
to 0 (false). If one operand is NULL and the other is
not, then the IS operator evaluates to 0 (false) and the
IS NOT operator is 1 (true). It is not possible for an IS
or IS NOT expression to evaluate to NULL. Operators IS
and IS NOT have the same precedence as =.

Literal Values (Constants)

A literal value represents a constant. Literal values may


be integers, floating point numbers, strings, BLOBs, or
NULLs.

The syntax for integer and floating point literals


(collectively "numeric literals") is shown by the
following diagram:

numeric-literal:

If a numeric literal has a decimal point or an


exponentiation clause or if its magnitude is less than
-9223372036854775808 or greater than
9223372036854775807, then it is a floating point
literal. Otherwise is it is an integer literal. The "E"
character that begins the exponentiation clause of a
floating point literal can be either upper or lower case.
The "." character is always used as the decimal point
even if the locale setting specifies "," for this role - the
use of "," for the decimal point would result in syntactic
ambiguity.

Hexadecimal integer literals follow the C-language


notation of "0x" or "0X" followed by hexadecimal digits.
For example, 0x1234 means the same as 4660 and
0x8000000000000000 means the same as
-9223372036854775808. Hexadecimal integer literals
are interpreted as 64-bit two's-complement integers
and are thus limited to sixteen significant digits of
precision. Support for hexadecimal integers was added
to SQLite version 3.8.6 (2014-08-15). For backwards
compatibility, the "0x" hexadecimal integer notation is
only understood by the SQL language parser, not by the
type conversions routines. String variables that contain
text formatted like hexadecimal integers are not
interpreted as hexadecimal integers when coercing the
string value into an integer due to a CAST expression
or for a column affinity transformation or prior to
performing a numeric operation or for any other run-
time conversions. When coercing a string value in the
format of a hexadecimal integer into an integer value,
the conversion process stops when the 'x' character is
seen so the resulting integer value is always zero.
SQLite only understands the hexadecimal integer
notation when it appears in the SQL statement text, not
when it appears as part of the content of the database.

A string constant is formed by enclosing the string in


single quotes ('). A single quote within the string can
be encoded by putting two single quotes in a row - as
in Pascal. C-style escapes using the backslash
character are not supported because they are not
standard SQL.

BLOB literals are string literals containing hexadecimal


data and preceded by a single "x" or "X" character.
Example: X'53514C697465'

A literal value can also be the token "NULL".

Parameters

A "variable" or "parameter" token specifies a


placeholder in the expression for a value that is filled
in at runtime using the sqlite3_bind() family of C/C++
interfaces. Parameters can take several forms:

A question mark followed by a number NNN holds a spot for


?NNN the NNN-th parameter. NNN must be between 1 and
SQLITE_MAX_VARIABLE_NUMBER.
A question mark that is not followed by a number creates a
parameter with a number one greater than the largest
parameter number already assigned. If this means the
parameter number is greater than
SQLITE_MAX_VARIABLE_NUMBER, it is an error. This
?
parameter format is provided for compatibility with other
database engines. But because it is easy to miscount the
question marks, the use of this parameter format is
discouraged. Programmers are encouraged to use one of the
symbolic formats below or the ?NNN format above instead.
A colon followed by an identifier name holds a spot for a
named parameter with the name :AAAA. Named parameters
are also numbered. The number assigned is one greater than
the largest parameter number already assigned. If this means
:AAAA
the parameter would be assigned a number greater than
SQLITE_MAX_VARIABLE_NUMBER, it is an error. To avoid
confusion, it is best to avoid mixing named and numbered
parameters.
An "at" sign works exactly like a colon, except that the name
@AAAA
of the parameter created is @AAAA.
A dollar-sign followed by an identifier name also holds a spot
for a named parameter with the name $AAAA. The identifier
name in this case can include one or more occurrences of "::"
and a suffix enclosed in "(...)" containing any text at all. This
$AAAA
syntax is the form of a variable name in the Tcl programming
language. The presence of this syntax results from the fact
that SQLite is really a Tcl extension that has escaped into the
wild.

Parameters that are not assigned values using


sqlite3_bind() are treated as NULL. The
sqlite3_bind_parameter_index() interface can be used
to translate a symbolic parameter name into its
equivalent numeric index.

The maximum parameter number is set at compile-time


by the SQLITE_MAX_VARIABLE_NUMBER macro. An
individual database connection D can reduce its
maximum parameter number below the compile-time
maximum using the sqlite3_limit(D,
SQLITE_LIMIT_VARIABLE_NUMBER,...) interface.

The LIKE, GLOB, REGEXP, and MATCH operators

The LIKE operator does a pattern matching comparison.


The operand to the right of the LIKE operator contains
the pattern and the left hand operand contains the
string to match against the pattern. A percent symbol
("%") in the LIKE pattern matches any sequence of
zero or more characters in the string. An underscore
("_") in the LIKE pattern matches any single character
in the string. Any other character matches itself or its
lower/upper case equivalent (i.e. case-insensitive
matching). Important Note: SQLite only understands
upper/lower case for ASCII characters by default. The
LIKE operator is case sensitive by default for unicode
characters that are beyond the ASCII range. For
example, the expression 'a' LIKE 'A' is TRUE but
'' LIKE '' is FALSE. The ICU extension to SQLite
includes an enhanced version of the LIKE operator that
does case folding across all unicode characters.

If the optional ESCAPE clause is present, then the


expression following the ESCAPE keyword must
evaluate to a string consisting of a single character.
This character may be used in the LIKE pattern to
include literal percent or underscore characters. The
escape character followed by a percent symbol (%),
underscore (_), or a second instance of the escape
character itself matches a literal percent symbol,
underscore, or a single escape character, respectively.

The infix LIKE operator is implemented by calling the


application-defined SQL functions like(Y,X) or
like(Y,X,Z).

The LIKE operator can be made case sensitive using


the case_sensitive_like pragma.
The GLOB operator is similar to LIKE but uses the Unix
file globbing syntax for its wildcards. Also, GLOB is
case sensitive, unlike LIKE. Both GLOB and LIKE may
be preceded by the NOT keyword to invert the sense of
the test. The infix GLOB operator is implemented by
calling the function glob(Y,X) and can be modified by
overriding that function.

The REGEXP operator is a special syntax for the


regexp() user function. No regexp() user function is
defined by default and so use of the REGEXP operator
will normally result in an error message. If an
application-defined SQL function named "regexp" is
added at run-time, then the "X REGEXP Y" operator will
be implemented as a call to "regexp(Y,X)".

The MATCH operator is a special syntax for the match()


application-defined function. The default match()
function implementation raises an exception and is not
really useful for anything. But extensions can override
the match() function with more helpful logic.

The BETWEEN operator

The BETWEEN operator is logically equivalent to a pair


of comparisons. "x BETWEEN y AND z" is equivalent
to "x>=y AND x<=z" except that with BETWEEN, the x
expression is only evaluated once. The precedence of
the BETWEEN operator is the same as the precedence
as operators == and != and LIKE and groups left to
right.
The CASE expression

A CASE expression serves a role similar to IF-THEN-


ELSE in other programming languages.

The optional expression that occurs in between the


CASE keyword and the first WHEN keyword is called the
"base" expression. There are two basic forms of the
CASE expression: those with a base expression and
those without.

In a CASE without a base expression, each WHEN


expression is evaluated and the result treated as a
boolean, starting with the leftmost and continuing to
the right. The result of the CASE expression is the
evaluation of the THEN expression that corresponds to
the first WHEN expression that evaluates to true. Or, if
none of the WHEN expressions evaluate to true, the
result of evaluating the ELSE expression, if any. If
there is no ELSE expression and none of the WHEN
expressions are true, then the overall result is NULL.

A NULL result is considered untrue when evaluating


WHEN terms.

In a CASE with a base expression, the base expression


is evaluated just once and the result is compared
against the evaluation of each WHEN expression from
left to right. The result of the CASE expression is the
evaluation of the THEN expression that corresponds to
the first WHEN expression for which the comparison is
true. Or, if none of the WHEN expressions evaluate to a
value equal to the base expression, the result of
evaluating the ELSE expression, if any. If there is no
ELSE expression and none of the WHEN expressions
produce a result equal to the base expression, the
overall result is NULL.

When comparing a base expression against a WHEN


expression, the same collating sequence, affinity, and
NULL-handling rules apply as if the base expression
and WHEN expression are respectively the left- and
right-hand operands of an = operator.

If the base expression is NULL then the result of the


CASE is always the result of evaluating the ELSE
expression if it exists, or NULL if it does not.

Both forms of the CASE expression use lazy, or short-


circuit, evaluation.

The only difference between the following two CASE


expressions is that the x expression is evaluated
exactly once in the first example but might be
evaluated multiple times in the second:

CASE x WHEN w1 THEN r1 WHEN w2 THEN r2 ELSE


r3 END
CASE WHEN x=w1 THEN r1 WHEN x=w2 THEN r2
ELSE r3 END

The IN and NOT IN operators


The IN and NOT IN operators take a single scalar
operand on the left and a vector operand on the right
formed by an explicit list of zero or more scalars or by
a single subquery. When the right operand of an IN or
NOT IN operator is a subquery, the subquery must have
a single result column. The "subquery" on the right-
hand side of an IN operator can be a table name or
table-valued function name in which case the subquery
is understood to be "(SELECT * FROM name)". When
the right operand is an empty set, the result of IN is
false and the result of NOT IN is true, regardless of the
left operand and even if the left operand is NULL.

The result of an IN or NOT IN operator is determined by


the following matrix:

Right Right Left operand Result


Left Result of
operand operand found of
operand NOT IN
contains is an within right IN
is NULL operator
NULL empty set operand operator
no no no no false true
does not
no yes no false true
matter
does not
no no yes true false
matter
no yes no no NULL NULL
does not
yes no does not matter NULL NULL
matter

Note that SQLite allows the parenthesized list of scalar


values on the right-hand side of an IN or NOT IN
operator to be an empty list but most other SQL
database database engines and the SQL92 standard
require the list to contain at least one element.

The EXISTS operator

The EXISTS operator always evaluates to one of the


integer values 0 and 1. If executing the SELECT
statement specified as the right-hand operand of the
EXISTS operator would return one or more rows, then
the EXISTS operator evaluates to 1. If executing the
SELECT would return no rows at all, then the EXISTS
operator evaluates to 0.

The number of columns in each row returned by the


SELECT statement (if any) and the specific values
returned have no effect on the results of the EXISTS
operator. In particular, rows containing NULL values are
not handled any differently from rows without NULL
values.

Scalar Subqueries

A SELECT statement enclosed in parentheses may


appear as a scalar quantity. A SELECT used as a scalar
quantity must return a result set with a single column.
The result of the expression is the value of the only
column in the first row returned by the SELECT
statement. If the SELECT yields more than one result
row, all rows after the first are ignored. If the SELECT
yields no rows, then the value of the expression is
NULL. The LIMIT of a scalar subquery is always 1. Any
other LIMIT value given in the SQL text is ignored.
All types of SELECT statement, including aggregate and
compound SELECT queries (queries with keywords like
UNION or EXCEPT) are allowed as scalar subqueries.

Table Column Names

A column name can be any of the names defined in the


CREATE TABLE statement or one of the following special
identifiers: "ROWID", "OID", or "_ROWID_". The
three special identifiers describe the unique integer key
(the rowid) associated with every row of every table
and so are not available on WITHOUT ROWID tables.
The special identifiers only refer to the row key if the
CREATE TABLE statement does not define a real column
with the same name. The rowid can be used anywhere
a regular column can be used.

Correlated Subqueries

A SELECT statement used as either a scalar subquery


or as the right-hand operand of an IN, NOT IN or
EXISTS expression may contain references to columns
in the outer query. Such a subquery is known as a
correlated subquery. A correlated subquery is
reevaluated each time its result is required. An
uncorrelated subquery is evaluated only once and the
result reused as necessary.

CAST expressions

A CAST expression of the form "CAST(expr AS type-


name)" is used to convert the value of expr to a
different storage class specified by type-name . A CAST
conversion is similar to the conversion that takes place
when a column affinity is applied to a value except that
with the CAST operator the conversion always takes
place even if the conversion lossy and irreversible,
whereas column affinity only changes the data type of
a value if the change is lossless and reversible.

If the value of expr is NULL, then the result of the


CAST expression is also NULL. Otherwise, the storage
class of the result is determined by applying the rules
for determining column affinity to the type-name .
Affinity
of type- Conversion Processing
name
Casting a value to a type-name with no affinity causes the value to
be converted into a BLOB. Casting to a BLOB consists of first
NONE casting the value to TEXT in the encoding of the database
connection, then interpreting the resulting byte sequence as a
BLOB instead of as TEXT.
To cast a BLOB value to TEXT, the sequence of bytes that make up
the BLOB is interpreted as text encoded using the database
encoding.
TEXT
Casting an INTEGER or REAL value into TEXT renders the value as
if via sqlite3_snprintf() except that the resulting TEXT uses the
encoding of the database connection.

When casting a BLOB value to a REAL, the value is first converted


to TEXT.

When casting a TEXT value to REAL, the longest possible prefix of


the value that can be interpreted as a real number is extracted
REAL from the TEXT value and the remainder ignored. Any leading spaces
in the TEXT value are ignored when converging from TEXT to REAL.
If there is no prefix that can be interpreted as a real number, the
result of the conversion is 0.0.
When casting a BLOB value to INTEGER, the value is first converted
to TEXT.

When casting a TEXT value to INTEGER, the longest possible prefix


of the value that can be interpreted as an integer number is
extracted from the TEXT value and the remainder ignored. Any
leading spaces in the TEXT value when converting from TEXT to
INTEGER are ignored. If there is no prefix that can be interpreted
as an integer number, the result of the conversion is 0. The CAST
operator understands decimal integers only conversion of
hexadecimal integers stops at the "x" in the "0x" prefix of the
hexadecimal integer string and thus result of the CAST is always
zero.
INTEGER
A cast of a REAL value into an INTEGER results in the integer
between the REAL value and zero that is closest to the REAL value.
If a REAL is greater than the greatest possible signed integer
(+9223372036854775807) then the result is the greatest possible
signed integer and if the REAL is less than the least possible signed
integer (-9223372036854775808) then the result is the least
possible signed integer.

Prior to SQLite version 3.8.2 (2013-12-06), casting a REAL value


greater than +9223372036854775807.0 into an integer resulted in
the most negative integer, -9223372036854775808. This behavior
was meant to emulate the behavior of x86/x64 hardware when
doing the equivalent cast.

Casting a TEXT or BLOB value into NUMERIC first does a forced


conversion into REAL but then further converts the result into
INTEGER if and only if the conversion from REAL to INTEGER is
lossless and reversible. This is the only context in SQLite where the
NUMERIC NUMERIC and INTEGER affinities behave differently.

Casting a REAL or INTEGER value to NUMERIC is a no-op, even if a


real value could be losslessly converted to an integer.

Note that the result from casting any non-BLOB value


into a BLOB and the result from casting any BLOB value
into a non-BLOB value may be different depending on
whether the database encoding is UTF-8, UTF-16be, or
UTF-16le.

Boolean Expressions

The SQL language features several contexts where an


expression is evaluated and the result converted to a
boolean (true or false) value. These contexts are:

the WHERE clause of a SELECT, UPDATE or DELETE


statement,
the ON or USING clause of a join in a SELECT
statement,
the HAVING clause of a SELECT statement,
the WHEN clause of an SQL trigger, and
the WHEN clause or clauses of some CASE
expressions.

To convert the results of an SQL expression to a


boolean value, SQLite first casts the result to a
NUMERIC value in the same way as a CAST expression.
A numeric zero value (integer value 0 or real value 0.0)
is considered to be false. A NULL value is still NULL. All
other values are considered true.

For example, the values NULL, 0.0, 0, 'english' and '0'


are all considered to be false. Values 1, 1.0, 0.1, -0.1
and '1english' are considered to be true.

Functions
SQLite supports many simple and aggregate SQL
functions. For presentation purposes, simple functions
are further subdivided into core functions and date-
time functions. Applications can add new functions,
written in C/C++, using the sqlite3_create_function()
interface.

It is possible to have an aggregate function with the


same name as a simple function, as long as the
number of arguments for the two forms of the function
are different. For example, the max() function with a
single argument is an aggregate and the max()
function with two or more arguments is a simple
function.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
INDEXED BY
The INDEXED BY phrase forces the SQLite query
planner to use a particular named index on a DELETE,
SELECT, or UPDATE statement. The INDEXED BY phrase
is an SQLite extension and is not portable to other SQL
database engines.

qualified-table-name: hide

The "INDEXED BY index-name " phrase specifies that


the named index must be used in order to look up
values on the preceding table. If index-name does not
exist or cannot be used for the query, then the
preparation of the SQL statement fails. The "NOT
INDEXED" clause specifies that no index shall be used
when accessing the preceding table, including implied
indices create by UNIQUE and PRIMARY KEY
constraints. However, the rowid can still be used to look
up entries even when "NOT INDEXED" is specified.

Some SQL database engines provide non-standard


"hint" mechanisms which can be used to give the query
optimizer clues about what indices it should use for a
particular statement. The INDEX BY clause of SQLite is
not a hinting mechanism and it should not be used as
such. The INDEXED BY clause does not give the
optimizer hints about which index to use; it gives the
optimizer a requirement of which index to use. If the
query optimizer is unable to use the index specified by
the INDEX BY clause, then the query will fail with an
error.

The INDEXED BY clause is not intended for use in


tuning the performance of a query. The intent of the
INDEXED BY clause is to raise a run-time error if a
schema change, such as dropping or creating an index,
causes the query plan for a time-sensitive query to
change. The INDEXED BY clause is designed to help
detect undesirable query plan changes during
regression testing. Application developers are
admonished to omit all use of INDEXED BY during
application design, implementation, testing, and
tuning. If INDEXED BY is to be used at all, it should be
inserted at the very end of the development process
when "locking down" a design.

See Also:

1. The query planner checklist describes steps that


application developers should following to help
resolve query planner problems. Notice the that the
use of INDEXED BY is a last resort, to be used only
when all other measures fail.

2. The unary "+" operator can be used to disqualify


terms in the WHERE clause from use by indices.
Careful use of unary + can sometimes help prevent
the query planner from choosing a poor index
without restricting it to using one specific index.
Careful placement of unary + operators is a better
method for controlling which indices are used by a
query.

3. The sqlite3_stmt_status() C/C++ interface together


with the SQLITE_STMTSTATUS_FULLSCAN_STEP and
SQLITE_STMTSTATUS_SORT verbs can be used to
detect at run-time when an SQL statement is not
making effective use of indices. Many applications
may prefer to use the sqlite3_stmt_status()
interface to detect index misuse rather than the
INDEXED BY phrase described here.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
INSERT

insert-stmt: hide

expr: show

select-stmt: show

with-clause: show

The INSERT statement comes in three basic forms.

The first form (with the "VALUES" keyword) creates


one or more new rows in an existing table. If the
column-name list after table-name is omitted then
the number of values inserted into each row must be
the same as the number of columns in the table. In
this case the result of evaluating the left-most
expression from each term of the VALUES list is
inserted into the left-most column of each new row,
and so forth for each subsequent expression. If a
column-name list is specified, then the number of
values in each term of the VALUE list must match
the number of specified columns. Each of the named
columns of the new row is populated with the results
of evaluating the corresponding VALUES expression.
Table columns that do not appear in the column list
are populated with the default column value
(specified as part of the CREATE TABLE statement),
or with NULL if no default value is specified.

The second form of the INSERT statement contains a


SELECT statement instead of a VALUES clause. A
new entry is inserted into the table for each row of
data returned by executing the SELECT statement. If
a column-list is specified, the number of columns in
the result of the SELECT must be the same as the
number of items in the column-list. Otherwise, if no
column-list is specified, the number of columns in
the result of the SELECT must be the same as the
number of columns in the table. Any SELECT
statement, including compound SELECTs and SELECT
statements with ORDER BY and/or LIMIT clauses,
may be used in an INSERT statement of this form.
The third form of an INSERT statement is with
DEFAULT VALUES. The INSERT ... DEFAULT VALUES
statement inserts a single new row into the named
table. Each column of the new row is populated with
its default value, or with a NULL if no default value
is specified as part of the column definition in the
CREATE TABLE statement.

The "REPLACE" and "INSERT OR action" forms specify


an alternative constraint conflict resolution algorithm
to use during this one INSERT command. See the
section titled ON CONFLICT for additional information.
For compatibility with MySQL, the parser allows the use
of the single keyword REPLACE as an alias for "INSERT
OR REPLACE".

The optional "schema-name." prefix on the table-name


is supported for top-level INSERT statements only. The
table name must be unqualified for INSERT statements
that occur within CREATE TRIGGER statements.
Similarly, the "DEFAULT VALUES" form of the INSERT
statement is supported for top-level INSERT statements
only and not for INSERT statements within triggers.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
SQLite Keywords
The SQL standard specifies a huge number of keywords
which may not be used as the names of tables, indices,
columns, databases, user-defined functions, collations,
virtual table modules, or any other named object. The
list of keywords is so long that few people can
remember them all. For most SQL code, your safest bet
is to never use any English language word as the name
of a user-defined object.

If you want to use a keyword as a name, you need to


quote it. There are four ways of quoting keywords in
SQLite:

'keyword' A keyword in single quotes is a string literal.


"keyword" A keyword in double-quotes is an identifier.
A keyword enclosed in square brackets is an identifier.
This is not standard SQL. This quoting mechanism is used
[keyword]
by MS Access and SQL Server and is included in SQLite
for compatibility.
A keyword enclosed in grave accents (ASCII code 96) is
an identifier. This is not standard SQL. This quoting
`keyword`
mechanism is used by MySQL and is included in SQLite
for compatibility.

For resilience when confronted with historical SQL


statements, SQLite will sometimes bend the quoting
rules above:

If a keyword in single quotes (ex: 'key' or 'glob') is


used in a context where an identifier is allowed but
where a string literal is not allowed, then the token
is understood to be an identifier instead of a string
literal.

If a keyword in double quotes (ex: "key" or "glob")


is used in a context where it cannot be resolved to
an identifier but where a string literal is allowed,
then the token is understood to be a string literal
instead of an identifier.

Programmers are cautioned not to use the two


exceptions described in the previous bullets. We
emphasize that they exist only so that old and ill-
formed SQL statements will run correctly. Future
versions of SQLite might raise errors instead of
accepting the malformed statements covered by the
exceptions above.

SQLite adds new keywords from time to time when it


takes on new features. So to prevent your code from
being broken by future enhancements, you should
normally quote any identifier that is an English
language word, even if you do not have to.

The list below shows all possible keywords used by any


build of SQLite regardless of compile-time options.
Most reasonable configurations use most or all of these
keywords, but some keywords may be omitted when
SQL language features are disabled. Regardless of the
compile-time configuration, any identifier that is not on
the following 124 element list is not a keyword to the
SQL parser in SQLite:
1. ABORT
2. ACTION
3. ADD
4. AFTER
5. ALL
6. ALTER
7. ANALYZE
8. AND
9. AS
0. ASC
1. ATTACH
2. AUTOINCREMENT
3. BEFORE
4. BEGIN
5. BETWEEN
6. BY
7. CASCADE
8. CASE
9. CAST
0. CHECK
1. COLLATE
2. COLUMN
3. COMMIT
4. CONFLICT
5. CONSTRAINT
6. CREATE
7. CROSS
8. CURRENT_DATE
9. CURRENT_TIME
0. CURRENT_TIMESTAMP
1. DATABASE
2. DEFAULT
3. DEFERRABLE
4. DEFERRED
5. DELETE
6. DESC
7. DETACH
8. DISTINCT
9. DROP
0. EACH
1. ELSE
2. END
3. ESCAPE
4. EXCEPT
5. EXCLUSIVE
6. EXISTS
7. EXPLAIN
8. FAIL
9. FOR
0. FOREIGN
1. FROM
2. FULL
3. GLOB
4. GROUP
5. HAVING
6. IF
7. IGNORE
8. IMMEDIATE
9. IN
0. INDEX
1. INDEXED
2. INITIALLY
3. INNER
4. INSERT
5. INSTEAD
6. INTERSECT
7. INTO
8. IS
9. ISNULL
0. JOIN
1. KEY
2. LEFT
3. LIKE
4. LIMIT
5. MATCH
6. NATURAL
7. NO
8. NOT
9. NOTNULL
0. NULL
1. OF
2. OFFSET
3. ON
4. OR
5. ORDER
6. OUTER
7. PLAN
8. PRAGMA
9. PRIMARY
0. QUERY
1. RAISE
2. RECURSIVE
3. REFERENCES
4. REGEXP
5. REINDEX
6. RELEASE
7. RENAME
8. REPLACE
9. RESTRICT
0. RIGHT
1. ROLLBACK
2. ROW
3. SAVEPOINT
4. SELECT
5. SET
6. TABLE
7. TEMP
8. TEMPORARY
9. THEN
0. TO
1. TRANSACTION
2. TRIGGER
3. UNION
4. UNIQUE
5. UPDATE
6. USING
7. VACUUM
8. VALUES
9. VIEW
0. VIRTUAL
1. WHEN
2. WHERE
3. WITH
4. WITHOUT
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
Database Object Name Resolution
In SQLite, a database object (a table, index, trigger or
view) is identified by the name of the object and the
name of the database that it resides in. Database
objects may reside in the main database, the temp
database, or in an attached database.

The syntax of the DROP TABLE, DROP INDEX, DROP


VIEW, DROP TRIGGER, REINDEX, ALTER TABLE and
many other commands all permit the user to specify a
database object either by its name alone, or by a
combination of its name and the name of its database.
If no database is specified as part of the object
reference, then SQLite searches the main, temp and all
attached databases for an object with a matching
name. The temp database is searched first, followed by
the main database, followed all attached databases in
the order that they were attached. The reference
resolves to the first match found. For example:
/* Add a table named 't1' to the temp, main and an a
ATTACH 'file.db' AS aux;
CREATE TABLE t1(x, y);
CREATE TEMP TABLE t1(x, y);
CREATE TABLE aux.t1(x, y);

DROP TABLE t1; /* Drop table in temp databas


DROP TABLE t1; /* Drop table in main databas
DROP TABLE t1; /* Drop table in aux database

If a schema name is specified as part of an object


reference, it must be either "main", or "temp" or the
schema-name of an attached database. Like other SQL
identifiers, schema names are case-insensitive. If a
schema name is specified, then only that one schema
is searched for the named object.

Most object references may only resolve to a specific


type of object (for example a reference that is part of a
DROP TABLE statement may only resolve to a table
object, not an index, trigger or view). However in some
contexts (e.g. REINDEX) an object reference may be
resolve to more than one type of object. When
searching database schemas for a named object,
objects of types that cannot be used in the context of
the reference are always ignored.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
REINDEX

reindex-stmt: hide

The REINDEX command is used to delete and recreate


indices from scratch. This is useful when the definition
of a collation sequence has changed.

If the REINDEX keyword is not followed by a collation-


sequence or database object identifier, then all indices
in all attached databases are rebuilt.

If the REINDEX keyword is followed by a collation-


sequence name, then all indices in all attached
databases that use the named collation sequences are
recreated.

Or, if the argument attached to the REINDEX identifies


a specific database table, then all indices attached to
the database table are rebuilt. If it identifies a specific
database index, then just that index is recreated.

For a command of the form "REINDEX name", a match


against collation-name takes precedence over a match
against index-name or table-name . This ambiguity in
the syntax may be avoided by always specifying a
schema-name when reindexing a specific table or
index.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
REPLACE
The REPLACE command is an alias for the "INSERT OR
REPLACE" variant of the INSERT command. This alias is
provided for compatibility other SQL database engines.
See the INSERT command documentation for additional
information.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
SAVEPOINT

savepoint-stmt: hide

release-stmt: hide

rollback-stmt: hide

SAVEPOINTs are a method of creating transactions,


similar to BEGIN and COMMIT, except that the
SAVEPOINT and RELEASE commands are named and
may be nested.

The SAVEPOINT command starts a new transaction with


a name. The transaction names need not be unique. A
SAVEPOINT can be started either within or outside of a
BEGIN...COMMIT. When a SAVEPOINT is the outer-most
savepoint and it is not within a BEGIN...COMMIT then
the behavior is the same as BEGIN DEFERRED
TRANSACTION.

The ROLLBACK TO command reverts the state of the


database back to what it was just after the
corresponding SAVEPOINT. Note that unlike that plain
ROLLBACK command (without the TO keyword) the
ROLLBACK TO command does not cancel the
transaction. Instead of cancelling the transaction, the
ROLLBACK TO command restarts the transaction again
at the beginning. All intervening SAVEPOINTs are
canceled, however.

The RELEASE command is like a COMMIT for a


SAVEPOINT. The RELEASE command causes all
savepoints back to and including the most recent
savepoint with a matching name to be removed from
the transaction stack. The RELEASE of an inner
transaction does not cause any changes to be written to
the database file; it merely removes savepoints from
the transaction stack such that it is no longer possible
to ROLLBACK TO those savepoints. If a RELEASE
command releases the outermost savepoint, so that the
transaction stack becomes empty, then RELEASE is the
same as COMMIT. The COMMIT command may be used
to release all savepoints and commit the transaction
even if the transaction was originally started by a
SAVEPOINT command instead of a BEGIN command.

If the savepoint-name in a RELEASE command does not


match any savepoint currently in the transaction stack,
then no savepoints are released, the database is
unchanged, and the RELEASE command returns an
error.

Note that an inner transaction might commit (using the


RELEASE command) but then later have its work
undone by a ROLLBACK in an outer transaction. A
power failure or program crash or OS crash will cause
the outer-most transaction to rollback, undoing all
changes that have occurred within that outer
transaction, even changes that have supposedly been
"committed" by the RELEASE command. Content is not
actually committed on the disk until the outermost
transaction commits.

There are several ways of thinking about the RELEASE


command:

Some people view RELEASE as the equivalent of


COMMIT for a SAVEPOINT. This is an acceptable
point of view as long as one remembers that the
changes committed by an inner transaction might
later be undone by a rollback in an outer
transaction.

Another view of RELEASE is that it merges a named


transaction into its parent transaction, so that the
named transaction and its parent become the same
transaction. After RELEASE, the named transaction
and its parent will commit or rollback together,
whatever their fate may be.

One can also think of savepoints as "marks" in the


transaction timeline. In this view, the SAVEPOINT
command creates a new mark, the ROLLBACK TO
command rewinds the timeline back to a point just
after the named mark, and the RELEASE command
erases marks from the timeline without actually
making any changes to the database.

Transaction Nesting Rules

The last transaction started will be the first transaction


committed or rolled back.

The BEGIN command only works if the transaction


stack is empty, or in other words if there are no
pending transactions. If the transaction stack is not
empty when the BEGIN command is invoked, then the
command fails with an error.

The COMMIT command commits all outstanding


transactions and leaves the transaction stack empty.

The RELEASE command starts with the most recent


addition to the transaction stack and releases
savepoints backwards in time until it releases a
savepoint with a matching savepoint-name. Prior
savepoints, even savepoints with matching savepoint-
names, are unchanged. If the RELEASE command
causes the transaction stack to become empty (if the
RELEASE command releases the outermost transaction
from the stack) then the transaction commits.

The ROLLBACK command without a TO clause rolls


backs all transactions and leaves the transaction stack
empty.
The ROLLBACK command with a TO clause rolls back
transactions going backwards in time back to the most
recent SAVEPOINT with a matching name. The
SAVEPOINT with the matching name remains on the
transaction stack, but all database changes that
occurred after that SAVEPOINT was created are rolled
back. If the savepoint-name in a ROLLBACK TO
command does not match any SAVEPOINT on the stack,
then the ROLLBACK command fails with an error and
leaves the state of the database unchanged.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
SELECT

select-stmt: hide

common-table-expression: show
compound-operator: show

expr: show

join-clause: show

ordering-term: show

result-column: show

table-or-subquery: show

The SELECT statement is used to query the database.


The result of a SELECT is zero or more rows of data
where each row has a fixed number of columns. A
SELECT statement does not make any changes to the
database.

The "select-stmt" syntax diagram above attempts to


show as much of the SELECT statement syntax as
possible in a single diagram, because some readers find
that helpful. The following "factored-select-stmt" is an
alternative syntax diagrams that expresses the same
syntax but tries to break the syntax down into smaller
chunks.

factored-select-stmt: show
Note that there are paths through the syntax diagrams
that are not allowed in practice. Some examples:

A VALUES clause can be the first element in a


compound SELECT that uses a WITH clause, but a
simple SELECT that consists of just a VALUES clause
cannot be preceded by a WITH clause.
The WITH clause must occur on the first SELECT of a
compound SELECT. It cannot follow a compound-
operator.

These and other similar syntax restrictions are


described in the text.

The SELECT statement is the most complicated


command in the SQL language. To make the description
easier to follow, some of the passages below describe
the way the data returned by a SELECT statement is
determined as a series of steps. It is important to keep
in mind that this is purely illustrative - in practice
neither SQLite nor any other SQL engine is required to
follow this or any other specific process.

Simple Select Processing

The core of a SELECT statement is a "simple SELECT"


shown by the select-core and simple-select-stmt syntax
diagrams below. In practice, most SELECT statements
are simple SELECT statements.

simple-select-stmt: hide
common-table-expression: show

expr: show

ordering-term: show

select-core: hide
join-clause: show

result-column: show

table-or-subquery: show

Generating the results of a simple SELECT statement is


presented as a four step process in the description
below:

1. FROM clause processing: The input data for the


simple SELECT is determined. The input data is
either implicitly a single row with 0 columns (if
there is no FROM clause) or is determined by the
FROM clause.
2. WHERE clause processing: The input data is filtered
using the WHERE clause expression.

3. GROUP BY, HAVING and result-column expression


processing: The set of result rows is computed by
aggregating the data according to any GROUP BY
clause and calculating the result-set expressions for
the rows of the filtered input dataset.

4. DISTINCT/ALL keyword processing: If the query is a


"SELECT DISTINCT" query, duplicate rows are
removed from the set of result rows.

There are two types of simple SELECT statement -


aggregate and non-aggregate queries. A simple SELECT
statement is an aggregate query if it contains either a
GROUP BY clause or one or more aggregate functions in
the result-set. Otherwise, if a simple SELECT contains
no aggregate functions or a GROUP BY clause, it is a
non-aggregate query.

1. Determination of input data (FROM clause


processing).

The input data used by a simple SELECT query is a set


of N rows each M columns wide.

If the FROM clause is omitted from a simple SELECT


statement, then the input data is implicitly a single row
zero columns wide (i.e. N=1 and M=0).

If a FROM clause is specified, the data on which a


simple SELECT query operates comes from the one or
more tables or subqueries (SELECT statements in
parenthesis) specified following the FROM keyword. A
subquery specified in the table-or-subquery following
the FROM clause in a simple SELECT statement is
handled as if it was a table containing the data
returned by executing the subquery statement. Each
column of the subquery has the collation sequence and
affinity of the corresponding expression in the subquery
statement.

If there is only a single table or subquery in the FROM


clause, then the input data used by the SELECT
statement is the contents of the named table. If there
is more than one table or subquery in FROM clause
then the contents of all tables and/or subqueries are
joined into a single dataset for the simple SELECT
statement to operate on. Exactly how the data is
combined depends on the specific join-operator and
join-constraint used to connect the tables or subqueries
together.

All joins in SQLite are based on the cartesian product of


the left and right-hand datasets. The columns of the
cartesian product dataset are, in order, all the columns
of the left-hand dataset followed by all the columns of
the right-hand dataset. There is a row in the cartesian
product dataset formed by combining each unique
combination of a row from the left-hand and right-hand
datasets. In other words, if the left-hand dataset
consists of Nleft rows of Mleft columns, and the right-hand
dataset of Nright rows of Mright columns, then the cartesian
product is a dataset of NleftNright rows, each containing
Mleft+Mright columns.

If the join-operator is "CROSS JOIN", "INNER JOIN",


"JOIN" or a comma (",") and there is no ON or USING
clause, then the result of the join is simply the
cartesian product of the left and right-hand datasets. If
join-operator does have ON or USING clauses, those
are handled according to the following bullet points:

If there is an ON clause then the ON expression is


evaluated for each row of the cartesian product as a
boolean expression. Only rows for which the
expression evaluates to true are included from the
dataset.

If there is a USING clause then each of the column


names specified must exist in the datasets to both
the left and right of the join-operator. For each pair
of named columns, the expression "lhs.X = rhs.X" is
evaluated for each row of the cartesian product as a
boolean expression. Only rows for which all such
expressions evaluates to true are included from the
result set. When comparing values as a result of a
USING clause, the normal rules for handling
affinities, collation sequences and NULL values in
comparisons apply. The column from the dataset on
the left-hand side of the join-operator is considered
to be on the left-hand side of the comparison
operator (=) for the purposes of collation sequence
and affinity precedence.

For each pair of columns identified by a USING


clause, the column from the right-hand dataset is
omitted from the joined dataset. This is the only
difference between a USING clause and its
equivalent ON constraint.

If the NATURAL keyword is in the join-operator then


an implicit USING clause is added to the join-
constraints. The implicit USING clause contains each
of the column names that appear in both the left and
right-hand input datasets. If the left and right-hand
input datasets feature no common column names,
then the NATURAL keyword has no effect on the
results of the join. A USING or ON clause may not be
added to a join that specifies the NATURAL keyword.

If the join-operator is a "LEFT JOIN" or "LEFT OUTER


JOIN", then after the ON or USING filtering clauses
have been applied, an extra row is added to the
output for each row in the original left-hand input
dataset that corresponds to no rows at all in the
composite dataset (if any). The added rows contain
NULL values in the columns that would normally
contain values copied from the right-hand input
dataset.

When more than two tables are joined together as part


of a FROM clause, the join operations are processed in
order from left to right. In other words, the FROM
clause (A join-op-1 B join-op-2 C) is computed as ((A
join-op-1 B) join-op-2 C).

Side note: Special handling of CROSS JOIN. There


is no difference between the "INNER JOIN", "JOIN" and
"," join operators. They are completely interchangeable
in SQLite. The "CROSS JOIN" join operator produces
the same result as the "INNER JOIN", "JOIN" and ","
operators, but is handled differently by the query
optimizer in that it prevents the query optimizer from
reordering the tables in the join. An application
programmer can use the CROSS JOIN operator to
directly influence the algorithm that is chosen to
implement the SELECT statement. Avoid using CROSS
JOIN except in specific situations where manual control
of the query optimizer is desired. Avoid using CROSS
JOIN early in the development of an application as
doing so is a premature optimization. The special
handling of CROSS JOIN is an SQLite-specific feature
and is not a part of standard SQL.

2. WHERE clause filtering.

If a WHERE clause is specified, the WHERE expression


is evaluated for each row in the input data as a boolean
expression. Only rows for which the WHERE clause
expression evaluates to true are included from the
dataset before continuing. Rows are excluded from the
result if the WHERE clause evaluates to either false or
NULL.
For a JOIN or INNER JOIN or CROSS JOIN, there is no
difference between a constraint expression in the
WHERE clause and one in the ON clause. However, for a
LEFT JOIN or LEFT OUTER JOIN, the difference is very
important. In a LEFT JOIN, the extra NULL row for the
right-hand table is added after ON clause processing
but before WHERE clause processing. A constraint of
the form "left.x=right.y" in an ON clause will therefore
allow through the added all-NULL rows of the right
table. But if that same constraint is in the WHERE
clause a NULL in "right.y" will prevent the expression
"left.x=right.y" from being true, and thus exclude that
row from the output.

3. Generation of the set of result rows.

Once the input data from the FROM clause has been
filtered by the WHERE clause expression (if any), the
set of result rows for the simple SELECT are calculated.
Exactly how this is done depends on whether the
simple SELECT is an aggregate or non-aggregate query,
and whether or not a GROUP BY clause was specified.

The list of expressions between the SELECT and FROM


keywords is known as the result expression list. If a
result expression is the special expression "*" then all
columns in the input data are substituted for that one
expression. If the expression is the alias of a table or
subquery in the FROM clause followed by ".*" then all
columns from the named table or subquery are
substituted for the single expression. It is an error to
use a "*" or "alias.*" expression in any context other
than a result expression list. It is also an error to use a
"*" or "alias.*" expression in a simple SELECT query
that does not have a FROM clause.

The number of columns in the rows returned by a


simple SELECT statement is equal to the number of
expressions in the result expression list after
substitution of * and alias.* expressions. Each result
row is calculated by evaluating the expressions in the
result expression list with respect to a single row of
input data or, for aggregate queries, with respect to a
group of rows.

If the SELECT statement is a non-aggregate


query, then each expression in the result
expression list is evaluated for each row in the
dataset filtered by the WHERE clause.

If the SELECT statement is an aggregate query


without a GROUP BY clause, then each aggregate
expression in the result-set is evaluated once across
the entire dataset. Each non-aggregate expression in
the result-set is evaluated once for an arbitrarily
selected row of the dataset. The same arbitrarily
selected row is used for each non-aggregate
expression. Or, if the dataset contains zero rows,
then each non-aggregate expression is evaluated
against a row consisting entirely of NULL values.

The single row of result-set data created by


evaluating the aggregate and non-aggregate
expressions in the result-set forms the result of an
aggregate query without a GROUP BY clause. An
aggregate query without a GROUP BY clause always
returns exactly one row of data, even if there are
zero rows of input data.

If the SELECT statement is an aggregate query


with a GROUP BY clause, then each of the
expressions specified as part of the GROUP BY
clause is evaluated for each row of the dataset. Each
row is then assigned to a "group" based on the
results; rows for which the results of evaluating the
GROUP BY expressions are the same get assigned to
the same group. For the purposes of grouping rows,
NULL values are considered equal. The usual rules
for selecting a collation sequence with which to
compare text values apply when evaluating
expressions in a GROUP BY clause. The expressions
in the GROUP BY clause do not have to be
expressions that appear in the result. The
expressions in a GROUP BY clause may not be
aggregate expressions.

If a HAVING clause is specified, it is evaluated once


for each group of rows as a boolean expression. If
the result of evaluating the HAVING clause is false,
the group is discarded. If the HAVING clause is an
aggregate expression, it is evaluated across all rows
in the group. If a HAVING clause is a non-aggregate
expression, it is evaluated with respect to an
arbitrarily selected row from the group. The HAVING
expression may refer to values, even aggregate
functions, that are not in the result.

Each expression in the result-set is then evaluated


once for each group of rows. If the expression is an
aggregate expression, it is evaluated across all rows
in the group. Otherwise, it is evaluated against a
single arbitrarily chosen row from within the group.
If there is more than one non-aggregate expression
in the result-set, then all such expressions are
evaluated for the same row.

Each group of input dataset rows contributes a single


row to the set of result rows. Subject to filtering
associated with the DISTINCT keyword, the number
of rows returned by an aggregate query with a
GROUP BY clause is the same as the number of
groups of rows produced by applying the GROUP BY
and HAVING clauses to the filtered input dataset.

4. Removal of duplicate rows (DISTINCT


processing).

One of the ALL or DISTINCT keywords may follow the


SELECT keyword in a simple SELECT statement. If the
simple SELECT is a SELECT ALL, then the entire set of
result rows are returned by the SELECT. If neither ALL
or DISTINCT are present, then the behavior is as if ALL
were specified. If the simple SELECT is a SELECT
DISTINCT, then duplicate rows are removed from the
set of result rows before it is returned. For the purposes
of detecting duplicate rows, two NULL values are
considered to be equal. The normal rules for selecting a
collation sequence to compare text values with apply.

Compound Select Statements

Two or more simple SELECT statements may be


connected together to form a compound SELECT using
the UNION, UNION ALL, INTERSECT or EXCEPT
operator, as shown by the following diagram:

compound-select-stmt: hide

common-table-expression: show
expr: show

ordering-term: show

select-core: show

In a compound SELECT, all the constituent SELECTs


must return the same number of result columns. As the
components of a compound SELECT must be simple
SELECT statements, they may not contain ORDER BY or
LIMIT clauses. ORDER BY and LIMIT clauses may only
occur at the end of the entire compound SELECT, and
then only if the final element of the compound is not a
VALUES clause.

A compound SELECT created using UNION ALL operator


returns all the rows from the SELECT to the left of the
UNION ALL operator, and all the rows from the SELECT
to the right of it. The UNION operator works the same
way as UNION ALL, except that duplicate rows are
removed from the final result set. The INTERSECT
operator returns the intersection of the results of the
left and right SELECTs. The EXCEPT operator returns
the subset of rows returned by the left SELECT that are
not also returned by the right-hand SELECT. Duplicate
rows are removed from the results of INTERSECT and
EXCEPT operators before the result set is returned.

For the purposes of determining duplicate rows for the


results of compound SELECT operators, NULL values
are considered equal to other NULL values and distinct
from all non-NULL values. The collation sequence used
to compare two text values is determined as if the
columns of the left and right-hand SELECT statements
were the left and right-hand operands of the equals (=)
operator, except that greater precedence is not
assigned to a collation sequence specified with the
postfix COLLATE operator. No affinity transformations
are applied to any values when comparing rows as part
of a compound SELECT.

When three or more simple SELECTs are connected into


a compound SELECT, they group from left to right. In
other words, if "A", "B" and "C" are all simple SELECT
statements, (A op B op C) is processed as ((A op B) op
C).

The ORDER BY clause

If a SELECT statement that returns more than one row


does not have an ORDER BY clause, the order in which
the rows are returned is undefined. Or, if a SELECT
statement does have an ORDER BY clause, then the list
of expressions attached to the ORDER BY determine the
order in which rows are returned to the user.

In a compound SELECT statement, only the last or


right-most simple SELECT may have an ORDER BY
clause. That ORDER BY clause will apply across all
elements of the compound. If the right-most element of
a compound SELECT is a VALUES clause, then no
ORDER BY clause is allowed on that statement.

Rows are first sorted based on the results of evaluating


the left-most expression in the ORDER BY list, then ties
are broken by evaluating the second left-most
expression and so on. The order in which two rows for
which all ORDER BY expressions evaluate to equal
values are returned is undefined. Each ORDER BY
expression may be optionally followed by one of the
keywords ASC (smaller values are returned first) or
DESC (larger values are returned first). If neither ASC
or DESC are specified, rows are sorted in ascending
(smaller values first) order by default.

Each ORDER BY expression is processed as follows:

1. If the ORDER BY expression is a constant integer K


then the expression is considered an alias for the K-
th column of the result set (columns are numbered
from left to right starting with 1).

2. If the ORDER BY expression is an identifier that


corresponds to the alias of one of the output
columns, then the expression is considered an alias
for that column.

3. Otherwise, if the ORDER BY expression is any other


expression, it is evaluated and the returned value
used to order the output rows. If the SELECT
statement is a simple SELECT, then an ORDER BY
may contain any arbitrary expressions. However, if
the SELECT is a compound SELECT, then ORDER BY
expressions that are not aliases to output columns
must be exactly the same as an expression used as
an output column.

For the purposes of sorting rows, values are compared


in the same way as for comparison expressions. The
collation sequence used to compare two text values is
determined as follows:

1. If the ORDER BY expression is assigned a collation


sequence using the postfix COLLATE operator, then
the specified collation sequence is used.

2. Otherwise, if the ORDER BY expression is an alias to


an expression that has been assigned a collation
sequence using the postfix COLLATE operator, then
the collation sequence assigned to the aliased
expression is used.

3. Otherwise, if the ORDER BY expression is a column


or an alias of an expression that is a column, then
the default collation sequence for the column is
used.

4. Otherwise, the BINARY collation sequence is used.

In a compound SELECT statement, all ORDER BY


expressions are handled as aliases for one of the result
columns of the compound. If an ORDER BY expression
is not an integer alias, then SQLite searches the left-
most SELECT in the compound for a result column that
matches either the second or third rules above. If a
match is found, the search stops and the expression is
handled as an alias for the result column that it has
been matched against. Otherwise, the next SELECT to
the right is tried, and so on. If no matching expression
can be found in the result columns of any constituent
SELECT, it is an error. Each term of the ORDER BY
clause is processed separately and may be matched
against result columns from different SELECT
statements in the compound.

The LIMIT clause

The LIMIT clause is used to place an upper bound on


the number of rows returned by the entire SELECT
statement.

In a compound SELECT, only the last or right-most


simple SELECT may contain a LIMIT clause. In a
compound SELECT, the LIMIT clause applies to the
entire compound, not just the final SELECT. If the right-
most simple SELECT is a VALUES clause then no LIMIT
clause is allowed.

Any scalar expression may be used in the LIMIT clause,


so long as it evaluates to an integer or a value that can
be losslessly converted to an integer. If the expression
evaluates to a NULL value or any other value that
cannot be losslessly converted to an integer, an error is
returned. If the LIMIT expression evaluates to a
negative value, then there is no upper bound on the
number of rows returned. Otherwise, the SELECT
returns the first N rows of its result set only, where N is
the value that the LIMIT expression evaluates to. Or, if
the SELECT statement would return less than N rows
without a LIMIT clause, then the entire result set is
returned.

The expression attached to the optional OFFSET clause


that may follow a LIMIT clause must also evaluate to
an integer, or a value that can be losslessly converted
to an integer. If an expression has an OFFSET clause,
then the first M rows are omitted from the result set
returned by the SELECT statement and the next N rows
are returned, where M and N are the values that the
OFFSET and LIMIT clauses evaluate to, respectively. Or,
if the SELECT would return less than M+N rows if it did
not have a LIMIT clause, then the first M rows are
skipped and the remaining rows (if any) are returned.
If the OFFSET clause evaluates to a negative value, the
results are the same as if it had evaluated to zero.

Instead of a separate OFFSET clause, the LIMIT clause


may specify two scalar expressions separated by a
comma. In this case, the first expression is used as the
OFFSET expression and the second as the LIMIT
expression. This is counter-intuitive, as when using the
OFFSET clause the second of the two expressions is the
OFFSET and the first the LIMIT. This reversal of the
offset and limit is intentional - it maximizes
compatibility with other SQL database systems.
However, to avoid confusion, programmers are strongly
encouraged to use the form of the LIMIT clause that
uses the "OFFSET" keyword and avoid using a LIMIT
clause with a comma-separated offset.

The VALUES clause

The phrase "VALUES(expr-list)" means the same thing


as "SELECT expr-list". The phrase "VALUES(expr-list-
1),...,(expr-list-N)" means the same thing as "SELECT
expr-list-1 UNION ALL ... UNION ALL SELECT expr-list-
N". Both forms are the same, except that the number of
SELECT statements in a compound is limited by
SQLITE_LIMIT_COMPOUND_SELECT whereas the
number of rows in a VALUES clause has no arbitrary
limit.

There are some restrictions on the use of a VALUES


clause that are not shown on the syntax diagrams:

A VALUES clause cannot be followed by ORDER BY.

A VALUES clause cannot be followed by LIMIT.

The WITH Clause

SELECT statements may be optionally preceded by a


single WITH clause that defines one or more common
table expressions for use within the SELECT statement.

Table-valued Functions In The FROM Clause

A virtual table that contains hidden columns can be


used like a table-valued function in the FROM clause.
The arguments to the table-valued function become
constraints on the HIDDEN columns of the virtual table.
Additional information can be found in the virtual table
documentation.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
BEGIN TRANSACTION

begin-stmt: hide

commit-stmt: hide

rollback-stmt: hide

No changes can be made to the database except within


a transaction. Any command that changes the database
(basically, any SQL command other than SELECT) will
automatically start a transaction if one is not already in
effect. Automatically started transactions are
committed when the last query finishes.

Transactions can be started manually using the BEGIN


command. Such transactions usually persist until the
next COMMIT or ROLLBACK command. But a
transaction will also ROLLBACK if the database is
closed or if an error occurs and the ROLLBACK conflict
resolution algorithm is specified. See the
documentation on the ON CONFLICT clause for
additional information about the ROLLBACK conflict
resolution algorithm.

END TRANSACTION is an alias for COMMIT.

Transactions created using BEGIN...COMMIT do not


nest. For nested transactions, use the SAVEPOINT and
RELEASE commands. The "TO SAVEPOINT name "
clause of the ROLLBACK command shown in the syntax
diagram above is only applicable to SAVEPOINT
transactions. An attempt to invoke the BEGIN command
within a transaction will fail with an error, regardless of
whether the transaction was started by SAVEPOINT or a
prior BEGIN. The COMMIT command and the ROLLBACK
command without the TO clause work the same on
SAVEPOINT transactions as they do with transactions
started by BEGIN.

Transactions can be deferred, immediate, or exclusive.


The default transaction behavior is deferred. Deferred
means that no locks are acquired on the database until
the database is first accessed. Thus with a deferred
transaction, the BEGIN statement itself does nothing to
the filesystem. Locks are not acquired until the first
read or write operation. The first read operation against
a database creates a SHARED lock and the first write
operation creates a RESERVED lock. Because the
acquisition of locks is deferred until they are needed, it
is possible that another thread or process could create
a separate transaction and write to the database after
the BEGIN on the current thread has executed. If the
transaction is immediate, then RESERVED locks are
acquired on all databases as soon as the BEGIN
command is executed, without waiting for the database
to be used. After a BEGIN IMMEDIATE, no other
database connection will be able to write to the
database or do a BEGIN IMMEDIATE or BEGIN
EXCLUSIVE. Other processes can continue to read from
the database, however. An exclusive transaction causes
EXCLUSIVE locks to be acquired on all databases. After
a BEGIN EXCLUSIVE, no other database connection
except for read_uncommitted connections will be able
to read the database and no other connection without
exception will be able to write the database until the
transaction is complete.

An implicit transaction (a transaction that is started


automatically, not a transaction started by BEGIN) is
committed automatically when the last active
statement finishes. A statement finishes when its
prepared statement is reset or finalized. An open
sqlite3_blob used for incremental BLOB I/O counts as
an unfinished statement. The sqlite3_blob finishes
when it is closed.

The explicit COMMIT command runs immediately, even


if there are pending SELECT statements. However, if
there are pending write operations, the COMMIT
command will fail with an error code SQLITE_BUSY.
An attempt to execute COMMIT might also result in an
SQLITE_BUSY return code if an another thread or
process has a shared lock on the database that
prevented the database from being updated. When
COMMIT fails in this way, the transaction remains
active and the COMMIT can be retried later after the
reader has had a chance to clear.

In very old versions of SQLite (before version 3.7.11 -


2012-03-20) the ROLLBACK will fail with an error code
SQLITE_BUSY if there are any pending queries. In more
recent versions of SQLite, the ROLLBACK will proceed
and pending statements will often be aborted, causing
them to return an SQLITE_ABORT or
SQLITE_ABORT_ROLLBACK error. In SQLite version
3.8.8 (2015-01-16) and later, a pending read will
continue functioning after the ROLLBACK as long as the
ROLLBACK does not modify the database schema.

If PRAGMA journal_mode is set to OFF (thus disabling


the rollback journal file) then the behavior of the
ROLLBACK command is undefined.

Response To Errors Within A Transaction

If certain kinds of errors occur within a transaction, the


transaction may or may not be rolled back
automatically. The errors that can cause an automatic
rollback include:

SQLITE_FULL: database or disk full


SQLITE_IOERR: disk I/O error
SQLITE_BUSY: database in use by another process
SQLITE_NOMEM: out or memory

For all of these errors, SQLite attempts to undo just the


one statement it was working on and leave changes
from prior statements within the same transaction
intact and continue with the transaction. However,
depending on the statement being evaluated and the
point at which the error occurs, it might be necessary
for SQLite to rollback and cancel the entire transaction.
An application can tell which course of action SQLite
took by using the sqlite3_get_autocommit() C-language
interface.

It is recommended that applications respond to the


errors listed above by explicitly issuing a ROLLBACK
command. If the transaction has already been rolled
back automatically by the error response, then the
ROLLBACK command will fail with an error, but no harm
is caused by this.

Future versions of SQLite may extend the list of errors


which might cause automatic transaction rollback.
Future versions of SQLite might change the error
response. In particular, we may choose to simplify the
interface in future versions of SQLite by causing the
errors above to force an unconditional rollback.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
UPDATE

update-stmt: hide

column-name-list: show

expr: show

qualified-table-name: show

with-clause: show

An UPDATE statement is used to modify a subset of the


values stored in zero or more rows of the database
table identified by the qualified-table-name specified as
part of the UPDATE statement.

If the UPDATE statement does not have a WHERE


clause, all rows in the table are modified by the
UPDATE. Otherwise, the UPDATE affects only those
rows for which the WHERE clause boolean expression is
true. It is not an error if the WHERE clause does not
evaluate to true for any row in the table - this just
means that the UPDATE statement affects zero rows.

The modifications made to each row affected by an


UPDATE statement are determined by the list of
assignments following the SET keyword. Each
assignment specifies a column-name to the left of the
equals sign and a scalar expression to the right. For
each affected row, the named columns are set to the
values found by evaluating the corresponding scalar
expressions. If a single column-name appears more
than once in the list of assignment expressions, all but
the rightmost occurrence is ignored. Columns that do
not appear in the list of assignments are left
unmodified. The scalar expressions may refer to
columns of the row being updated. In this case all
scalar expressions are evaluated before any
assignments are made.

Beginning in SQLite version 3.15.0 (2016-10-14), an


assignment in the SET clause can be a parenthesized
list of column names on the left and a row value of the
same size on the right.

The optional "OR action" conflict clause that follows the


UPDATE keyword allows the user to nominate a specific
constraint conflict resolution algorithm to use during
this one UPDATE command. Refer to the section
entitled ON CONFLICT for additional information.

Restrictions on UPDATE Statements Within


CREATE TRIGGER

The following additional syntax restrictions apply to


UPDATE statements that occur within the body of a
CREATE TRIGGER statement.

The table-name specified as part of an UPDATE


statement within a trigger body must be unqualified.
In other words, the schema-name. prefix on the
table name of the UPDATE is not allowed within
triggers. Unless the table to which the trigger is
attached is in the TEMP database, the table being
updated by the trigger program must reside in the
same database as it. If the table to which the trigger
is attached is in the TEMP database, then the
unqualified name of the table being updated is
resolved in the same way as it is for a top-level
statement (by searching first the TEMP database,
then the main database, then any other databases in
the order they were attached).

The INDEXED BY and NOT INDEXED clauses are not


allowed on UPDATE statements within triggers.

The LIMIT and ORDER BY clauses for UPDATE are


unsupported within triggers, regardless of the
compilation options used to build SQLite.

Optional LIMIT and ORDER BY Clauses


If SQLite is built with the
SQLITE_ENABLE_UPDATE_DELETE_LIMIT compile-time
option then the syntax of the UPDATE statement is
extended with optional ORDER BY and LIMIT clauses as
follows:

update-stmt-limited:

If an UPDATE statement has a LIMIT clause, the


maximum number of rows that will be updated is found
by evaluating the accompanying expression and casting
it to an integer value. A negative value is interpreted
as "no limit".
If the LIMIT expression evaluates to non-negative
value N and the UPDATE statement has an ORDER BY
clause, then all rows that would be updated in the
absence of the LIMIT clause are sorted according to the
ORDER BY and the first N updated. If the UPDATE
statement also has an OFFSET clause, then it is
similarly evaluated and cast to an integer value. If the
OFFSET expression evaluates to a non-negative value
M, then the first M rows are skipped and the following
N rows updated instead.

If the UPDATE statement has no ORDER BY clause, then


all rows that would be updated in the absence of the
LIMIT clause are assembled in an arbitrary order before
applying the LIMIT and OFFSET clauses to determine
which are actually updated.

The ORDER BY clause on an UPDATE statement is used


only to determine which rows fall within the LIMIT. The
order in which rows are modified is arbitrary and is not
influenced by the ORDER BY clause.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
VACUUM

vacuum-stmt: hide

The VACUUM command rebuilds the database file,


repacking it into a minimal amount of disk space. There
are several reasons an application might do this:

Unless SQLite is running in "auto_vacuum=FULL"


mode, when a large amount of data is deleted from
the database file it leaves behind empty space, or
"free" database pages. This means the database file
might be larger than strictly necessary. Running
VACUUM to rebuild the database reclaims this space
and reduces the size of the database file.

Frequent inserts, updates, and deletes can cause the


database file to become fragmented - where data for
a single table or index is scattered around the
database file. Running VACUUM ensures that each
table and index is largely stored contiguously within
the database file. In some cases, VACUUM may also
reduce the number of partially filled pages in the
database, reducing the size of the database file
further.

Normally, the database page_size and whether or


not the database supports auto_vacuum must be
configured before the database file is actually
created. However, when not in write-ahead log
mode, the page_size and/or auto_vacuum properties
of an existing database may be changed by using
the page_size and/or pragma auto_vacuum pragmas
and then immediately VACUUMing the database.
When in write-ahead log mode, only the
auto_vacuum support property can be changed using
VACUUM.

By default, VACUUM only works only on the main


database. Attached databases can be vacuumed by
appending the appropriate schema-name to the
VACUUM statement.

Compatibility Warning: The ability to vacuum


attached databases was added in version 3.15.0 (2016-
10-14). Prior to that, a schema-name added to the
VACUUM statement would be silently ignored and the
"main" schema would be vacuumed.

The VACUUM command works by copying the contents


of the database into a temporary database file and then
overwriting the original with the contents of the
temporary file. When overwriting the original, a
rollback journal or write-ahead log WAL file is used just
as it would be for any other database transaction. This
means that when VACUUMing a database, as much as
twice the size of the original database file is required in
free disk space.
The VACUUM command may change the ROWIDs of
entries in any tables that do not have an explicit
INTEGER PRIMARY KEY.

A VACUUM will fail if there is an open transaction, or if


there are one or more active SQL statements when it is
run.

An alternative to using the VACUUM command to


reclaim space after data has been deleted is auto-
vacuum mode, enabled using the auto_vacuum pragma.
When auto_vacuum is enabled for a database free
pages may be reclaimed after deleting data, causing
the file to shrink, without rebuilding the entire
database using VACUUM. However, using auto_vacuum
can lead to extra database file fragmentation. And
auto_vacuum does not compact partially filled pages of
the database as VACUUM does.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
SQL As Understood By SQLite
[Top]
WITH clause

with-clause: hide

cte-table-name: show

select-stmt: show

Common Table Expressions or CTEs act like temporary


views that exist only for the duration of a single SQL
statement. There are two kinds of common table
expressions: "ordinary" and "recursive". Ordinary
common table expressions are helpful for making
queries easier to understand by factoring subqueries
out of the main SQL statement. Recursive common
table expressions provide the ability to do hierarchical
or recursive queries of trees and graphs, a capability
that is not otherwise available in the SQL language.

All common table expressions (ordinary and recursive)


are created by prepending a WITH clause in front of a
SELECT, INSERT, DELETE, or UPDATE statement. A
single WITH clause can specify one or more common
table expressions, some of which are ordinary and
some of which are recursive.

Ordinary Common Table Expressions


An ordinary common table expression works as if it
were a view that exists for the duration of a single
statement. Ordinary common table expressions are
useful for factoring out subqueries and making the
overall SQL statement easier to read and understand.

A WITH clause can contain ordinary common table


expressions even if it includes the RECURSIVE
keyword. The use of RECURSIVE does not force
common table expressions to be recursive.

Recursive Common Table Expressions

A recursive common table expression can be used to


write a query that walks a tree or graph. A recursive
common table expression has the same basic syntax as
an ordinary common table expression, but with the
following additional features:

1. The "select-stmt" must be a compound select where


the right-most compound-operator is either UNION
or UNION ALL.
2. The table named on the left-hand side of the AS
keyword must appear exactly once in the FROM
clause of the right-most SELECT statement of the
compound select, and nowhere else.

To put it another way, a recursive common table


expression must look like the following:

recursive-cte: hide
cte-table-name: show

Call the table named by the cte-table-name in a


recursive common table expression the "recursive
table". In the recursive-cte bubble diagram above, the
recursive table must appear exactly once in the FROM
clause of the recursive-select and must not appear
anywhere else in either the initial-select or the
recursive-select , including subqueries. The initial-
select may be a compound select, but it may not
include an ORDER BY, LIMIT, or OFFSET. The recursive-
select must be a simple select, not a compound. The
recursive-select is allowed to include an ORDER BY,
LIMIT, and/or OFFSET.

The basic algorithm for computing the content of the


recursive table is as follows:

1. Run the initial-select and add the results to a


queue.
2. While the queue is not empty:
1. Extract a single row from the queue.
2. Insert that single row into the recursive table
3. Pretend that the single row just extracted is the
only row in the recursive table and run the
recursive-select, adding all results to the queue.

The basic procedure above may modified by the


following additional rules:

If a UNION operator connects the initial-select with


the recursive-select , then only add rows to the
queue if no identical row has been previously added
to the queue. Repeated rows are discarded before
being added to the queue even if the repeated rows
have already been extracted from the queue by the
recursion step. If the operator is UNION ALL, then all
rows generated by both the initial-select and the
recursive-select are always added to the queue
even if they are repeats. When determining if a row
is repeated, NULL values compare equal to one
another and not equal to any other value.

The LIMIT clause, if present, determines the


maximum number of rows that will ever be added to
the recursive table in step 2b. Once the limit is
reached, the recursion stops. A limit of zero means
that no rows are ever added to the recursive table,
and a negative limit means an unlimited number of
rows may be added to the recursive table.

The OFFSET clause, if it is present and has a positive


value N, prevents the first N rows from being added
to the recursive table. The first N rows are still
processed by the recursive-select they just are
not added to the recursive table. Rows are not
counted toward fulfilling the LIMIT until all OFFSET
rows have been skipped.
If an ORDER BY clause is present, it determines the
order in which rows are extracted from the queue in
step 2a. If there is no ORDER BY clause, then the
order in which rows are extracted is undefined. (In
the current implementation, the queue becomes a
FIFO if the ORDER BY clause is omitted, but
applications should not depend on that fact since it
might change.)

Recursive Query Examples

The following query returns all integers between 1 and


1000000:
WITH RECURSIVE
cnt(x) AS (VALUES(1) UNION ALL SELECT x+1 FROM cnt WHE
SELECT x FROM cnt;

Consider how this query works. The initial-select runs


first and returns a single row with a single column "1".
This one row is added to the queue. In step 2a, that
one row is extracted from the queue and added to
"cnt". Then the recursive-select is run in accordance
with step 2c generating a single new row with value "2"
to add to the queue. The queue still has one row, so
step 2 repeats. The "2" row is extracted and added to
the recursive table by steps 2a and 2b. Then the row
containing 2 is used as if it were the complete content
of the recursive table and the recursive-select is run
again, resulting in a row with value "3" being added to
the queue. This repeats 999999 times until finally at
step 2a the only value on the queue is a row containing
1000000. That row is extracted and added to the
recursive table. But this time, the WHERE clause
causes the recursive-select to return no rows, so the
queue remains empty and the recursion stops.

Optimization note: In the discussion above,


statements like "insert the row into the recursive table"
should be understood conceptually, not literally. It
sounds as if SQLite is accumulating a huge table
containing one million rows, then going back and
scanning that table from top to bottom to generate the
result. What really happens is that the query optimizer
sees that values in the "cnt" recursive table are only
used once. So as each row is added to the recursive
table, that row is immediately returned as a result of
the main SELECT statement and then discarded. SQLite
does not accumulate a temporary table containing a
million rows. Very little memory is needed to run the
above example. However, if the example had used
UNION instead of UNION ALL, then SQLite would have
had to keep around all previously generated content in
order to check for duplicates. For this reason,
programmers should strive to use UNION ALL instead of
UNION when feasible.

Here is a variation on the previous example:


WITH RECURSIVE
cnt(x) AS (
SELECT 1
UNION ALL
SELECT x+1 FROM cnt
LIMIT 1000000
)
SELECT x FROM cnt;

There are two differences in this variation. The initial-


select is "SELECT 1" instead of "VALUES(1)". But those
are just different syntaxes for saying exactly the same
thing. The other change is that the recursion is stopped
by a LIMIT rather than a WHERE clause. The use of
LIMIT means that when the one-millionth row is added
to the "cnt" table (and returned by the main SELECT,
thanks to the query optimizer) then the recursion stops
immediately regardless of how many rows might be left
in the queue. On more complex queries, it can
sometimes be difficult to ensure that the WHERE clause
will eventually cause the queue to drain and the
recursion to terminate. But the LIMIT clause will
always stop the recursion. So it is good practice to
always include a LIMIT clause as a safety if an upper
bound on the size of the recursion is known.

Hierarchical Query Examples

Consider a table that describes the members of an


organization as well as the chain-of-command within
that organization:
CREATE TABLE org(
name TEXT PRIMARY KEY,
boss TEXT REFERENCES org,
height INT,
-- other content omitted
);

Every member in the organization has a name, and


most members have a single boss. (The head of the
whole organization has a NULL "boss" field.) The rows
of the "org" table form a tree.

Here is a query that computes the average height over


everyone in Alice's organization, including Alice:
WITH RECURSIVE
works_for_alice(n) AS (
VALUES('Alice')
UNION
SELECT name FROM org, works_for_alice
WHERE org.boss=works_for_alice.n
)
SELECT avg(height) FROM org
WHERE org.name IN works_for_alice;

The next example uses two common table expressions


in a single WITH clause. The following table records a
family tree:
CREATE TABLE family(
name TEXT PRIMARY KEY,
mom TEXT REFERENCES family,
dad TEXT REFERENCES family,
born DATETIME,
died DATETIME, -- NULL if still alive
-- other content
);

The "family" table is similar to the earlier "org" table


except that now there are two parents to each member.
We want to know all living ancestors of Alice, from
oldest to youngest. An ordinary common table
expression, "parent_of", is defined first. That ordinary
CTE is a view that can be used to find all parents of any
individual. That ordinary CTE is then used in the
"ancestor_of_alice" recursive CTE. The recursive CTE is
then used in the final query:
WITH RECURSIVE
parent_of(name, parent) AS
(SELECT name, mom FROM family UNION SELECT name, dad
ancestor_of_alice(name) AS
(SELECT parent FROM parent_of WHERE name='Alice'
UNION ALL
SELECT parent FROM parent_of JOIN ancestor_of_alice
SELECT family.name FROM ancestor_of_alice, family
WHERE ancestor_of_alice.name=family.name
AND died IS NULL
ORDER BY born;

Queries Against A Graph

A version control system (VCS) will typically store the


evolving versions of a project as a directed acyclic
graph (DAG). Call each version of the project a
"checkin". A single checkin can have zero or more
parents. Most checkins (except the first) have a single
parent, but in the case of a merge, a checkin might
have two or three or more parents. A schema to keep
track of checkins and the order in which they occur
might look something like this:
CREATE TABLE checkin(
id INTEGER PRIMARY KEY,
mtime INTEGER -- timestamp when this checkin occurred
);
CREATE TABLE derivedfrom(
xfrom INTEGER NOT NULL REFERENCES checkin, -- parent c
xto INTEGER NOT NULL REFERENCES checkin, -- derived
PRIMARY KEY(xfrom,xto)
);
CREATE INDEX derivedfrom_back ON derivedfrom(xto,xfrom);

This graph is acyclic. And we assume that the mtime of


every child checkin is no less than the mtime of all its
parents. But unlike the earlier examples, this graph
might have multiple paths of differing lengths between
any two checkins.

We want to know the twenty most recent ancestors in


time (out of the thousands and thousands of ancestors
in the whole DAG) for checkin "@BASELINE". (A query
similar to this is used by the Fossil VCS to show the N
most recent ancestors of a check. For example:
http://www.sqlite.org/src/timeline?p=trunk&n;=30.)
WITH RECURSIVE
ancestor(id,mtime) AS (
SELECT id, mtime FROM checkin WHERE id=@BASELINE
UNION
SELECT derivedfrom.xfrom, checkin.mtime
FROM ancestor, derivedfrom, checkin
WHERE ancestor.id=derivedfrom.xto
AND checkin.id=derivedfrom.xfrom
ORDER BY checkin.mtime DESC
LIMIT 20
)
SELECT * FROM checkin JOIN ancestor USING(id);

The "ORDER BY checkin.mtime DESC" term in the


recursive-select makes the query run much faster by
preventing it from following branches that merge
checkins from long ago. The ORDER BY forces the
recursive-select to focus on the most recent checkins,
the ones we want. Without the ORDER BY on the
recursive-select, one would be forced to compute the
complete set of thousands of ancestors, sort them all
by mtime, then take the top twenty. The ORDER BY
essentially sets up a priority queue that forces the
recursive query to look at the most recent ancestors
first, allowing the use of a LIMIT clause to restrict the
scope of the query to just the checkins of interest.

Controlling Depth-First Versus Breadth-First


Search Of a Tree Using ORDER BY

An ORDER BY clause on the recursive-select can be


used to control whether the search of a tree is depth-
first or breadth-first. To illustrate, we will use a
variation on the "org" table from an example above,
without the "height" column, and with some real data
inserted:
CREATE TABLE org(
name TEXT PRIMARY KEY,
boss TEXT REFERENCES org
) WITHOUT ROWID;
INSERT INTO org VALUES('Alice',NULL);
INSERT INTO org VALUES('Bob','Alice');
INSERT INTO org VALUES('Cindy','Alice');
INSERT INTO org VALUES('Dave','Bob');
INSERT INTO org VALUES('Emma','Bob');
INSERT INTO org VALUES('Fred','Cindy');
INSERT INTO org VALUES('Gail','Cindy');

Here is a query to show the tree structure in a breadth-


first pattern:
WITH RECURSIVE
under_alice(name,level) AS (
VALUES('Alice',0)
UNION ALL
SELECT org.name, under_alice.level+1
FROM org JOIN under_alice ON org.boss=under_alice.
ORDER BY 2
)
SELECT substr('..........',1,level*3) || name FROM under

The "ORDER BY 2" (which means the same as "ORDER


BY under_alice.level+1") causes higher levels in the
organization chart (with smaller "level" values) to be
processed first, resulting in a breadth-first search. The
output is:
Alice
...Bob
...Cindy
......Dave
......Emma
......Fred
......Gail

But if we change the ORDER BY clause to add the


"DESC" modifier, that will cause lower levels in the
organization (with larger "level" values) to be
processed first by the recursive-select, resulting in a
depth-first search:
WITH RECURSIVE
under_alice(name,level) AS (
VALUES('Alice',0)
UNION ALL
SELECT org.name, under_alice.level+1
FROM org JOIN under_alice ON org.boss=under_alice.
ORDER BY 2 DESC
)
SELECT substr('..........',1,level*3) || name FROM under

The output of this revised query is:


Alice
...Bob
......Dave
......Emma
...Cindy
......Fred
......Gail

When the ORDER BY clause is omitted from the


recursive-select, the queue behaves as a FIFO, which
results in a breadth-first search.

Outlandish Recursive Query Examples

The following query computes an approximation of the


Mandelbrot Set and outputs the result as ASCII-art:
WITH RECURSIVE
xaxis(x) AS (VALUES(-2.0) UNION ALL SELECT x+0.05 FROM
yaxis(y) AS (VALUES(-1.0) UNION ALL SELECT y+0.1 FROM
m(iter, cx, cy, x, y) AS (
SELECT 0, x, y, 0.0, 0.0 FROM xaxis, yaxis
UNION ALL
SELECT iter+1, cx, cy, x*x-y*y + cx, 2.0*x*y + cy FR
WHERE (x*x + y*y) < 4.0 AND iter<28
),
m2(iter, cx, cy) AS (
SELECT max(iter), cx, cy FROM m GROUP BY cx, cy
),
a(t) AS (
SELECT group_concat( substr(' .+*#', 1+min(iter/7,4)
FROM m2 GROUP BY cy
)
SELECT group_concat(rtrim(t),x'0a') FROM a;

In this query, the "xaxis" and "yaxis" CTEs define the


grid of points for which the Mandelbrot Set will be
approximated. Each row in the "m(iter,cx,cy,x,y)" CTE
means that after "iter" iterations, the Mandelbrot
iteration starting at cx,cy has reached point x,y. The
number of iterations in this example is limited to 28
(which severely limits the resolution of the
computation, but is sufficient for low-resolution ASCII-
art output). The "m2(iter,cx,cy)" CTE holds the
maximum number of iterations reached when starting
at point cx,cy. Finally, each row in the "a(t)" CTE holds
a string which is a single line of the output ASCII-art.
The SELECT statement at the end just queries the "a"
CTE to retrieve all lines of ASCII-art, one by one.

Running the query above in an SQLite command-line


shell results in the following output:
....#
..#*..
..+####+.
.......+####.... +
..##+*##########+.++++
.+.##################+.
.............+###################+.+
..++..#.....*#####################+.
...+#######++#######################.
....+*################################.
#############################################...
....+*################################.
...+#######++#######################.
..++..#.....*#####################+.
.............+###################+.+
.+.##################+.
..##+*##########+.++++
.......+####.... +
..+####+.
..#*..
....#
+.

This next query solves a Sudoku puzzle. The state of


the puzzle is defined by an 81-character string formed
by reading entries from the puzzle box row by row from
left to right and then from top to bottom. Blank squares
in the puzzle are denoted by a "." character. Thus the
input string:

53..7....6..195....98....6.8...6...34..8.3..17...2...6.6....2

Corresponds to a puzzle like this:

53 7
6 195
98 6
8 6 3
4 8 3 1
7 2 6
6 28
419 5
8 79

This is the query that solves the puzzle:


WITH RECURSIVE
input(sud) AS (
VALUES('53..7....6..195....98....6.8...6...34..8.3..
),
digits(z, lp) AS (
VALUES('1', 1)
UNION ALL SELECT
CAST(lp+1 AS TEXT), lp+1 FROM digits WHERE lp<9
),
x(s, ind) AS (
SELECT sud, instr(sud, '.') FROM input
UNION ALL
SELECT
substr(s, 1, ind-1) || z || substr(s, ind+1),
instr( substr(s, 1, ind-1) || z || substr(s, ind+1
FROM x, digits AS z
WHERE ind>0
AND NOT EXISTS (
SELECT 1
FROM digits AS lp
WHERE z.z = substr(s, ((ind-1)/9)*9 + lp, 1
OR z.z = substr(s, ((ind-1)%9) + (lp-1)*
OR z.z = substr(s, (((ind-1)/3) % 3) * 3
+ ((ind-1)/27) * 27 + lp
+ ((lp-1) / 3) * 6, 1)
)
)
SELECT s FROM x WHERE ind=0;

The "input" CTE defines the input puzzle. The "digits"


CTE defines a table that holds all digits between 1 and
9. The work of solving the puzzle is undertaken by the
"x" CTE. An entry in x(s,ind) means that the 81-
character string "s" is a valid sudoku puzzle (it has no
conflicts) and that the first unknown character is at
position "ind", or ind==0 if all character positions are
filled in. The goal, then, is to compute entries for "x"
with an "ind" of 0.

The solver works by adding new entries to the "x"


recursive table. Given prior entries, the recursive-
select tries to fill in a single new position with all
values between 1 and 9 that actually work in that
position. The complicated "NOT EXISTS" subquery is
the magic that figures out whether or not each
candidate "s" string is a valid sudoku puzzle or not.

The final answer is found by looking for a string with


ind==0. If the original sudoku problem did not have a
unique solution, then the query will return all possible
solutions. If the original problem was unsolvable, then
no rows will be returned. In this case, the unique
answer is:

53467891267219534819834256785976142342685379

The solution was computed in less than 300


milliseconds on a modern workstation.

Limitations And Caveats

The WITH clause cannot be used within a CREATE


TRIGGER.

The WITH clause must appear at the beginning of a


top-level SELECT statement or at the beginning of a
subquery. The WITH clause cannot be prepended to
the second or subsequent SELECT statement of a
compound select.

The SQL:1999 spec requires that the RECURSIVE


keyword follow WITH in any WITH clause that
includes a recursive common table expression.
However, for compatibility with SqlServer and
Oracle, SQLite does not enforce this rule.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
PRAGMA Statements
The PRAGMA statement is an SQL extension specific to
SQLite and used to modify the operation of the SQLite
library or to query the SQLite library for internal (non-
table) data. The PRAGMA statement is issued using the
same interface as other SQLite commands (e.g.
SELECT, INSERT) but is different in the following
important respects:

Specific pragma statements may be removed and


others added in future releases of SQLite. There is
no guarantee of backwards compatibility.
No error messages are generated if an unknown
pragma is issued. Unknown pragmas are simply
ignored. This means if there is a typo in a pragma
statement the library does not inform the user of the
fact.
Some pragmas take effect during the SQL
compilation stage, not the execution stage. This
means if using the C-language sqlite3_prepare(),
sqlite3_step(), sqlite3_finalize() API (or similar in a
wrapper interface), the pragma may run during the
sqlite3_prepare() call, not during the sqlite3_step()
call as normal SQL statements do. Or the pragma
might run during sqlite3_step() just like normal SQL
statements. Whether or not the pragma runs during
sqlite3_prepare() or sqlite3_step() depends on the
pragma and on the specific release of SQLite.
The pragma command is specific to SQLite and is
very unlikely to be compatible with any other SQL
database engine.

The C-language API for SQLite provides the


SQLITE_FCNTL_PRAGMA file control which gives VFS
implementations the opportunity to add new PRAGMA
statements or to override the meaning of built-in
PRAGMA statements.
PRAGMA command syntax

pragma-stmt: hide

pragma-value: hide

signed-number: show

A pragma can take either zero or one argument. The


argument is may be either in parentheses or it may be
separated from the pragma name by an equal sign. The
two syntaxes yield identical results. In many pragmas,
the argument is a boolean. The boolean can be one of:

1 yes true on
0 no false off

Keyword arguments can optionally appear in quotes.


(Example: 'yes' [FALSE].) Some pragmas takes a string
literal as their argument. When pragma takes a
keyword argument, it will usually also take a numeric
equivalent as well. For example, "0" and "no" mean the
same thing, as does "1" and "yes". When querying the
value of a setting, many pragmas return the number
rather than the keyword.

A pragma may have an optional schema-name before


the pragma name. The schema-name is the name of
an ATTACH-ed database or "main" or "temp" for the
main and the TEMP databases. If the optional schema
name is omitted, "main" is assumed. In some pragmas,
the schema name is meaningless and is simply
ignored. In the documentation below, pragmas for
which the schema name is meaningful are shown with
a "schema." prefix.
List Of PRAGMAs

Notes:

1. Pragmas whose names are struck through are


deprecated. Do not use them. They exist for
historical compatibility.
2. These pragmas are used for debugging SQLite and
are only available when SQLite is compiled using
SQLITE_DEBUG.
3. These pragmas are used for testing SQLite and are
not recommended for use in application programs.

PRAGMA schema.application_id;
PRAGMA schema.application_id = integer ;

The application_id PRAGMA is used to query or set the


32-bit unsigned big-endian "Application ID" integer
located at offset 68 into the database header.
Applications that use SQLite as their application file-
format should set the Application ID integer to a unique
integer so that utilities such as file(1) can determine
the specific file type rather than just reporting "SQLite3
Database". A list of assigned application IDs can be
seen by consulting the magic.txt file in the SQLite
source repository.

See also the user_version pragma.


PRAGMA schema.auto_vacuum;
PRAGMA schema.auto_vacuum = 0 | NONE | 1 |
FULL | 2 | INCREMENTAL;

Query or set the auto-vacuum status in the database.

The default setting for auto-vacuum is 0 or "none",


unless the SQLITE_DEFAULT_AUTOVACUUM compile-
time option is used. The "none" setting means that
auto-vacuum is disabled. When auto-vacuum is
disabled and data is deleted data from a database, the
database file remains the same size. Unused database
file pages are added to a "freelist" and reused for
subsequent inserts. So no database file space is lost.
However, the database file does not shrink. In this
mode the VACUUM command can be used to rebuild the
entire database file and thus reclaim unused disk
space.

When the auto-vacuum mode is 1 or "full", the freelist


pages are moved to the end of the database file and
the database file is truncated to remove the freelist
pages at every transaction commit. Note, however, that
auto-vacuum only truncates the freelist pages from the
file. Auto-vacuum does not defragment the database
nor repack individual database pages the way that the
VACUUM command does. In fact, because it moves
pages around within the file, auto-vacuum can actually
make fragmentation worse.

Auto-vacuuming is only possible if the database stores


some additional information that allows each database
page to be traced backwards to its referrer. Therefore,
auto-vacuuming must be turned on before any tables
are created. It is not possible to enable or disable auto-
vacuum after a table has been created.

When the value of auto-vacuum is 2 or "incremental"


then the additional information needed to do auto-
vacuuming is stored in the database file but auto-
vacuuming does not occur automatically at each
commit as it does with auto_vacuum=full. In
incremental mode, the separate incremental_vacuum
pragma must be invoked to cause the auto-vacuum to
occur.

The database connection can be changed between full


and incremental autovacuum mode at any time.
However, changing from "none" to "full" or
"incremental" can only occur when the database is new
(no tables have yet been created) or by running the
VACUUM command. To change auto-vacuum modes,
first use the auto_vacuum pragma to set the new
desired mode, then invoke the VACUUM command to
reorganize the entire database file. To change from
"full" or "incremental" back to "none" always requires
running VACUUM even on an empty database.

When the auto_vacuum pragma is invoked with no


arguments, it returns the current auto_vacuum mode.
PRAGMA automatic_index;
PRAGMA automatic_index = boolean;

Query, set, or clear the automatic indexing capability.

Automatic indexing is enabled by default as of version


3.7.17 (dateof:3.7.17]), but this might change in future
releases of SQLite.

PRAGMA busy_timeout;
PRAGMA busy_timeout = milliseconds;

Query or change the setting of the busy timeout. This


pragma is an alternative to the sqlite3_busy_timeout()
C-language interface which is made available as a
pragma for use with language bindings that do not
provide direct access to sqlite3_busy_timeout().

Each database connection can only have a single busy


handler. This PRAGMA sets the busy handler for the
process, possibly overwriting any previously set busy
handler.

PRAGMA schema.cache_size;
PRAGMA schema.cache_size = pages;
PRAGMA schema.cache_size = -kibibytes;

Query or change the suggested maximum number of


database disk pages that SQLite will hold in memory at
once per open database file. Whether or not this
suggestion is honored is at the discretion of the
Application Defined Page Cache. The default page cache
that is built into SQLite honors the request, however
alternative application-defined page cache
implementations may choose to interpret the suggested
cache size in different ways or to ignore it all together.
The default suggested cache size is -2000, which
means the cache size is limited to 2048000 bytes of
memory. The default suggested cache size can be
altered using the SQLITE_DEFAULT_CACHE_SIZE
compile-time options. The TEMP database has a default
suggested cache size of 0 pages.

If the argument N is positive then the suggested cache


size is set to N. If the argument N is negative, then the
number of cache pages is adjusted to use
approximately abs(N*1024) bytes of memory.
Backwards compatibility note: The behavior of
cache_size with a negative N was different in prior to
version 3.7.10 (2012-01-16). In version 3.7.9 and
earlier, the number of pages in the cache was set to the
absolute value of N.

When you change the cache size using the cache_size


pragma, the change only endures for the current
session. The cache size reverts to the default value
when the database is closed and reopened.

PRAGMA cache_spill;
PRAGMA cache_spill=boolean;
PRAGMA schema.cache_spill=N;

The cache_spill pragma enables or disables the ability


of the pager to spill dirty cache pages to the database
file in the middle of a transaction. Cache_spill is
enabled by default and most applications should leave
it that way as cache spilling is usually advantageous.
However, a cache spill has the side-effect of acquiring
an EXCLUSIVE lock on the database file. Hence, some
applications that have large long-running transactions
may want to disable cache spilling in order to prevent
the application from acquiring an exclusive lock on the
database until the moment that the transaction
COMMITs.

The "PRAGMA cache_spill=N" form of this pragma sets


a minimum cache size threshold required for spilling to
occur. The number of pages in cache must exceed both
the cache_spill threshold and the maximum cache size
set by the PRAGMA cache_size statement in order for
spilling to occur.

The "PRAGMA cache_spill=boolean" form of this pragma


applies across all databases attached to the database
connection. But the "PRAGMA cache_spill=N" form of
this statement only applies to the "main" schema or
whatever other schema is specified as part of the
statement.

PRAGMA case_sensitive_like = boolean;


The default behavior of the LIKE operator is to ignore
case for ASCII characters. Hence, by default 'a' LIKE
'A' is true. The case_sensitive_like pragma installs a
new application-defined LIKE function that is either
case sensitive or insensitive depending on the value of
the case_sensitive_like pragma. When
case_sensitive_like is disabled, the default LIKE
behavior is expressed. When case_sensitive_like is
enabled, case becomes significant. So, for example, 'a'
LIKE 'A' is false but 'a' LIKE 'a' is still true.

This pragma uses sqlite3_create_function() to overload


the LIKE and GLOB functions, which may override
previous implementations of LIKE and GLOB registered
by the application. This pragma only changes the
behavior of the SQL LIKE operator. It does not change
the behavior of the sqlite3_strlike() C-language
interface, which is always case insensitive.

PRAGMA cell_size_check
PRAGMA cell_size_check = boolean;

The cell_size_check pragma enables or disables


additional sanity checking on database b-tree pages as
they are initially read from disk. With cell size checking
enabled, database corruption is detected earlier and is
less likely to "spread". However, there is a small
performance hit for doing the extra checks and so cell
size checking is turned off by default.
PRAGMA checkpoint_fullfsync
PRAGMA checkpoint_fullfsync = boolean;

Query or change the fullfsync flag for checkpoint


operations. If this flag is set, then the F_FULLFSYNC
syncing method is used during checkpoint operations
on systems that support F_FULLFSYNC. The default
value of the checkpoint_fullfsync flag is off. Only Mac
OS-X supports F_FULLFSYNC.

If the fullfsync flag is set, then the F_FULLFSYNC


syncing method is used for all sync operations and the
checkpoint_fullfsync setting is irrelevant.

PRAGMA collation_list;

Return a list of the collating sequences defined for the


current database connection.

PRAGMA compile_options;

This pragma returns the names of compile-time options


used when building SQLite, one option per row. The
"SQLITE_" prefix is omitted from the returned option
names. See also the sqlite3_compileoption_get()
C/C++ interface and the sqlite_compileoption_get()
SQL functions.

PRAGMA count_changes;
PRAGMA count_changes = boolean;

Query or change the count-changes flag. Normally,


when the count-changes flag is not set, INSERT,
UPDATE and DELETE statements return no data. When
count-changes is set, each of these commands returns
a single row of data consisting of one integer value -
the number of rows inserted, modified or deleted by the
command. The returned change count does not include
any insertions, modifications or deletions performed by
triggers, or any changes made automatically by foreign
key actions.

Another way to get the row change counts is to use the


sqlite3_changes() or sqlite3_total_changes()
interfaces. There is a subtle different, though. When an
INSERT, UPDATE, or DELETE is run against a view using
an INSTEAD OF trigger, the count_changes pragma
reports the number of rows in the view that fired the
trigger, whereas sqlite3_changes() and
sqlite3_total_changes() do not.

This pragma is deprecated and exists for backwards


compatibility only. New applications should avoid using
this pragma. Older applications should discontinue use
of this pragma at the earliest opportunity. This pragma
may be omitted from the build when SQLite is compiled
using SQLITE_OMIT_DEPRECATED.

PRAGMA data_store_directory;
PRAGMA data_store_directory = 'directory-name';

Query or change the value of the


sqlite3_data_directory global variable, which windows
operating-system interface backends use to determine
where to store database files specified using a relative
pathname.

Changing the data_store_directory setting is not


threadsafe. Never change the data_store_directory
setting if another thread within the application is
running any SQLite interface at the same time. Doing
so results in undefined behavior. Changing the
data_store_directory setting writes to the
sqlite3_data_directory global variable and that global
variable is not protected by a mutex.

This facility is provided for WinRT which does not have


an OS mechanism for reading or changing the current
working directory. The use of this pragma in any other
context is discouraged and may be disallowed in future
releases.

This pragma is deprecated and exists for backwards


compatibility only. New applications should avoid using
this pragma. Older applications should discontinue use
of this pragma at the earliest opportunity. This pragma
may be omitted from the build when SQLite is compiled
using SQLITE_OMIT_DEPRECATED.

PRAGMA schema.data_version;
The "PRAGMA data_version" command provides an
indication that the database file has been modified.
Interactive programs that hold database content in
memory or that display database content on-screen can
use the PRAGMA data_version command to determine if
they need to flush and reload their memory or update
the screen display.

The integer values returned by two invocations of


"PRAGMA data_version" from the same connection will
be different if changes were committed to the database
by any other connection in the interim. The "PRAGMA
data_version" value is unchanged for commits made on
the same database connection. The behavior of
"PRAGMA data_version" is the same for all database
connections, including database connections in
separate processes and shared cache database
connections.

The "PRAGMA data_version" value is a local property of


each database connection and so values returned by
two concurrent invocations of "PRAGMA data_version"
on separate database connections are often different
even though the underlying database is identical. It is
only meaningful to compare the "PRAGMA
data_version" values returned by the same database
connection at two different points in time.

PRAGMA database_list;
This pragma works like a query to return one row for
each database attached to the current database
connection. The second column is the "main" for the
main database file, "temp" for the database file used to
store TEMP objects, or the name of the ATTACHed
database for other database files. The third column is
the name of the database file itself, or an empty string
if the database is not associated with a file.

PRAGMA schema.default_cache_size;
PRAGMA schema.default_cache_size = Number-of-
pages;

This pragma queries or sets the suggested maximum


number of pages of disk cache that will be allocated per
open database file. The difference between this pragma
and cache_size is that the value set here persists
across database connections. The value of the default
cache size is stored in the 4-byte big-endian integer
located at offset 48 in the header of the database file.

This pragma is deprecated and exists for backwards


compatibility only. New applications should avoid using
this pragma. Older applications should discontinue use
of this pragma at the earliest opportunity. This pragma
may be omitted from the build when SQLite is compiled
using SQLITE_OMIT_DEPRECATED.

PRAGMA defer_foreign_keys
PRAGMA defer_foreign_keys = boolean;
When the defer_foreign_keys PRAGMA is on,
enforcement of all foreign key constraints is delayed
until the outermost transaction is committed. The
defer_foreign_keys pragma defaults to OFF so that
foreign key constraints are only deferred if they are
created as "DEFERRABLE INITIALLY DEFERRED". The
defer_foreign_keys pragma is automatically switched
off at each COMMIT or ROLLBACK. Hence, the
defer_foreign_keys pragma must be separately enabled
for each transaction. This pragma is only meaningful if
foreign key constraints are enabled, of course.

The
sqlite3_db_status(db,SQLITE_DBSTATUS_DEFERRED_FKS
C-language interface can be used during a transaction
to determine if there are deferred and unresolved
foreign key constraints.

PRAGMA empty_result_callbacks;
PRAGMA empty_result_callbacks = boolean;

Query or change the empty-result-callbacks flag.

The empty-result-callbacks flag affects the


sqlite3_exec() API only. Normally, when the empty-
result-callbacks flag is cleared, the callback function
supplied to the sqlite3_exec() is not invoked for
commands that return zero rows of data. When empty-
result-callbacks is set in this situation, the callback
function is invoked exactly once, with the third
parameter set to 0 (NULL). This is to enable programs
that use the sqlite3_exec() API to retrieve column-
names even when a query returns no data.

This pragma is deprecated and exists for backwards


compatibility only. New applications should avoid using
this pragma. Older applications should discontinue use
of this pragma at the earliest opportunity. This pragma
may be omitted from the build when SQLite is compiled
using SQLITE_OMIT_DEPRECATED.

PRAGMA encoding;
PRAGMA encoding = "UTF-8";
PRAGMA encoding = "UTF-16";
PRAGMA encoding = "UTF-16le";
PRAGMA encoding = "UTF-16be";

In first form, if the main database has already been


created, then this pragma returns the text encoding
used by the main database, one of "UTF-8", "UTF-16le"
(little-endian UTF-16 encoding) or "UTF-16be" (big-
endian UTF-16 encoding). If the main database has not
already been created, then the value returned is the
text encoding that will be used to create the main
database, if it is created by this session.

The second through fifth forms of this pragma set the


encoding that the main database will be created with if
it is created by this session. The string "UTF-16" is
interpreted as "UTF-16 encoding using native machine
byte-ordering". It is not possible to change the text
encoding of a database after it has been created and
any attempt to do so will be silently ignored.

Once an encoding has been set for a database, it


cannot be changed.

Databases created by the ATTACH command always use


the same encoding as the main database. An attempt to
ATTACH a database with a different text encoding from
the "main" database will fail.

PRAGMA schema.foreign_key_check;
PRAGMA schema.foreign_key_check(table-name);

The foreign_key_check pragma checks the database, or


the table called "table-name", for foreign key
constraints that are violated and returns one row of
output for each violation. There are four columns in
each result row. The first column is the name of the
table that contains the REFERENCES clause. The second
column is the rowid of the row that contains the invalid
REFERENCES clause. The third column is the name of
the table that is referred to. The fourth column is the
index of the specific foreign key constraint that failed.
The fourth column in the output of the
foreign_key_check pragma is the same integer as the
first column in the output of the foreign_key_list
pragma. When a "table-name" is specified, the only
foreign key constraints checked are those created by
REFERENCES clauses in the CREATE TABLE statement
for table-name.

PRAGMA foreign_key_list(table-name);

This pragma returns one row for each foreign key


constraint created by a REFERENCES clause in the
CREATE TABLE statement of table "table-name".

PRAGMA foreign_keys;
PRAGMA foreign_keys = boolean;

Query, set, or clear the enforcement of foreign key


constraints.

This pragma is a no-op within a transaction; foreign


key constraint enforcement may only be enabled or
disabled when there is no pending BEGIN or
SAVEPOINT.

Changing the foreign_keys setting affects the execution


of all statements prepared using the database
connection, including those prepared before the setting
was changed. Any existing statements prepared using
the legacy sqlite3_prepare() interface may fail with an
SQLITE_SCHEMA error after the foreign_keys setting is
changed.

As of SQLite version 3.6.19, the default setting for


foreign key enforcement is OFF. However, that might
change in a future release of SQLite. The default
setting for foreign key enforcement can be specified at
compile-time using the
SQLITE_DEFAULT_FOREIGN_KEYS preprocessor macro.
To minimize future problems, applications should set
the foreign key enforcement flag as required by the
application and not depend on the default setting.

PRAGMA schema.freelist_count;

Return the number of unused pages in the database


file.

PRAGMA full_column_names;
PRAGMA full_column_names = boolean;

Query or change the full_column_names flag. This flag


together with the short_column_names flag determine
the way SQLite assigns names to result columns of
SELECT statements. Result columns are named by
applying the following rules in order:

1. If there is an AS clause on the result, then the name


of the column is the right-hand side of the AS
clause.

2. If the result is a general expression, not a just the


name of a source table column, then the name of
the result is a copy of the expression text.
3. If the short_column_names pragma is ON, then the
name of the result is the name of the source table
column without the source table name prefix:
COLUMN.

4. If both pragmas short_column_names and


full_column_names are OFF then case (2) applies.

5. The name of the result column is a combination of


the source table and source column name:
TABLE.COLUMN

This pragma is deprecated and exists for backwards


compatibility only. New applications should avoid using
this pragma. Older applications should discontinue use
of this pragma at the earliest opportunity. This pragma
may be omitted from the build when SQLite is compiled
using SQLITE_OMIT_DEPRECATED.

PRAGMA fullfsync
PRAGMA fullfsync = boolean;

Query or change the fullfsync flag. This flag determines


whether or not the F_FULLFSYNC syncing method is
used on systems that support it. The default value of
the fullfsync flag is off. Only Mac OS X supports
F_FULLFSYNC.

See also checkpoint_fullfsync.


PRAGMA ignore_check_constraints = boolean;

This pragma enables or disables the enforcement of


CHECK constraints. The default setting is off, meaning
that CHECK constraints are enforced by default.

PRAGMA schema.incremental_vacuum(N);

The incremental_vacuum pragma causes up to N pages


to be removed from the freelist. The database file is
truncated by the same amount. The
incremental_vacuum pragma has no effect if the
database is not in auto_vacuum=incremental mode or
if there are no pages on the freelist. If there are fewer
than N pages on the freelist, or if N is less than 1, or if
N is omitted entirely, then the entire freelist is cleared.

PRAGMA schema.index_info(index-name);

This pragma returns one row for each key column in


the named index. A key column is a column that is
actually named in the CREATE INDEX index statement
or UNIQUE constraint or PRIMARY KEY constraint that
created the index. Index entries also usually contain
auxiliary columns that point back to the table row
being indexed. The auxiliary index-columns are not
shown by the index_info pragma, but they are listed by
the index_xinfo pragma.

Output columns from the index_info pragma are as


follows:

1. The rank of the column within the index. (0 means


left-most.)
2. The rank of the column within the table being
indexed.
3. The name of the column being indexed.

PRAGMA schema.index_list(table-name);

This pragma returns one row for each index associated


with the given table.

Output columns from the index_list pragma are as


follows:

1. A sequence number assigned to each index for


internal tracking purposes.
2. The name of the index.
3. "1" if the index is UNIQUE and "0" if not.
4. "c" if the index was created by a CREATE INDEX
statement, "u" if the index was created by a UNIQUE
constraint, or "pk" if the index was created by a
PRIMARY KEY constraint.
5. "1" if the index is a partial index and "0" if not.

PRAGMA schema.index_xinfo(index-name);

This pragma returns information about every column in


an index. Unlike this index_info pragma, this pragma
returns information about every column in the index,
not just the key columns. (A key column is a column
that is actually named in the CREATE INDEX index
statement or UNIQUE constraint or PRIMARY KEY
constraint that created the index. Auxiliary columns are
additional columns needed to locate the table entry
that corresponds to each index entry.)

Output columns from the index_xinfo pragma are as


follows:

1. The rank of the column within the index. (0 means


left-most. Key columns come before auxiliary
columns.)
2. The rank of the column within the table being
indexed, or -1 if the index-column is the rowid of the
table being indexed.
3. The name of the column being indexed, or NULL if
the index-column is the rowid of the table being
indexed.
4. 1 if the index-column is sorted in reverse (DESC)
order by the index and 0 otherwise.
5. The name for the collating sequence used to
compare values in the index-column.
6. 1 if the index-column is a key column and 0 if the
index-column is an auxiliary column.

PRAGMA schema.integrity_check;
PRAGMA schema.integrity_check(N)
This pragma does an integrity check of the entire
database. The integrity_check pragma looks for out-of-
order records, missing pages, malformed records,
missing index entries, and UNIQUE and NOT NULL
constraint errors. If the integrity_check pragma finds
problems, strings are returned (as multiple rows with a
single column per row) which describe the problems.
Pragma integrity_check will return at most N errors
before the analysis quits, with N defaulting to 100. If
pragma integrity_check finds no errors, a single row
with the value 'ok' is returned.

PRAGMA integrity_check does not find FOREIGN KEY


errors. Use the PRAGMA foreign_key_check command
for to find errors in FOREIGN KEY constraints.

See also the PRAGMA quick_check command which


does most of the checking of PRAGMA integrity_check
but runs much faster.

PRAGMA schema.journal_mode;
PRAGMA schema.journal_mode = DELETE |
TRUNCATE | PERSIST | MEMORY | WAL | OFF

This pragma queries or sets the journal mode for


databases associated with the current database
connection.

The first form of this pragma queries the current


journaling mode for database. When database is
omitted, the "main" database is queried.
The second form changes the journaling mode for
"database" or for all attached databases if "database" is
omitted. The new journal mode is returned. If the
journal mode could not be changed, the original journal
mode is returned.

The DELETE journaling mode is the normal behavior. In


the DELETE mode, the rollback journal is deleted at the
conclusion of each transaction. Indeed, the delete
operation is the action that causes the transaction to
commit. (See the document titled Atomic Commit In
SQLite for additional detail.)

The TRUNCATE journaling mode commits transactions


by truncating the rollback journal to zero-length
instead of deleting it. On many systems, truncating a
file is much faster than deleting the file since the
containing directory does not need to be changed.

The PERSIST journaling mode prevents the rollback


journal from being deleted at the end of each
transaction. Instead, the header of the journal is
overwritten with zeros. This will prevent other database
connections from rolling the journal back. The PERSIST
journaling mode is useful as an optimization on
platforms where deleting or truncating a file is much
more expensive than overwriting the first block of a file
with zeros. See also: PRAGMA journal_size_limit and
SQLITE_DEFAULT_JOURNAL_SIZE_LIMIT.

The MEMORY journaling mode stores the rollback


journal in volatile RAM. This saves disk I/O but at the
expense of database safety and integrity. If the
application using SQLite crashes in the middle of a
transaction when the MEMORY journaling mode is set,
then the database file will very likely go corrupt.

The WAL journaling mode uses a write-ahead log


instead of a rollback journal to implement transactions.
The WAL journaling mode is persistent; after being set
it stays in effect across multiple database connections
and after closing and reopening the database. A
database in WAL journaling mode can only be accessed
by SQLite version 3.7.0 (2010-07-21) or later.

The OFF journaling mode disables the rollback journal


completely. No rollback journal is ever created and
hence there is never a rollback journal to delete. The
OFF journaling mode disables the atomic commit and
rollback capabilities of SQLite. The ROLLBACK
command no longer works; it behaves in an undefined
way. Applications must avoid using the ROLLBACK
command when the journal mode is OFF. If the
application crashes in the middle of a transaction when
the OFF journaling mode is set, then the database file
will very likely go corrupt.

Note that the journal_mode for an in-memory database


is either MEMORY or OFF and can not be changed to a
different value. An attempt to change the journal_mode
of an in-memory database to any setting other than
MEMORY or OFF is ignored. Note also that the
journal_mode cannot be changed while a transaction is
active.

PRAGMA schema.journal_size_limit
PRAGMA schema.journal_size_limit = N ;

If a database connection is operating in exclusive


locking mode or in persistent journal mode (PRAGMA
journal_mode=persist) then after committing a
transaction the rollback journal file may remain in the
file-system. This increases performance for subsequent
transactions since overwriting an existing file is faster
than append to a file, but it also consumes file-system
space. After a large transaction (e.g. a VACUUM), the
rollback journal file may consume a very large amount
of space.

Similarly, in WAL mode, the write-ahead log file is not


truncated following a checkpoint. Instead, SQLite
reuses the existing file for subsequent WAL entries
since overwriting is faster than appending.

The journal_size_limit pragma may be used to limit the


size of rollback-journal and WAL files left in the file-
system after transactions or checkpoints. Each time a
transaction is committed or a WAL file resets, SQLite
compares the size of the rollback journal file or WAL
file left in the file-system to the size limit set by this
pragma and if the journal or WAL file is larger it is
truncated to the limit.
The second form of the pragma listed above is used to
set a new limit in bytes for the specified database. A
negative number implies no limit. To always truncate
rollback journals and WAL files to their minimum size,
set the journal_size_limit to zero. Both the first and
second forms of the pragma listed above return a single
result row containing a single integer column - the
value of the journal size limit in bytes. The default
journal size limit is -1 (no limit). The
SQLITE_DEFAULT_JOURNAL_SIZE_LIMIT preprocessor
macro can be used to change the default journal size
limit at compile-time.

This pragma only operates on the single database


specified prior to the pragma name (or on the "main"
database if no database is specified.) There is no way
to change the journal size limit on all attached
databases using a single PRAGMA statement. The size
limit must be set separately for each attached
database.

PRAGMA legacy_file_format;
PRAGMA legacy_file_format = boolean

This pragma sets or queries the value of the


legacy_file_format flag. When this flag is on, new
SQLite databases are created in a file format that is
readable and writable by all versions of SQLite going
back to 3.0.0. When the flag is off, new databases are
created using the latest file format which might not be
readable or writable by versions of SQLite prior to
3.3.0.

When the legacy_file_format pragma is issued with no


argument, it returns the setting of the flag. This
pragma does not tell which file format the current
database is using; it tells what format will be used by
any newly created databases.

The legacy_file_format pragma is initialized to OFF


when an existing database in the newer file format is
first opened.

The default file format is set by the


SQLITE_DEFAULT_FILE_FORMAT compile-time option.

PRAGMA schema.locking_mode;
PRAGMA schema.locking_mode = NORMAL |
EXCLUSIVE

This pragma sets or queries the database connection


locking-mode. The locking-mode is either NORMAL or
EXCLUSIVE.

In NORMAL locking-mode (the default unless


overridden at compile-time using
SQLITE_DEFAULT_LOCKING_MODE), a database
connection unlocks the database file at the conclusion
of each read or write transaction. When the locking-
mode is set to EXCLUSIVE, the database connection
never releases file-locks. The first time the database is
read in EXCLUSIVE mode, a shared lock is obtained and
held. The first time the database is written, an
exclusive lock is obtained and held.

Database locks obtained by a connection in EXCLUSIVE


mode may be released either by closing the database
connection, or by setting the locking-mode back to
NORMAL using this pragma and then accessing the
database file (for read or write). Simply setting the
locking-mode to NORMAL is not enough - locks are not
released until the next time the database file is
accessed.

There are three reasons to set the locking-mode to


EXCLUSIVE.

1. The application wants to prevent other processes


from accessing the database file.
2. The number of system calls for filesystem operations
is reduced, possibly resulting in a small performance
increase.
3. WAL databases can be accessed in EXCLUSIVE mode
without the use of shared memory. (Additional
information)

When the locking_mode pragma specifies a particular


database, for example:

PRAGMA main.locking_mode=EXCLUSIVE;

Then the locking mode applies only to the named


database. If no database name qualifier precedes the
"locking_mode" keyword then the locking mode is
applied to all databases, including any new databases
added by subsequent ATTACH commands.

The "temp" database (in which TEMP tables and indices


are stored) and in-memory databases always uses
exclusive locking mode. The locking mode of temp and
in-memory databases cannot be changed. All other
databases use the normal locking mode by default and
are affected by this pragma.

If the locking mode is EXCLUSIVE when first entering


WAL journal mode, then the locking mode cannot be
changed to NORMAL until after exiting WAL journal
mode. If the locking mode is NORMAL when first
entering WAL journal mode, then the locking mode can
be changed between NORMAL and EXCLUSIVE and back
again at any time and without needing to exit WAL
journal mode.

PRAGMA schema.max_page_count;
PRAGMA schema.max_page_count = N;

Query or set the maximum number of pages in the


database file. Both forms of the pragma return the
maximum page count. The second form attempts to
modify the maximum page count. The maximum page
count cannot be reduced below the current database
size.
PRAGMA schema.mmap_size;
PRAGMA schema.mmap_size=N

Query or change the maximum number of bytes that


are set aside for memory-mapped I/O on a single
database. The first form (without an argument) queries
the current limit. The second form (with a numeric
argument) sets the limit for the specified database, or
for all databases if the optional database name is
omitted. In the second form, if the database name is
omitted, the limit that is set becomes the default limit
for all databases that are added to the database
connection by subsequent ATTACH statements.

The argument N is the maximum number of bytes of


the database file that will be accessed using memory-
mapped I/O. If N is zero then memory mapped I/O is
disabled. If N is negative, then the limit reverts to the
default value determined by the most recent
sqlite3_config(SQLITE_CONFIG_MMAP_SIZE), or to the
compile time default determined by
SQLITE_DEFAULT_MMAP_SIZE if not start-time limit
has been set.

The PRAGMA mmap_size statement will never increase


the amount of address space used for memory-mapped
I/O above the hard limit set by the
SQLITE_MAX_MMAP_SIZE compile-time option, nor the
hard limit set start-time by the second argument to
sqlite3_config(SQLITE_CONFIG_MMAP_SIZE)
The size of the memory-mapped I/O region cannot be
changed while the memory-mapped I/O region is in
active use, to avoid unmapping memory out from under
running SQL statements. For this reason, the
mmap_size pragma may be a no-op if the prior
mmap_size is non-zero and there are other SQL
statements running concurrently on the same database
connection.

PRAGMA schema.page_count;

Return the total number of pages in the database file.

PRAGMA schema.page_size;
PRAGMA schema.page_size = bytes;

Query or set the page size of the database. The page


size must be a power of two between 512 and 65536
inclusive.

When a new database is created, SQLite assigned a


page size to the database based on platform and
filesystem. For many years, the default page size was
almost always 1024 bytes, but beginning with SQLite
version 3.12.0 (2016-03-29), the default page size
increased to 4096.

The page_size pragma will only set in the page size if it


is issued before any other SQL statements that cause
I/O against the database file. SQL statements that
cause I/O against the database file include "CREATE",
"SELECT", "BEGIN IMMEDIATE", and "PRAGMA
journal_mode=WAL". If the page_size pragma is used
to specify a new page size just prior to running the
VACUUM command and if the database is not in WAL
journal mode then VACUUM will change the page size
to the new value.

The SQLITE_DEFAULT_PAGE_SIZE compile-time option


can be used to change the default page size assigned to
new databases.

PRAGMA parser_trace = boolean;

If SQLite has been compiled with the SQLITE_DEBUG


compile-time option, then the parser_trace pragma can
be used to turn on tracing for the SQL parser used
internally by SQLite. This feature is used for debugging
SQLite itself.

This pragma is intended for use when debugging SQLite


itself. It is only available when the SQLITE_DEBUG
compile-time option is used.

PRAGMA query_only;
PRAGMA query_only = boolean;

The query_only pragma prevents all changes to


database files when enabled.
PRAGMA schema.quick_check;
PRAGMA schema.quick_check(N)

The pragma is like integrity_check except that it does


not verify UNIQUE and NOT NULL constraints and does
not verify that index content matches table content. By
skipping UNIQUE and NOT NULL and index consistency
checks, quick_check is able to run much faster than
integrity_check. Otherwise the two pragmas are the
same.

PRAGMA read_uncommitted;
PRAGMA read_uncommitted = boolean;

Query, set, or clear READ UNCOMMITTED isolation. The


default isolation level for SQLite is SERIALIZABLE. Any
process or thread can select READ UNCOMMITTED
isolation, but SERIALIZABLE will still be used except
between connections that share a common page and
schema cache. Cache sharing is enabled using the
sqlite3_enable_shared_cache() API. Cache sharing is
disabled by default.

See SQLite Shared-Cache Mode for additional


information.

PRAGMA recursive_triggers;
PRAGMA recursive_triggers = boolean;

Query, set, or clear the recursive trigger capability.


Changing the recursive_triggers setting affects the
execution of all statements prepared using the
database connection, including those prepared before
the setting was changed. Any existing statements
prepared using the legacy sqlite3_prepare() interface
may fail with an SQLITE_SCHEMA error after the
recursive_triggers setting is changed.

Prior to SQLite version 3.6.18 (2009-09-11), recursive


triggers were not supported. The behavior of SQLite
was always as if this pragma was set to OFF. Support
for recursive triggers was added in version 3.6.18 but
was initially turned OFF by default, for compatibility.
Recursive triggers may be turned on by default in
future versions of SQLite.

The depth of recursion for triggers has a hard upper


limit set by the SQLITE_MAX_TRIGGER_DEPTH
compile-time option and a run-time limit set by
sqlite3_limit(db,SQLITE_LIMIT_TRIGGER_DEPTH,...).

PRAGMA reverse_unordered_selects;
PRAGMA reverse_unordered_selects = boolean;

When enabled, this PRAGMA causes many SELECT


statements without an ORDER BY clause to emit their
results in the reverse order from what they normally
would. This can help debug applications that are
making invalid assumptions about the result order. The
reverse_unordered_selects pragma works for most
SELECT statements, however the query planner may
sometimes choose an algorithm that is not easily
reversed, in which case the output will appear in the
same order regardless of the
reverse_unordered_selects setting.

SQLite makes no guarantees about the order of results


if a SELECT omits the ORDER BY clause. Even so, the
order of results does not change from one run to the
next, and so many applications mistakenly come to
depend on the arbitrary output order whatever that
order happens to be. However, sometimes new versions
of SQLite will contain optimizer enhancements that will
cause the output order of queries without ORDER BY
clauses to shift. When that happens, applications that
depend on a certain output order might malfunction. By
running the application multiple times with this pragma
both disabled and enabled, cases where the application
makes faulty assumptions about output order can be
identified and fixed early, reducing problems that might
be caused by linking against a different version of
SQLite.

PRAGMA schema.schema_version;
PRAGMA schema.schema_version = integer ;

The schema_version pragma will to get or set the value


of the schema-version integer at offset 40 in the
database header.
SQLite automatically increments the schema-version
whenever the schema changes. As each SQL statement
runs, the schema version is checked to ensure that the
schema has not changed since the SQL statement was
prepared. Subverting this mechanism by using
"PRAGMA schema_version" my cause SQL statement to
run using an obsolete schema, which can lead to
incorrect answers and/or database corruption.

Warning: Misuse of this pragma can result in database


corruption.

For the purposes of this pragma, the VACUUM command


is considered a schema change, since VACUUM will
usual alter the "rootpage" values for entries in the
sqlite_master table.

See also the application_id pragma and user_version


pragma.

PRAGMA schema.secure_delete;
PRAGMA schema.secure_delete = boolean

Query or change the secure-delete setting. When


secure_delete is on, SQLite overwrites deleted content
with zeros. The default setting for secure_delete is
determined by the SQLITE_SECURE_DELETE compile-
time option and is normally off. The off setting for
secure_delete improves performance by reducing the
amount of disk I/O. Applications that wish to avoid
leaving forensic traces after content is deleted or
updated should enable the secure_delete pragma prior
to performing the delete or update, or else run VACUUM
after the delete or update.

When there are attached databases and no database is


specified in the pragma, all databases have their
secure-delete setting altered. The secure-delete setting
for newly attached databases is the setting of the main
database at the time the ATTACH command is
evaluated.

When multiple database connections share the same


cache, changing the secure-delete flag on one database
connection changes it for them all.

PRAGMA short_column_names;
PRAGMA short_column_names = boolean;

Query or change the short-column-names flag. This


flag affects the way SQLite names columns of data
returned by SELECT statements. See the
full_column_names pragma for full details.

This pragma is deprecated and exists for backwards


compatibility only. New applications should avoid using
this pragma. Older applications should discontinue use
of this pragma at the earliest opportunity. This pragma
may be omitted from the build when SQLite is compiled
using SQLITE_OMIT_DEPRECATED.
PRAGMA shrink_memory

This pragma causes the database connection on which


it is invoked to free up as much memory as it can, by
calling sqlite3_db_release_memory().

PRAGMA soft_heap_limit
PRAGMA soft_heap_limit=N

This pragma invokes the sqlite3_soft_heap_limit64()


interface with the argument N, if N is specified and is a
non-negative integer. The soft_heap_limit pragma
always returns the same integer that would be returned
by the sqlite3_soft_heap_limit64(-1) C-language
function.

PRAGMA stats;

This pragma returns auxiliary information about tables


and indices. The returned information is used during
testing to help verify that the query planner is
operating correctly. The format and meaning of this
pragma will likely change from one release to the next.
Because of its volatility, the behavior and output format
of this pragma are deliberately undocumented.

The intended use of this pragma is only for testing and


validation of SQLite. This pragma is subject to change
without notice and is not recommended for use by
application programs.
PRAGMA schema.synchronous;
PRAGMA schema.synchronous = 0 | OFF | 1 |
NORMAL | 2 | FULL | 3 | EXTRA;

Query or change the setting of the "synchronous" flag.


The first (query) form will return the synchronous
setting as an integer. The second form changes the
synchronous setting. The meanings of the various
synchronous settings are as follows:

EXTRA (3)
EXTRA synchronous is like FULL with the addition
that the directory containing a rollback journal is
synced after that journal is unlinked to commit a
transaction in DELETE mode. EXTRA provides
additional durability if the commit is followed closely
by a power loss.
FULL (2)
When synchronous is FULL (2), the SQLite database
engine will use the xSync method of the VFS to
ensure that all content is safely written to the disk
surface prior to continuing. This ensures that an
operating system crash or power failure will not
corrupt the database. FULL synchronous is very safe,
but it is also slower. FULL is the most commonly
used synchronous setting when not in WAL mode.
NORMAL (1)
When synchronous is NORMAL (1), the SQLite
database engine will still sync at the most critical
moments, but less often than in FULL mode. There is
a very small (though non-zero) chance that a power
failure at just the wrong time could corrupt the
database in NORMAL mode. But in practice, you are
more likely to suffer a catastrophic disk failure or
some other unrecoverable hardware fault. Many
applications choose NORMAL when in WAL mode.
OFF (0)
With synchronous OFF (0), SQLite continues without
syncing as soon as it has handed data off to the
operating system. If the application running SQLite
crashes, the data will be safe, but the database
might become corrupted if the operating system
crashes or the computer loses power before that
data has been written to the disk surface. On the
other hand, commits can be orders of magnitude
faster with synchronous OFF.

In WAL mode when synchronous is NORMAL (1), the


WAL file is synchronized before each checkpoint and
the database file is synchronized after each completed
checkpoint and the WAL file header is synchronized
when a WAL file begins to be reused after a checkpoint,
but no sync operations occur during most transactions.
With synchronous=FULL in WAL mode, an additional
sync operation of the WAL file happens after each
transaction commit. The extra WAL sync following each
transaction help ensure that transactions are durable
across a power loss, but they do not aid in preserving
consistency. If durability is not a concern, then
synchronous=NORMAL is normally all one needs in
WAL mode.
The default setting is usually synchronous=FULL. The
SQLITE_EXTRA_DURABLE compile-time option changes
the default to synchronous=EXTRA.

See also the fullfsync and checkpoint_fullfsync


pragmas.

PRAGMA schema.table_info(table-name);

This pragma returns one row for each column in the


named table. Columns in the result set include the
column name, data type, whether or not the column
can be NULL, and the default value for the column. The
"pk" column in the result set is zero for columns that
are not part of the primary key, and is the index of the
column in the primary key for columns that are part of
the primary key.

The table named in the table_info pragma can also be a


view.

PRAGMA temp_store;
PRAGMA temp_store = 0 | DEFAULT | 1 | FILE | 2 |
MEMORY;

Query or change the setting of the "temp_store"


parameter. When temp_store is DEFAULT (0), the
compile-time C preprocessor macro
SQLITE_TEMP_STORE is used to determine where
temporary tables and indices are stored. When
temp_store is MEMORY (2) temporary tables and
indices are kept in as if they were pure in-memory
databases memory. When temp_store is FILE (1)
temporary tables and indices are stored in a file. The
temp_store_directory pragma can be used to specify
the directory containing temporary files when FILE is
specified. When the temp_store setting is changed, all
existing temporary tables, indices, triggers, and views
are immediately deleted.

It is possible for the library compile-time C


preprocessor symbol SQLITE_TEMP_STORE to override
this pragma setting. The following table summarizes
the interaction of the SQLITE_TEMP_STORE
preprocessor macro and the temp_store pragma:

PRAGMA Storage used for


SQLITE_TEMP_STORE
temp_store TEMP tables and indices
0 any file
1 0 file
1 1 file
1 2 memory
2 0 memory
2 1 file
2 2 memory
3 any memory

PRAGMA temp_store_directory;
PRAGMA temp_store_directory = 'directory-name';

Query or change the value of the


sqlite3_temp_directory global variable, which many
operating-system interface backends use to determine
where to store temporary tables and indices.

When the temp_store_directory setting is changed, all


existing temporary tables, indices, triggers, and
viewers in the database connection that issued the
pragma are immediately deleted. In practice,
temp_store_directory should be set immediately after
the first database connection for a process is opened. If
the temp_store_directory is changed for one database
connection while other database connections are open
in the same process, then the behavior is undefined
and probably undesirable.

Changing the temp_store_directory setting is not


threadsafe. Never change the temp_store_directory
setting if another thread within the application is
running any SQLite interface at the same time. Doing
so results in undefined behavior. Changing the
temp_store_directory setting writes to the
sqlite3_temp_directory global variable and that global
variable is not protected by a mutex.

The value directory-name should be enclosed in single


quotes. To revert the directory to the default, set the
directory-name to an empty string, e.g., PRAGMA
temp_store_directory = ''. An error is raised if
directory-name is not found or is not writable.

The default directory for temporary files depends on the


OS. Some OS interfaces may choose to ignore this
variable and place temporary files in some other
directory different from the directory specified here. In
that sense, this pragma is only advisory.

This pragma is deprecated and exists for backwards


compatibility only. New applications should avoid using
this pragma. Older applications should discontinue use
of this pragma at the earliest opportunity. This pragma
may be omitted from the build when SQLite is compiled
using SQLITE_OMIT_DEPRECATED.

PRAGMA threads;
PRAGMA threads = N;

Query or change the value of the


sqlite3_limit(db,SQLITE_LIMIT_WORKER_THREADS,...)
limit for the current database connection. This limit
sets an upper bound on the number of auxiliary threads
that a prepared statement is allowed to launch to assist
with a query. The default limit is 0 unless it is changed
using the SQLITE_DEFAULT_WORKER_THREADS
compile-time option. When the limit is zero, that
means no auxiliary threads will be launched.

This pragma is a thin wrapper around the


sqlite3_limit(db,SQLITE_LIMIT_WORKER_THREADS,...)
interface.

PRAGMA schema.user_version;
PRAGMA schema.user_version = integer ;

The user_version pragma will to get or set the value of


the user-version integer at offset 60 in the database
header. The user-version is an integer that is available
to applications to use however they want. SQLite
makes no use of the user-version itself.

See also the application_id pragma and


schema_version pragma.

PRAGMA vdbe_addoptrace = boolean;

If SQLite has been compiled with the SQLITE_DEBUG


compile-time option, then the vdbe_addoptrace pragma
can be used to cause a complete VDBE opcodes to be
displayed as they are created during code generation.
This feature is used for debugging SQLite itself. See the
VDBE documentation for more information.

This pragma is intended for use when debugging SQLite


itself. It is only available when the SQLITE_DEBUG
compile-time option is used.

PRAGMA vdbe_debug = boolean;

If SQLite has been compiled with the SQLITE_DEBUG


compile-time option, then the vdbe_debug pragma is a
shorthand for three other debug-only pragmas:
vdbe_addoptrace, vdbe_listing, and vdbe_trace. This
feature is used for debugging SQLite itself. See the
VDBE documentation for more information.

This pragma is intended for use when debugging SQLite


itself. It is only available when the SQLITE_DEBUG
compile-time option is used.

PRAGMA vdbe_listing = boolean;

If SQLite has been compiled with the SQLITE_DEBUG


compile-time option, then the vdbe_listing pragma can
be used to cause a complete listing of the virtual
machine opcodes to appear on standard output as each
statement is evaluated. With listing is on, the entire
content of a program is printed just prior to beginning
execution. The statement executes normally after the
listing is printed. This feature is used for debugging
SQLite itself. See the VDBE documentation for more
information.

This pragma is intended for use when debugging SQLite


itself. It is only available when the SQLITE_DEBUG
compile-time option is used.

PRAGMA vdbe_trace = boolean;

If SQLite has been compiled with the SQLITE_DEBUG


compile-time option, then the vdbe_trace pragma can
be used to cause virtual machine opcodes to be printed
on standard output as they are evaluated. This feature
is used for debugging SQLite. See the VDBE
documentation for more information.

This pragma is intended for use when debugging SQLite


itself. It is only available when the SQLITE_DEBUG
compile-time option is used.

PRAGMA wal_autocheckpoint;
PRAGMA wal_autocheckpoint=N;

This pragma queries or sets the write-ahead log auto-


checkpoint interval. When the write-ahead log is
enabled (via the journal_mode pragma) a checkpoint
will be run automatically whenever the write-ahead log
equals or exceeds N pages in length. Setting the auto-
checkpoint size to zero or a negative value turns auto-
checkpointing off.

This pragma is a wrapper around the


sqlite3_wal_autocheckpoint() C interface. All automatic
checkpoints are PASSIVE.

Autocheckpointing is enabled by default with an


interval of 1000 or
SQLITE_DEFAULT_WAL_AUTOCHECKPOINT.

PRAGMA schema.wal_checkpoint;
PRAGMA schema.wal_checkpoint(PASSIVE);
PRAGMA schema.wal_checkpoint(FULL);
PRAGMA schema.wal_checkpoint(RESTART);
PRAGMA schema.wal_checkpoint(TRUNCATE);

If the write-ahead log is enabled (via the journal_mode


pragma), this pragma causes a checkpoint operation to
run on database database, or on all attached databases
if database is omitted. If write-ahead log mode is
disabled, this pragma is a harmless no-op.

Invoking this pragma without an argument is


equivalent to calling the sqlite3_wal_checkpoint() C
interface.

Invoking this pragma with an argument is equivalent to


calling the sqlite3_wal_checkpoint_v2() C interface
with a 3rd parameter corresponding to the argument:

PASSIVE
Checkpoint as many frames as possible without
waiting for any database readers or writers to finish.
Sync the db file if all frames in the log are
checkpointed. This mode is the same as calling the
sqlite3_wal_checkpoint() C interface. The busy-
handler callback is never invoked in this mode.
FULL
This mode blocks (invokes the busy-handler
callback) until there is no database writer and all
readers are reading from the most recent database
snapshot. It then checkpoints all frames in the log
file and syncs the database file. FULL blocks
concurrent writers while it is running, but readers
can proceed.
RESTART
This mode works the same way as FULL with the
addition that after checkpointing the log file it blocks
(calls the busy-handler callback) until all readers are
finished with the log file. This ensures that the next
client to write to the database file restarts the log
file from the beginning. RESTART blocks concurrent
writers while it is running, but allowed readers to
proceed.
TRUNCATE
This mode works the same way as RESTART with the
addition that the WAL file is truncated to zero bytes
upon successful completion.

The wal_checkpoint pragma returns a single row with


three integer columns. The first column is usually 0 but
will be 1 if a RESTART or FULL or TRUNCATE checkpoint
was blocked from completing, for example because
another thread or process was actively using the
database. In other words, the first column is 0 if the
equivalent call to sqlite3_wal_checkpoint_v2() would
have returned SQLITE_OK or 1 if the equivalent call
would have returned SQLITE_BUSY. The second column
is the number of modified pages that have been written
to the write-ahead log file. The third column is the
number of pages in the write-ahead log file that have
been successfully moved back into the database file at
the conclusion of the checkpoint. The second and third
column are -1 if there is no write-ahead log, for
example if this pragma is invoked on a database
connection that is not in WAL mode.
PRAGMA writable_schema = boolean;

When this pragma is on, the SQLITE_MASTER tables in


which database can be changed using ordinary UPDATE,
INSERT, and DELETE statements. Warning: misuse of
this pragma can easily result in a corrupt database file.
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
Syntax Diagrams For SQLite
sql-stmt-list:

References: sql-stmt
See also: lang.html

sql-stmt:
Used by: sql-stmt-list
References: alter-table-stmt analyze-stmt attach-
stmt begin-stmt commit-stmt create-index-stmt
create-table-stmt create-trigger-stmt create-view-
stmt create-virtual-table-stmt delete-stmt delete-
stmt-limited detach-stmt drop-index-stmt drop-
table-stmt drop-trigger-stmt drop-view-stmt insert-
stmt pragma-stmt reindex-stmt release-stmt
rollback-stmt savepoint-stmt select-stmt update-
stmt update-stmt-limited vacuum-stmt
See also: lang.html lang_explain.html

alter-table-stmt:

Used by: sql-stmt


References: column-def
See also: lang_altertable.html

analyze-stmt:

Used by: sql-stmt


See also: lang_analyze.html

attach-stmt:

Used by: sql-stmt


References: expr
See also: lang_attach.html

begin-stmt:
Used by: sql-stmt
See also: lang_transaction.html

commit-stmt:

Used by: sql-stmt


See also: lang_transaction.html

rollback-stmt:

Used by: sql-stmt


See also: lang_savepoint.html lang_transaction.html

savepoint-stmt:

Used by: sql-stmt


See also: lang_savepoint.html

release-stmt:
Used by: sql-stmt
See also: lang_savepoint.html

create-index-stmt:

Used by: sql-stmt


References: expr indexed-column
See also: lang_createindex.html partialindex.html

indexed-column:

Used by: create-index-stmt table-constraint


References: expr
See also: lang_createindex.html
lang_createtable.html
lang_createtable.html#primkeyconst
lang_createtable.html#uniqueconst partialindex.html

create-table-stmt:
Used by: sql-stmt
References: column-def select-stmt table-
constraint
See also: lang_createtable.html

column-def:

Used by: alter-table-stmt create-table-stmt


References: column-constraint type-name
See also: lang_altertable.html
lang_createtable.html
lang_createtable.html#tablecoldef

type-name:

Used by: column-def expr


References: signed-number
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

column-constraint:

Used by: column-def


References: conflict-clause expr foreign-key-
clause literal-value signed-number
See also: lang_altertable.html
lang_createtable.html
lang_createtable.html#tablecoldef

signed-number:
Used by: column-constraint pragma-value type-
name
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html
pragma.html#syntax

table-constraint:

Used by: create-table-stmt


References: conflict-clause expr foreign-key-
clause indexed-column
See also: lang_createtable.html
lang_createtable.html#primkeyconst
lang_createtable.html#tablecoldef
lang_createtable.html#uniqueconst
foreign-key-clause:

Used by: column-constraint table-constraint


See also: lang_altertable.html lang_createtable.html

conflict-clause:

Used by: column-constraint table-constraint


See also: lang_altertable.html lang_conflict.html
lang_createtable.html
lang_createtable.html#notnullconst
create-trigger-stmt:

Used by: sql-stmt


References: delete-stmt expr insert-stmt select-
stmt update-stmt
See also: lang_createtrigger.html

create-view-stmt:
Used by: sql-stmt
References: select-stmt
See also: lang_createview.html

create-virtual-table-stmt:

Used by: sql-stmt


See also: lang_createvtab.html

with-clause:

Used by: delete-stmt delete-stmt-limited insert-


stmt update-stmt update-stmt-limited
References: cte-table-name select-stmt
See also: lang_createtrigger.html lang_delete.html
lang_insert.html lang_update.html lang_with.html
cte-table-name:

Used by: recursive-cte with-clause


See also: lang_createtrigger.html lang_delete.html
lang_insert.html lang_update.html lang_with.html
lang_with.html#recursivecte

recursive-cte:

References: cte-table-name
See also: lang_with.html#recursivecte

common-table-expression:

Used by: compound-select-stmt factored-select-


stmt select-stmt simple-select-stmt
References: select-stmt
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

delete-stmt:

Used by: create-trigger-stmt sql-stmt


References: expr qualified-table-name with-clause
See also: lang_createtrigger.html lang_delete.html

delete-stmt-limited:

Used by: sql-stmt


References: expr ordering-term qualified-table-
name with-clause
See also: lang_delete.html

detach-stmt:
Used by: sql-stmt
See also: lang_detach.html

drop-index-stmt:

Used by: sql-stmt


See also: lang_dropindex.html

drop-table-stmt:

Used by: sql-stmt


See also: lang_droptable.html

drop-trigger-stmt:

Used by: sql-stmt


See also: lang_droptrigger.html

drop-view-stmt:

Used by: sql-stmt


See also: lang_dropview.html
expr:
Used by: attach-stmt column-constraint compound-
select-stmt create-index-stmt create-trigger-stmt
delete-stmt delete-stmt-limited factored-select-
stmt indexed-column insert-stmt join-constraint
ordering-term result-column select-core select-
stmt simple-select-stmt table-constraint table-or-
subquery update-stmt update-stmt-limited
References: literal-value raise-function select-
stmt type-name
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

raise-function:

Used by: expr


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html
lang_createtrigger.html#raise lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

literal-value:

Used by: column-constraint expr


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

numeric-literal:

See also: lang_expr.html#litvalue

insert-stmt:
Used by: create-trigger-stmt sql-stmt
References: expr select-stmt with-clause
See also: lang_createtrigger.html lang_insert.html

pragma-stmt:

Used by: sql-stmt


References: pragma-value
See also: pragma.html#syntax

pragma-value:
Used by: pragma-stmt
References: signed-number
See also: pragma.html#syntax

reindex-stmt:

Used by: sql-stmt


See also: lang_reindex.html

select-stmt:
Used by: common-table-expression create-table-
stmt create-trigger-stmt create-view-stmt expr
insert-stmt sql-stmt table-or-subquery with-clause
References: common-table-expression compound-
operator expr join-clause ordering-term result-
column table-or-subquery
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html lang_with.html#recursivecte
partialindex.html

join-clause:

Used by: select-core select-stmt table-or-subquery


References: join-constraint join-operator table-or-
subquery
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

select-core:
Used by: compound-select-stmt factored-select-
stmt simple-select-stmt
References: expr join-clause result-column table-
or-subquery
See also: lang_select.html
lang_select.html#compound
lang_select.html#simpleselect

factored-select-stmt:
References: common-table-expression compound-
operator expr ordering-term select-core
See also: lang_select.html

simple-select-stmt:

References: common-table-expression expr


ordering-term select-core
See also: lang_select.html#simpleselect
compound-select-stmt:

References: common-table-expression expr


ordering-term select-core
See also: lang_select.html#compound

table-or-subquery:
Used by: join-clause select-core select-stmt
References: expr join-clause select-stmt
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

result-column:
Used by: select-core select-stmt
References: expr
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

join-operator:

Used by: join-clause


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#fromclause
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

join-constraint:
Used by: join-clause
References: expr
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#fromclause
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html

ordering-term:

Used by: compound-select-stmt delete-stmt-limited


factored-select-stmt select-stmt simple-select-stmt
update-stmt-limited
References: expr
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html partialindex.html
compound-operator:

Used by: factored-select-stmt select-stmt


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_select.html#compound
lang_select.html#simpleselect lang_update.html
lang_with.html lang_with.html#recursivecte
partialindex.html

update-stmt:

Used by: create-trigger-stmt sql-stmt


References: column-name-list expr qualified-table-
name with-clause
See also: lang_createtrigger.html lang_update.html

column-name-list:

Used by: update-stmt update-stmt-limited


See also: lang_createtrigger.html lang_update.html

update-stmt-limited:

Used by: sql-stmt


References: column-name-list expr ordering-term
qualified-table-name with-clause
See also: lang_update.html

qualified-table-name:

Used by: delete-stmt delete-stmt-limited update-


stmt update-stmt-limited
See also: lang_createtrigger.html lang_delete.html
lang_indexedby.html lang_update.html

vacuum-stmt:

Used by: sql-stmt


See also: lang_vacuum.html

comment-syntax:

See also: lang_comment.html


SQLite ADO.NET Provider
System.Data.SQLite Namespace

Namespace Hierarchy

Classes
Class Description
AssemblySourceIdAttribute Defines a source code identifier custom
AssemblySourceTimeStampAttribute Defines a source code time-stamp custo
AuthorizerEventArgs The data associated with a call into the
CommitEventArgs Event arguments raised when a transa
ConnectionEventArgs Event data for connection event handle
LogEventArgs Event data for logging event handlers.
ProgressEventArgs The event data associated with progres
SQLiteBlob Represents a single SQL blob in SQLite
SQLiteCommand SQLite implementation of DbCommand
SQLiteCommandBuilder SQLite implementation of DbCommand
SQLiteConnection SQLite implentation of DbConnection.
SQLiteConnectionStringBuilder SQLite implementation of DbConnectio
SQLiteContext This class represents a context from th
sqlite3_result_*() and associated funct
SQLiteConvert This base class provides datatype conve
SQLiteDataAdapter SQLite implementation of DbDataAdapt
SQLiteDataReader SQLite implementation of DbDataReade
SQLiteDataReaderValue This class represents a single value to
via its GetBlob, GetBoolean, GetByte,
GetDecimal, GetDouble, GetFloat, GetG
or GetValue method. If the value of the
upon returning from the callback, the n
for the SQLiteDataReader method ca
returned from the SQLiteDataReader
type), an exception will be thrown.
SQLiteDelegateFunction This class implements a SQLite function
the SQLiteFunction class are implemen
SQLiteStepDelegate, SQLiteFinalDelega
typed delegate types or via the Dynam
in the same order they appear in the a
exception: the first argument is the na
SQLiteException SQLite exception class.
SQLiteFactory SQLite implementation of DbProviderFa
SQLiteFunction This abstract class is designed to handl
the derived class is made for each conn
SQLiteFunctionAttribute A simple custom attribute to enable us
loaded assemblies and initialize them i
SQLiteFunctionEx Extends SQLiteFunction and allows an
associated with a function call.
SQLiteIndex This class represents the various inputs
SQLiteIndexConstraint This class represents the native sqlite3
core library.
SQLiteIndexConstraintUsage This class represents the native sqlite3
SQLite core library.
SQLiteIndexInputs This class represents the various inputs
BestIndex method.
SQLiteIndexOrderBy This class represents the native sqlite3
library.
SQLiteIndexOutputs This class represents the various outpu
BestIndex method.
SQLiteLog Manages the SQLite custom logging fun
whole process.
SQLiteMetaDataCollectionNames MetaDataCollections specific to SQLite
SQLiteModule This class represents a managed virtua
and must be used as the base class for
implemented in managed code.
SQLiteModuleCommon This class contains some virtual metho
classes. It specifically does NOT implem
interface methods.
SQLiteModuleEnumerable This class implements a virtual table m
instance as a read-only virtual table. It
class for any user-defined virtual table
instance. The following short example s
as a table data source:
public static class Sample
{
public static void Main()
{
using (SQLiteConnection co
"Data Source=:memory:;
{
connection.Open();

connection.CreateModule(
"sampleModule", new st

using (SQLiteCommand com


{
command.CommandText =
"CREATE VIRTUAL TA

command.ExecuteNonQuer
}

using (SQLiteCommand com


{
command.CommandText =

using (SQLiteDataReade
{
while (dataReader.Re
Console.WriteLine(
}
}

connection.Close();
}
}
}

SQLiteModuleNoop This class implements a virtual table m


implementations for all of the ISQLiteM
codes returned by these "empty" meth
per-method basis by using and/or over
ResultCodeToEofResult, ResultCodeToFin
SetMethodResultCode methods from wi

SQLiteParameter SQLite implementation of DbParameter


SQLiteParameterCollection SQLite implementation of DbParameter
SQLiteReadArrayEventArgs This class represents the parameters th
methods, with the exception of the colu
SQLiteReadBlobEventArgs This class represents the parameters th
the exception of the column index (pro
SQLiteReadEventArgs This class represents the parameters th
methods, with the exception of the colu
SQLiteReadValueEventArgs This class represents the parameters a
GetByte, GetBytes, GetChar, GetChars
GetFloat, GetGuid, GetInt16, GetInt32
SQLiteTransaction SQLite implementation of DbTransactio
SQLiteTransaction2 SQLite implementation of DbTransactio
SQLiteTransactionBase Base class used by to implement DbTra
SQLiteTypeCallbacks This class represents the custom data t
SQLiteValue This class represents a value from the
sqlite3_value_*() and associated funct
SQLiteVirtualTable This class represents a managed virtua
should be used as the base class for an
implemented in managed code.
SQLiteVirtualTableCursor This class represents a managed virtua
and should be used as the base class fo
implemented in managed code.
SQLiteVirtualTableCursorEnumerator This class represents a virtual table cur
SQLiteModuleEnumerable class. It is no
any user-defined virtual table cursor cl
TraceEventArgs Passed during an Trace callback, these
of the SQL statement text
UpdateEventArgs Passed during an Update callback, thes
operation being performed on the given
Interfaces
Interface Description
ISQLiteConnectionPool This interface represents a custom
connection pool implementation
usable by System.Data.SQLite.
ISQLiteManagedModule This interface represents a virtual
table implementation written in
managed code.
ISQLiteNativeHandle This interface represents a native
handle provided by the SQLite core
library.
ISQLiteNativeModule This interface represents a virtual
table implementation written in
native code.
ISQLiteSchemaExtensions

Structures
Structure Description
CollationSequence A struct describing the collating
sequence a function is executing in

Delegates
Delegate Description
SQLiteAuthorizerEventHandler Raised when authorization is
required to perform an action
contained within a SQL query.
SQLiteBackupCallback Raised between each backup step.
SQLiteBindValueCallback This represents a method that will
be called in response to a request
to bind a parameter to a command.
If an exception is thrown, it will
cause the parameter binding
operation to fail -AND- it will
continue to unwind the call stack.
SQLiteCallback An internal callback delegate
declaration.
SQLiteCommitHandler Raised when a transaction is about
to be committed. To roll back a
transaction, set the rollbackTrans
boolean value to true.
SQLiteCompareDelegate This Delegate type is used with the
Compare method.
SQLiteConnectionEventHandler Raised when an event pertaining to
a connection occurs.
SQLiteFinalDelegate This Delegate type is used with the
Final method.
SQLiteInvokeDelegate This Delegate type is used with the
Invoke method.
SQLiteLogEventHandler Raised when a log event occurs.
SQLiteProgressEventHandler Raised each time the number of
virtual machine instructions is
approximately equal to the value of
the ProgressOps property.
SQLiteReadValueCallback This represents a method that will
be called in response to a request
to read a value from a data reader.
If an exception is thrown, it will
cause the data reader operation to
fail -AND- it will continue to unwind
the call stack.
SQLiteStepDelegate This Delegate type is used with the
Step method.
SQLiteTraceEventHandler Raised when a statement first
begins executing on a given
connection
SQLiteUpdateEventHandler Raised when data is inserted,
updated and deleted on a given
connection

Enumerations
Enumeration Description
CollationEncodingEnum The encoding type the collation
sequence uses
CollationTypeEnum The type of collating sequence
FunctionType The type of user-defined function to
declare
SQLiteAuthorizerActionCode The action code responsible for the
current call into the authorizer.
SQLiteAuthorizerReturnCode The return code for the current call
into the authorizer.
SQLiteConfigDbOpsEnum These are the supported
configuration verbs for use with the
native SQLite library. They are
used with the
SetConfigurationOption method.
SQLiteConnectionEventType These are the event types
associated with the
SQLiteConnectionEventHandler
delegate (and its corresponding
event) and the
ConnectionEventArgs class.
SQLiteConnectionFlags The extra behavioral flags that can
be applied to a connection.
SQLiteDateFormats This implementation of SQLite for
ADO.NET can process date/time
fields in databases in one of six
formats.
SQLiteErrorCode SQLite error codes. Actually, this
enumeration represents a return
code, which may also indicate
success in one of several ways (e.g.
SQLITE_OK, SQLITE_ROW, and
SQLITE_DONE). Therefore, the
name of this enumeration is
something of a misnomer.
SQLiteExecuteType The requested command execution
type. This controls which method of
the SQLiteCommand object will be
called.
SQLiteIndexConstraintOp These are the allowed values for
the operators that are part of a
constraint term in the WHERE
clause of a query that uses a
virtual table.
SQLiteIndexFlags These are the allowed values for
the index flags from the BestIndex
method.
SQLiteJournalModeEnum This enum determines how SQLite
treats its journal file.
SQLiteProgressReturnCode The possible return codes for the
progress callback.
SynchronizationModes The I/O file cache flushing behavior
for the connection
TypeAffinity SQLite has very limited types, and
is inherently text-based. The first 5
types below represent the sum of
all types SQLite understands. The
DateTime extension to the spec is
for internal use only.
UpdateEventType Whenever an update event is
triggered on a connection, this
enum will indicate exactly what
type of operation is being
performed.

Send comments on this topic.


SQLite ADO.NET Provider
AssemblySourceIdAttribute Class

Defines a source code identifier custom attribute for an assembly manifest.


For a list of all members of this type, see AssemblySourceIdAttribute
Members .
System.Object Attribute
AssemblySourceIdAttribute

public sealed class AssemblySourceIdAttribute :


Attribute

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
AssemblySourceIdAttribute Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceIdAttribute Members

AssemblySourceIdAttribute overview

Public Instance Constructors


AssemblySourceIdAttribute Constructs an instance of this
Constructor attribute class using the specified
source code identifier value.

Public Instance Properties


SourceId Gets the source code identifier
value.
TypeId (inherited from Attribute) When implemented in a derived
class, gets a unique identifier for
this Attribute.

Public Instance Methods


Equals (inherited from Attribute) Returns a value that indicates
whether this instance is equal to a
specified object.
GetHashCode (inherited from Returns the hash code for this
Attribute) instance.
GetType (inherited from Object) Gets the Type of the current
instance.
IsDefaultAttribute (inherited from When overridden in a derived class,
Attribute) indicates whether the value of this
instance is the default value for the
derived class.
Match (inherited from Attribute) When overridden in a derived class,
returns a value that indicates
whether this instance equals a
specified object.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
AssemblySourceIdAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceIdAttribute Constructor

Constructs an instance of this attribute class using the specified source


code identifier value.

AssemblySourceIdAttribute(
string value
);

Parameters
value
The source code identifier value to use.

See Also
AssemblySourceIdAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceIdAttribute Properties

The properties of the AssemblySourceIdAttribute class are listed below.


For a complete list of AssemblySourceIdAttribute class members, see
the AssemblySourceIdAttribute Members topic.

Public Instance Properties


SourceId Gets the source code identifier
value.
TypeId (inherited from Attribute) When implemented in a derived
class, gets a unique identifier for
this Attribute.

See Also
AssemblySourceIdAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceIdAttribute.SourceId Property

Gets the source code identifier value.

public string SourceId { public get; }

See Also
AssemblySourceIdAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceTimeStampAttribute Class

Defines a source code time-stamp custom attribute for an assembly


manifest.
For a list of all members of this type, see
AssemblySourceTimeStampAttribute Members .
System.Object Attribute
AssemblySourceTimeStampAttribute

public sealed class AssemblySourceTimeStampAttribute


: Attribute

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
AssemblySourceTimeStampAttribute Members | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceTimeStampAttribute Members

AssemblySourceTimeStampAttribute overview

Public Instance Constructors


Constructs an instance of this
AssemblySourceTimeStampAttribute attribute class using the specified
Constructor source code time-stamp value.

Public Instance Properties


SourceTimeStamp Gets the source code time-stamp
value.
TypeId (inherited from Attribute) When implemented in a derived
class, gets a unique identifier for
this Attribute.

Public Instance Methods


Equals (inherited from Attribute) Returns a value that indicates
whether this instance is equal to a
specified object.
GetHashCode (inherited from Returns the hash code for this
Attribute) instance.
GetType (inherited from Object) Gets the Type of the current
instance.
IsDefaultAttribute (inherited from When overridden in a derived class,
Attribute) indicates whether the value of this
instance is the default value for the
derived class.
Match (inherited from Attribute) When overridden in a derived class,
returns a value that indicates
whether this instance equals a
specified object.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
AssemblySourceTimeStampAttribute Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceTimeStampAttribute Constructor

Constructs an instance of this attribute class using the specified source


code time-stamp value.

AssemblySourceTimeStampAttribute(
string value
);

Parameters
value
The source code time-stamp value to use.

See Also
AssemblySourceTimeStampAttribute Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceTimeStampAttribute Properties

The properties of the AssemblySourceTimeStampAttribute class are


listed below. For a complete list of
AssemblySourceTimeStampAttribute class members, see the
AssemblySourceTimeStampAttribute Members topic.

Public Instance Properties


SourceTimeStamp Gets the source code time-stamp
value.
TypeId (inherited from Attribute) When implemented in a derived
class, gets a unique identifier for
this Attribute.

See Also
AssemblySourceTimeStampAttribute Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AssemblySourceTimeStampAttribute.SourceTimeStamp
Property

Gets the source code time-stamp value.

public string SourceTimeStamp { public get; }

See Also
AssemblySourceTimeStampAttribute Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs Class

The data associated with a call into the authorizer.


For a list of all members of this type, see AuthorizerEventArgs Members .
System.Object EventArgs
AuthorizerEventArgs

public class AuthorizerEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
AuthorizerEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs Members

AuthorizerEventArgs overview

Public Instance Fields


ActionCode The action code responsible for the
current call into the authorizer.
Argument1 The first string argument for the
current call into the authorizer. The
exact value will vary based on the
action code, see the
SQLiteAuthorizerActionCode
enumeration for possible values.
Argument2 The second string argument for the
current call into the authorizer. The
exact value will vary based on the
action code, see the
SQLiteAuthorizerActionCode
enumeration for possible values.
Context The name of the inner-most trigger
or view that is responsible for the
access attempt or a null value if
this access attempt is directly from
top-level SQL code.
Database The database name for the current
call into the authorizer, if
applicable.
ReturnCode The return code for the current call
into the authorizer.
UserData The user-defined native data
associated with this event.
Currently, this will always contain
the value of Zero.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs Fields

The fields of the AuthorizerEventArgs class are listed below. For a


complete list of AuthorizerEventArgs class members, see the
AuthorizerEventArgs Members topic.

Public Instance Fields


ActionCode The action code responsible for the
current call into the authorizer.
Argument1 The first string argument for the
current call into the authorizer. The
exact value will vary based on the
action code, see the
SQLiteAuthorizerActionCode
enumeration for possible values.
Argument2 The second string argument for the
current call into the authorizer. The
exact value will vary based on the
action code, see the
SQLiteAuthorizerActionCode
enumeration for possible values.
Context The name of the inner-most trigger
or view that is responsible for the
access attempt or a null value if
this access attempt is directly from
top-level SQL code.
Database The database name for the current
call into the authorizer, if
applicable.
ReturnCode The return code for the current call
into the authorizer.
UserData The user-defined native data
associated with this event.
Currently, this will always contain
the value of Zero.

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs.ActionCode Field

The action code responsible for the current call into the authorizer.

public readonly SQLiteAuthorizerActionCode ActionCode;

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs.Argument1 Field

The first string argument for the current call into the authorizer. The exact
value will vary based on the action code, see the
SQLiteAuthorizerActionCode enumeration for possible values.

public readonly string Argument1;

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs.Argument2 Field

The second string argument for the current call into the authorizer. The
exact value will vary based on the action code, see the
SQLiteAuthorizerActionCode enumeration for possible values.

public readonly string Argument2;

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs.Context Field

The name of the inner-most trigger or view that is responsible for the
access attempt or a null value if this access attempt is directly from top-
level SQL code.

public readonly string Context;

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs.Database Field

The database name for the current call into the authorizer, if applicable.

public readonly string Database;

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs.ReturnCode Field

The return code for the current call into the authorizer.

public SQLiteAuthorizerReturnCode ReturnCode;

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
AuthorizerEventArgs.UserData Field

The user-defined native data associated with this event. Currently, this will
always contain the value of Zero.

public readonly IntPtr UserData;

See Also
AuthorizerEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationEncodingEnum Enumeration

The encoding type the collation sequence uses

public enum CollationEncodingEnum

Members
Member Name Description
UTF8 The collation sequence is UTF8
UTF16LE The collation sequence is UTF16
little-endian
UTF16BE The collation sequence is UTF16
big-endian

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence Structure

A struct describing the collating sequence a function is executing in


For a list of all members of this type, see CollationSequence Members .
System.Object CollationSequence

public struct CollationSequence

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
CollationSequence Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence Members

CollationSequence overview

Public Instance Fields


Encoding The text encoding of the collation
sequence
Name The name of the collating sequence
Type The type of collating sequence

Public Instance Methods


Compare Overloaded. Calls the base collating
sequence to compare two strings
Equals (inherited from Indicates whether this instance and
ValueType) a specified object are equal.
GetHashCode (inherited from Returns the hash code for this
ValueType) instance.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Returns the fully qualified type
ValueType) name of this instance.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
CollationSequence Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence Fields

The fields of the CollationSequence structure are listed below. For a


complete list of CollationSequence structure members, see the
CollationSequence Members topic.

Public Instance Fields


Encoding The text encoding of the collation
sequence
Name The name of the collating sequence
Type The type of collating sequence

See Also
CollationSequence Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence.Encoding Field

The text encoding of the collation sequence

public CollationEncodingEnum Encoding;

See Also
CollationSequence Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence.Name Field

The name of the collating sequence

public string Name;

See Also
CollationSequence Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence.Type Field

The type of collating sequence

public CollationTypeEnum Type;

See Also
CollationSequence Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence Methods

The methods of the CollationSequence structure are listed below. For a


complete list of CollationSequence structure members, see the
CollationSequence Members topic.

Public Instance Methods


Compare Overloaded. Calls the base collating
sequence to compare two strings
Equals (inherited from Indicates whether this instance and
ValueType) a specified object are equal.
GetHashCode (inherited from Returns the hash code for this
ValueType) instance.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Returns the fully qualified type
ValueType) name of this instance.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
CollationSequence Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence.Compare Method

Calls the base collating sequence to compare two character arrays

Overload List
Calls the base collating sequence to compare two character arrays
public int Compare(char[],char[])
Calls the base collating sequence to compare two strings
public int Compare(string,string)

See Also
CollationSequence Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence.Compare(Char, Char) Method

Calls the base collating sequence to compare two character arrays

public int Compare(


char[] c1,
char[] c2
);

Parameters
c1
The first array to compare
c2
The second array to compare

Return Value
-1 if c1 is less than c2, 0 if c1 is equal to c2, and 1 if c1 is greater than c2

See Also
CollationSequence Class | System.Data.SQLite Namespace |
CollationSequence.Compare Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationSequence.Compare(String, String) Method

Calls the base collating sequence to compare two strings

public int Compare(


string s1,
string s2
);

Parameters
s1
The first string to compare
s2
The second string to compare

Return Value
-1 if s1 is less than s2, 0 if s1 is equal to s2, and 1 if s1 is greater than s2

See Also
CollationSequence Class | System.Data.SQLite Namespace |
CollationSequence.Compare Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CollationTypeEnum Enumeration

The type of collating sequence

public enum CollationTypeEnum

Members
Member Name Description
Binary The built-in BINARY collating
sequence
NoCase The built-in NOCASE collating
sequence
Reverse The built-in REVERSE collating
sequence
Custom A custom user-defined collating
sequence

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CommitEventArgs Class

Event arguments raised when a transaction is being committed


For a list of all members of this type, see CommitEventArgs Members .
System.Object EventArgs
CommitEventArgs

public class CommitEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
CommitEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CommitEventArgs Members

CommitEventArgs overview

Public Instance Fields


AbortTransaction Set to true to abort the transaction
and trigger a rollback

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
CommitEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CommitEventArgs Fields

The fields of the CommitEventArgs class are listed below. For a complete
list of CommitEventArgs class members, see the CommitEventArgs
Members topic.

Public Instance Fields


AbortTransaction Set to true to abort the transaction
and trigger a rollback

See Also
CommitEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
CommitEventArgs.AbortTransaction Field

Set to true to abort the transaction and trigger a rollback

public bool AbortTransaction;

See Also
CommitEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs Class

Event data for connection event handlers.


For a list of all members of this type, see ConnectionEventArgs Members .
System.Object EventArgs
ConnectionEventArgs

public class ConnectionEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
ConnectionEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs Members

ConnectionEventArgs overview

Public Instance Fields


Command The command associated with this
event, if any.
CriticalHandle The critical handle associated with
this event, if any.
Data Extra data associated with this
event, if any.
DataReader The data reader associated with
this event, if any.
EventArgs The StateChangeEventArgs
associated with this event, if any.
EventType The type of event being raised.
Text Command or message text
associated with this event, if any.
Transaction The transaction associated with this
event, if any.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs Fields

The fields of the ConnectionEventArgs class are listed below. For a


complete list of ConnectionEventArgs class members, see the
ConnectionEventArgs Members topic.

Public Instance Fields


Command The command associated with this
event, if any.
CriticalHandle The critical handle associated with
this event, if any.
Data Extra data associated with this
event, if any.
DataReader The data reader associated with
this event, if any.
EventArgs The StateChangeEventArgs
associated with this event, if any.
EventType The type of event being raised.
Text Command or message text
associated with this event, if any.
Transaction The transaction associated with this
event, if any.

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.Command Field

The command associated with this event, if any.

public readonly IDbCommand Command;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.CriticalHandle Field

The critical handle associated with this event, if any.

public readonly CriticalHandle CriticalHandle;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.Data Field

Extra data associated with this event, if any.

public readonly object Data;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.DataReader Field

The data reader associated with this event, if any.

public readonly IDataReader DataReader;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.EventArgs Field

The StateChangeEventArgs associated with this event, if any.

public readonly StateChangeEventArgs EventArgs;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.EventType Field

The type of event being raised.

public readonly SQLiteConnectionEventType EventType;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.Text Field

Command or message text associated with this event, if any.

public readonly string Text;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ConnectionEventArgs.Transaction Field

The transaction associated with this event, if any.

public readonly IDbTransaction Transaction;

See Also
ConnectionEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
FunctionType Enumeration

The type of user-defined function to declare

public enum FunctionType

Members
Member Name Description
Scalar Scalar functions are designed to be
called and return a result
immediately. Examples include
ABS(), Upper(), Lower(), etc.
Aggregate Aggregate functions are designed
to accumulate data until the end of
a call and then return a result
gleaned from the accumulated
data. Examples include SUM(),
COUNT(), AVG(), etc.
Collation Collating sequences are used to
sort textual data in a custom
manner, and appear in an ORDER
BY clause. Typically text in an
ORDER BY is sorted using a straight
case-insensitive comparison
function. Custom collating
sequences can be used to alter the
behavior of text sorting in a user-
defined manner.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool Interface

This interface represents a custom connection pool implementation usable


by System.Data.SQLite.
For a list of all members of this type, see ISQLiteConnectionPool Members
.

public interface ISQLiteConnectionPool

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
ISQLiteConnectionPool Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool Members

ISQLiteConnectionPool overview

Public Instance Methods


Add Adds a connection to the pool of
those associated with the specified
database file name.
ClearAllPools Disposes of all pooled connections.
ClearPool Disposes of all pooled connections
associated with the specified
database file name.
GetCounts Counts the number of pool entries
matching the specified file name.
Remove Removes a connection from the
pool of those associated with the
specified database file name with
the intent of using it to interact
with the database.

See Also
ISQLiteConnectionPool Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool Methods

The methods of the ISQLiteConnectionPool interface are listed below.


For a complete list of ISQLiteConnectionPool interface members, see
the ISQLiteConnectionPool Members topic.

Public Instance Methods


Add Adds a connection to the pool of
those associated with the specified
database file name.
ClearAllPools Disposes of all pooled connections.
ClearPool Disposes of all pooled connections
associated with the specified
database file name.
GetCounts Counts the number of pool entries
matching the specified file name.
Remove Removes a connection from the
pool of those associated with the
specified database file name with
the intent of using it to interact
with the database.

See Also
ISQLiteConnectionPool Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool.Add Method

Adds a connection to the pool of those associated with the specified


database file name.

void Add(
string fileName,
object handle,
int version
);

Parameters
fileName
The database file name.
handle
The database connection handle.
version
The connection pool version at the point the database connection
handle was received from the connection pool. This is also the
connection pool version that the database connection handle was
created under.

See Also
ISQLiteConnectionPool Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool.ClearAllPools Method

Disposes of all pooled connections.

void ClearAllPools();

See Also
ISQLiteConnectionPool Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool.ClearPool Method

Disposes of all pooled connections associated with the specified database


file name.

void ClearPool(
string fileName
);

Parameters
fileName
The database file name.

See Also
ISQLiteConnectionPool Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool.GetCounts Method

Counts the number of pool entries matching the specified file name.

void GetCounts(
string fileName,
ref Dictionary<string, int> counts,
ref int openCount,
ref int closeCount,
ref int totalCount
);

Parameters
fileName
The file name to match or null to match all files.
counts
The pool entry counts for each matching file.
openCount
The total number of connections successfully opened from any pool.
closeCount
The total number of connections successfully closed from any pool.
totalCount
The total number of pool entries for all matching files.

See Also
ISQLiteConnectionPool Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteConnectionPool.Remove Method

Removes a connection from the pool of those associated with the specified
database file name with the intent of using it to interact with the
database.

object Remove(
string fileName,
int maxPoolSize,
out int version
);

Parameters
fileName
The database file name.
maxPoolSize
The new maximum size of the connection pool for the specified
database file name.
version
The connection pool version associated with the returned database
connection handle, if any.

Return Value
The database connection handle associated with the specified database file
name or null if it cannot be obtained.

See Also
ISQLiteConnectionPool Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule Interface

This interface represents a virtual table implementation written in


managed code.
For a list of all members of this type, see ISQLiteManagedModule Members
.

public interface ISQLiteManagedModule

Types that implement ISQLiteManagedModule


Type Description
SQLiteModuleEnumerable(T) This class implements a virtual table module th
instance as a read-only virtual table. It is not s
class for any user-defined virtual table class th
instance.
SQLiteModule This class represents a managed virtual table m
and must be used as the base class for any use
implemented in managed code.
SQLiteModuleCommon This class contains some virtual methods that m
classes. It specifically does NOT implement any
interface methods.
SQLiteModuleEnumerable This class implements a virtual table module th
instance as a read-only virtual table. It is not s
class for any user-defined virtual table class th
instance. The following short example shows it
as a table data source:
public static class Sample
{
public static void Main()
{
using (SQLiteConnection connecti
"Data Source=:memory:;"))
{
connection.Open();

connection.CreateModule(new SQ
"sampleModule", new string[]

using (SQLiteCommand command =


{
command.CommandText =
"CREATE VIRTUAL TABLE t1

command.ExecuteNonQuery();
}

using (SQLiteCommand command =


{
command.CommandText = "SELEC

using (SQLiteDataReader data


{
while (dataReader.Read())
Console.WriteLine(dataRe
}
}

connection.Close();
}
}
}

SQLiteModuleNoop This class implements a virtual table module th


implementations for all of the ISQLiteManagedM
codes returned by these "empty" method imple
per-method basis by using and/or overriding th
ResultCodeToEofResult, ResultCodeToFindFuncti
SetMethodResultCode methods from within der

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
ISQLiteManagedModule Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule Members

ISQLiteManagedModule overview

Public Instance Properties


Declared Returns non-zero if the schema for
the virtual table has been declared.
Name Returns the name of the module as
it was registered with the SQLite
core library.

Public Instance Methods


Begin This method is called in response to
the xBegin method.
BestIndex This method is called in response to
the xBestIndex method.
Close This method is called in response to
the xClose method.
Column This method is called in response to
the xColumn method.
Commit This method is called in response to
the xCommit method.
Connect This method is called in response to
the xConnect method.
Create This method is called in response to
the xCreate method.
Destroy This method is called in response to
the xDestroy method.
Disconnect This method is called in response to
the xDisconnect method.
Eof This method is called in response to
the xEof method.
Filter This method is called in response to
the xFilter method.
FindFunction This method is called in response to
the xFindFunction method.
Next This method is called in response to
the xNext method.
Open This method is called in response to
the xOpen method.
Release This method is called in response to
the xRelease method.
Rename This method is called in response to
the xRename method.
Rollback This method is called in response to
the xRollback method.
RollbackTo This method is called in response to
the xRollbackTo method.
RowId This method is called in response to
the xRowId method.
Savepoint This method is called in response to
the xSavepoint method.
Sync This method is called in response to
the xSync method.
Update This method is called in response to
the xUpdate method.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule Properties

The properties of the ISQLiteManagedModule interface are listed below.


For a complete list of ISQLiteManagedModule interface members, see
the ISQLiteManagedModule Members topic.

Public Instance Properties


Declared Returns non-zero if the schema for
the virtual table has been declared.
Name Returns the name of the module as
it was registered with the SQLite
core library.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Declared Property

Returns non-zero if the schema for the virtual table has been declared.

public bool Declared { public get; }

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Name Property

Returns the name of the module as it was registered with the SQLite core
library.

public string Name { public get; }

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule Methods

The methods of the ISQLiteManagedModule interface are listed below.


For a complete list of ISQLiteManagedModule interface members, see
the ISQLiteManagedModule Members topic.

Public Instance Methods


Begin This method is called in response to
the xBegin method.
BestIndex This method is called in response to
the xBestIndex method.
Close This method is called in response to
the xClose method.
Column This method is called in response to
the xColumn method.
Commit This method is called in response to
the xCommit method.
Connect This method is called in response to
the xConnect method.
Create This method is called in response to
the xCreate method.
Destroy This method is called in response to
the xDestroy method.
Disconnect This method is called in response to
the xDisconnect method.
Eof This method is called in response to
the xEof method.
Filter This method is called in response to
the xFilter method.
FindFunction This method is called in response to
the xFindFunction method.
Next This method is called in response to
the xNext method.
Open This method is called in response to
the xOpen method.
Release This method is called in response to
the xRelease method.
Rename This method is called in response to
the xRename method.
Rollback This method is called in response to
the xRollback method.
RollbackTo This method is called in response to
the xRollbackTo method.
RowId This method is called in response to
the xRowId method.
Savepoint This method is called in response to
the xSavepoint method.
Sync This method is called in response to
the xSync method.
Update This method is called in response to
the xUpdate method.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Begin Method

This method is called in response to the xBegin method.

SQLiteErrorCode Begin(
SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.BestIndex Method

This method is called in response to the xBestIndex method.

SQLiteErrorCode BestIndex(
SQLiteVirtualTable table,
SQLiteIndex index
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
index
The SQLiteIndex object instance containing all the data for the inputs
and outputs relating to index selection.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Close Method

This method is called in response to the xClose method.

SQLiteErrorCode Close(
SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Column Method

This method is called in response to the xColumn method.

SQLiteErrorCode Column(
SQLiteVirtualTableCursor cursor,
SQLiteContext context,
int index
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
context
The SQLiteContext object instance to be used for returning the
specified column value to the SQLite core library.
index
The zero-based index corresponding to the column containing the value
to be returned.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Commit Method

This method is called in response to the xCommit method.

SQLiteErrorCode Commit(
SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Connect Method

This method is called in response to the xConnect method.

SQLiteErrorCode Connect(
SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
The SQLiteConnection object instance associated with the virtual table.
pClientData
The native user-data pointer associated with this module, as it was
provided to the SQLite core library when the native module instance
was created.
arguments
The module name, database name, virtual table name, and all other
arguments passed to the CREATE VIRTUAL TABLE statement.
table
Upon success, this parameter must be modified to contain the
SQLiteVirtualTable object instance associated with the virtual table.
error
Upon failure, this parameter must be modified to contain an error
message.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Create Method

This method is called in response to the xCreate method.

SQLiteErrorCode Create(
SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
The SQLiteConnection object instance associated with the virtual table.
pClientData
The native user-data pointer associated with this module, as it was
provided to the SQLite core library when the native module instance
was created.
arguments
The module name, database name, virtual table name, and all other
arguments passed to the CREATE VIRTUAL TABLE statement.
table
Upon success, this parameter must be modified to contain the
SQLiteVirtualTable object instance associated with the virtual table.
error
Upon failure, this parameter must be modified to contain an error
message.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Destroy Method

This method is called in response to the xDestroy method.

SQLiteErrorCode Destroy(
SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Disconnect Method

This method is called in response to the xDisconnect method.

SQLiteErrorCode Disconnect(
SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Eof Method

This method is called in response to the xEof method.

bool Eof(
SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.

Return Value
Non-zero if no more rows are available; zero otherwise.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Filter Method

This method is called in response to the xFilter method.

SQLiteErrorCode Filter(
SQLiteVirtualTableCursor cursor,
int indexNumber,
string indexString,
SQLiteValue[] values
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
indexNumber
Number used to help identify the selected index.
indexString
String used to help identify the selected index.
values
The values corresponding to each column in the selected index.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.FindFunction Method

This method is called in response to the xFindFunction method.

bool FindFunction(
SQLiteVirtualTable table,
int argumentCount,
string name,
ref SQLiteFunction function,
ref IntPtr pClientData
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
argumentCount
The number of arguments to the function being sought.
name
The name of the function being sought.
function
Upon success, this parameter must be modified to contain the
SQLiteFunction object instance responsible for implementing the
specified function.
pClientData
Upon success, this parameter must be modified to contain the native
user-data pointer associated with function.

Return Value
Non-zero if the specified function was found; zero otherwise.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Next Method

This method is called in response to the xNext method.

SQLiteErrorCode Next(
SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Open Method

This method is called in response to the xOpen method.

SQLiteErrorCode Open(
SQLiteVirtualTable table,
ref SQLiteVirtualTableCursor cursor
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
cursor
Upon success, this parameter must be modified to contain the
SQLiteVirtualTableCursor object instance associated with the newly
opened virtual table cursor.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Release Method

This method is called in response to the xRelease method.

SQLiteErrorCode Release(
SQLiteVirtualTable table,
int savepoint
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
savepoint
This is an integer used to indicate that any saved states with an
identifier greater than or equal to this should be deleted by the virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Rename Method

This method is called in response to the xRename method.

SQLiteErrorCode Rename(
SQLiteVirtualTable table,
string newName
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
newName
The new name for the virtual table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Rollback Method

This method is called in response to the xRollback method.

SQLiteErrorCode Rollback(
SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.RollbackTo Method

This method is called in response to the xRollbackTo method.

SQLiteErrorCode RollbackTo(
SQLiteVirtualTable table,
int savepoint
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
savepoint
This is an integer identifier used to specify a specific saved state for the
virtual table for it to restore itself back to, which should also have the
effect of deleting all saved states with an integer identifier greater than
this one.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.RowId Method

This method is called in response to the xRowId method.

SQLiteErrorCode RowId(
SQLiteVirtualTableCursor cursor,
ref long rowId
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
rowId
Upon success, this parameter must be modified to contain the unique
integer row identifier for the current row for the specified cursor.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Savepoint Method

This method is called in response to the xSavepoint method.

SQLiteErrorCode Savepoint(
SQLiteVirtualTable table,
int savepoint
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
savepoint
This is an integer identifier under which the the current state of the
virtual table should be saved.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Sync Method

This method is called in response to the xSync method.

SQLiteErrorCode Sync(
SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteManagedModule.Update Method

This method is called in response to the xUpdate method.

SQLiteErrorCode Update(
SQLiteVirtualTable table,
SQLiteValue[] values,
ref long rowId
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
values
The array of SQLiteValue object instances containing the new or
modified column values, if any.
rowId
Upon success, this parameter must be modified to contain the unique
integer row identifier for the row that was inserted, if any.

Return Value
A standard SQLite return code.

See Also
ISQLiteManagedModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeHandle Interface

This interface represents a native handle provided by the SQLite core


library.
For a list of all members of this type, see ISQLiteNativeHandle Members .

public interface ISQLiteNativeHandle

Types that implement ISQLiteNativeHandle


Type Description
SQLiteVirtualTableCursorEnumerator(T) This class represents a virtual
table cursor to be used with the
SQLiteModuleEnumerable class.
It is not sealed and may be
used as the base class for any
user-defined virtual table
cursor class that wraps an
IEnumerator`1 object instance.
SQLiteContext This class represents a context
from the SQLite core library
that can be passed to the
sqlite3_result_*() and
associated functions.
SQLiteValue This class represents a value
from the SQLite core library
that can be passed to the
sqlite3_value_*() and
associated functions.
SQLiteVirtualTable This class represents a
managed virtual table
implementation. It is not sealed
and should be used as the base
class for any user-defined
virtual table classes
implemented in managed code.
SQLiteVirtualTableCursor This class represents a
managed virtual table cursor
implementation. It is not sealed
and should be used as the base
class for any user-defined
virtual table cursor classes
implemented in managed code.
SQLiteVirtualTableCursorEnumerator This class represents a virtual
table cursor to be used with the
SQLiteModuleEnumerable class.
It is not sealed and may be
used as the base class for any
user-defined virtual table
cursor class that wraps an
IEnumerator object instance.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
ISQLiteNativeHandle Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeHandle Members

ISQLiteNativeHandle overview

Public Instance Properties


NativeHandle The native handle value.

See Also
ISQLiteNativeHandle Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeHandle Properties

The properties of the ISQLiteNativeHandle interface are listed below. For


a complete list of ISQLiteNativeHandle interface members, see the
ISQLiteNativeHandle Members topic.

Public Instance Properties


NativeHandle The native handle value.

See Also
ISQLiteNativeHandle Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeHandle.NativeHandle Property

The native handle value.

public IntPtr NativeHandle { public get; }

See Also
ISQLiteNativeHandle Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule Interface

This interface represents a virtual table implementation written in native


code.
For a list of all members of this type, see ISQLiteNativeModule Members .

public interface ISQLiteNativeModule

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
ISQLiteNativeModule Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule Members

ISQLiteNativeModule overview

Public Instance Methods


xBegin
int (*xBegin)(sqlite3_vtab *pVTab);

This method begins a transaction on a virtual table. This is me


of sqlite3_module may be NULL. This method is always follow
or xRollback method. Virtual table transactions do not nest, so
invoked more than once on a single virtual table without an in
xRollback. Multiple calls to other methods can and likely will o
corresponding xCommit or xRollback.
xBestIndex SQLite uses the xBestIndex method of a virtual table module
the virtual table. The xBestIndex method has a prototype like
int (*xBestIndex)(sqlite3_vtab *pVTab, sqlite3_index

The SQLite core communicates with the xBestIndex method b


sqlite3_index_info structure and passing a pointer to that stru
parameter. The xBestIndex method fills out other fields of this
sqlite3_index_info structure looks like this:
struct sqlite3_index_info {
/* Inputs */
const int nConstraint; /* Number of entries in
const struct sqlite3_index_constraint {
int iColumn; /* Column constrained
unsigned char op; /* Constraint operato
unsigned char usable; /* True if this const
int iTermOffset; /* Used internally -
} *const aConstraint; /* Table of WHERE claus
const int nOrderBy; /* Number of terms in t
const struct sqlite3_index_orderby {
int iColumn; /* Column number */
unsigned char desc; /* True for DESC. Fa
} *const aOrderBy; /* The ORDER BY clause
/* Outputs */
struct sqlite3_index_constraint_usage {
int argvIndex; /* if >0, constraint is
unsigned char omit; /* Do not code a test f
} *const aConstraintUsage;
int idxNum; /* Number used to ident
char *idxStr; /* String, possibly obt
int needToFreeIdxStr; /* Free idxStr using sq
int orderByConsumed; /* True if output is al
double estimatedCost; /* Estimated cost of us
/* Fields below are only available in SQLit
sqlite3_int64 estimatedRows; /* Estimated numbe
/* Fields below are only available in SQLit
int idxFlags; /* Mask of SQLITE_INDEX
/* Fields below are only available in SQLit
sqlite3_uint64 colUsed; /* Input: Mask of colum
};
Note the warnings on the "estimatedRows", "idxFlags", and co
with SQLite versions 3.8.2, 3.9.0, and 3.10.0, respectively. An
these fields must first check that the version of the SQLite lib
to appropriate version - perhaps comparing the value returne
against constants 3008002, 3009000, and/or 3010000. The r
fields in an sqlite3_index_info structure created by an older v
addition, there are some defined constants:
#define SQLITE_INDEX_CONSTRAINT_EQ 2
#define SQLITE_INDEX_CONSTRAINT_GT 4
#define SQLITE_INDEX_CONSTRAINT_LE 8
#define SQLITE_INDEX_CONSTRAINT_LT 16
#define SQLITE_INDEX_CONSTRAINT_GE 32
#define SQLITE_INDEX_CONSTRAINT_MATCH 64
#define SQLITE_INDEX_CONSTRAINT_LIKE 65 /* 3.1
#define SQLITE_INDEX_CONSTRAINT_GLOB 66 /* 3.1
#define SQLITE_INDEX_CONSTRAINT_REGEXP 67 /* 3.1
#define SQLITE_INDEX_SCAN_UNIQUE 1 /* Sca

The SQLite core calls the xBestIndex method when it is compi


table. In other words, SQLite calls this method when it is runn
equivalent. By calling this method, the SQLite core is saying t
access some subset of the rows in the virtual table and it wan
do that access. The xBestIndex method replies with informatio
to conduct an efficient search of the virtual table. While comp
core might call xBestIndex multiple times with different settin
core will then select the combination that appears to give the
method, the SQLite core initializes an instance of the sqlite3_
information about the query that it is currently trying to proce
from the WHERE clause and ORDER BY or GROUP BY clauses
USING clauses if the query is a join. The information that the
xBestIndex method is held in the part of the structure that is
section is initialized to zero. The information in the sqlite3_in
may be overwritten or deallocated as soon as the xBestIndex
method needs to remember any part of the sqlite3_index_info
Care must be take to store the copy in a place where it will be
field with needToFreeIdxStr set to 1. Note that xBestIndex wil
since the idxNum and idxStr outputs from xBestIndex are req
there is no guarantee that xFilter will be called following a su
method is required for every virtual table implementation. Th
trying to communicate to the virtual table is the constraints th
of rows that need to be searched. The aConstraint[] array con
There will be exactly nConstraint entries in that array. Each c
the WHERE clause or in a USING or ON clause that is of the fo
column OP EXPR

Where "column" is a column in the virtual table, OP is an ope


arbitrary expression. So, for example, if the WHERE clause co
a = 5

Then one of the constraints would be on the "a" column with o


"5". Constraints need not have a literal representation of the
might make transformations to the WHERE clause in order to
can. So, for example, if the WHERE clause contained somethin
x BETWEEN 10 AND 100 AND 999>y

The query optimizer might translate this into three separate c


x >= 10
x <= 100
y < 999

For each constraint, the aConstraint[].iColumn field indicates


hand side of the constraint. The first column of the virtual tab
virtual table is column -1. The aConstraint[].op field indicates
SQLITE_INDEX_CONSTRAINT_* constants map integer consta
occur in the order they were defined by the call to sqlite3_dec
xConnect method. Hidden columns are counted when determi
aConstraint[] array contains information about all constraints
some of the constraints might not be usable because of the w
xBestIndex method must therefore only consider constraints t
flag which is true. In addition to WHERE clause constraints, th
xBestIndex method about the ORDER BY clause. (In an aggre
put in GROUP BY clause information in place of the ORDER BY
should not make any difference to the xBestIndex method.) If
are columns in the virtual table, then nOrderBy will be the nu
clause and the aOrderBy[] array will identify the column for e
whether or not that column is ASC or DESC. In SQLite version
colUsed field is available to indicate which fields of the virtual
statement being prepared. If the lowest bit of colUsed is set, t
used. The second lowest bit corresponds to the second column
bit of colUsed is set, that means that one or more columns oth
used. If column usage information is needed by the xFilter me
encoded into either the idxNum or idxStr output fields. Given
of the xBestIndex method it to figure out the best way to sear
method fills the idxNum and idxStr fields with information tha
to the xFilter method. The information in idxNum and idxStr i
is concerned. The SQLite core just copies the information thro
desired meaning can be assigned to idxNum and idxStr as lon
what that meaning is. The idxStr value may be a string obtain
allocation function such as sqlite3_mprintf(). If this is the cas
must be set to true so that the SQLite core will know to call sq
has finished with it, and thus avoid a memory leak. If the virt
order specified by the ORDER BY clause, then the orderByCon
output is not automatically in the correct order then orderByC
false setting. This will indicate to the SQLite core that it will n
over the data after it comes out of the virtual table. The estim
estimated number of disk access operations required to execu
table. The SQLite core will often call xBestIndex multiple time
multiple cost estimates, then choose the query plan that gives
version of SQLite is 3.8.2 or greater, the estimatedRows field
number of rows returned by the proposed query plan. If this v
estimate of 25 rows is used. If the current version of SQLite is
may be set to SQLITE_INDEX_SCAN_UNIQUE to indicate that
zero or one rows given the input constraints. Additional bits o
understood in later versions of SQLite. The aConstraintUsage[
each of the nConstraint constraints in the inputs section of th
aConstraintUsage[] array is used by xBestIndex to tell the cor
xBestIndex method may set aConstraintUsage[].argvIndex en
Exactly one entry should be set to 1, another to 2, another to
few as the xBestIndex method wants. The EXPR of the corresp
passed in as the argv[] parameters to xFilter. For example, if
to 1, then when xFilter is called, the argv[0] passed to xFilter
aConstraint[3] constraint. By default, the SQLite core double
the virtual table that it receives. If such a check is redundant,
suppress that double-check by setting aConstraintUsage[].om
xClose
int (*xClose)(sqlite3_vtab_cursor*);

The xClose method closes a cursor previously opened by xOpe


xClose once for each cursor opened using xOpen. This method
by the corresponding xOpen call. The routine will not be calle
The SQLite core will not use the sqlite3_vtab_cursor again aft
method is required for every virtual table implementation.
xColumn
int (*xColumn)(sqlite3_vtab_cursor*, sqlite3_context

The SQLite core invokes this method in order to find the value
row. N is zero-based so the first column is numbered 0. The x
back to SQLite using one of the following interface:
sqlite3_result_blob()
sqlite3_result_double()
sqlite3_result_int()
sqlite3_result_int64()
sqlite3_result_null()
sqlite3_result_text()
sqlite3_result_text16()
sqlite3_result_text16le()
sqlite3_result_text16be()
sqlite3_result_zeroblob()
If the xColumn method implementation calls none of the func
column defaults to an SQL NULL. To raise an error, the xColum
result_text() methods to set the error message text, then retu
xColumn method must return SQLITE_OK on success. The xC
virtual table implementation.
xCommit
int (*xCommit)(sqlite3_vtab *pVTab);

This method causes a virtual table transaction to commit. This


pointer of sqlite3_module may be NULL. A call to this method
and xSync.
xConnect
int (*xConnect)(sqlite3*, void *pAux,
int argc, char **argv,
sqlite3_vtab **ppVTab,
char **pzErr);

The xConnect method is very similar to xCreate. It has the sa


sqlite3_vtab structure just like xCreate. And it must also call
The difference is that xConnect is called to establish a new co
whereas xCreate is called to create a new virtual table from s
methods are only different when the virtual table has some ki
initialized the first time the virtual table is created. The xCrea
backing store. The xConnect method just connects to an exist
xConnect are the same, the table is an eponymous virtual tab
table implementation that provides read-only access to existin
files on disk. There is no backing store that needs to be create
table (since the CSV files already exist on disk) so the xCreat
identical for that module. Another example is a virtual table t
xCreate method must create and initialize data structures to h
for that index. The xConnect method, on the other hand, only
dictionary and posting lists that were created by a prior xCrea
return SQLITE_OK if it is successful in creating the new virtua
successful. If not successful, the sqlite3_vtab structure must n
may optionally be returned in *pzErr if unsuccessful. Space to
be allocated using an SQLite memory allocation function like s
as the SQLite core will attempt to free the space using sqlite3
reported up to the application. The xConnect method is requir
implementation, though the xCreate and xConnect pointers o
point to the same function if the virtual table does not need to
xCreate
int (*xCreate)(sqlite3 *db, void *pAux,
int argc, char **argv,
sqlite3_vtab **ppVTab,
char **pzErr);

The xCreate method is called to create a new instance of a vir


VIRTUAL TABLE statement. If the xCreate method is the same
then the virtual table is an eponymous virtual table. If the xC
NULL pointer) then the virtual table is an eponymous-only vir
pointer to the SQLite database connection that is executing th
statement. The pAux argument is the copy of the client data p
to the sqlite3_create_module() or sqlite3_create_module_v2(
table module. The argv parameter is an array of argc pointers
string, argv[0], is the name of the module being invoked. The
as the second argument to sqlite3_create_module() and as th
the CREATE VIRTUAL TABLE statement that is running. The se
database in which the new virtual table is being created. The
primary database, or "temp" for TEMP database, or the name
statement for attached databases. The third element of the ar
virtual table, as specified following the TABLE keyword in the
If present, the fourth and subsequent strings in the argv[] arr
module name in the CREATE VIRTUAL TABLE statement. The j
new virtual table object (an sqlite3_vtab object) and return a
the task of creating a new sqlite3_vtab structure, this method
to tell the SQLite core about the columns and datatypes in the
sqlite3_declare_vtab() API has the following prototype:
int sqlite3_declare_vtab(sqlite3 *db, const char *zC

The first argument to sqlite3_declare_vtab() must be the sam


first parameter to this method. The second argument to sqlite
terminated UTF-8 string that contains a well-formed CREATE
columns in the virtual table and their data types. The name o
statement is ignored, as are all constraints. Only the column n
CREATE TABLE statement string need not to be held in persist
deallocated and/or reused as soon as the sqlite3_declare_vtab
method need not initialize the pModule, nRef, and zErrMsg fie
SQLite core will take care of that chore. The xCreate should r
creating the new virtual table, or SQLITE_ERROR if it is not su
sqlite3_vtab structure must not be allocated. An error messag
*pzErr if unsuccessful. Space to hold the error message string
memory allocation function like sqlite3_malloc() or sqlite3_m
attempt to free the space using sqlite3_free() after the error
application. If the xCreate method is omitted (left as a NULL p
eponymous-only virtual table. New instances of the virtual tab
VIRTUAL TABLE and the virtual table can only be used via its
versions prior to 3.9.0 do not understand eponymous-only vir
attempt is made to CREATE VIRTUAL TABLE on an eponymous
xCreate method was not checked for null. If the xCreate meth
xConnect method, that indicates that the virtual table does no
Such a virtual table can be used as an eponymous virtual tabl
CREATE VIRTUAL TABLE or both. If a column datatype contain
any combination of upper and lower case letters) then that ke
datatype name and the column is marked as a hidden column
from a normal column in three respects:
Hidden columns are not listed in the dataset retur
Hidden columns are not included in the expansion
of a SELECT, and
Hidden columns are not included in the implicit co
statement that lacks an explicit column-list.
For example, if the following SQL is passed to sqlite3_declare_
CREATE TABLE x(a HIDDEN VARCHAR(12), b INTEGER, c IN

Then the virtual table would be created with two hidden colum
"VARCHAR(12)" and "INTEGER". An example use of hidden co
virtual table implementation, where every FTS virtual table co
used to pass information from the virtual table into FTS auxili
operator. A virtual table that contains hidden columns can be
the FROM clause of a SELECT statement. The arguments to th
constraints on the HIDDEN columns of the virtual table. For e
extension (located in the ext/misc/series.c file in the source t
virtual table with the following schema:
CREATE TABLE generate_series(
value,
start HIDDEN,
stop HIDDEN,
step HIDDEN
);

The sqlite3_module.xBestIndex method in the implementation


constraints against the HIDDEN columns, and uses those as in
range of integer "value" outputs to generate. Reasonable defa
columns. For example, to list all integers between 5 and 50:
SELECT value FROM generate_series(5,50);

The previous query is equivalent to the following:


SELECT value FROM generate_series WHERE start=5 AND

Arguments on the virtual table name are matched to hidden c


arguments can be less than the number of hidden columns, in
columns are unconstrained. However, an error results if there
hidden columns in the virtual table. Beginning with SQLite ve
CREATE TABLE statement that is passed into sqlite3_declare_
ROWID clause. This is useful for cases where the virtual table
unique integers. A CREATE TABLE statement that includes WI
more columns as the PRIMARY KEY. Every column of the PRIM
NULL and all columns for each row must be collectively unique
the PRIMARY KEY for a WITHOUT ROWID virtual table. Enforc
underlying virtual table implementation. But SQLite does assu
is valid - that the identified columns really are UNIQUE and N
assumption to optimize queries against the virtual table. The
WITHOUT ROWID virtual table (of course). Furthermore, since
having a valid rowid, the xUpdate method must be NULL for a
in turn means that WITHOUT ROWID virtual tables must be re
xDestroy
int (*xDestroy)(sqlite3_vtab *pVTab);

This method releases a connection to a virtual table, just like


destroys the underlying table implementation. This method un
xDisconnect method is called whenever a database connection
The xDestroy method is only called when a DROP TABLE state
table. The xDestroy method is required for every virtual table
acceptable for the xDisconnect and xDestroy methods to be th
for the particular virtual table.
xDisconnect
int (*xDisconnect)(sqlite3_vtab *pVTab);

This method releases a connection to a virtual table. Only the


The virtual table is not destroyed and any backing store assoc
This method undoes the work of xConnect. This method is a d
virtual table. Contrast this method with xDestroy. The xDestro
virtual table. The xDisconnect method is required for every vi
is acceptable for the xDisconnect and xDestroy methods to be
sense for the particular virtual table.
xEof
int (*xEof)(sqlite3_vtab_cursor*);

The xEof method must return false (zero) if the specified curs
data, or true (non-zero) otherwise. This method is called by th
each xFilter and xNext invocation. The xEof method is require
implementation.
xFilter
int (*xFilter)(sqlite3_vtab_cursor*, int idxNum, con
int argc, sqlite3_value **argv);

This method begins a search of a virtual table. The first argum


The next two arguments define a particular search index prev
specific meanings of idxNum and idxStr are unimportant as lo
on what that meaning is. The xBestIndex function may have r
expressions using the aConstraintUsage[].argvIndex values o
Those values are passed to xFilter using the argc and argv pa
contains one or more rows that match the search criteria, the
first row. Subsequent calls to xEof must return false (zero). If
cursor must be left in a state that will cause the xEof to retur
will use the xColumn and xRowid methods to access that row
used to advance to the next row. This method must return SQ
error code if an error occurs. The xFilter method is required fo
implementation.

xFindFunction int (*xFindFunction)(


sqlite3_vtab *pVtab,
int nArg,
const char *zName,
void (**pxFunc)(sqlite3_context*,int,sqlite3_value
void **ppArg
);

This method is called during sqlite3_prepare() to give the virt


opportunity to overload functions. This method may be set to
occurs. When a function uses a column from a virtual table as
called to see if the virtual table would like to overload the fun
inputs: the virtual table, the number of arguments to the func
If no overloading is desired, this method returns 0. To overloa
the new function implementation into *pxFunc and writes use
Note that infix functions (LIKE, GLOB, REGEXP, and MATCH) r
So "like(A,B)" is equivalent to "B like A". For the form "B like
argument to the function. But for "like(A,B)" the A term is con
function pointer returned by this routine must be valid for the
given in the first parameter.
xNext
int (*xNext)(sqlite3_vtab_cursor*);

The xNext method advances a virtual table cursor to the next


xFilter. If the cursor is already pointing at the last row when t
no longer points to valid data and a subsequent call to the xE
zero). If the cursor is successfully advanced to another row of
xEof must return false (zero). This method must return SQLIT
code if an error occurs. The xNext method is required for ever
xOpen
int (*xOpen)(sqlite3_vtab *pVTab, sqlite3_vtab_curso
The xOpen method creates a new cursor used for accessing (r
successful invocation of this method will allocate the memory
subclass), initialize the new object, and make *ppCursor poin
call then returns SQLITE_OK. For every successful call to this
invoke the xClose method to destroy the allocated cursor. The
the pVtab field of the sqlite3_vtab_cursor structure. The SQLi
automatically. A virtual table implementation must be able to
simultaneously open cursors. When initially opened, the curso
SQLite core will invoke the xFilter method on the cursor prior
from the cursor. The xOpen method is required for every virtu

xRelease
int (*xSavepoint)(sqlite3_vtab *pVtab, int);
int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an op


transactions. They are always optional and will only be called
23) and later. When xSavepoint(X,N) is invoked, that is a sign
should save its current state as savepoint N. A subsequent ca
state of the virtual table should return to what it was when xS
call to xRollbackTo(X,R) will invalidate all savepoints with N>R
will be rolled back or released without first being reinitialized
xRelease(X,M) invalidates all savepoints where N>=M. None o
xRollbackTo() methods will ever be called except in between c
xCommit() or xRollback().
xRename
int (*xRename)(sqlite3_vtab *pVtab, const char *zNew

This method provides notification that the virtual table implem


be given a new name. If this method returns SQLITE_OK then
method returns an error code then the renaming is prevented
for every virtual table implementation.
xRollback
int (*xRollback)(sqlite3_vtab *pVTab);

This method causes a virtual table transaction to rollback. Thi


xRollback pointer of sqlite3_module may be NULL. A call to th
to xBegin.
xRollbackTo
int (*xSavepoint)(sqlite3_vtab *pVtab, int);
int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);
These methods provide the virtual table implementation an op
transactions. They are always optional and will only be called
23) and later. When xSavepoint(X,N) is invoked, that is a sign
should save its current state as savepoint N. A subsequent ca
state of the virtual table should return to what it was when xS
call to xRollbackTo(X,R) will invalidate all savepoints with N>R
will be rolled back or released without first being reinitialized
xRelease(X,M) invalidates all savepoints where N>=M. None o
xRollbackTo() methods will ever be called except in between c
xCommit() or xRollback().

xRowId
int (*xRowid)(sqlite3_vtab_cursor *pCur, sqlite_int6

A successful invocation of this method will cause *pRowid to b


the virtual table cursor pCur is currently pointing at. This met
It returns an appropriate error code on failure. The xRowid m
table implementation.
xSavepoint
int (*xSavepoint)(sqlite3_vtab *pVtab, int);
int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an op


transactions. They are always optional and will only be called
23) and later. When xSavepoint(X,N) is invoked, that is a sign
should save its current state as savepoint N. A subsequent ca
state of the virtual table should return to what it was when xS
call to xRollbackTo(X,R) will invalidate all savepoints with N>R
will be rolled back or released without first being reinitialized
xRelease(X,M) invalidates all savepoints where N>=M. None o
xRollbackTo() methods will ever be called except in between c
xCommit() or xRollback().
xSync
int (*xSync)(sqlite3_vtab *pVTab);

This method signals the start of a two-phase commit on a virt


The xSync pointer of sqlite3_module may be NULL. This meth
xBegin method and prior to an xCommit or xRollback. In orde
the xSync method on all virtual tables is invoked prior to invo
virtual table. If any of the xSync methods fail, the entire tran
xUpdate
int (*xUpdate)(
sqlite3_vtab *pVTab,
int argc,
sqlite3_value **argv,
sqlite_int64 *pRowid
);

All changes to a virtual table are made using the xUpdate me


insert, delete, or update. The argc parameter specifies the nu
The value of argc will be 1 for a pure delete operation or N+2
where N is the number of columns in the table. In the previou
columns. Every argv entry will have a non-NULL value in C bu
In other words, it is always true that argv[i]!=0 for i between
the case that sqlite3_value_type(argv[i])==SQLITE_NULL. The arg
in the virtual table to be deleted. If argv[0] is an SQL NULL, t
parameter is the rowid of a new row to be inserted into the vi
NULL, then the implementation must choose a rowid for the n
argv[] entries contain values of the columns of the virtual tab
were declared. The number of columns will match the table de
xCreate method made using the sqlite3_declare_vtab() call. A
When doing an insert without a rowid (argc>1, argv[1] is an S
set *pRowid to the rowid of the newly inserted row; this will b
sqlite3_last_insert_rowid() function. Setting this value in all t
the SQLite engine ignores the *pRowid return value if argc==
Each call to xUpdate will fall into one of cases shown below. N
the SQL value held within the argv[i] object, not the argv[i] o

argc = 1
The single row with rowid equal to argv[0] is del

argc > 1
argv[0] = NULL
A new row is inserted with a rowid argv[1] and co
argv[2] and following. If arg
the a new unique rowid is gene

argc > 1
argv[0] NULL
argv[0] = argv[1]
The row with rowid argv[0] is updated with new va
in argv[2] and following param
argc > 1
argv[0] NULL
argv[0] argv[1]
The row with rowid argv[0] is updated with rowid
and new values in argv[2] and followi
when an SQL statement updates a rowid

UPDATE table SET rowid=rowid+1 WHE

The xUpdate method must return SQLITE_OK if and only if it


xUpdate must return an appropriate error code. On a failure,
optionally be replaced with error message text stored in mem
functions such as sqlite3_mprintf() or sqlite3_malloc(). If the
constraint of the virtual table (including, but not limited to, at
wrong datatype, attempting to store a value that is too large
a read-only value) then the xUpdate must fail with an approp
or more sqlite3_vtab_cursor objects open and in use on the v
even on the row of the virtual table when the xUpdate metho
xUpdate must be prepared for attempts to delete or modify ro
existing cursors. If the virtual table cannot accommodate such
return an error code. The xUpdate method is optional. If the x
sqlite3_module for a virtual table is a NULL pointer, then the v

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule Methods

The methods of the ISQLiteNativeModule interface are listed below. For


a complete list of ISQLiteNativeModule interface members, see the
ISQLiteNativeModule Members topic.

Public Instance Methods


xBegin
int (*xBegin)(sqlite3_vtab *pVTab);

This method begins a transaction on a virtual table. This is me


of sqlite3_module may be NULL. This method is always follow
or xRollback method. Virtual table transactions do not nest, so
invoked more than once on a single virtual table without an in
xRollback. Multiple calls to other methods can and likely will o
corresponding xCommit or xRollback.
xBestIndex SQLite uses the xBestIndex method of a virtual table module
the virtual table. The xBestIndex method has a prototype like
int (*xBestIndex)(sqlite3_vtab *pVTab, sqlite3_index

The SQLite core communicates with the xBestIndex method b


sqlite3_index_info structure and passing a pointer to that stru
parameter. The xBestIndex method fills out other fields of this
sqlite3_index_info structure looks like this:
struct sqlite3_index_info {
/* Inputs */
const int nConstraint; /* Number of entries in
const struct sqlite3_index_constraint {
int iColumn; /* Column constrained
unsigned char op; /* Constraint operato
unsigned char usable; /* True if this const
int iTermOffset; /* Used internally -
} *const aConstraint; /* Table of WHERE claus
const int nOrderBy; /* Number of terms in t
const struct sqlite3_index_orderby {
int iColumn; /* Column number */
unsigned char desc; /* True for DESC. Fa
} *const aOrderBy; /* The ORDER BY clause
/* Outputs */
struct sqlite3_index_constraint_usage {
int argvIndex; /* if >0, constraint is
unsigned char omit; /* Do not code a test f
} *const aConstraintUsage;
int idxNum; /* Number used to ident
char *idxStr; /* String, possibly obt
int needToFreeIdxStr; /* Free idxStr using sq
int orderByConsumed; /* True if output is al
double estimatedCost; /* Estimated cost of us
/* Fields below are only available in SQLit
sqlite3_int64 estimatedRows; /* Estimated numbe
/* Fields below are only available in SQLit
int idxFlags; /* Mask of SQLITE_INDEX
/* Fields below are only available in SQLit
sqlite3_uint64 colUsed; /* Input: Mask of colum
};

Note the warnings on the "estimatedRows", "idxFlags", and co


with SQLite versions 3.8.2, 3.9.0, and 3.10.0, respectively. An
these fields must first check that the version of the SQLite lib
to appropriate version - perhaps comparing the value returne
against constants 3008002, 3009000, and/or 3010000. The r
fields in an sqlite3_index_info structure created by an older v
addition, there are some defined constants:
#define SQLITE_INDEX_CONSTRAINT_EQ 2
#define SQLITE_INDEX_CONSTRAINT_GT 4
#define SQLITE_INDEX_CONSTRAINT_LE 8
#define SQLITE_INDEX_CONSTRAINT_LT 16
#define SQLITE_INDEX_CONSTRAINT_GE 32
#define SQLITE_INDEX_CONSTRAINT_MATCH 64
#define SQLITE_INDEX_CONSTRAINT_LIKE 65 /* 3.1
#define SQLITE_INDEX_CONSTRAINT_GLOB 66 /* 3.1
#define SQLITE_INDEX_CONSTRAINT_REGEXP 67 /* 3.1
#define SQLITE_INDEX_SCAN_UNIQUE 1 /* Sca

The SQLite core calls the xBestIndex method when it is compi


table. In other words, SQLite calls this method when it is runn
equivalent. By calling this method, the SQLite core is saying t
access some subset of the rows in the virtual table and it wan
do that access. The xBestIndex method replies with informatio
to conduct an efficient search of the virtual table. While comp
core might call xBestIndex multiple times with different settin
core will then select the combination that appears to give the
method, the SQLite core initializes an instance of the sqlite3_
information about the query that it is currently trying to proce
from the WHERE clause and ORDER BY or GROUP BY clauses
USING clauses if the query is a join. The information that the
xBestIndex method is held in the part of the structure that is
section is initialized to zero. The information in the sqlite3_in
may be overwritten or deallocated as soon as the xBestIndex
method needs to remember any part of the sqlite3_index_info
Care must be take to store the copy in a place where it will be
field with needToFreeIdxStr set to 1. Note that xBestIndex wil
since the idxNum and idxStr outputs from xBestIndex are req
there is no guarantee that xFilter will be called following a su
method is required for every virtual table implementation. Th
trying to communicate to the virtual table is the constraints th
of rows that need to be searched. The aConstraint[] array con
There will be exactly nConstraint entries in that array. Each c
the WHERE clause or in a USING or ON clause that is of the fo
column OP EXPR

Where "column" is a column in the virtual table, OP is an ope


arbitrary expression. So, for example, if the WHERE clause co
a = 5

Then one of the constraints would be on the "a" column with o


"5". Constraints need not have a literal representation of the
might make transformations to the WHERE clause in order to
can. So, for example, if the WHERE clause contained somethin
x BETWEEN 10 AND 100 AND 999>y

The query optimizer might translate this into three separate c


x >= 10
x <= 100
y < 999

For each constraint, the aConstraint[].iColumn field indicates


hand side of the constraint. The first column of the virtual tab
virtual table is column -1. The aConstraint[].op field indicates
SQLITE_INDEX_CONSTRAINT_* constants map integer consta
occur in the order they were defined by the call to sqlite3_dec
xConnect method. Hidden columns are counted when determi
aConstraint[] array contains information about all constraints
some of the constraints might not be usable because of the w
xBestIndex method must therefore only consider constraints t
flag which is true. In addition to WHERE clause constraints, th
xBestIndex method about the ORDER BY clause. (In an aggre
put in GROUP BY clause information in place of the ORDER BY
should not make any difference to the xBestIndex method.) If
are columns in the virtual table, then nOrderBy will be the nu
clause and the aOrderBy[] array will identify the column for e
whether or not that column is ASC or DESC. In SQLite version
colUsed field is available to indicate which fields of the virtual
statement being prepared. If the lowest bit of colUsed is set, t
used. The second lowest bit corresponds to the second column
bit of colUsed is set, that means that one or more columns oth
used. If column usage information is needed by the xFilter me
encoded into either the idxNum or idxStr output fields. Given
of the xBestIndex method it to figure out the best way to sear
method fills the idxNum and idxStr fields with information tha
to the xFilter method. The information in idxNum and idxStr i
is concerned. The SQLite core just copies the information thro
desired meaning can be assigned to idxNum and idxStr as lon
what that meaning is. The idxStr value may be a string obtain
allocation function such as sqlite3_mprintf(). If this is the cas
must be set to true so that the SQLite core will know to call sq
has finished with it, and thus avoid a memory leak. If the virt
order specified by the ORDER BY clause, then the orderByCon
output is not automatically in the correct order then orderByC
false setting. This will indicate to the SQLite core that it will n
over the data after it comes out of the virtual table. The estim
estimated number of disk access operations required to execu
table. The SQLite core will often call xBestIndex multiple time
multiple cost estimates, then choose the query plan that gives
version of SQLite is 3.8.2 or greater, the estimatedRows field
number of rows returned by the proposed query plan. If this v
estimate of 25 rows is used. If the current version of SQLite is
may be set to SQLITE_INDEX_SCAN_UNIQUE to indicate that
zero or one rows given the input constraints. Additional bits o
understood in later versions of SQLite. The aConstraintUsage[
each of the nConstraint constraints in the inputs section of th
aConstraintUsage[] array is used by xBestIndex to tell the cor
xBestIndex method may set aConstraintUsage[].argvIndex en
Exactly one entry should be set to 1, another to 2, another to
few as the xBestIndex method wants. The EXPR of the corresp
passed in as the argv[] parameters to xFilter. For example, if
to 1, then when xFilter is called, the argv[0] passed to xFilter
aConstraint[3] constraint. By default, the SQLite core double
the virtual table that it receives. If such a check is redundant,
suppress that double-check by setting aConstraintUsage[].om
xClose
int (*xClose)(sqlite3_vtab_cursor*);

The xClose method closes a cursor previously opened by xOpe


xClose once for each cursor opened using xOpen. This method
by the corresponding xOpen call. The routine will not be calle
The SQLite core will not use the sqlite3_vtab_cursor again aft
method is required for every virtual table implementation.
xColumn
int (*xColumn)(sqlite3_vtab_cursor*, sqlite3_context

The SQLite core invokes this method in order to find the value
row. N is zero-based so the first column is numbered 0. The x
back to SQLite using one of the following interface:
sqlite3_result_blob()
sqlite3_result_double()
sqlite3_result_int()
sqlite3_result_int64()
sqlite3_result_null()
sqlite3_result_text()
sqlite3_result_text16()
sqlite3_result_text16le()
sqlite3_result_text16be()
sqlite3_result_zeroblob()
If the xColumn method implementation calls none of the func
column defaults to an SQL NULL. To raise an error, the xColum
result_text() methods to set the error message text, then retu
xColumn method must return SQLITE_OK on success. The xC
virtual table implementation.
xCommit
int (*xCommit)(sqlite3_vtab *pVTab);

This method causes a virtual table transaction to commit. This


pointer of sqlite3_module may be NULL. A call to this method
and xSync.
xConnect
int (*xConnect)(sqlite3*, void *pAux,
int argc, char **argv,
sqlite3_vtab **ppVTab,
char **pzErr);

The xConnect method is very similar to xCreate. It has the sa


sqlite3_vtab structure just like xCreate. And it must also call
The difference is that xConnect is called to establish a new co
whereas xCreate is called to create a new virtual table from s
methods are only different when the virtual table has some ki
initialized the first time the virtual table is created. The xCrea
backing store. The xConnect method just connects to an exist
xConnect are the same, the table is an eponymous virtual tab
table implementation that provides read-only access to existin
files on disk. There is no backing store that needs to be create
table (since the CSV files already exist on disk) so the xCreat
identical for that module. Another example is a virtual table t
xCreate method must create and initialize data structures to h
for that index. The xConnect method, on the other hand, only
dictionary and posting lists that were created by a prior xCrea
return SQLITE_OK if it is successful in creating the new virtua
successful. If not successful, the sqlite3_vtab structure must n
may optionally be returned in *pzErr if unsuccessful. Space to
be allocated using an SQLite memory allocation function like s
as the SQLite core will attempt to free the space using sqlite3
reported up to the application. The xConnect method is requir
implementation, though the xCreate and xConnect pointers o
point to the same function if the virtual table does not need to
xCreate
int (*xCreate)(sqlite3 *db, void *pAux,
int argc, char **argv,
sqlite3_vtab **ppVTab,
char **pzErr);

The xCreate method is called to create a new instance of a vir


VIRTUAL TABLE statement. If the xCreate method is the same
then the virtual table is an eponymous virtual table. If the xC
NULL pointer) then the virtual table is an eponymous-only vir
pointer to the SQLite database connection that is executing th
statement. The pAux argument is the copy of the client data p
to the sqlite3_create_module() or sqlite3_create_module_v2(
table module. The argv parameter is an array of argc pointers
string, argv[0], is the name of the module being invoked. The
as the second argument to sqlite3_create_module() and as th
the CREATE VIRTUAL TABLE statement that is running. The se
database in which the new virtual table is being created. The
primary database, or "temp" for TEMP database, or the name
statement for attached databases. The third element of the ar
virtual table, as specified following the TABLE keyword in the
If present, the fourth and subsequent strings in the argv[] arr
module name in the CREATE VIRTUAL TABLE statement. The j
new virtual table object (an sqlite3_vtab object) and return a
the task of creating a new sqlite3_vtab structure, this method
to tell the SQLite core about the columns and datatypes in the
sqlite3_declare_vtab() API has the following prototype:
int sqlite3_declare_vtab(sqlite3 *db, const char *zC

The first argument to sqlite3_declare_vtab() must be the sam


first parameter to this method. The second argument to sqlite
terminated UTF-8 string that contains a well-formed CREATE
columns in the virtual table and their data types. The name o
statement is ignored, as are all constraints. Only the column n
CREATE TABLE statement string need not to be held in persist
deallocated and/or reused as soon as the sqlite3_declare_vtab
method need not initialize the pModule, nRef, and zErrMsg fie
SQLite core will take care of that chore. The xCreate should r
creating the new virtual table, or SQLITE_ERROR if it is not su
sqlite3_vtab structure must not be allocated. An error messag
*pzErr if unsuccessful. Space to hold the error message string
memory allocation function like sqlite3_malloc() or sqlite3_m
attempt to free the space using sqlite3_free() after the error
application. If the xCreate method is omitted (left as a NULL p
eponymous-only virtual table. New instances of the virtual tab
VIRTUAL TABLE and the virtual table can only be used via its
versions prior to 3.9.0 do not understand eponymous-only vir
attempt is made to CREATE VIRTUAL TABLE on an eponymous
xCreate method was not checked for null. If the xCreate meth
xConnect method, that indicates that the virtual table does no
Such a virtual table can be used as an eponymous virtual tabl
CREATE VIRTUAL TABLE or both. If a column datatype contain
any combination of upper and lower case letters) then that ke
datatype name and the column is marked as a hidden column
from a normal column in three respects:
Hidden columns are not listed in the dataset retur
Hidden columns are not included in the expansion
of a SELECT, and
Hidden columns are not included in the implicit co
statement that lacks an explicit column-list.
For example, if the following SQL is passed to sqlite3_declare_
CREATE TABLE x(a HIDDEN VARCHAR(12), b INTEGER, c IN

Then the virtual table would be created with two hidden colum
"VARCHAR(12)" and "INTEGER". An example use of hidden co
virtual table implementation, where every FTS virtual table co
used to pass information from the virtual table into FTS auxili
operator. A virtual table that contains hidden columns can be
the FROM clause of a SELECT statement. The arguments to th
constraints on the HIDDEN columns of the virtual table. For e
extension (located in the ext/misc/series.c file in the source t
virtual table with the following schema:
CREATE TABLE generate_series(
value,
start HIDDEN,
stop HIDDEN,
step HIDDEN
);

The sqlite3_module.xBestIndex method in the implementation


constraints against the HIDDEN columns, and uses those as in
range of integer "value" outputs to generate. Reasonable defa
columns. For example, to list all integers between 5 and 50:
SELECT value FROM generate_series(5,50);

The previous query is equivalent to the following:


SELECT value FROM generate_series WHERE start=5 AND

Arguments on the virtual table name are matched to hidden c


arguments can be less than the number of hidden columns, in
columns are unconstrained. However, an error results if there
hidden columns in the virtual table. Beginning with SQLite ve
CREATE TABLE statement that is passed into sqlite3_declare_
ROWID clause. This is useful for cases where the virtual table
unique integers. A CREATE TABLE statement that includes WI
more columns as the PRIMARY KEY. Every column of the PRIM
NULL and all columns for each row must be collectively unique
the PRIMARY KEY for a WITHOUT ROWID virtual table. Enforc
underlying virtual table implementation. But SQLite does assu
is valid - that the identified columns really are UNIQUE and N
assumption to optimize queries against the virtual table. The
WITHOUT ROWID virtual table (of course). Furthermore, since
having a valid rowid, the xUpdate method must be NULL for a
in turn means that WITHOUT ROWID virtual tables must be re

xDestroy
int (*xDestroy)(sqlite3_vtab *pVTab);

This method releases a connection to a virtual table, just like


destroys the underlying table implementation. This method un
xDisconnect method is called whenever a database connection
The xDestroy method is only called when a DROP TABLE state
table. The xDestroy method is required for every virtual table
acceptable for the xDisconnect and xDestroy methods to be th
for the particular virtual table.
xDisconnect
int (*xDisconnect)(sqlite3_vtab *pVTab);

This method releases a connection to a virtual table. Only the


The virtual table is not destroyed and any backing store assoc
This method undoes the work of xConnect. This method is a d
virtual table. Contrast this method with xDestroy. The xDestro
virtual table. The xDisconnect method is required for every vi
is acceptable for the xDisconnect and xDestroy methods to be
sense for the particular virtual table.
xEof
int (*xEof)(sqlite3_vtab_cursor*);

The xEof method must return false (zero) if the specified curs
data, or true (non-zero) otherwise. This method is called by th
each xFilter and xNext invocation. The xEof method is require
implementation.
xFilter
int (*xFilter)(sqlite3_vtab_cursor*, int idxNum, con
int argc, sqlite3_value **argv);

This method begins a search of a virtual table. The first argum


The next two arguments define a particular search index prev
specific meanings of idxNum and idxStr are unimportant as lo
on what that meaning is. The xBestIndex function may have r
expressions using the aConstraintUsage[].argvIndex values o
Those values are passed to xFilter using the argc and argv pa
contains one or more rows that match the search criteria, the
first row. Subsequent calls to xEof must return false (zero). If
cursor must be left in a state that will cause the xEof to retur
will use the xColumn and xRowid methods to access that row
used to advance to the next row. This method must return SQ
error code if an error occurs. The xFilter method is required fo
implementation.

xFindFunction int (*xFindFunction)(


sqlite3_vtab *pVtab,
int nArg,
const char *zName,
void (**pxFunc)(sqlite3_context*,int,sqlite3_value
void **ppArg
);

This method is called during sqlite3_prepare() to give the virt


opportunity to overload functions. This method may be set to
occurs. When a function uses a column from a virtual table as
called to see if the virtual table would like to overload the fun
inputs: the virtual table, the number of arguments to the func
If no overloading is desired, this method returns 0. To overloa
the new function implementation into *pxFunc and writes use
Note that infix functions (LIKE, GLOB, REGEXP, and MATCH) r
So "like(A,B)" is equivalent to "B like A". For the form "B like
argument to the function. But for "like(A,B)" the A term is con
function pointer returned by this routine must be valid for the
given in the first parameter.
xNext
int (*xNext)(sqlite3_vtab_cursor*);

The xNext method advances a virtual table cursor to the next


xFilter. If the cursor is already pointing at the last row when t
no longer points to valid data and a subsequent call to the xE
zero). If the cursor is successfully advanced to another row of
xEof must return false (zero). This method must return SQLIT
code if an error occurs. The xNext method is required for ever
xOpen int (*xOpen)(sqlite3_vtab *pVTab, sqlite3_vtab_curso

The xOpen method creates a new cursor used for accessing (r


successful invocation of this method will allocate the memory
subclass), initialize the new object, and make *ppCursor poin
call then returns SQLITE_OK. For every successful call to this
invoke the xClose method to destroy the allocated cursor. The
the pVtab field of the sqlite3_vtab_cursor structure. The SQLi
automatically. A virtual table implementation must be able to
simultaneously open cursors. When initially opened, the curso
SQLite core will invoke the xFilter method on the cursor prior
from the cursor. The xOpen method is required for every virtu

xRelease
int (*xSavepoint)(sqlite3_vtab *pVtab, int);
int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an op


transactions. They are always optional and will only be called
23) and later. When xSavepoint(X,N) is invoked, that is a sign
should save its current state as savepoint N. A subsequent ca
state of the virtual table should return to what it was when xS
call to xRollbackTo(X,R) will invalidate all savepoints with N>R
will be rolled back or released without first being reinitialized
xRelease(X,M) invalidates all savepoints where N>=M. None o
xRollbackTo() methods will ever be called except in between c
xCommit() or xRollback().
xRename
int (*xRename)(sqlite3_vtab *pVtab, const char *zNew

This method provides notification that the virtual table implem


be given a new name. If this method returns SQLITE_OK then
method returns an error code then the renaming is prevented
for every virtual table implementation.
xRollback
int (*xRollback)(sqlite3_vtab *pVTab);

This method causes a virtual table transaction to rollback. Thi


xRollback pointer of sqlite3_module may be NULL. A call to th
to xBegin.
xRollbackTo
int (*xSavepoint)(sqlite3_vtab *pVtab, int);
int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an op


transactions. They are always optional and will only be called
23) and later. When xSavepoint(X,N) is invoked, that is a sign
should save its current state as savepoint N. A subsequent ca
state of the virtual table should return to what it was when xS
call to xRollbackTo(X,R) will invalidate all savepoints with N>R
will be rolled back or released without first being reinitialized
xRelease(X,M) invalidates all savepoints where N>=M. None o
xRollbackTo() methods will ever be called except in between c
xCommit() or xRollback().

xRowId
int (*xRowid)(sqlite3_vtab_cursor *pCur, sqlite_int6

A successful invocation of this method will cause *pRowid to b


the virtual table cursor pCur is currently pointing at. This met
It returns an appropriate error code on failure. The xRowid m
table implementation.
xSavepoint
int (*xSavepoint)(sqlite3_vtab *pVtab, int);
int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an op


transactions. They are always optional and will only be called
23) and later. When xSavepoint(X,N) is invoked, that is a sign
should save its current state as savepoint N. A subsequent ca
state of the virtual table should return to what it was when xS
call to xRollbackTo(X,R) will invalidate all savepoints with N>R
will be rolled back or released without first being reinitialized
xRelease(X,M) invalidates all savepoints where N>=M. None o
xRollbackTo() methods will ever be called except in between c
xCommit() or xRollback().
xSync
int (*xSync)(sqlite3_vtab *pVTab);

This method signals the start of a two-phase commit on a virt


The xSync pointer of sqlite3_module may be NULL. This meth
xBegin method and prior to an xCommit or xRollback. In orde
the xSync method on all virtual tables is invoked prior to invo
virtual table. If any of the xSync methods fail, the entire tran
xUpdate
int (*xUpdate)(
sqlite3_vtab *pVTab,
int argc,
sqlite3_value **argv,
sqlite_int64 *pRowid
);

All changes to a virtual table are made using the xUpdate me


insert, delete, or update. The argc parameter specifies the nu
The value of argc will be 1 for a pure delete operation or N+2
where N is the number of columns in the table. In the previou
columns. Every argv entry will have a non-NULL value in C bu
In other words, it is always true that argv[i]!=0 for i between
the case that sqlite3_value_type(argv[i])==SQLITE_NULL. The arg
in the virtual table to be deleted. If argv[0] is an SQL NULL, t
parameter is the rowid of a new row to be inserted into the vi
NULL, then the implementation must choose a rowid for the n
argv[] entries contain values of the columns of the virtual tab
were declared. The number of columns will match the table de
xCreate method made using the sqlite3_declare_vtab() call. A
When doing an insert without a rowid (argc>1, argv[1] is an S
set *pRowid to the rowid of the newly inserted row; this will b
sqlite3_last_insert_rowid() function. Setting this value in all t
the SQLite engine ignores the *pRowid return value if argc==
Each call to xUpdate will fall into one of cases shown below. N
the SQL value held within the argv[i] object, not the argv[i] o

argc = 1
The single row with rowid equal to argv[0] is del

argc > 1
argv[0] = NULL
A new row is inserted with a rowid argv[1] and co
argv[2] and following. If arg
the a new unique rowid is gene

argc > 1
argv[0] NULL
argv[0] = argv[1]
The row with rowid argv[0] is updated with new va
in argv[2] and following param
argc > 1
argv[0] NULL
argv[0] argv[1]
The row with rowid argv[0] is updated with rowid
and new values in argv[2] and followi
when an SQL statement updates a rowid

UPDATE table SET rowid=rowid+1 WHE

The xUpdate method must return SQLITE_OK if and only if it


xUpdate must return an appropriate error code. On a failure,
optionally be replaced with error message text stored in mem
functions such as sqlite3_mprintf() or sqlite3_malloc(). If the
constraint of the virtual table (including, but not limited to, at
wrong datatype, attempting to store a value that is too large
a read-only value) then the xUpdate must fail with an approp
or more sqlite3_vtab_cursor objects open and in use on the v
even on the row of the virtual table when the xUpdate metho
xUpdate must be prepared for attempts to delete or modify ro
existing cursors. If the virtual table cannot accommodate such
return an error code. The xUpdate method is optional. If the x
sqlite3_module for a virtual table is a NULL pointer, then the v

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xBegin Method

int (*xBegin)(sqlite3_vtab *pVTab);

This method begins a transaction on a virtual table. This is method is


optional. The xBegin pointer of sqlite3_module may be NULL.
This method is always followed by one call to either the xCommit or
xRollback method. Virtual table transactions do not nest, so the xBegin
method will not be invoked more than once on a single virtual table
without an intervening call to either xCommit or xRollback. Multiple calls
to other methods can and likely will occur in between the xBegin and the
corresponding xCommit or xRollback.

SQLiteErrorCode xBegin(
IntPtr pVtab
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xBestIndex Method

SQLite uses the xBestIndex method of a virtual table module to determine


the best way to access the virtual table. The xBestIndex method has a
prototype like this:
int (*xBestIndex)(sqlite3_vtab *pVTab, sqlite3_index_info*);

The SQLite core communicates with the xBestIndex method by filling in


certain fields of the sqlite3_index_info structure and passing a pointer to
that structure into xBestIndex as the second parameter. The xBestIndex
method fills out other fields of this structure which forms the reply. The
sqlite3_index_info structure looks like this:
struct sqlite3_index_info {
/* Inputs */
const int nConstraint; /* Number of entries in aConstraint *
const struct sqlite3_index_constraint {
int iColumn; /* Column constrained. -1 for ROWI
unsigned char op; /* Constraint operator */
unsigned char usable; /* True if this constraint is usabl
int iTermOffset; /* Used internally - xBestIndex sho
} *const aConstraint; /* Table of WHERE clause constraints
const int nOrderBy; /* Number of terms in the ORDER BY cl
const struct sqlite3_index_orderby {
int iColumn; /* Column number */
unsigned char desc; /* True for DESC. False for ASC. *
} *const aOrderBy; /* The ORDER BY clause */
/* Outputs */
struct sqlite3_index_constraint_usage {
int argvIndex; /* if >0, constraint is part of argv
unsigned char omit; /* Do not code a test for this constr
} *const aConstraintUsage;
int idxNum; /* Number used to identify the index
char *idxStr; /* String, possibly obtained from sql
int needToFreeIdxStr; /* Free idxStr using sqlite3_free() i
int orderByConsumed; /* True if output is already ordered
double estimatedCost; /* Estimated cost of using this index
/* Fields below are only available in SQLite 3.8.2 and
sqlite3_int64 estimatedRows; /* Estimated number of rows retu
/* Fields below are only available in SQLite 3.9.0 and
int idxFlags; /* Mask of SQLITE_INDEX_SCAN_* flags
/* Fields below are only available in SQLite 3.10.0 and
sqlite3_uint64 colUsed; /* Input: Mask of columns used by sta
};

Note the warnings on the "estimatedRows", "idxFlags", and colUsed fields.


These fields were added with SQLite versions 3.8.2, 3.9.0, and 3.10.0,
respectively. Any extension that reads or writes these fields must first
check that the version of the SQLite library in use is greater than or equal
to appropriate version - perhaps comparing the value returned from
sqlite3_libversion_number() against constants 3008002, 3009000, and/or
3010000. The result of attempting to access these fields in an
sqlite3_index_info structure created by an older version of SQLite are
undefined.
In addition, there are some defined constants:
#define SQLITE_INDEX_CONSTRAINT_EQ 2
#define SQLITE_INDEX_CONSTRAINT_GT 4
#define SQLITE_INDEX_CONSTRAINT_LE 8
#define SQLITE_INDEX_CONSTRAINT_LT 16
#define SQLITE_INDEX_CONSTRAINT_GE 32
#define SQLITE_INDEX_CONSTRAINT_MATCH 64
#define SQLITE_INDEX_CONSTRAINT_LIKE 65 /* 3.10.0 and later
#define SQLITE_INDEX_CONSTRAINT_GLOB 66 /* 3.10.0 and later
#define SQLITE_INDEX_CONSTRAINT_REGEXP 67 /* 3.10.0 and later
#define SQLITE_INDEX_SCAN_UNIQUE 1 /* Scan visits at mo

The SQLite core calls the xBestIndex method when it is compiling a query
that involves a virtual table. In other words, SQLite calls this method
when it is running sqlite3_prepare() or the equivalent. By calling this
method, the SQLite core is saying to the virtual table that it needs to
access some subset of the rows in the virtual table and it wants to know
the most efficient way to do that access. The xBestIndex method replies
with information that the SQLite core can then use to conduct an efficient
search of the virtual table.
While compiling a single SQL query, the SQLite core might call xBestIndex
multiple times with different settings in sqlite3_index_info. The SQLite
core will then select the combination that appears to give the best
performance.
Before calling this method, the SQLite core initializes an instance of the
sqlite3_index_info structure with information about the query that it is
currently trying to process. This information derives mainly from the
WHERE clause and ORDER BY or GROUP BY clauses of the query, but also
from any ON or USING clauses if the query is a join. The information that
the SQLite core provides to the xBestIndex method is held in the part of
the structure that is marked as "Inputs". The "Outputs" section is
initialized to zero.
The information in the sqlite3_index_info structure is ephemeral and may
be overwritten or deallocated as soon as the xBestIndex method returns.
If the xBestIndex method needs to remember any part of the
sqlite3_index_info structure, it should make a copy. Care must be take to
store the copy in a place where it will be deallocated, such as in the idxStr
field with needToFreeIdxStr set to 1.
Note that xBestIndex will always be called before xFilter, since the idxNum
and idxStr outputs from xBestIndex are required inputs to xFilter.
However, there is no guarantee that xFilter will be called following a
successful xBestIndex.
The xBestIndex method is required for every virtual table implementation.
The main thing that the SQLite core is trying to communicate to the
virtual table is the constraints that are available to limit the number of
rows that need to be searched. The aConstraint[] array contains one entry
for each constraint. There will be exactly nConstraint entries in that array.
Each constraint will correspond to a term in the WHERE clause or in a
USING or ON clause that is of the form
column OP EXPR

Where "column" is a column in the virtual table, OP is an operator like "="


or "<", and EXPR is an arbitrary expression. So, for example, if the
WHERE clause contained a term like this:
a = 5

Then one of the constraints would be on the "a" column with operator "="
and an expression of "5". Constraints need not have a literal
representation of the WHERE clause. The query optimizer might make
transformations to the WHERE clause in order to extract as many
constraints as it can. So, for example, if the WHERE clause contained
something like this:
x BETWEEN 10 AND 100 AND 999>y

The query optimizer might translate this into three separate constraints:
x >= 10
x <= 100
y < 999

For each constraint, the aConstraint[].iColumn field indicates which


column appears on the left-hand side of the constraint. The first column of
the virtual table is column 0. The rowid of the virtual table is column -1.
The aConstraint[].op field indicates which operator is used. The
SQLITE_INDEX_CONSTRAINT_* constants map integer constants into
operator values. Columns occur in the order they were defined by the call
to sqlite3_declare_vtab() in the xCreate or xConnect method. Hidden
columns are counted when determining the column index.
The aConstraint[] array contains information about all constraints that
apply to the virtual table. But some of the constraints might not be usable
because of the way tables are ordered in a join. The xBestIndex method
must therefore only consider constraints that have an aConstraint[].usable
flag which is true.
In addition to WHERE clause constraints, the SQLite core also tells the
xBestIndex method about the ORDER BY clause. (In an aggregate query,
the SQLite core might put in GROUP BY clause information in place of the
ORDER BY clause information, but this fact should not make any difference
to the xBestIndex method.) If all terms of the ORDER BY clause are
columns in the virtual table, then nOrderBy will be the number of terms in
the ORDER BY clause and the aOrderBy[] array will identify the column for
each term in the order by clause and whether or not that column is ASC or
DESC.
In SQLite version 3.10.0 (2016-01-06) and later, the colUsed field is
available to indicate which fields of the virtual table are actually used by
the statement being prepared. If the lowest bit of colUsed is set, that
means that the first column is used. The second lowest bit corresponds to
the second column. And so forth. If the most significant bit of colUsed is
set, that means that one or more columns other than the first 63 columns
are used. If column usage information is needed by the xFilter method,
then the required bits must be encoded into either the idxNum or idxStr
output fields.
Given all of the information above, the job of the xBestIndex method it to
figure out the best way to search the virtual table.
The xBestIndex method fills the idxNum and idxStr fields with information
that communicates an indexing strategy to the xFilter method. The
information in idxNum and idxStr is arbitrary as far as the SQLite core is
concerned. The SQLite core just copies the information through to the
xFilter method. Any desired meaning can be assigned to idxNum and
idxStr as long as xBestIndex and xFilter agree on what that meaning is.
The idxStr value may be a string obtained from an SQLite memory
allocation function such as sqlite3_mprintf(). If this is the case, then the
needToFreeIdxStr flag must be set to true so that the SQLite core will
know to call sqlite3_free() on that string when it has finished with it, and
thus avoid a memory leak.
If the virtual table will output rows in the order specified by the ORDER BY
clause, then the orderByConsumed flag may be set to true. If the output is
not automatically in the correct order then orderByConsumed must be left
in its default false setting. This will indicate to the SQLite core that it will
need to do a separate sorting pass over the data after it comes out of the
virtual table.
The estimatedCost field should be set to the estimated number of disk
access operations required to execute this query against the virtual table.
The SQLite core will often call xBestIndex multiple times with different
constraints, obtain multiple cost estimates, then choose the query plan
that gives the lowest estimate.
If the current version of SQLite is 3.8.2 or greater, the estimatedRows field
may be set to an estimate of the number of rows returned by the proposed
query plan. If this value is not explicitly set, the default estimate of 25
rows is used.
If the current version of SQLite is 3.9.0 or greater, the idxFlags field may
be set to SQLITE_INDEX_SCAN_UNIQUE to indicate that the virtual table
will return only zero or one rows given the input constraints. Additional
bits of the idxFlags field might be understood in later versions of SQLite.
The aConstraintUsage[] array contains one element for each of the
nConstraint constraints in the inputs section of the sqlite3_index_info
structure. The aConstraintUsage[] array is used by xBestIndex to tell the
core how it is using the constraints.
The xBestIndex method may set aConstraintUsage[].argvIndex entries to
values greater than zero. Exactly one entry should be set to 1, another to
2, another to 3, and so forth up to as many or as few as the xBestIndex
method wants. The EXPR of the corresponding constraints will then be
passed in as the argv[] parameters to xFilter.
For example, if the aConstraint[3].argvIndex is set to 1, then when xFilter
is called, the argv[0] passed to xFilter will have the EXPR value of the
aConstraint[3] constraint.
By default, the SQLite core double checks all constraints on each row of
the virtual table that it receives. If such a check is redundant, the
xBestFilter method can suppress that double-check by setting
aConstraintUsage[].omit.

SQLiteErrorCode xBestIndex(
IntPtr pVtab,
IntPtr pIndex
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
pIndex
The native pointer to the sqlite3_index_info structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xClose Method

int (*xClose)(sqlite3_vtab_cursor*);

The xClose method closes a cursor previously opened by xOpen. The


SQLite core will always call xClose once for each cursor opened using
xOpen.
This method must release all resources allocated by the corresponding
xOpen call. The routine will not be called again even if it returns an error.
The SQLite core will not use the sqlite3_vtab_cursor again after it has
been closed.
The xClose method is required for every virtual table implementation.

SQLiteErrorCode xClose(
IntPtr pCursor
);

Parameters
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xColumn Method

int (*xColumn)(sqlite3_vtab_cursor*, sqlite3_context*, int N);

The SQLite core invokes this method in order to find the value for the N-th
column of the current row. N is zero-based so the first column is numbered
0. The xColumn method may return its result back to SQLite using one of
the following interface:
sqlite3_result_blob()
sqlite3_result_double()
sqlite3_result_int()
sqlite3_result_int64()
sqlite3_result_null()
sqlite3_result_text()
sqlite3_result_text16()
sqlite3_result_text16le()
sqlite3_result_text16be()
sqlite3_result_zeroblob()

If the xColumn method implementation calls none of the functions above,


then the value of the column defaults to an SQL NULL.
To raise an error, the xColumn method should use one of the result_text()
methods to set the error message text, then return an appropriate error
code. The xColumn method must return SQLITE_OK on success.
The xColumn method is required for every virtual table implementation.

SQLiteErrorCode xColumn(
IntPtr pCursor,
IntPtr pContext,
int index
);

Parameters
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure.
pContext
The native pointer to the sqlite3_context structure to be used for
returning the specified column value to the SQLite core library.
index
The zero-based index corresponding to the column containing the value
to be returned.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xCommit Method

int (*xCommit)(sqlite3_vtab *pVTab);

This method causes a virtual table transaction to commit. This is method is


optional. The xCommit pointer of sqlite3_module may be NULL.
A call to this method always follows a prior call to xBegin and xSync.

SQLiteErrorCode xCommit(
IntPtr pVtab
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xConnect Method

int (*xConnect)(sqlite3*, void *pAux,


int argc, char **argv,
sqlite3_vtab **ppVTab,
char **pzErr);

The xConnect method is very similar to xCreate. It has the same


parameters and constructs a new sqlite3_vtab structure just like xCreate.
And it must also call sqlite3_declare_vtab() like xCreate.
The difference is that xConnect is called to establish a new connection to
an existing virtual table whereas xCreate is called to create a new virtual
table from scratch.
The xCreate and xConnect methods are only different when the virtual
table has some kind of backing store that must be initialized the first time
the virtual table is created. The xCreate method creates and initializes the
backing store. The xConnect method just connects to an existing backing
store. When xCreate and xConnect are the same, the table is an
eponymous virtual table.
As an example, consider a virtual table implementation that provides read-
only access to existing comma-separated-value (CSV) files on disk. There
is no backing store that needs to be created or initialized for such a virtual
table (since the CSV files already exist on disk) so the xCreate and
xConnect methods will be identical for that module.
Another example is a virtual table that implements a full-text index. The
xCreate method must create and initialize data structures to hold the
dictionary and posting lists for that index. The xConnect method, on the
other hand, only has to locate and use an existing dictionary and posting
lists that were created by a prior xCreate call.
The xConnect method must return SQLITE_OK if it is successful in creating
the new virtual table, or SQLITE_ERROR if it is not successful. If not
successful, the sqlite3_vtab structure must not be allocated. An error
message may optionally be returned in *pzErr if unsuccessful. Space to
hold the error message string must be allocated using an SQLite memory
allocation function like sqlite3_malloc() or sqlite3_mprintf() as the SQLite
core will attempt to free the space using sqlite3_free() after the error has
been reported up to the application.
The xConnect method is required for every virtual table implementation,
though the xCreate and xConnect pointers of the sqlite3_module object
may point to the same function if the virtual table does not need to
initialize backing store.

SQLiteErrorCode xConnect(
IntPtr pDb,
IntPtr pAux,
int argc,
IntPtr argv,
ref IntPtr pVtab,
ref IntPtr pError
);

Parameters
pDb
The native database connection handle.
pAux
The original native pointer value that was provided to the
sqlite3_create_module(), sqlite3_create_module_v2() or
sqlite3_create_disposable_module() functions.
argc
The number of arguments from the CREATE VIRTUAL TABLE statement.
argv
The array of string arguments from the CREATE VIRTUAL TABLE
statement.
pVtab
Upon success, this parameter must be modified to point to the newly
created native sqlite3_vtab derived structure.
pError
Upon failure, this parameter must be modified to point to the error
message, with the underlying memory having been obtained from the
sqlite3_malloc() function.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xCreate Method

int (*xCreate)(sqlite3 *db, void *pAux,


int argc, char **argv,
sqlite3_vtab **ppVTab,
char **pzErr);

The xCreate method is called to create a new instance of a virtual table in


response to a CREATE VIRTUAL TABLE statement. If the xCreate method is
the same pointer as the xConnect method, then the virtual table is an
eponymous virtual table. If the xCreate method is omitted (if it is a NULL
pointer) then the virtual table is an eponymous-only virtual table.
The db parameter is a pointer to the SQLite database connection that is
executing the CREATE VIRTUAL TABLE statement. The pAux argument is
the copy of the client data pointer that was the fourth argument to the
sqlite3_create_module() or sqlite3_create_module_v2() call that
registered the virtual table module. The argv parameter is an array of argc
pointers to null terminated strings. The first string, argv[0], is the name of
the module being invoked. The module name is the name provided as the
second argument to sqlite3_create_module() and as the argument to the
USING clause of the CREATE VIRTUAL TABLE statement that is running.
The second, argv[1], is the name of the database in which the new virtual
table is being created. The database name is "main" for the primary
database, or "temp" for TEMP database, or the name given at the end of
the ATTACH statement for attached databases. The third element of the
array, argv[2], is the name of the new virtual table, as specified following
the TABLE keyword in the CREATE VIRTUAL TABLE statement. If present,
the fourth and subsequent strings in the argv[] array report the
arguments to the module name in the CREATE VIRTUAL TABLE statement.
The job of this method is to construct the new virtual table object (an
sqlite3_vtab object) and return a pointer to it in *ppVTab.
As part of the task of creating a new sqlite3_vtab structure, this method
must invoke sqlite3_declare_vtab() to tell the SQLite core about the
columns and datatypes in the virtual table. The sqlite3_declare_vtab() API
has the following prototype:
int sqlite3_declare_vtab(sqlite3 *db, const char *zCreateTable)

The first argument to sqlite3_declare_vtab() must be the same database


connection pointer as the first parameter to this method. The second
argument to sqlite3_declare_vtab() must a zero-terminated UTF-8 string
that contains a well-formed CREATE TABLE statement that defines the
columns in the virtual table and their data types. The name of the table in
this CREATE TABLE statement is ignored, as are all constraints. Only the
column names and datatypes matter. The CREATE TABLE statement string
need not to be held in persistent memory. The string can be deallocated
and/or reused as soon as the sqlite3_declare_vtab() routine returns.
The xCreate method need not initialize the pModule, nRef, and zErrMsg
fields of the sqlite3_vtab object. The SQLite core will take care of that
chore.
The xCreate should return SQLITE_OK if it is successful in creating the
new virtual table, or SQLITE_ERROR if it is not successful. If not
successful, the sqlite3_vtab structure must not be allocated. An error
message may optionally be returned in *pzErr if unsuccessful. Space to
hold the error message string must be allocated using an SQLite memory
allocation function like sqlite3_malloc() or sqlite3_mprintf() as the SQLite
core will attempt to free the space using sqlite3_free() after the error has
been reported up to the application.
If the xCreate method is omitted (left as a NULL pointer) then the virtual
table is an eponymous-only virtual table. New instances of the virtual
table cannot be created using CREATE VIRTUAL TABLE and the virtual
table can only be used via its module name. Note that SQLite versions
prior to 3.9.0 do not understand eponymous-only virtual tables and will
segfault if an attempt is made to CREATE VIRTUAL TABLE on an
eponymous-only virtual table because the xCreate method was not
checked for null.
If the xCreate method is the exact same pointer as the xConnect method,
that indicates that the virtual table does not need to initialize backing
store. Such a virtual table can be used as an eponymous virtual table or as
a named virtual table using CREATE VIRTUAL TABLE or both.
If a column datatype contains the special keyword "HIDDEN" (in any
combination of upper and lower case letters) then that keyword it is
omitted from the column datatype name and the column is marked as a
hidden column internally. A hidden column differs from a normal column in
three respects:
Hidden columns are not listed in the dataset returned by
"PRAGMA table_info",
Hidden columns are not included in the expansion of a "*"
expression in the result set of a SELECT, and
Hidden columns are not included in the implicit column-list
used by an INSERT statement that lacks an explicit column-
list.

For example, if the following SQL is passed to sqlite3_declare_vtab():


CREATE TABLE x(a HIDDEN VARCHAR(12), b INTEGER, c INTEGER Hidden);

Then the virtual table would be created with two hidden columns, and with
datatypes of "VARCHAR(12)" and "INTEGER".
An example use of hidden columns can be seen in the FTS3 virtual table
implementation, where every FTS virtual table contains an FTS hidden
column that is used to pass information from the virtual table into FTS
auxiliary functions and to the FTS MATCH operator.
A virtual table that contains hidden columns can be used like a table-
valued function in the FROM clause of a SELECT statement. The
arguments to the table-valued function become constraints on the HIDDEN
columns of the virtual table.
For example, the "generate_series" extension (located in the
ext/misc/series.c file in the source tree) implements an eponymous virtual
table with the following schema:
CREATE TABLE generate_series(
value,
start HIDDEN,
stop HIDDEN,
step HIDDEN
);

The sqlite3_module.xBestIndex method in the implementation of this table


checks for equality constraints against the HIDDEN columns, and uses
those as input parameters to determine the range of integer "value"
outputs to generate. Reasonable defaults are used for any unconstrained
columns. For example, to list all integers between 5 and 50:
SELECT value FROM generate_series(5,50);

The previous query is equivalent to the following:


SELECT value FROM generate_series WHERE start=5 AND stop=50;

Arguments on the virtual table name are matched to hidden columns in


order. The number of arguments can be less than the number of hidden
columns, in which case the latter hidden columns are unconstrained.
However, an error results if there are more arguments than there are
hidden columns in the virtual table.
Beginning with SQLite version 3.14.0 (2016-08-08), the CREATE TABLE
statement that is passed into sqlite3_declare_vtab() may contain a
WITHOUT ROWID clause. This is useful for cases where the virtual table
rows cannot easily be mapped into unique integers. A CREATE TABLE
statement that includes WITHOUT ROWID must define one or more
columns as the PRIMARY KEY. Every column of the PRIMARY KEY must
individually be NOT NULL and all columns for each row must be collectively
unique.
Note that SQLite does not enforce the PRIMARY KEY for a WITHOUT
ROWID virtual table. Enforcement is the responsibility of the underlying
virtual table implementation. But SQLite does assume that the PRIMARY
KEY constraint is valid - that the identified columns really are UNIQUE and
NOT NULL - and it uses that assumption to optimize queries against the
virtual table.
The rowid column is not accessible on a WITHOUT ROWID virtual table (of
course). Furthermore, since the xUpdate method depends on having a
valid rowid, the xUpdate method must be NULL for a WITHOUT ROWID
virtual table. That in turn means that WITHOUT ROWID virtual tables must
be read-only.

SQLiteErrorCode xCreate(
IntPtr pDb,
IntPtr pAux,
int argc,
IntPtr argv,
ref IntPtr pVtab,
ref IntPtr pError
);

Parameters
pDb
The native database connection handle.
pAux
The original native pointer value that was provided to the
sqlite3_create_module(), sqlite3_create_module_v2() or
sqlite3_create_disposable_module() functions.
argc
The number of arguments from the CREATE VIRTUAL TABLE statement.
argv
The array of string arguments from the CREATE VIRTUAL TABLE
statement.
pVtab
Upon success, this parameter must be modified to point to the newly
created native sqlite3_vtab derived structure.
pError
Upon failure, this parameter must be modified to point to the error
message, with the underlying memory having been obtained from the
sqlite3_malloc() function.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xDestroy Method

int (*xDestroy)(sqlite3_vtab *pVTab);

This method releases a connection to a virtual table, just like the


xDisconnect method, and it also destroys the underlying table
implementation. This method undoes the work of xCreate.
The xDisconnect method is called whenever a database connection that
uses a virtual table is closed. The xDestroy method is only called when a
DROP TABLE statement is executed against the virtual table.
The xDestroy method is required for every virtual table implementation,
though it is acceptable for the xDisconnect and xDestroy methods to be
the same function if that makes sense for the particular virtual table.

SQLiteErrorCode xDestroy(
IntPtr pVtab
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xDisconnect Method

int (*xDisconnect)(sqlite3_vtab *pVTab);

This method releases a connection to a virtual table. Only the sqlite3_vtab


object is destroyed. The virtual table is not destroyed and any backing
store associated with the virtual table persists.
This method undoes the work of xConnect.
This method is a destructor for a connection to the virtual table. Contrast
this method with xDestroy. The xDestroy is a destructor for the entire
virtual table.
The xDisconnect method is required for every virtual table
implementation, though it is acceptable for the xDisconnect and xDestroy
methods to be the same function if that makes sense for the particular
virtual table.

SQLiteErrorCode xDisconnect(
IntPtr pVtab
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xEof Method

int (*xEof)(sqlite3_vtab_cursor*);

The xEof method must return false (zero) if the specified cursor currently
points to a valid row of data, or true (non-zero) otherwise. This method is
called by the SQL engine immediately after each xFilter and xNext
invocation.
The xEof method is required for every virtual table implementation.

int xEof(
IntPtr pCursor
);

Parameters
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure.

Return Value
Non-zero if no more rows are available; zero otherwise.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xFilter Method

int (*xFilter)(sqlite3_vtab_cursor*, int idxNum, const char *idxSt


int argc, sqlite3_value **argv);

This method begins a search of a virtual table. The first argument is a


cursor opened by xOpen. The next two arguments define a particular
search index previously chosen by xBestIndex. The specific meanings of
idxNum and idxStr are unimportant as long as xFilter and xBestIndex
agree on what that meaning is.
The xBestIndex function may have requested the values of certain
expressions using the aConstraintUsage[].argvIndex values of the
sqlite3_index_info structure. Those values are passed to xFilter using the
argc and argv parameters.
If the virtual table contains one or more rows that match the search
criteria, then the cursor must be left point at the first row. Subsequent
calls to xEof must return false (zero). If there are no rows match, then the
cursor must be left in a state that will cause the xEof to return true (non-
zero). The SQLite engine will use the xColumn and xRowid methods to
access that row content. The xNext method will be used to advance to the
next row.
This method must return SQLITE_OK if successful, or an sqlite error code
if an error occurs.
The xFilter method is required for every virtual table implementation.

SQLiteErrorCode xFilter(
IntPtr pCursor,
int idxNum,
IntPtr idxStr,
int argc,
IntPtr argv
);

Parameters
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure.
idxNum
Number used to help identify the selected index.
idxStr
The native pointer to the UTF-8 encoded string containing the string
used to help identify the selected index.
argc
The number of native pointers to sqlite3_value structures specified in
argv.
argv
An array of native pointers to sqlite3_value structures containing
filtering criteria for the selected index.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xFindFunction Method

int (*xFindFunction)(
sqlite3_vtab *pVtab,
int nArg,
const char *zName,
void (**pxFunc)(sqlite3_context*,int,sqlite3_value**),
void **ppArg
);

This method is called during sqlite3_prepare() to give the virtual table


implementation an opportunity to overload functions. This method may be
set to NULL in which case no overloading occurs.
When a function uses a column from a virtual table as its first argument,
this method is called to see if the virtual table would like to overload the
function. The first three parameters are inputs: the virtual table, the
number of arguments to the function, and the name of the function. If no
overloading is desired, this method returns 0. To overload the function,
this method writes the new function implementation into *pxFunc and
writes user data into *ppArg and returns 1.
Note that infix functions (LIKE, GLOB, REGEXP, and MATCH) reverse the
order of their arguments. So "like(A,B)" is equivalent to "B like A". For the
form "B like A" the B term is considered the first argument to the function.
But for "like(A,B)" the A term is considered the first argument.
The function pointer returned by this routine must be valid for the lifetime
of the sqlite3_vtab object given in the first parameter.

int xFindFunction(
IntPtr pVtab,
int nArg,
IntPtr zName,
ref SQLiteCallback callback,
ref IntPtr pClientData
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
nArg
The number of arguments to the function being sought.
zName
The name of the function being sought.
callback
Upon success, this parameter must be modified to contain the delegate
responsible for implementing the specified function.
pClientData
Upon success, this parameter must be modified to contain the native
user-data pointer associated with callback.

Return Value
Non-zero if the specified function was found; zero otherwise.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xNext Method

int (*xNext)(sqlite3_vtab_cursor*);

The xNext method advances a virtual table cursor to the next row of a
result set initiated by xFilter. If the cursor is already pointing at the last
row when this routine is called, then the cursor no longer points to valid
data and a subsequent call to the xEof method must return true (non-
zero). If the cursor is successfully advanced to another row of content,
then subsequent calls to xEof must return false (zero).
This method must return SQLITE_OK if successful, or an sqlite error code
if an error occurs.
The xNext method is required for every virtual table implementation.

SQLiteErrorCode xNext(
IntPtr pCursor
);

Parameters
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xOpen Method

int (*xOpen)(sqlite3_vtab *pVTab, sqlite3_vtab_cursor **ppCursor);

The xOpen method creates a new cursor used for accessing (read and/or
writing) a virtual table. A successful invocation of this method will allocate
the memory for the sqlite3_vtab_cursor (or a subclass), initialize the new
object, and make *ppCursor point to the new object. The successful call
then returns SQLITE_OK.
For every successful call to this method, the SQLite core will later invoke
the xClose method to destroy the allocated cursor.
The xOpen method need not initialize the pVtab field of the
sqlite3_vtab_cursor structure. The SQLite core will take care of that chore
automatically.
A virtual table implementation must be able to support an arbitrary
number of simultaneously open cursors.
When initially opened, the cursor is in an undefined state. The SQLite core
will invoke the xFilter method on the cursor prior to any attempt to
position or read from the cursor.
The xOpen method is required for every virtual table implementation.

SQLiteErrorCode xOpen(
IntPtr pVtab,
ref IntPtr pCursor
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
pCursor
Upon success, this parameter must be modified to point to the newly
created native sqlite3_vtab_cursor derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xRelease Method

int (*xSavepoint)(sqlite3_vtab *pVtab, int);


int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an opportunity to


implement nested transactions. They are always optional and will only be
called in SQLite version 3.7.7 (2011-06-23) and later.
When xSavepoint(X,N) is invoked, that is a signal to the virtual table X
that it should save its current state as savepoint N. A subsequent call to
xRollbackTo(X,R) means that the state of the virtual table should return to
what it was when xSavepoint(X,R) was last called. The call to
xRollbackTo(X,R) will invalidate all savepoints with N>R; none of the
invalided savepoints will be rolled back or released without first being
reinitialized by a call to xSavepoint(). A call to xRelease(X,M) invalidates
all savepoints where N>=M.
None of the xSavepoint(), xRelease(), or xRollbackTo() methods will ever
be called except in between calls to xBegin() and either xCommit() or
xRollback().

SQLiteErrorCode xRelease(
IntPtr pVtab,
int iSavepoint
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
iSavepoint
This is an integer used to indicate that any saved states with an
identifier greater than or equal to this should be deleted by the virtual
table.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xRename Method

int (*xRename)(sqlite3_vtab *pVtab, const char *zNew);

This method provides notification that the virtual table implementation


that the virtual table will be given a new name. If this method returns
SQLITE_OK then SQLite renames the table. If this method returns an
error code then the renaming is prevented.
The xRename method is required for every virtual table implementation.

SQLiteErrorCode xRename(
IntPtr pVtab,
IntPtr zNew
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
zNew
The native pointer to the UTF-8 encoded string containing the new
name for the virtual table.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xRollback Method

int (*xRollback)(sqlite3_vtab *pVTab);

This method causes a virtual table transaction to rollback. This is method


is optional. The xRollback pointer of sqlite3_module may be NULL.
A call to this method always follows a prior call to xBegin.

SQLiteErrorCode xRollback(
IntPtr pVtab
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xRollbackTo Method

int (*xSavepoint)(sqlite3_vtab *pVtab, int);


int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an opportunity to


implement nested transactions. They are always optional and will only be
called in SQLite version 3.7.7 (2011-06-23) and later.
When xSavepoint(X,N) is invoked, that is a signal to the virtual table X
that it should save its current state as savepoint N. A subsequent call to
xRollbackTo(X,R) means that the state of the virtual table should return to
what it was when xSavepoint(X,R) was last called. The call to
xRollbackTo(X,R) will invalidate all savepoints with N>R; none of the
invalided savepoints will be rolled back or released without first being
reinitialized by a call to xSavepoint(). A call to xRelease(X,M) invalidates
all savepoints where N>=M.
None of the xSavepoint(), xRelease(), or xRollbackTo() methods will ever
be called except in between calls to xBegin() and either xCommit() or
xRollback().

SQLiteErrorCode xRollbackTo(
IntPtr pVtab,
int iSavepoint
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
iSavepoint
This is an integer identifier used to specify a specific saved state for the
virtual table for it to restore itself back to, which should also have the
effect of deleting all saved states with an integer identifier greater than
this one.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xRowId Method

int (*xRowid)(sqlite3_vtab_cursor *pCur, sqlite_int64 *pRowid);

A successful invocation of this method will cause *pRowid to be filled with


the rowid of row that the virtual table cursor pCur is currently pointing at.
This method returns SQLITE_OK on success. It returns an appropriate
error code on failure.
The xRowid method is required for every virtual table implementation.

SQLiteErrorCode xRowId(
IntPtr pCursor,
ref long rowId
);

Parameters
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure.
rowId
Upon success, this parameter must be modified to contain the unique
integer row identifier for the current row for the specified cursor.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xSavepoint Method

int (*xSavepoint)(sqlite3_vtab *pVtab, int);


int (*xRelease)(sqlite3_vtab *pVtab, int);
int (*xRollbackTo)(sqlite3_vtab *pVtab, int);

These methods provide the virtual table implementation an opportunity to


implement nested transactions. They are always optional and will only be
called in SQLite version 3.7.7 (2011-06-23) and later.
When xSavepoint(X,N) is invoked, that is a signal to the virtual table X
that it should save its current state as savepoint N. A subsequent call to
xRollbackTo(X,R) means that the state of the virtual table should return to
what it was when xSavepoint(X,R) was last called. The call to
xRollbackTo(X,R) will invalidate all savepoints with N>R; none of the
invalided savepoints will be rolled back or released without first being
reinitialized by a call to xSavepoint(). A call to xRelease(X,M) invalidates
all savepoints where N>=M.
None of the xSavepoint(), xRelease(), or xRollbackTo() methods will ever
be called except in between calls to xBegin() and either xCommit() or
xRollback().

SQLiteErrorCode xSavepoint(
IntPtr pVtab,
int iSavepoint
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
iSavepoint
This is an integer identifier under which the the current state of the
virtual table should be saved.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xSync Method

int (*xSync)(sqlite3_vtab *pVTab);

This method signals the start of a two-phase commit on a virtual table.


This is method is optional. The xSync pointer of sqlite3_module may be
NULL.
This method is only invoked after call to the xBegin method and prior to
an xCommit or xRollback. In order to implement two-phase commit, the
xSync method on all virtual tables is invoked prior to invoking the
xCommit method on any virtual table. If any of the xSync methods fail,
the entire transaction is rolled back.

SQLiteErrorCode xSync(
IntPtr pVtab
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteNativeModule.xUpdate Method

int (*xUpdate)(
sqlite3_vtab *pVTab,
int argc,
sqlite3_value **argv,
sqlite_int64 *pRowid
);

All changes to a virtual table are made using the xUpdate method. This
one method can be used to insert, delete, or update.
The argc parameter specifies the number of entries in the argv array. The
value of argc will be 1 for a pure delete operation or N+2 for an insert or
replace or update where N is the number of columns in the table. In the
previous sentence, N includes any hidden columns.
Every argv entry will have a non-NULL value in C but may contain the SQL
value NULL. In other words, it is always true that argv[i]!=0 for i between
0 and argc-1. However, it might be the case that
sqlite3_value_type(argv[i])==SQLITE_NULL.

The argv[0] parameter is the rowid of a row in the virtual table to be


deleted. If argv[0] is an SQL NULL, then no deletion occurs.
The argv[1] parameter is the rowid of a new row to be inserted into the
virtual table. If argv[1] is an SQL NULL, then the implementation must
choose a rowid for the newly inserted row. Subsequent argv[] entries
contain values of the columns of the virtual table, in the order that the
columns were declared. The number of columns will match the table
declaration that the xConnect or xCreate method made using the
sqlite3_declare_vtab() call. All hidden columns are included.
When doing an insert without a rowid (argc>1, argv[1] is an SQL NULL),
the implementation must set *pRowid to the rowid of the newly inserted
row; this will become the value returned by the
sqlite3_last_insert_rowid() function. Setting this value in all the other
cases is a harmless no-op; the SQLite engine ignores the *pRowid return
value if argc==1 or argv[1] is not an SQL NULL.
Each call to xUpdate will fall into one of cases shown below. Not that
references to argv[i] mean the SQL value held within the argv[i] object,
not the argv[i] object itself.

argc = 1
The single row with rowid equal to argv[0] is deleted. No inser

argc > 1
argv[0] = NULL
A new row is inserted with a rowid argv[1] and column values in
argv[2] and following. If argv[1] is an SQL
the a new unique rowid is generated automati

argc > 1
argv[0] NULL
argv[0] = argv[1]
The row with rowid argv[0] is updated with new values
in argv[2] and following parameters.

argc > 1
argv[0] NULL
argv[0] argv[1]
The row with rowid argv[0] is updated with rowid argv[1]
and new values in argv[2] and following parameters.
when an SQL statement updates a rowid, as in the st

UPDATE table SET rowid=rowid+1 WHERE ...;

The xUpdate method must return SQLITE_OK if and only if it is successful.


If a failure occurs, the xUpdate must return an appropriate error code. On
a failure, the pVTab->zErrMsg element may optionally be replaced with
error message text stored in memory allocated from SQLite using
functions such as sqlite3_mprintf() or sqlite3_malloc().
If the xUpdate method violates some constraint of the virtual table
(including, but not limited to, attempting to store a value of the wrong
datatype, attempting to store a value that is too large or too small, or
attempting to change a read-only value) then the xUpdate must fail with
an appropriate error code.
There might be one or more sqlite3_vtab_cursor objects open and in use
on the virtual table instance and perhaps even on the row of the virtual
table when the xUpdate method is invoked. The implementation of
xUpdate must be prepared for attempts to delete or modify rows of the
table out from other existing cursors. If the virtual table cannot
accommodate such changes, the xUpdate method must return an error
code.
The xUpdate method is optional. If the xUpdate pointer in the
sqlite3_module for a virtual table is a NULL pointer, then the virtual table
is read-only.

SQLiteErrorCode xUpdate(
IntPtr pVtab,
int argc,
IntPtr argv,
ref long rowId
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
argc
The number of new or modified column values contained in argv.
argv
The array of native pointers to sqlite3_value structures containing the
new or modified column values, if any.
rowId
Upon success, this parameter must be modified to contain the unique
integer row identifier for the row that was inserted, if any.

Return Value
A standard SQLite return code.

See Also
ISQLiteNativeModule Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteSchemaExtensions Interface

For a list of all members of this type, see ISQLiteSchemaExtensions


Members .

public interface ISQLiteSchemaExtensions

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
ISQLiteSchemaExtensions Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteSchemaExtensions Members

ISQLiteSchemaExtensions overview

Public Instance Methods


BuildTempSchema Creates temporary tables on the
connection so schema information
can be queried.

See Also
ISQLiteSchemaExtensions Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteSchemaExtensions Methods

The methods of the ISQLiteSchemaExtensions interface are listed


below. For a complete list of ISQLiteSchemaExtensions interface
members, see the ISQLiteSchemaExtensions Members topic.

Public Instance Methods


BuildTempSchema Creates temporary tables on the
connection so schema information
can be queried.

See Also
ISQLiteSchemaExtensions Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ISQLiteSchemaExtensions.BuildTempSchema Method

Creates temporary tables on the connection so schema information can be


queried.

void BuildTempSchema(
SQLiteConnection connection
);

Parameters
connection
The connection upon which to build the schema tables.

See Also
ISQLiteSchemaExtensions Interface | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
LogEventArgs Class

Event data for logging event handlers.


For a list of all members of this type, see LogEventArgs Members .
System.Object EventArgs
LogEventArgs

public class LogEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
LogEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
LogEventArgs Members

LogEventArgs overview

Public Instance Fields


Data Extra data associated with this
event, if any.
ErrorCode The error code. The type of this
object value should be Int32 or
SQLiteErrorCode.
Message SQL statement text as the
statement first begins executing

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
LogEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
LogEventArgs Fields

The fields of the LogEventArgs class are listed below. For a complete list
of LogEventArgs class members, see the LogEventArgs Members topic.

Public Instance Fields


Data Extra data associated with this
event, if any.
ErrorCode The error code. The type of this
object value should be Int32 or
SQLiteErrorCode.
Message SQL statement text as the
statement first begins executing

See Also
LogEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
LogEventArgs.Data Field

Extra data associated with this event, if any.

public readonly object Data;

See Also
LogEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
LogEventArgs.ErrorCode Field

The error code. The type of this object value should be Int32 or
SQLiteErrorCode.

public readonly object ErrorCode;

See Also
LogEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
LogEventArgs.Message Field

SQL statement text as the statement first begins executing

public readonly string Message;

See Also
LogEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ProgressEventArgs Class

The event data associated with progress reporting events.


For a list of all members of this type, see ProgressEventArgs Members .
System.Object EventArgs
ProgressEventArgs

public class ProgressEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
ProgressEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ProgressEventArgs Members

ProgressEventArgs overview

Public Instance Fields


ReturnCode The return code for the current call
into the progress callback.
UserData The user-defined native data
associated with this event.
Currently, this will always contain
the value of Zero.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
ProgressEventArgs Class | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ProgressEventArgs Fields

The fields of the ProgressEventArgs class are listed below. For a


complete list of ProgressEventArgs class members, see the
ProgressEventArgs Members topic.

Public Instance Fields


ReturnCode The return code for the current call
into the progress callback.
UserData The user-defined native data
associated with this event.
Currently, this will always contain
the value of Zero.

See Also
ProgressEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ProgressEventArgs.ReturnCode Field

The return code for the current call into the progress callback.

public SQLiteProgressReturnCode ReturnCode;

See Also
ProgressEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
ProgressEventArgs.UserData Field

The user-defined native data associated with this event. Currently, this will
always contain the value of Zero.

public readonly IntPtr UserData;

See Also
ProgressEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteAuthorizerActionCode Enumeration

The action code responsible for the current call into the authorizer.

public enum SQLiteAuthorizerActionCode

Members
Member Name Description
None No action is being performed. This
value should not be used from
external code.
Copy No longer used.
CreateIndex An index will be created. The
action-specific arguments are the
index name and the table name.
CreateTable A table will be created. The action-
specific arguments are the table
name and a null value.
CreateTempIndex A temporary index will be created.
The action-specific arguments are
the index name and the table
name.
CreateTempTable A temporary table will be created.
The action-specific arguments are
the table name and a null value.
CreateTempTrigger A temporary trigger will be created.
The action-specific arguments are
the trigger name and the table
name.
CreateTempView A temporary view will be created.
The action-specific arguments are
the view name and a null value.
CreateTrigger A trigger will be created. The
action-specific arguments are the
trigger name and the table name.
CreateView A view will be created. The action-
specific arguments are the view
name and a null value.
Delete A DELETE statement will be
executed. The action-specific
arguments are the table name and
a null value.
DropIndex An index will be dropped. The
action-specific arguments are the
index name and the table name.
DropTable A table will be dropped. The action-
specific arguments are the tables
name and a null value.
DropTempIndex A temporary index will be dropped.
The action-specific arguments are
the index name and the table
name.
DropTempTable A temporary table will be dropped.
The action-specific arguments are
the table name and a null value.
DropTempTrigger A temporary trigger will be
dropped. The action-specific
arguments are the trigger name
and the table name.
DropTempView A temporary view will be dropped.
The action-specific arguments are
the view name and a null value.
DropTrigger A trigger will be dropped. The
action-specific arguments are the
trigger name and the table name.
DropView A view will be dropped. The action-
specific arguments are the view
name and a null value.
Insert An INSERT statement will be
executed. The action-specific
arguments are the table name and
a null value.
Pragma A PRAGMA statement will be
executed. The action-specific
arguments are the name of the
PRAGMA and the new value or a
null value.
Read A table column will be read. The
action-specific arguments are the
table name and the column name.
Select A SELECT statement will be
executed. The action-specific
arguments are both null values.
Transaction A transaction will be started,
committed, or rolled back. The
action-specific arguments are the
name of the operation (BEGIN,
COMMIT, or ROLLBACK) and a null
value.
Update An UPDATE statement will be
executed. The action-specific
arguments are the table name and
the column name.
Attach A database will be attached to the
connection. The action-specific
arguments are the database file
name and a null value.
Detach A database will be detached from
the connection. The action-specific
arguments are the database name
and a null value.
AlterTable The schema of a table will be
altered. The action-specific
arguments are the database name
and the table name.
Reindex An index will be deleted and then
recreated. The action-specific
arguments are the index name and
a null value.
Analyze A table will be analyzed to gathers
statistics about it. The action-
specific arguments are the table
name and a null value.
CreateVtable A virtual table will be created. The
action-specific arguments are the
table name and the module name.
DropVtable A virtual table will be dropped. The
action-specific arguments are the
table name and the module name.
Function A SQL function will be called. The
action-specific arguments are a null
value and the function name.
Savepoint A savepoint will be created,
released, or rolled back. The
action-specific arguments are the
name of the operation (BEGIN,
RELEASE, or ROLLBACK) and the
savepoint name.
Recursive A recursive query will be executed.
The action-specific arguments are
two null values.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteAuthorizerEventHandler Delegate

Raised when authorization is required to perform an action contained


within a SQL query.

public delegate void SQLiteAuthorizerEventHandler(


object sender,
AuthorizerEventArgs e
);

Parameters
sender
The connection performing the action.
e
A AuthorizerEventArgs that contains the event data.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteAuthorizerReturnCode Enumeration

The return code for the current call into the authorizer.

public enum SQLiteAuthorizerReturnCode

Members
Member Name Description
Ok The action will be allowed.
Deny The overall action will be disallowed
and an error message will be
returned from the query
preparation method.
Ignore The specific action will be
disallowed; however, the overall
action will continue. The exact
effects of this return code vary
depending on the specific action,
please refer to the SQLite core
library documentation for futher
details.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBackupCallback Delegate

Raised between each backup step.

public delegate bool SQLiteBackupCallback(


SQLiteConnection source,
string sourceName,
SQLiteConnection destination,
string destinationName,
int pages,
int remainingPages,
int totalPages,
bool retry
);

Parameters
source
The source database connection.
sourceName
The source database name.
destination
The destination database connection.
destinationName
The destination database name.
pages
The number of pages copied with each step.
remainingPages
The number of pages remaining to be copied.
totalPages
The total number of pages in the source database.
retry
Set to true if the operation needs to be retried due to database locking
issues; otherwise, set to false.

Return Value
True to continue with the backup process or false to halt the backup
process, rolling back any changes that have been made so far.
Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBindValueCallback Delegate

This represents a method that will be called in response to a request to


bind a parameter to a command. If an exception is thrown, it will cause
the parameter binding operation to fail -AND- it will continue to unwind
the call stack.

public delegate void SQLiteBindValueCallback(


SQLiteConvert convert,
SQLiteCommand command,
SQLiteConnectionFlags flags,
SQLiteParameter parameter,
string typeName,
int index,
object userData,
out bool complete
);

Parameters
convert
The SQLiteConvert instance in use.
command
The SQLiteCommand instance in use.
flags
The flags associated with the SQLiteConnection instance in use.
parameter
The SQLiteParameter instance being bound to the command.
typeName
The database type name associated with this callback.
index
The ordinal of the parameter being bound to the command.
userData
The data originally used when registering this callback.
complete
Non-zero if the default handling for the parameter binding call should
be skipped (i.e. the parameter should not be bound at all). Great care
should be used when setting this to non-zero.
Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob Class

Represents a single SQL blob in SQLite.


For a list of all members of this type, see SQLiteBlob Members .
System.Object SQLiteBlob

public sealed class SQLiteBlob : IDisposable

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteBlob Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob Members

SQLiteBlob overview

Public Static Methods


Create Creates a SQLiteBlob object. This
will not work for tables that were
created WITHOUT ROWID -OR- if
the query does not include the
"rowid" column or one of its aliases
-OR- if the SQLiteDataReader was
not created with the KeyInfo flag.

Public Instance Methods


Close Closes the blob, freeing the
associated resources.
Dispose Disposes and finalizes the blob.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetCount Queries the total number of bytes
for the underlying database blob.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Read Reads data from the underlying
database blob.
Reopen Retargets this object to an
underlying database blob for a
different row; the database, table,
and column remain exactly the
same. If this operation fails for any
reason, this blob object is
automatically disposed.
ToString (inherited from Object) Returns a String that represents
the current Object.
Write Writes data into the underlying
database blob.

Protected Instance Methods


Finalize The destructor.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob Methods

The methods of the SQLiteBlob class are listed below. For a complete list
of SQLiteBlob class members, see the SQLiteBlob Members topic.

Public Static Methods


Create Creates a SQLiteBlob object. This
will not work for tables that were
created WITHOUT ROWID -OR- if
the query does not include the
"rowid" column or one of its aliases
-OR- if the SQLiteDataReader was
not created with the KeyInfo flag.

Public Instance Methods


Close Closes the blob, freeing the
associated resources.
Dispose Disposes and finalizes the blob.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetCount Queries the total number of bytes
for the underlying database blob.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Read Reads data from the underlying
database blob.
Reopen Retargets this object to an
underlying database blob for a
different row; the database, table,
and column remain exactly the
same. If this operation fails for any
reason, this blob object is
automatically disposed.
ToString (inherited from Object) Returns a String that represents
the current Object.
Write Writes data into the underlying
database blob.

Protected Instance Methods


Finalize The destructor.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.Close Method

Closes the blob, freeing the associated resources.

public void Close();

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.Create Method

Creates a SQLiteBlob object. This will not work for tables that were
created WITHOUT ROWID -OR- if the query does not include the "rowid"
column or one of its aliases -OR- if the SQLiteDataReader was not created
with the KeyInfo flag.

public static SQLiteBlob Create(


SQLiteDataReader dataReader,
int i,
bool readOnly
);

Parameters
dataReader
The SQLiteDataReader instance with a result set containing the desired
blob column.
i
The index of the blob column.
readOnly
Non-zero to open the blob object for read-only access.

Return Value
The newly created SQLiteBlob instance -OR- null if an error occurs.

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.Dispose Method

Disposes and finalizes the blob.

public void Dispose();

Implements
IDisposable.Dispose

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.Finalize Method

The destructor.

protected override void Finalize();

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.GetCount Method

Queries the total number of bytes for the underlying database blob.

public int GetCount();

Return Value
The total number of bytes for the underlying database blob.

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.Read Method

Reads data from the underlying database blob.

public void Read(


byte[] buffer,
int count,
int offset
);

Parameters
buffer
This array will be populated with the bytes read from the underlying
database blob.
count
The number of bytes to read.
offset
The byte offset, relative to the start of the underlying database blob,
where the read operation will begin.

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.Reopen Method

Retargets this object to an underlying database blob for a different row;


the database, table, and column remain exactly the same. If this operation
fails for any reason, this blob object is automatically disposed.

public void Reopen(


long rowId
);

Parameters
rowId
The integer identifier for the new row.

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteBlob.Write Method

Writes data into the underlying database blob.

public void Write(


byte[] buffer,
int count,
int offset
);

Parameters
buffer
This array contains the new values for the specified portion of the
underlying database blob.
count
The number of bytes to write.
offset
The byte offset, relative to the start of the underlying database blob,
where the write operation will begin.

See Also
SQLiteBlob Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCallback Delegate

An internal callback delegate declaration.

public delegate void SQLiteCallback(


IntPtr context,
int argc,
IntPtr argv
);

Parameters
context
Raw native context pointer for the user function.
argc
Total number of arguments to the user function.
argv
Raw native pointer to the array of raw native argument pointers.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Class

SQLite implementation of DbCommand.


For a list of all members of this type, see SQLiteCommand Members .
System.Object MarshalByRefObject
Component
DbCommand
SQLiteCommand

public sealed class SQLiteCommand : DbCommand,


ICloneable

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteCommand Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Members

SQLiteCommand overview

Public Static Methods


Execute Overloaded. This method creates a
new connection, executes the
query using the given execution
type, closes the connection, and
returns the results. If the
connection string is null, a
temporary in-memory database
connection will be used.

Public Instance Constructors


SQLiteCommand Overloaded. Constructs a new
SQLiteCommand

Public Instance Properties


CommandText The SQL command text associated
with the command
CommandTimeout The amount of time to wait for the
connection to become available
before erroring out
CommandType The type of the command. SQLite
only supports CommandType.Text
Connection Overloaded. The connection
associated with this command
Container (inherited from Gets the IContainer that contains
Component) the Component.
DesignTimeVisible Determines if the command is
visible at design time. Defaults to
True.
Parameters Overloaded. Returns the
SQLiteParameterCollection for the
given command
Site (inherited from Component) Gets or sets the ISite of the
Component.
Transaction Overloaded. The transaction
associated with this command.
SQLite only supports one
transaction per connection, so this
property forwards to the
command's underlying connection.
UpdatedRowSource Sets the method the
SQLiteCommandBuilder uses to
determine how to update inserted
or updated rows in a DataTable.

Public Instance Methods


Cancel Not implemented
Clone Clones a command, including all its
parameters
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
CreateParameter Create a new parameter
Dispose (inherited from Overloaded. Releases all resources
Component) used by the Component.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
ExecuteNonQuery Overloaded. Execute the command
and return the number of rows
inserted/updated affected by it.
ExecuteReader Overloaded. Overrides the default
behavior to return a
SQLiteDataReader specialization
class
ExecuteScalar Overloaded. Execute the command
and return the first column of the
first row of the resultset (if
present), or null if no resultset was
returned.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Prepare Does nothing. Commands are
prepared as they are executed the
first time, and kept in prepared
state afterwards.
Reset Overloaded. This method resets all
the prepared statements held by
this instance back to their initial
states, ready to be re-executed.
ToString (inherited from Returns a String containing the
Component) name of the Component, if any.
This method should not be
overridden.
VerifyOnly Verifies that all SQL queries
associated with the current
command text can be successfully
compiled. A SQLiteException will be
raised if any errors occur.

Public Instance Events


Disposed (inherited from Occurs when the component is
Component) disposed by a call to the Dispose
method.
Protected Instance Properties
CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DbConnection Forwards to the local Connection
property
DbParameterCollection Forwards to the local Parameters
property
DbTransaction Forwards to the local Transaction
property
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.

Protected Instance Methods


CreateDbParameter Forwards to the local
CreateParameter() function
Dispose Overloaded. Disposes of the
command and clears all member
variables
ExecuteDbDataReader Creates a new SQLiteDataReader to
execute/iterate the array of SQLite
prepared statements
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Constructor

Constructs a new SQLiteCommand

Overload List
Default constructor
public SQLiteCommand()
Initializes the command and associates it with the specified connection.
public SQLiteCommand(SQLiteConnection)
Initializes the command with the given command text
public SQLiteCommand(string)
Initializes the command with the given SQL command text and attach the
command to the specified connection.
public SQLiteCommand(string,SQLiteConnection)
Initializes a command with the given SQL, connection and transaction
public SQLiteCommand(string,SQLiteConnection,SQLiteTransaction)

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Constructor

Default constructor

SQLiteCommand();

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Constructor

Initializes the command with the given command text

SQLiteCommand(
string commandText
);

Parameters
commandText
The SQL command text

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Constructor

Initializes the command with the given SQL command text and attach the
command to the specified connection.

SQLiteCommand(
string commandText,
SQLiteConnection connection
);

Parameters
commandText
The SQL command text
connection
The connection to associate with the command

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Constructor

Initializes the command and associates it with the specified connection.

SQLiteCommand(
SQLiteConnection connection
);

Parameters
connection
The connection to associate with the command

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Constructor

Initializes a command with the given SQL, connection and transaction

SQLiteCommand(
string commandText,
SQLiteConnection connection,
SQLiteTransaction transaction
);

Parameters
commandText
The SQL command text
connection
The connection to associate with the command
transaction
The transaction the command should be associated with

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Properties

The properties of the SQLiteCommand class are listed below. For a


complete list of SQLiteCommand class members, see the
SQLiteCommand Members topic.

Public Instance Properties


CommandText The SQL command text associated
with the command
CommandTimeout The amount of time to wait for the
connection to become available
before erroring out
CommandType The type of the command. SQLite
only supports CommandType.Text
Connection Overloaded. The connection
associated with this command
Container (inherited from Gets the IContainer that contains
Component) the Component.
DesignTimeVisible Determines if the command is
visible at design time. Defaults to
True.
Parameters Overloaded. Returns the
SQLiteParameterCollection for the
given command
Site (inherited from Component) Gets or sets the ISite of the
Component.
Transaction Overloaded. The transaction
associated with this command.
SQLite only supports one
transaction per connection, so this
property forwards to the
command's underlying connection.
UpdatedRowSource Sets the method the
SQLiteCommandBuilder uses to
determine how to update inserted
or updated rows in a DataTable.
Protected Instance Properties
CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DbConnection Forwards to the local Connection
property
DbParameterCollection Forwards to the local Parameters
property
DbTransaction Forwards to the local Transaction
property
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.CommandText Property

The SQL command text associated with the command

public override string CommandText { public get; public

Implements
IDbCommand.CommandText

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.CommandTimeout Property

The amount of time to wait for the connection to become available before
erroring out

public override int CommandTimeout { public get; public

Implements
IDbCommand.CommandTimeout

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.CommandType Property

The type of the command. SQLite only supports CommandType.Text

public override CommandType CommandType { public get; pu

Implements
IDbCommand.CommandType

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Connection Property

The connection associated with this command

new public SQLiteConnection Connection { public get; pub

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.DbConnection Property

Forwards to the local Connection property

protected override DbConnection DbConnection { protected

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.DbParameterCollection Property

Forwards to the local Parameters property

protected override DbParameterCollection DbParameterColl

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.DbTransaction Property

Forwards to the local Transaction property

protected override DbTransaction DbTransaction { protect

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.DesignTimeVisible Property

Determines if the command is visible at design time. Defaults to True.

public override bool DesignTimeVisible { public get; pub

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Parameters Property

Returns the SQLiteParameterCollection for the given command

new public SQLiteParameterCollection Parameters { public

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Transaction Property

The transaction associated with this command. SQLite only supports one
transaction per connection, so this property forwards to the command's
underlying connection.

new public SQLiteTransaction Transaction { public get; p

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.UpdatedRowSource Property

Sets the method the SQLiteCommandBuilder uses to determine how to


update inserted or updated rows in a DataTable.

public override UpdateRowSource UpdatedRowSource { publi

Implements
IDbCommand.UpdatedRowSource

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand Methods

The methods of the SQLiteCommand class are listed below. For a


complete list of SQLiteCommand class members, see the
SQLiteCommand Members topic.

Public Static Methods


Execute Overloaded. This method creates a
new connection, executes the
query using the given execution
type, closes the connection, and
returns the results. If the
connection string is null, a
temporary in-memory database
connection will be used.

Public Instance Methods


Cancel Not implemented
Clone Clones a command, including all its
parameters
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
CreateParameter Create a new parameter
Dispose (inherited from Overloaded. Releases all resources
Component) used by the Component.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
ExecuteNonQuery Overloaded. Execute the command
and return the number of rows
inserted/updated affected by it.
ExecuteReader Overloaded. Overrides the default
behavior to return a
SQLiteDataReader specialization
class
ExecuteScalar Overloaded. Execute the command
and return the first column of the
first row of the resultset (if
present), or null if no resultset was
returned.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Prepare Does nothing. Commands are
prepared as they are executed the
first time, and kept in prepared
state afterwards.
Reset Overloaded. This method resets all
the prepared statements held by
this instance back to their initial
states, ready to be re-executed.
ToString (inherited from Returns a String containing the
Component) name of the Component, if any.
This method should not be
overridden.
VerifyOnly Verifies that all SQL queries
associated with the current
command text can be successfully
compiled. A SQLiteException will be
raised if any errors occur.

Protected Instance Methods


CreateDbParameter Forwards to the local
CreateParameter() function
Dispose Overloaded. Disposes of the
command and clears all member
variables
ExecuteDbDataReader Creates a new SQLiteDataReader to
execute/iterate the array of SQLite
prepared statements
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Cancel Method

Not implemented

public override void Cancel();

Implements
IDbCommand.Cancel

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Clone Method

Clones a command, including all its parameters

public object Clone();

Return Value
A new SQLiteCommand with the same commandtext, connection and
parameters

Implements
ICloneable.Clone

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.CreateDbParameter Method

Forwards to the local CreateParameter() function

protected override DbParameter CreateDbParameter();

Return Value

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.CreateParameter Method

Create a new parameter

new public SQLiteParameter CreateParameter();

Return Value

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Dispose Method

Disposes of the command and clears all member variables

Overload List
Inherited from Component.
public void Dispose()
Disposes of the command and clears all member variables
protected override void Dispose(bool)

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Dispose(Boolean) Method

Disposes of the command and clears all member variables

protected override void Dispose(


bool disposing
);

Parameters
disposing
Whether or not the class is being explicitly or implicitly disposed

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Execute Method

This method creates a new connection, executes the query using the given
execution type and command behavior, closes the connection unless a data
reader is created, and returns the results. If the connection string is null,
a temporary in-memory database connection will be used.

Overload List
This method creates a new connection, executes the query using the given
execution type and command behavior, closes the connection unless a data
reader is created, and returns the results. If the connection string is null,
a temporary in-memory database connection will be used.
public static object Execute(string,SQLiteExecuteType,CommandBehavior,st
This method creates a new connection, executes the query using the given
execution type, closes the connection, and returns the results. If the
connection string is null, a temporary in-memory database connection will
be used.
public static object Execute(string,SQLiteExecuteType,string,params object[

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Execute(String, SQLiteExecuteType,
CommandBehavior, String, Object) Method

This method creates a new connection, executes the query using the given
execution type and command behavior, closes the connection unless a data
reader is created, and returns the results. If the connection string is null,
a temporary in-memory database connection will be used.

public static object Execute(


string commandText,
SQLiteExecuteType executeType,
CommandBehavior commandBehavior,
string connectionString,
params object[] args
);

Parameters
commandText
The text of the command to be executed.
executeType
The execution type for the command. This is used to determine which
method of the command object to call, which then determines the type
of results returned, if any.
commandBehavior
The command behavior flags for the command.
connectionString
The connection string to the database to be opened, used, and closed. If
this parameter is null, a temporary in-memory databse will be used.
args
The SQL parameter values to be used when building the command
object to be executed, if any.

Return Value
The results of the query -OR- null if no results were produced from the
given execution type.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.Execute Overload List
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Execute(String, SQLiteExecuteType, String,
Object) Method

This method creates a new connection, executes the query using the given
execution type, closes the connection, and returns the results. If the
connection string is null, a temporary in-memory database connection will
be used.

public static object Execute(


string commandText,
SQLiteExecuteType executeType,
string connectionString,
params object[] args
);

Parameters
commandText
The text of the command to be executed.
executeType
The execution type for the command. This is used to determine which
method of the command object to call, which then determines the type
of results returned, if any.
connectionString
The connection string to the database to be opened, used, and closed. If
this parameter is null, a temporary in-memory databse will be used.
args
The SQL parameter values to be used when building the command
object to be executed, if any.

Return Value
The results of the query -OR- null if no results were produced from the
given execution type.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.Execute Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteDbDataReader Method

Creates a new SQLiteDataReader to execute/iterate the array of SQLite


prepared statements

protected override DbDataReader ExecuteDbDataReader(


CommandBehavior behavior
);

Parameters
behavior
The behavior the data reader should adopt

Return Value
Returns a SQLiteDataReader object

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteNonQuery Method

Execute the command and return the number of rows inserted/updated


affected by it.

Overload List
Execute the command and return the number of rows inserted/updated
affected by it.
public override int ExecuteNonQuery()
Execute the command and return the number of rows inserted/updated
affected by it.
public int ExecuteNonQuery(CommandBehavior)

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteNonQuery() Method

Execute the command and return the number of rows inserted/updated


affected by it.

public override int ExecuteNonQuery();

Return Value
The number of rows inserted/updated affected by it.

Implements
IDbCommand.ExecuteNonQuery

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.ExecuteNonQuery Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteNonQuery(CommandBehavior)
Method

Execute the command and return the number of rows inserted/updated


affected by it.

public int ExecuteNonQuery(


CommandBehavior behavior
);

Parameters
behavior
The flags to be associated with the reader.

Return Value
The number of rows inserted/updated affected by it.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.ExecuteNonQuery Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteReader Method

Overrides the default behavior of DbDataReader to return a specialized


SQLiteDataReader class

Overload List
Overrides the default behavior of DbDataReader to return a specialized
SQLiteDataReader class
new public SQLiteDataReader ExecuteReader()
Overrides the default behavior to return a SQLiteDataReader specialization
class
new public SQLiteDataReader ExecuteReader(CommandBehavior)

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteReader() Method

Overrides the default behavior of DbDataReader to return a specialized


SQLiteDataReader class

new public SQLiteDataReader ExecuteReader();

Return Value
A SQLiteDataReader

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.ExecuteReader Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteReader(CommandBehavior) Method

Overrides the default behavior to return a SQLiteDataReader specialization


class

new public SQLiteDataReader ExecuteReader(


CommandBehavior behavior
);

Parameters
behavior
The flags to be associated with the reader.

Return Value
A SQLiteDataReader

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.ExecuteReader Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteScalar Method

Execute the command and return the first column of the first row of the
resultset (if present), or null if no resultset was returned.

Overload List
Execute the command and return the first column of the first row of the
resultset (if present), or null if no resultset was returned.
public override object ExecuteScalar()
Execute the command and return the first column of the first row of the
resultset (if present), or null if no resultset was returned.
public object ExecuteScalar(CommandBehavior)

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteScalar() Method

Execute the command and return the first column of the first row of the
resultset (if present), or null if no resultset was returned.

public override object ExecuteScalar();

Return Value
The first column of the first row of the first resultset from the query.

Implements
IDbCommand.ExecuteScalar

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.ExecuteScalar Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.ExecuteScalar(CommandBehavior) Method

Execute the command and return the first column of the first row of the
resultset (if present), or null if no resultset was returned.

public object ExecuteScalar(


CommandBehavior behavior
);

Parameters
behavior
The flags to be associated with the reader.

Return Value
The first column of the first row of the first resultset from the query.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.ExecuteScalar Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Prepare Method

Does nothing. Commands are prepared as they are executed the first time,
and kept in prepared state afterwards.

public override void Prepare();

Implements
IDbCommand.Prepare

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Reset Method

This method resets all the prepared statements held by this instance back
to their initial states, ready to be re-executed.

Overload List
This method resets all the prepared statements held by this instance back
to their initial states, ready to be re-executed.
public void Reset()
This method resets all the prepared statements held by this instance back
to their initial states, ready to be re-executed.
public void Reset(bool,bool)

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Reset() Method

This method resets all the prepared statements held by this instance back
to their initial states, ready to be re-executed.

public void Reset();

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.Reset Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.Reset(Boolean, Boolean) Method

This method resets all the prepared statements held by this instance back
to their initial states, ready to be re-executed.

public void Reset(


bool clearBindings,
bool ignoreErrors
);

Parameters
clearBindings
Non-zero if the parameter bindings should be cleared as well.
ignoreErrors
If this is zero, a SQLiteException may be thrown for any unsuccessful
return codes from the native library; otherwise, a SQLiteException
will only be thrown if the connection or its state is invalid.

See Also
SQLiteCommand Class | System.Data.SQLite Namespace |
SQLiteCommand.Reset Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommand.VerifyOnly Method

Verifies that all SQL queries associated with the current command text can
be successfully compiled. A SQLiteException will be raised if any errors
occur.

public void VerifyOnly();

See Also
SQLiteCommand Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder Class

SQLite implementation of DbCommandBuilder.


For a list of all members of this type, see SQLiteCommandBuilder Members
.
System.Object MarshalByRefObject
Component
DbCommandBuilder
SQLiteCommandBuilder

public sealed class SQLiteCommandBuilder :


DbCommandBuilder

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteCommandBuilder Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder Members

SQLiteCommandBuilder overview

Public Instance Constructors


SQLiteCommandBuilder Overloaded. Initializes a new
instance of the
SQLiteCommandBuilder class.

Public Instance Properties


CatalogLocation Overridden to hide its property
from the designer
CatalogSeparator Overridden to hide its property
from the designer
ConflictOption (inherited from Specifies which ConflictOption is to
DbCommandBuilder) be used by the DbCommandBuilder.
Container (inherited from Gets the IContainer that contains
Component) the Component.
DataAdapter Overloaded. Gets/sets the
DataAdapter for this
CommandBuilder
QuotePrefix Overridden to hide its property
from the designer
QuoteSuffix Overridden to hide its property
from the designer
SchemaSeparator Overridden to hide its property
from the designer
SetAllValues (inherited from Specifies whether all column values
DbCommandBuilder) in an update statement are
included or only changed ones.
Site (inherited from Component) Gets or sets the ISite of the
Component.

Public Instance Methods


CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases all resources
Component) used by the Component.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetDeleteCommand Overloaded. Returns the
automatically-generated SQLite
command to delete rows from the
database
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetInsertCommand Overloaded. Returns the
automatically-generated SQLite
command to insert rows into the
database
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
GetUpdateCommand Overloaded. Returns the
automatically-generated SQLite
command to update rows in the
database
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
QuoteIdentifier Places brackets around an identifier
RefreshSchema (inherited from Clears the commands associated
DbCommandBuilder) with this DbCommandBuilder.
ToString (inherited from Returns a String containing the
Component) name of the Component, if any.
This method should not be
overridden.
UnquoteIdentifier Removes brackets around an
identifier

Public Instance Events


Disposed (inherited from Occurs when the component is
Component) disposed by a call to the Dispose
method.

Protected Instance Properties


CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.

Protected Instance Methods


ApplyParameterInfo Minimal amount of parameter
processing. Primarily sets the
DbType for the parameter equal to
the provider type in the schema
Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetParameterName Overloaded. Returns a valid named
parameter
GetParameterPlaceholder Returns a placeholder character for
the specified parameter i.
GetSchemaTable Override helper, which can help the
base command builder choose the
right keys for the given query
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
InitializeCommand (inherited Resets the CommandTimeout,
from DbCommandBuilder) Transaction, CommandType, and
UpdateRowSource properties on the
DbCommand.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
RowUpdatingHandler (inherited Adds an event handler for the
from DbCommandBuilder) RowUpdating event.
SetRowUpdatingHandler Sets the handler for receiving row
updating events. Used by the
DbCommandBuilder to
autogenerate SQL statements that
may not have previously been
generated.

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder Constructor

Default constructor

Overload List
Default constructor
public SQLiteCommandBuilder()
Initializes the command builder and associates it with the specified data
adapter.
public SQLiteCommandBuilder(SQLiteDataAdapter)

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder Constructor

Default constructor

SQLiteCommandBuilder();

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder Constructor

Initializes the command builder and associates it with the specified data
adapter.

SQLiteCommandBuilder(
SQLiteDataAdapter adp
);

Parameters
adp

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder Properties

The properties of the SQLiteCommandBuilder class are listed below. For


a complete list of SQLiteCommandBuilder class members, see the
SQLiteCommandBuilder Members topic.

Public Instance Properties


CatalogLocation Overridden to hide its property
from the designer
CatalogSeparator Overridden to hide its property
from the designer
ConflictOption (inherited from Specifies which ConflictOption is to
DbCommandBuilder) be used by the DbCommandBuilder.
Container (inherited from Gets the IContainer that contains
Component) the Component.
DataAdapter Overloaded. Gets/sets the
DataAdapter for this
CommandBuilder
QuotePrefix Overridden to hide its property
from the designer
QuoteSuffix Overridden to hide its property
from the designer
SchemaSeparator Overridden to hide its property
from the designer
SetAllValues (inherited from Specifies whether all column values
DbCommandBuilder) in an update statement are
included or only changed ones.
Site (inherited from Component) Gets or sets the ISite of the
Component.

Protected Instance Properties


CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.CatalogLocation Property

Overridden to hide its property from the designer

public override CatalogLocation CatalogLocation { public

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.CatalogSeparator Property

Overridden to hide its property from the designer

public override string CatalogSeparator { public get; pu

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.DataAdapter Property

Gets/sets the DataAdapter for this CommandBuilder

new public SQLiteDataAdapter DataAdapter { public get; p

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.QuotePrefix Property

Overridden to hide its property from the designer

public override string QuotePrefix { public get; public

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.QuoteSuffix Property

Overridden to hide its property from the designer

public override string QuoteSuffix { public get; public

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.SchemaSeparator Property

Overridden to hide its property from the designer

public override string SchemaSeparator { public get; pub

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder Methods

The methods of the SQLiteCommandBuilder class are listed below. For a


complete list of SQLiteCommandBuilder class members, see the
SQLiteCommandBuilder Members topic.

Public Instance Methods


CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases all resources
Component) used by the Component.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetDeleteCommand Overloaded. Returns the
automatically-generated SQLite
command to delete rows from the
database
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetInsertCommand Overloaded. Returns the
automatically-generated SQLite
command to insert rows into the
database
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
GetUpdateCommand Overloaded. Returns the
automatically-generated SQLite
command to update rows in the
database
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
QuoteIdentifier Places brackets around an identifier
RefreshSchema (inherited from Clears the commands associated
DbCommandBuilder) with this DbCommandBuilder.
ToString (inherited from Returns a String containing the
Component) name of the Component, if any.
This method should not be
overridden.
UnquoteIdentifier Removes brackets around an
identifier

Protected Instance Methods


ApplyParameterInfo Minimal amount of parameter
processing. Primarily sets the
DbType for the parameter equal to
the provider type in the schema
Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetParameterName Overloaded. Returns a valid named
parameter
GetParameterPlaceholder Returns a placeholder character for
the specified parameter i.
GetSchemaTable Override helper, which can help the
base command builder choose the
right keys for the given query
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
InitializeCommand (inherited Resets the CommandTimeout,
from DbCommandBuilder) Transaction, CommandType, and
UpdateRowSource properties on the
DbCommand.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
RowUpdatingHandler (inherited Adds an event handler for the
from DbCommandBuilder) RowUpdating event.
SetRowUpdatingHandler Sets the handler for receiving row
updating events. Used by the
DbCommandBuilder to
autogenerate SQL statements that
may not have previously been
generated.

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.ApplyParameterInfo Method

Minimal amount of parameter processing. Primarily sets the DbType for the
parameter equal to the provider type in the schema

protected override void ApplyParameterInfo(


DbParameter parameter,
DataRow row,
StatementType statementType,
bool whereClause
);

Parameters
parameter
The parameter to use in applying custom behaviors to a row
row
The row to apply the parameter to
statementType
The type of statement
whereClause
Whether the application of the parameter is part of a WHERE clause

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.Dispose Method

Cleans up resources (native and managed) associated with the current


instance.

Overload List
Inherited from Component.
public void Dispose()
Cleans up resources (native and managed) associated with the current
instance.
protected override void Dispose(bool)

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.Dispose(Boolean) Method

Cleans up resources (native and managed) associated with the current


instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Zero when being disposed via garbage collection; otherwise, non-zero.

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetDeleteCommand Method

Returns the automatically-generated SQLite command to delete rows from


the database

Overload List
Returns the automatically-generated SQLite command to delete rows from
the database
new public SQLiteCommand GetDeleteCommand()
Returns the automatically-generated SQLite command to delete rows from
the database
new public SQLiteCommand GetDeleteCommand(bool)

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetDeleteCommand() Method

Returns the automatically-generated SQLite command to delete rows from


the database

new public SQLiteCommand GetDeleteCommand();

Return Value

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetDeleteCommand Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetDeleteCommand(Boolean)
Method

Returns the automatically-generated SQLite command to delete rows from


the database

new public SQLiteCommand GetDeleteCommand(


bool useColumnsForParameterNames
);

Parameters
useColumnsForParameterNames

Return Value

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetDeleteCommand Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetInsertCommand Method

Returns the automatically-generated SQLite command to insert rows into


the database

Overload List
Returns the automatically-generated SQLite command to insert rows into
the database
new public SQLiteCommand GetInsertCommand()
Returns the automatically-generated SQLite command to insert rows into
the database
new public SQLiteCommand GetInsertCommand(bool)

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetInsertCommand() Method

Returns the automatically-generated SQLite command to insert rows into


the database

new public SQLiteCommand GetInsertCommand();

Return Value

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetInsertCommand Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetInsertCommand(Boolean)
Method

Returns the automatically-generated SQLite command to insert rows into


the database

new public SQLiteCommand GetInsertCommand(


bool useColumnsForParameterNames
);

Parameters
useColumnsForParameterNames

Return Value

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetInsertCommand Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetParameterName Method

Returns a named parameter for the given ordinal

Overload List
Returns a named parameter for the given ordinal
protected override string GetParameterName(int)
Returns a valid named parameter
protected override string GetParameterName(string)

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetParameterName(Int32) Method

Returns a named parameter for the given ordinal

protected override string GetParameterName(


int parameterOrdinal
);

Parameters
parameterOrdinal
The i of the parameter

Return Value
Error

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetParameterName Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetParameterName(String) Method

Returns a valid named parameter

protected override string GetParameterName(


string parameterName
);

Parameters
parameterName
The name of the parameter

Return Value
Error

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetParameterName Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetParameterPlaceholder Method

Returns a placeholder character for the specified parameter i.

protected override string GetParameterPlaceholder(


int parameterOrdinal
);

Parameters
parameterOrdinal
The index of the parameter to provide a placeholder for

Return Value
Returns a named parameter

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetSchemaTable Method

Override helper, which can help the base command builder choose the
right keys for the given query

protected override DataTable GetSchemaTable(


DbCommand sourceCommand
);

Parameters
sourceCommand

Return Value

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetUpdateCommand Method

Returns the automatically-generated SQLite command to update rows in


the database

Overload List
Returns the automatically-generated SQLite command to update rows in
the database
new public SQLiteCommand GetUpdateCommand()
Returns the automatically-generated SQLite command to update rows in
the database
new public SQLiteCommand GetUpdateCommand(bool)

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetUpdateCommand() Method

Returns the automatically-generated SQLite command to update rows in


the database

new public SQLiteCommand GetUpdateCommand();

Return Value

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetUpdateCommand Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.GetUpdateCommand(Boolean)
Method

Returns the automatically-generated SQLite command to update rows in


the database

new public SQLiteCommand GetUpdateCommand(


bool useColumnsForParameterNames
);

Parameters
useColumnsForParameterNames

Return Value

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace |
SQLiteCommandBuilder.GetUpdateCommand Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.QuoteIdentifier Method

Places brackets around an identifier

public override string QuoteIdentifier(


string unquotedIdentifier
);

Parameters
unquotedIdentifier
The identifier to quote

Return Value
The bracketed identifier

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.SetRowUpdatingHandler Method

Sets the handler for receiving row updating events. Used by the
DbCommandBuilder to autogenerate SQL statements that may not have
previously been generated.

protected override void SetRowUpdatingHandler(


DbDataAdapter adapter
);

Parameters
adapter
A data adapter to receive events on.

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommandBuilder.UnquoteIdentifier Method

Removes brackets around an identifier

public override string UnquoteIdentifier(


string quotedIdentifier
);

Parameters
quotedIdentifier
The quoted (bracketed) identifier

Return Value
The undecorated identifier

See Also
SQLiteCommandBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCommitHandler Delegate

Raised when a transaction is about to be committed. To roll back a


transaction, set the rollbackTrans boolean value to true.

public delegate void SQLiteCommitHandler(


object sender,
CommitEventArgs e
);

Parameters
sender
The connection committing the transaction
e
Event arguments on the transaction

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteCompareDelegate Delegate

This Delegate type is used with the Compare method.

public delegate int SQLiteCompareDelegate(


string param0,
string param1,
string param2
);

Parameters
param0
This is always the string literal "Compare".
param1
The first string to compare.
param2
The second strnig to compare.

Return Value
A positive integer if the param1 parameter is greater than the param2
parameter, a negative integer if the param1 parameter is less than the
param2 parameter, or zero if they are equal.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConfigDbOpsEnum Enumeration

These are the supported configuration verbs for use with the native SQLite
library. They are used with the SetConfigurationOption method.

public enum SQLiteConfigDbOpsEnum

Members
Member Name Description
SQLITE_DBCONFIG_NONE This value
represents an
unknown (or
invalid) option, do
not use it.
SQLITE_DBCONFIG_LOOKASIDE This option is not
currently supported
by
System.Data.SQLite.
It may be supported
in the future.
SQLITE_DBCONFIG_ENABLE_FKEY This option is used
to enable or disable
the enforcement of
foreign key
constraints.
SQLITE_DBCONFIG_ENABLE_TRIGGER This option is used
to enable or disable
triggers.
SQLITE_DBCONFIG_ENABLE_FTS3_TOKENIZER This option is used
to enable or disable
the two-argument
version of the
fts3_tokenizer()
function which is
part of the FTS3
full-text search
engine extension.
SQLITE_DBCONFIG_ENABLE_LOAD_EXTENSION This option is used
to enable or disable
the loading of
extensions.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Class

SQLite implentation of DbConnection.


For a list of all members of this type, see SQLiteConnection Members .
System.Object MarshalByRefObject
Component
DbConnection
SQLiteConnection

public sealed class SQLiteConnection : DbConnection,


ICloneable

Remarks
The ConnectionString property can contain the following parameter(s),
delimited with a semi-colon:
Parameter Values Required Default
Data Source This may be a file name, the Y
string ":memory:", or any
supported URI (starting with
SQLite 3.7.7). Starting with
release 1.0.86.0, in order to
use more than one
consecutive backslash (e.g.
for a UNC path), each of the
adjoining backslash
characters must be doubled
(e.g.
"\\Network\Share\test.db"
would become
"\\\\Network\Share\test.db").
Uri If specified, this must be a N null
file name that starts with
"file://", "file:", or "/". Any
leading "file://" or "file:"
prefix will be stripped off and
the resulting file name will
be used to open the
database.
FullUri If specified, this must be a N null
URI in a format recognized
by the SQLite core library
(starting with SQLite 3.7.7).
It will be passed verbatim to
the SQLite core library.
Version 3 N 3
UseUTF16Encoding True - The UTF-16 encoding N False
should be used.
False - The UTF-8 encoding
should be used.
DefaultDbType This is the default DbType to N null
use when one cannot be
determined based on the
column metadata and the
configured type mappings.
DefaultTypeName This is the default type name N null
to use when one cannot be
determined based on the
column metadata and the
configured type mappings.
NoDefaultFlags True - Do not combine the N False
specified (or existing)
connection flags with the
value of the DefaultFlags
property.
False - Combine the
specified (or existing)
connection flags with the
value of the DefaultFlags
property.
NoSharedFlags True - Do not combine the N False
specified (or existing)
connection flags with the
value of the SharedFlags
property.
False - Combine the
specified (or existing)
connection flags with the
value of the SharedFlags
property.
VfsName The name of the VFS to use N null
when opening the database
connection. If this is not
specified, the default VFS will
be used.
ZipVfsVersion If non-null, this is the N null
"version" of ZipVFS to use.
This requires the
System.Data.SQLite interop
assembly -AND- primary
managed assembly to be
compiled with the
INTEROP_INCLUDE_ZIPVFS
option; otherwise, this
property does nothing. The
valid values are "v2" and
"v3". Using anyother value
will cause an exception to be
thrown. Please see the
ZipVFS documentation for
more information on how to
use this parameter.
DateTimeFormat Ticks - Use the value of N ISO8601
DateTime.Ticks.
ISO8601 - Use the ISO-
8601 format. Uses the "yyyy-
MM-dd HH:mm:ss.FFFFFFFK"
format for UTC DateTime
values and "yyyy-MM-dd
HH:mm:ss.FFFFFFF" format
for local DateTime values).
JulianDay - The interval of
time in days and fractions of
a day since January 1, 4713
BC.
UnixEpoch - The whole
number of seconds since the
Unix epoch (January 1,
1970).
InvariantCulture - Any
culture-independent string
value that the .NET
Framework can interpret as a
valid DateTime.
CurrentCulture - Any string
value that the .NET
Framework can interpret as a
valid DateTime using the
current culture.
DateTimeKind Unspecified - Not specified N Unspecified
as either UTC or local time.
Utc - The time represented is
UTC.
Local - The time represented
is local time.
DateTimeFormatString The exact DateTime format N null
string to use for all
formatting and parsing of all
DateTime values for this
connection.
BaseSchemaName Some base data classes in N sqlite_defa
the framework (e.g. those
that build SQL queries
dynamically) assume that an
ADO.NET provider cannot
support an alternate catalog
(i.e. database) without
supporting alternate schemas
as well; however, SQLite does
not fit into this model.
Therefore, this value is used
as a placeholder and
removed prior to preparing
any SQL statements that
may contain it.
BinaryGUID True - Store GUID columns N True
in binary form
False - Store GUID columns
as text
Cache Size If the argument N is positive N -2000
then the suggested cache
size is set to N. If the
argument N is negative, then
the number of cache pages is
adjusted to use
approximately abs(N*4096)
bytes of memory. Backwards
compatibility note: The
behavior of cache_size with a
negative N was different in
SQLite versions prior to
3.7.10. In version 3.7.9 and
earlier, the number of pages
in the cache was set to the
absolute value of N.
Synchronous Normal - Normal file N Full
flushing behavior
Full - Full flushing after all
writes
Off - Underlying OS flushes
I/O's
Page Size {size in bytes} N 4096
Password {password} - Using this N
parameter requires that the
CryptoAPI based codec be
enabled at compile-time for
both the native interop
assembly and the core
managed assemblies;
otherwise, using this
parameter may result in an
exception being thrown when
attempting to open the
connection.
HexPassword {hexPassword} - Must N
contain a sequence of zero or
more hexadecimal encoded
byte values without a leading
"0x" prefix. Using this
parameter requires that the
CryptoAPI based codec be
enabled at compile-time for
both the native interop
assembly and the core
managed assemblies;
otherwise, using this
parameter may result in an
exception being thrown when
attempting to open the
connection.
Enlist Y - Automatically enlist in N Y
distributed transactions
N - No automatic enlistment
Pooling True - Use connection N False
pooling.
False - Do not use
connection pooling.

WARNING: When using the


default connection pool
implementation, setting this
property to True should be
avoided by applications that
make use of COM (either
directly or indirectly) due to
possible deadlocks that can
occur during the finalization
of some COM objects.
FailIfMissing True - Don't create the N False
database if it does not exist,
throw an error instead
False - Automatically create
the database if it does not
exist
Max Page Count {size in pages} - Limits the N 0
maximum number of pages
(limits the size) of the
database
Legacy Format True - Use the more N False
compatible legacy 3.x
database format
False - Use the newer 3.3x
database format which
compresses numbers more
effectively

Default Timeout {time in seconds} N 30


The default command
timeout
BusyTimeout {time in milliseconds} N 0
Sets the busy timeout for the
core library.
Journal Mode Delete - Delete the journal N Delete
file after a commit.
Persist - Zero out and leave
the journal file on disk after
a commit.
Off - Disable the rollback
journal entirely. This saves
disk I/O but at the expense
of database safety and
integrity. If the application
using SQLite crashes in the
middle of a transaction when
this journaling mode is set,
then the database file will
very likely go corrupt.
Truncate - Truncate the
journal file to zero-length
instead of deleting it.
Memory - Store the journal
in volatile RAM. This saves
disk I/O but at the expense
of database safety and
integrity. If the application
using SQLite crashes in the
middle of a transaction when
this journaling mode is set,
then the database file will
very likely go corrupt.
Wal - Use a write-ahead log
instead of a rollback journal.
Read Only True - Open the database for N False
read only access
False - Open the database
for normal read/write access
Max Pool Size The maximum number of N 100
connections for the given
connection string that can be
in the connection pool
Default IsolationLevel The default transaciton N Serializabl
isolation level
Foreign Keys Enable foreign key N False
constraints
Flags Extra behavioral flags for the N Default
connection. See the
SQLiteConnectionFlags
enumeration for possible
values.
SetDefaults True - Apply the default N True
connection settings to the
opened database.
False - Skip applying the
default connection settings to
the opened database.
ToFullPath True - Attempt to expand N True
the data source file name to
a fully qualified path before
opening.
False - Skip attempting to
expand the data source file
name to a fully qualified path
before opening.
PrepareRetries The maximum number of N 3
retries when preparing SQL
to be executed. This normally
only applies to preparation
errors resulting from the
database schema being
changed.
ProgressOps The approximate number of N 0
virtual machine instructions
between progress events. In
order for progress events to
actually fire, the event
handler must be added to the
Progress event as well.
Recursive Triggers True - Enable the recursive N False
trigger capability. False -
Disable the recursive trigger
capability.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteConnection Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Members

SQLiteConnection overview

Public Static Properties


ConnectionPool This property is used to obtain or
set the custom connection pool
implementation to use, if any.
Setting this property to null will
cause the default connection pool
implementation to be used.
DefaultFlags The default connection flags to be
used for all opened connections
when they are not present in the
connection string.
DefineConstants Returns a string containing the
define constants (i.e. compile-time
options) used to compile the core
managed assembly, delimited with
spaces.
InteropCompileOptions Returns a string containing the
compile-time options used to
compile the SQLite interop
assembly, delimited with spaces.
InteropSourceId This method returns the string
whose value contains the unique
identifier for the source checkout
used to build the interop assembly.
If the SQLite interop assembly is
not in use or the necessary
information cannot be obtained for
any reason, a null value may be
returned.
InteropVersion This method returns the version of
the interop SQLite assembly used.
If the SQLite interop assembly is
not in use or the necessary
information cannot be obtained for
any reason, a null value may be
returned.
ProviderSourceId This method returns the string
whose value contains the unique
identifier for the source checkout
used to build the managed
components currently executing. If
the necessary information cannot
be obtained for any reason, a null
value may be returned.
ProviderVersion This method returns the version of
the managed components used to
interact with the SQLite core
library. If the necessary information
cannot be obtained for any reason,
a null value may be returned.
SharedFlags The extra connection flags to be
used for all opened connections.
SQLiteCompileOptions Returns a string containing the
compile-time options used to
compile the SQLite core native
library, delimited with spaces.
SQLiteSourceId This method returns the string
whose value is the same as the
SQLITE_SOURCE_ID C
preprocessor macro used when
compiling the SQLite core library.
SQLiteVersion Returns the version of the
underlying SQLite core library.

Public Static Methods


ClearAllPools Clears all connection pools. Any active
connections will be discarded instead of
sent to the pool when they are closed.
ClearPool Clears the connection pool associated with
the connection. Any other active
connections using the same database file
will be discarded instead of returned to
the pool when they are closed.
CreateFile Creates a database file. This just creates a
zero-byte file which SQLite will turn into a
database when the file is opened properly.
CreateHandle Creates and returns a new managed
database connection handle. This method
is intended to be used by implementations
of the ISQLiteConnectionPool interface
only. In theory, it could be used by other
classes; however, that usage is not
supported.
GetMemoryStatistics Returns various global memory statistics
for the SQLite core library via a dictionary
of key/value pairs. Currently, only the
"MemoryUsed" and "MemoryHighwater"
keys are returned and they have values
that correspond to the values that could
be obtained via the MemoryUsed and
MemoryHighwater connection properties.
ReleaseMemory Overloaded. Attempts to free N bytes of
heap memory by deallocating non-
essential memory allocations held by the
database library. Memory used to cache
database pages to improve performance is
an example of non-essential memory. This
is a no-op returning zero if the SQLite
core library was not compiled with the
compile-time option
SQLITE_ENABLE_MEMORY_MANAGEMENT.
Optionally, attempts to reset and/or
compact the Win32 native heap, if
applicable.
SetMemoryStatus Sets the status of the memory usage
tracking subsystem in the SQLite core
library. By default, this is enabled. If this
is disabled, memory usage tracking will
not be performed. This is not really a per-
connection value, it is global to the
process.
Shutdown Overloaded. Passes a shutdown request to
the SQLite core library. Throws an
exception if the shutdown request fails
and the no-throw parameter is non-zero.

Public Static Events


Changed This event is raised when events
related to the lifecycle of a
SQLiteConnection object occur.

Public Instance Constructors


SQLiteConnection Overloaded. Constructs a new
SQLiteConnection object

Public Instance Properties


AutoCommit Returns non-zero if the given
database connection is in
autocommit mode. Autocommit
mode is on by default. Autocommit
mode is disabled by a BEGIN
statement. Autocommit mode is re-
enabled by a COMMIT or
ROLLBACK.
BusyTimeout Gets/sets the default busy timeout
to use with the SQLite core library.
This is only used when opening a
connection.
Changes Returns the number of rows
changed by the last INSERT,
UPDATE, or DELETE statement
executed on this connection.
ConnectionString The connection string containing
the parameters for the connection
ConnectionTimeout (inherited Gets the time to wait while
from DbConnection) establishing a connection before
terminating the attempt and
generating an error.
Container (inherited from Gets the IContainer that contains
Component) the Component.
Database Returns the string "main".
DataSource Returns the data source file name
without extension or path.
DefaultDbType Gets/sets the default database type
for this connection. This value will
only be used when not null.
DefaultTimeout Gets/sets the default command
timeout for newly-created
commands. This is especially useful
for commands used internally such
as inside a SQLiteTransaction,
where setting the timeout is not
possible. This can also be set in the
ConnectionString with "Default
Timeout"
DefaultTypeName Gets/sets the default database type
name for this connection. This
value will only be used when not
null.
FileName Returns the fully qualified path and
file name for the currently open
database, if any.
Flags Gets/sets the extra behavioral flags
for this connection. See the
SQLiteConnectionFlags
enumeration for a list of possible
values.
LastInsertRowId Returns the rowid of the most
recent successful INSERT into the
database from this connection.
MemoryHighwater Returns the maximum amount of
memory (in bytes) used by the
SQLite core library since the high-
water mark was last reset.
MemoryUsed Returns the amount of memory (in
bytes) currently in use by the
SQLite core library.
OwnHandle Returns non-zero if the underlying
native connection handle is owned
by this instance.
ParseViaFramework Non-zero if the built-in (i.e.
framework provided) connection
string parser should be used when
opening the connection.
PoolCount Returns the number of pool entries
for the file name associated with
this connection.
PrepareRetries The maximum number of retries
when preparing SQL to be
executed. This normally only
applies to preparation errors
resulting from the database schema
being changed.
ProgressOps The approximate number of virtual
machine instructions between
progress events. In order for
progress events to actually fire, the
event handler must be added to the
Progress event as well. This value
will only be used when the
underlying native progress callback
needs to be changed.
ServerVersion Returns the version of the
underlying SQLite database engine
Site (inherited from Component) Gets or sets the ISite of the
Component.
State Returns the state of the connection.
VfsName Gets/sets the VFS name for this
connection. This value will only be
used when opening the database.

Public Instance Methods


AddTypeMapping Adds a per-connection type
mapping, possibly replacing one or
more that already exist.
BackupDatabase Backs up the database, using the
specified database connection as
the destination.
BeginTransaction Overloaded. OBSOLETE. Creates a
new SQLiteTransaction if one isn't
already active on the connection.
BindFunction Overloaded. Attempts to bind the
specified SQLiteFunction object
instance to this connection.
Cancel This method causes any pending
database operation to abort and
return at its earliest opportunity.
This routine is typically called in
response to a user action such as
pressing "Cancel" or Ctrl-C where
the user wants a long query
operation to halt immediately. It is
safe to call this routine from any
thread. However, it is not safe to
call this routine with a database
connection that is closed or might
close before this method returns.
ChangeDatabase This method is not implemented;
however, the Changed event will
still be raised.
ChangePassword Overloaded. Change the password
(or assign a password) to an open
database.
ClearCachedSettings Clears the per-connection cached
settings.
ClearTypeCallbacks Clears the per-connection type
callbacks.
ClearTypeMappings Clears the per-connection type
mappings.
Clone Creates a clone of the connection.
All attached databases and user-
defined functions are cloned. If the
existing connection is open, the
cloned connection will also be
opened.

Close When the database connection is


closed, all commands linked to this
connection are automatically reset.
CreateCommand Create a new SQLiteCommand and
associate it with this connection.
CreateModule Creates a disposable module
containing the implementation of a
virtual table.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose Overloaded. Disposes and finalizes
the connection, if applicable.
EnableExtensions Enables or disabled extension
loading.
EnlistTransaction Manual distributed transaction
enlistment support
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
ExtendedResultCode Enables or disabled extended result
codes returned by SQLite
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetSchema Overloaded. The following
commands are used to extract
schema information out of the
database. Valid schema types are:
MetaDataCollections
DataSourceInformation
Catalogs
Columns
ForeignKeys
Indexes
IndexColumns
Tables
Views
ViewColumns

GetType (inherited from Object) Gets the Type of the current


instance.
GetTypeMappings Returns the per-connection type
mappings.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
IsReadOnly Checks if this connection to the
specified database should be
considered read-only. An exception
will be thrown if the database name
specified via name cannot be found.
LoadExtension Overloaded. Loads a SQLite
extension library from the named
dynamic link library file.
LogMessage Overloaded. Add a log message via
the SQLite sqlite3_log interface.
Open Opens the connection using the
parameters found in the
ConnectionString.
OpenAndReturn Opens the connection using the
parameters found in the
ConnectionString and then returns
it.

ReleaseMemory Overloaded. Attempts to free as


much heap memory as possible for
this database connection.
ResultCode Enables or disabled extended result
codes returned by SQLite
SetAvRetry Queries or modifies the number of
retries or the retry interval (in
milliseconds) for certain I/O
operations that may fail due to
anti-virus software.
SetChunkSize Sets the chunk size for the primary
file associated with this database
connection.
SetConfigurationOption Enables or disables a configuration
option for the database.
SetExtendedResultCodes Enables or disabled extended result
codes returned by SQLite
SetPassword Overloaded. Sets the password for
a password-protected database. A
password-protected database is
unusable for any operation until
the password has been set.
SetTypeCallbacks Sets, resets, or clears the per-
connection type callbacks for the
specified database type name.
Shutdown Overloaded. Passes a shutdown
request to the SQLite core library.
Does not throw an exception if the
shutdown request fails.
ToString (inherited from Returns a String containing the
Component) name of the Component, if any.
This method should not be
overridden.
TryGetTypeCallbacks Attempts to get the per-connection
type callbacks for the specified
database type name.

UnbindAllFunctions This method unbinds all registered


(known) functions -OR- all
previously bound user-defined
functions from this connection.
UnbindFunction Attempts to unbind the specified
SQLiteFunction object instance to
this connection.

Public Instance Events


Authorize This event is raised whenever
SQLite encounters an action
covered by the authorizer during
query preparation. Changing the
value of the ReturnCode property
will determine if the specific action
will be allowed, ignored, or denied.
For the entire duration of the
event, the associated connection
and statement objects must not be
modified, either directly or
indirectly, by the called code.
Commit This event is raised whenever
SQLite is committing a transaction.
Return non-zero to trigger a
rollback.
Disposed (inherited from Occurs when the component is
Component) disposed by a call to the Dispose
method.
Progress This event is raised periodically
during long running queries.
Changing the value of the
ReturnCode property will determine
if the operation in progress will
continue or be interrupted. For the
entire duration of the event, the
associated connection and
statement objects must not be
modified, either directly or
indirectly, by the called code.
RollBack This event is raised whenever
SQLite is rolling back a transaction.
StateChange This event is raised whenever the
database is opened or closed.
Trace This event is raised whenever
SQLite statement first begins
executing on this connection. It
only applies to the given
connection.
Update This event is raised whenever
SQLite makes an
update/delete/insert into the
database on this connection. It only
applies to the given connection.

Protected Instance Properties


CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DbProviderFactory Returns the SQLiteFactory instance.
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.

Protected Instance Methods


BeginDbTransaction Forwards to the local
BeginTransaction function
CreateDbCommand Forwards to the local
CreateCommand function.
Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
OnStateChange (inherited from Raises the StateChange event.
DbConnection)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Constructor

Constructs a new SQLiteConnection object

Overload List
Default constructor
public SQLiteConnection()
Clones the settings and connection string from an existing connection. If
the existing connection is already open, this function will open its own
connection, enumerate any attached databases of the original connection,
and automatically attach to them.
public SQLiteConnection(SQLiteConnection)
Initializes the connection with the specified connection string.
public SQLiteConnection(string)
Initializes the connection with the specified connection string.
public SQLiteConnection(string,bool)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Constructor

Default constructor

SQLiteConnection();

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Constructor

Initializes the connection with the specified connection string.

SQLiteConnection(
string connectionString
);

Parameters
connectionString
The connection string to use.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Constructor

Initializes the connection with the specified connection string.

SQLiteConnection(
string connectionString,
bool parseViaFramework
);

Parameters
connectionString
The connection string to use.
parseViaFramework
Non-zero to parse the connection string using the built-in (i.e.
framework provided) parser when opening the connection.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Constructor

Clones the settings and connection string from an existing connection. If


the existing connection is already open, this function will open its own
connection, enumerate any attached databases of the original connection,
and automatically attach to them.

SQLiteConnection(
SQLiteConnection connection
);

Parameters
connection
The connection to copy the settings from.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Properties

The properties of the SQLiteConnection class are listed below. For a


complete list of SQLiteConnection class members, see the
SQLiteConnection Members topic.

Public Static Properties


ConnectionPool This property is used to obtain or
set the custom connection pool
implementation to use, if any.
Setting this property to null will
cause the default connection pool
implementation to be used.
DefaultFlags The default connection flags to be
used for all opened connections
when they are not present in the
connection string.
DefineConstants Returns a string containing the
define constants (i.e. compile-time
options) used to compile the core
managed assembly, delimited with
spaces.
InteropCompileOptions Returns a string containing the
compile-time options used to
compile the SQLite interop
assembly, delimited with spaces.
InteropSourceId This method returns the string
whose value contains the unique
identifier for the source checkout
used to build the interop assembly.
If the SQLite interop assembly is
not in use or the necessary
information cannot be obtained for
any reason, a null value may be
returned.
InteropVersion This method returns the version of
the interop SQLite assembly used.
If the SQLite interop assembly is
not in use or the necessary
information cannot be obtained for
any reason, a null value may be
returned.
ProviderSourceId This method returns the string
whose value contains the unique
identifier for the source checkout
used to build the managed
components currently executing. If
the necessary information cannot
be obtained for any reason, a null
value may be returned.
ProviderVersion This method returns the version of
the managed components used to
interact with the SQLite core
library. If the necessary information
cannot be obtained for any reason,
a null value may be returned.
SharedFlags The extra connection flags to be
used for all opened connections.
SQLiteCompileOptions Returns a string containing the
compile-time options used to
compile the SQLite core native
library, delimited with spaces.
SQLiteSourceId This method returns the string
whose value is the same as the
SQLITE_SOURCE_ID C
preprocessor macro used when
compiling the SQLite core library.
SQLiteVersion Returns the version of the
underlying SQLite core library.

Public Instance Properties


AutoCommit Returns non-zero if the given
database connection is in
autocommit mode. Autocommit
mode is on by default. Autocommit
mode is disabled by a BEGIN
statement. Autocommit mode is re-
enabled by a COMMIT or
ROLLBACK.
BusyTimeout Gets/sets the default busy timeout
to use with the SQLite core library.
This is only used when opening a
connection.
Changes Returns the number of rows
changed by the last INSERT,
UPDATE, or DELETE statement
executed on this connection.
ConnectionString The connection string containing
the parameters for the connection
ConnectionTimeout (inherited Gets the time to wait while
from DbConnection) establishing a connection before
terminating the attempt and
generating an error.
Container (inherited from Gets the IContainer that contains
Component) the Component.
Database Returns the string "main".
DataSource Returns the data source file name
without extension or path.
DefaultDbType Gets/sets the default database type
for this connection. This value will
only be used when not null.
DefaultTimeout Gets/sets the default command
timeout for newly-created
commands. This is especially useful
for commands used internally such
as inside a SQLiteTransaction,
where setting the timeout is not
possible. This can also be set in the
ConnectionString with "Default
Timeout"
DefaultTypeName Gets/sets the default database type
name for this connection. This
value will only be used when not
null.
FileName Returns the fully qualified path and
file name for the currently open
database, if any.

Flags Gets/sets the extra behavioral flags


for this connection. See the
SQLiteConnectionFlags
enumeration for a list of possible
values.
LastInsertRowId Returns the rowid of the most
recent successful INSERT into the
database from this connection.
MemoryHighwater Returns the maximum amount of
memory (in bytes) used by the
SQLite core library since the high-
water mark was last reset.
MemoryUsed Returns the amount of memory (in
bytes) currently in use by the
SQLite core library.
OwnHandle Returns non-zero if the underlying
native connection handle is owned
by this instance.
ParseViaFramework Non-zero if the built-in (i.e.
framework provided) connection
string parser should be used when
opening the connection.
PoolCount Returns the number of pool entries
for the file name associated with
this connection.
PrepareRetries The maximum number of retries
when preparing SQL to be
executed. This normally only
applies to preparation errors
resulting from the database schema
being changed.
ProgressOps The approximate number of virtual
machine instructions between
progress events. In order for
progress events to actually fire, the
event handler must be added to the
Progress event as well. This value
will only be used when the
underlying native progress callback
needs to be changed.
ServerVersion Returns the version of the
underlying SQLite database engine
Site (inherited from Component) Gets or sets the ISite of the
Component.
State Returns the state of the connection.
VfsName Gets/sets the VFS name for this
connection. This value will only be
used when opening the database.

Protected Instance Properties


CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DbProviderFactory Returns the SQLiteFactory instance.
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.AutoCommit Property

Returns non-zero if the given database connection is in autocommit mode.


Autocommit mode is on by default. Autocommit mode is disabled by a
BEGIN statement. Autocommit mode is re-enabled by a COMMIT or
ROLLBACK.

public bool AutoCommit { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BusyTimeout Property

Gets/sets the default busy timeout to use with the SQLite core library. This
is only used when opening a connection.

public int BusyTimeout { public get; public set; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Changes Property

Returns the number of rows changed by the last INSERT, UPDATE, or


DELETE statement executed on this connection.

public int Changes { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ConnectionPool Property

This property is used to obtain or set the custom connection pool


implementation to use, if any. Setting this property to null will cause the
default connection pool implementation to be used.

public static ISQLiteConnectionPool ConnectionPool { pub

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ConnectionString Property

The connection string containing the parameters for the connection

public override string ConnectionString { public get; pu

Implements
IDbConnection.ConnectionString

Remarks
For the complete list of supported connection string properties, please see
SQLiteConnection.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Database Property

Returns the string "main".

public override string Database { public get; }

Implements
IDbConnection.Database

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.DataSource Property

Returns the data source file name without extension or path.

public override string DataSource { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.DbProviderFactory Property

Returns the SQLiteFactory instance.

protected override DbProviderFactory DbProviderFactory {

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.DefaultDbType Property

Gets/sets the default database type for this connection. This value will
only be used when not null.

public DbType? DefaultDbType { public get; public set; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.DefaultFlags Property

The default connection flags to be used for all opened connections when
they are not present in the connection string.

public static SQLiteConnectionFlags DefaultFlags { publi

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.DefaultTimeout Property

Gets/sets the default command timeout for newly-created commands. This


is especially useful for commands used internally such as inside a
SQLiteTransaction, where setting the timeout is not possible. This can also
be set in the ConnectionString with "Default Timeout"

public int DefaultTimeout { public get; public set; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.DefaultTypeName Property

Gets/sets the default database type name for this connection. This value
will only be used when not null.

public string DefaultTypeName { public get; public set;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.DefineConstants Property

Returns a string containing the define constants (i.e. compile-time options)


used to compile the core managed assembly, delimited with spaces.

public static string DefineConstants { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.FileName Property

Returns the fully qualified path and file name for the currently open
database, if any.

public string FileName { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Flags Property

Gets/sets the extra behavioral flags for this connection. See the
SQLiteConnectionFlags enumeration for a list of possible values.

public SQLiteConnectionFlags Flags { public get; public

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.InteropCompileOptions Property

Returns a string containing the compile-time options used to compile the


SQLite interop assembly, delimited with spaces.

public static string InteropCompileOptions { public get;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.InteropSourceId Property

This method returns the string whose value contains the unique identifier
for the source checkout used to build the interop assembly. If the SQLite
interop assembly is not in use or the necessary information cannot be
obtained for any reason, a null value may be returned.

public static string InteropSourceId { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.InteropVersion Property

This method returns the version of the interop SQLite assembly used. If
the SQLite interop assembly is not in use or the necessary information
cannot be obtained for any reason, a null value may be returned.

public static string InteropVersion { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.LastInsertRowId Property

Returns the rowid of the most recent successful INSERT into the database
from this connection.

public long LastInsertRowId { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.MemoryHighwater Property

Returns the maximum amount of memory (in bytes) used by the SQLite
core library since the high-water mark was last reset.

public long MemoryHighwater { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.MemoryUsed Property

Returns the amount of memory (in bytes) currently in use by the SQLite
core library.

public long MemoryUsed { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.OwnHandle Property

Returns non-zero if the underlying native connection handle is owned by


this instance.

public bool OwnHandle { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ParseViaFramework Property

Non-zero if the built-in (i.e. framework provided) connection string parser


should be used when opening the connection.

public bool ParseViaFramework { public get; public set;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.PoolCount Property

Returns the number of pool entries for the file name associated with this
connection.

public int PoolCount { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.PrepareRetries Property

The maximum number of retries when preparing SQL to be executed. This


normally only applies to preparation errors resulting from the database
schema being changed.

public int PrepareRetries { public get; public set; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ProgressOps Property

The approximate number of virtual machine instructions between progress


events. In order for progress events to actually fire, the event handler
must be added to the Progress event as well. This value will only be used
when the underlying native progress callback needs to be changed.

public int ProgressOps { public get; public set; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ProviderSourceId Property

This method returns the string whose value contains the unique identifier
for the source checkout used to build the managed components currently
executing. If the necessary information cannot be obtained for any reason,
a null value may be returned.

public static string ProviderSourceId { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ProviderVersion Property

This method returns the version of the managed components used to


interact with the SQLite core library. If the necessary information cannot
be obtained for any reason, a null value may be returned.

public static string ProviderVersion { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ServerVersion Property

Returns the version of the underlying SQLite database engine

public override string ServerVersion { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SharedFlags Property

The extra connection flags to be used for all opened connections.

public static SQLiteConnectionFlags SharedFlags { public

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SQLiteCompileOptions Property

Returns a string containing the compile-time options used to compile the


SQLite core native library, delimited with spaces.

public static string SQLiteCompileOptions { public get;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SQLiteSourceId Property

This method returns the string whose value is the same as the
SQLITE_SOURCE_ID C preprocessor macro used when compiling the
SQLite core library.

public static string SQLiteSourceId { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SQLiteVersion Property

Returns the version of the underlying SQLite core library.

public static string SQLiteVersion { public get; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.State Property

Returns the state of the connection.

public override ConnectionState State { public get; }

Implements
IDbConnection.State

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.VfsName Property

Gets/sets the VFS name for this connection. This value will only be used
when opening the database.

public string VfsName { public get; public set; }

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Methods

The methods of the SQLiteConnection class are listed below. For a


complete list of SQLiteConnection class members, see the
SQLiteConnection Members topic.

Public Static Methods


ClearAllPools Clears all connection pools. Any active
connections will be discarded instead of
sent to the pool when they are closed.
ClearPool Clears the connection pool associated with
the connection. Any other active
connections using the same database file
will be discarded instead of returned to
the pool when they are closed.
CreateFile Creates a database file. This just creates a
zero-byte file which SQLite will turn into a
database when the file is opened properly.
CreateHandle Creates and returns a new managed
database connection handle. This method
is intended to be used by implementations
of the ISQLiteConnectionPool interface
only. In theory, it could be used by other
classes; however, that usage is not
supported.
GetMemoryStatistics Returns various global memory statistics
for the SQLite core library via a dictionary
of key/value pairs. Currently, only the
"MemoryUsed" and "MemoryHighwater"
keys are returned and they have values
that correspond to the values that could
be obtained via the MemoryUsed and
MemoryHighwater connection properties.
ReleaseMemory Overloaded. Attempts to free N bytes of
heap memory by deallocating non-
essential memory allocations held by the
database library. Memory used to cache
database pages to improve performance is
an example of non-essential memory. This
is a no-op returning zero if the SQLite
core library was not compiled with the
compile-time option
SQLITE_ENABLE_MEMORY_MANAGEMENT.
Optionally, attempts to reset and/or
compact the Win32 native heap, if
applicable.
SetMemoryStatus Sets the status of the memory usage
tracking subsystem in the SQLite core
library. By default, this is enabled. If this
is disabled, memory usage tracking will
not be performed. This is not really a per-
connection value, it is global to the
process.
Shutdown Overloaded. Passes a shutdown request to
the SQLite core library. Throws an
exception if the shutdown request fails
and the no-throw parameter is non-zero.

Public Instance Methods


AddTypeMapping Adds a per-connection type
mapping, possibly replacing one or
more that already exist.
BackupDatabase Backs up the database, using the
specified database connection as
the destination.
BeginTransaction Overloaded. OBSOLETE. Creates a
new SQLiteTransaction if one isn't
already active on the connection.
BindFunction Overloaded. Attempts to bind the
specified SQLiteFunction object
instance to this connection.
Cancel This method causes any pending
database operation to abort and
return at its earliest opportunity.
This routine is typically called in
response to a user action such as
pressing "Cancel" or Ctrl-C where
the user wants a long query
operation to halt immediately. It is
safe to call this routine from any
thread. However, it is not safe to
call this routine with a database
connection that is closed or might
close before this method returns.
ChangeDatabase This method is not implemented;
however, the Changed event will
still be raised.
ChangePassword Overloaded. Change the password
(or assign a password) to an open
database.
ClearCachedSettings Clears the per-connection cached
settings.
ClearTypeCallbacks Clears the per-connection type
callbacks.
ClearTypeMappings Clears the per-connection type
mappings.
Clone Creates a clone of the connection.
All attached databases and user-
defined functions are cloned. If the
existing connection is open, the
cloned connection will also be
opened.
Close When the database connection is
closed, all commands linked to this
connection are automatically reset.
CreateCommand Create a new SQLiteCommand and
associate it with this connection.
CreateModule Creates a disposable module
containing the implementation of a
virtual table.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose Overloaded. Disposes and finalizes
the connection, if applicable.

EnableExtensions Enables or disabled extension


loading.
EnlistTransaction Manual distributed transaction
enlistment support
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
ExtendedResultCode Enables or disabled extended result
codes returned by SQLite
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetSchema Overloaded. The following
commands are used to extract
schema information out of the
database. Valid schema types are:
MetaDataCollections
DataSourceInformation
Catalogs
Columns
ForeignKeys
Indexes
IndexColumns
Tables
Views
ViewColumns
GetType (inherited from Object) Gets the Type of the current
instance.

GetTypeMappings Returns the per-connection type


mappings.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
IsReadOnly Checks if this connection to the
specified database should be
considered read-only. An exception
will be thrown if the database name
specified via name cannot be found.
LoadExtension Overloaded. Loads a SQLite
extension library from the named
dynamic link library file.
LogMessage Overloaded. Add a log message via
the SQLite sqlite3_log interface.
Open Opens the connection using the
parameters found in the
ConnectionString.
OpenAndReturn Opens the connection using the
parameters found in the
ConnectionString and then returns
it.
ReleaseMemory Overloaded. Attempts to free as
much heap memory as possible for
this database connection.
ResultCode Enables or disabled extended result
codes returned by SQLite
SetAvRetry Queries or modifies the number of
retries or the retry interval (in
milliseconds) for certain I/O
operations that may fail due to
anti-virus software.
SetChunkSize Sets the chunk size for the primary
file associated with this database
connection.
SetConfigurationOption Enables or disables a configuration
option for the database.

SetExtendedResultCodes Enables or disabled extended result


codes returned by SQLite
SetPassword Overloaded. Sets the password for
a password-protected database. A
password-protected database is
unusable for any operation until
the password has been set.
SetTypeCallbacks Sets, resets, or clears the per-
connection type callbacks for the
specified database type name.
Shutdown Overloaded. Passes a shutdown
request to the SQLite core library.
Does not throw an exception if the
shutdown request fails.
ToString (inherited from Returns a String containing the
Component) name of the Component, if any.
This method should not be
overridden.
TryGetTypeCallbacks Attempts to get the per-connection
type callbacks for the specified
database type name.
UnbindAllFunctions This method unbinds all registered
(known) functions -OR- all
previously bound user-defined
functions from this connection.
UnbindFunction Attempts to unbind the specified
SQLiteFunction object instance to
this connection.

Protected Instance Methods


BeginDbTransaction Forwards to the local
BeginTransaction function
CreateDbCommand Forwards to the local
CreateCommand function.
Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
OnStateChange (inherited from Raises the StateChange event.
DbConnection)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.AddTypeMapping Method

Adds a per-connection type mapping, possibly replacing one or more that


already exist.

public int AddTypeMapping(


string typeName,
DbType dataType,
bool primary
);

Parameters
typeName
The case-insensitive database type name (e.g. "MYDATE"). The value of
this parameter cannot be null. Using an empty string value (or a string
value consisting entirely of whitespace) for this parameter is not
recommended.
dataType
The DbType value that should be associated with the specified type
name.
primary
Non-zero if this mapping should be considered to be the primary one
for the specified DbType.

Return Value
A negative value if nothing was done. Zero if no per-connection type
mappings were replaced (i.e. it was a pure add operation). More than zero
if some per-connection type mappings were replaced.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BackupDatabase Method

Backs up the database, using the specified database connection as the


destination.

public void BackupDatabase(


SQLiteConnection destination,
string destinationName,
string sourceName,
int pages,
SQLiteBackupCallback callback,
int retryMilliseconds
);

Parameters
destination
The destination database connection.
destinationName
The destination database name.
sourceName
The source database name.
pages
The number of pages to copy or negative to copy all remaining pages.
callback
The method to invoke between each step of the backup process. This
parameter may be null (i.e. no callbacks will be performed).
retryMilliseconds
The number of milliseconds to sleep after encountering a locking error
during the backup process. A value less than zero means that no sleep
should be performed.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BeginDbTransaction Method

Forwards to the local BeginTransaction function

protected override DbTransaction BeginDbTransaction(


IsolationLevel isolationLevel
);

Parameters
isolationLevel
Supported isolation levels are Unspecified, Serializable, and
ReadCommitted

Return Value

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BeginTransaction Method

Creates a new SQLiteTransaction if one isn't already active on the


connection.

Overload List
Creates a new SQLiteTransaction if one isn't already active on the
connection.
new public SQLiteTransaction BeginTransaction()
Obsolete. OBSOLETE. Creates a new SQLiteTransaction if one isn't
already active on the connection.
public SQLiteTransaction BeginTransaction(bool)
Creates a new SQLiteTransaction if one isn't already active on the
connection.
new public SQLiteTransaction BeginTransaction(IsolationLevel)
Obsolete. OBSOLETE. Creates a new SQLiteTransaction if one isn't
already active on the connection.
public SQLiteTransaction BeginTransaction(IsolationLevel,bool)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BeginTransaction() Method

Creates a new SQLiteTransaction if one isn't already active on the


connection.

new public SQLiteTransaction BeginTransaction();

Return Value
Returns the new transaction object.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.BeginTransaction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BeginTransaction(Boolean) Method

NOTE: This method is now obsolete.


Use one of the standard BeginTransaction methods, this one will be
removed soon

OBSOLETE. Creates a new SQLiteTransaction if one isn't already active on


the connection.

public SQLiteTransaction BeginTransaction(


bool deferredLock
);

Parameters
deferredLock
When TRUE, SQLite defers obtaining a write lock until a write operation
is requested. When FALSE, a writelock is obtained immediately. The
default is false, but in a multi-threaded multi-writer environment, one
may instead choose to lock the database immediately to avoid any
possible writer deadlock.

Return Value
Returns a SQLiteTransaction object.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.BeginTransaction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BeginTransaction(IsolationLevel) Method

Creates a new SQLiteTransaction if one isn't already active on the


connection.

new public SQLiteTransaction BeginTransaction(


IsolationLevel isolationLevel
);

Parameters
isolationLevel
Supported isolation levels are Serializable, ReadCommitted and
Unspecified.

Return Value
Returns a SQLiteTransaction object.

Remarks
Unspecified will use the default isolation level specified in the connection
string. If no isolation level is specified in the connection string,
Serializable is used. Serializable transactions are the default. In this
mode, the engine gets an immediate lock on the database, and no other
threads may begin a transaction. Other threads may read from the
database, but not write. With a ReadCommitted isolation level, locks are
deferred and elevated as needed. It is possible for multiple threads to start
a transaction in ReadCommitted mode, but if a thread attempts to commit
a transaction while another thread has a ReadCommitted lock, it may
timeout or cause a deadlock on both threads until both threads'
CommandTimeout's are reached.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.BeginTransaction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BeginTransaction(IsolationLevel,
Boolean) Method

NOTE: This method is now obsolete.


Use one of the standard BeginTransaction methods, this one will be
removed soon

OBSOLETE. Creates a new SQLiteTransaction if one isn't already active on


the connection.

public SQLiteTransaction BeginTransaction(


IsolationLevel isolationLevel,
bool deferredLock
);

Parameters
isolationLevel
This parameter is ignored.
deferredLock
When TRUE, SQLite defers obtaining a write lock until a write operation
is requested. When FALSE, a writelock is obtained immediately. The
default is TRUE, but in a multi-threaded multi-writer environment, one
may instead choose to lock the database immediately to avoid any
possible writer deadlock.

Return Value
Returns a SQLiteTransaction object.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.BeginTransaction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BindFunction Method

Attempts to bind the specified SQLiteFunction object instance to this


connection.

Overload List
Attempts to bind the specified SQLiteFunction object instance to this
connection.
public void BindFunction(SQLiteFunctionAttribute,SQLiteFunction)
Attempts to bind the specified SQLiteFunction object instance to this
connection.
public void BindFunction(SQLiteFunctionAttribute,Delegate,Delegate)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BindFunction(SQLiteFunctionAttribute,
SQLiteFunction) Method

Attempts to bind the specified SQLiteFunction object instance to this


connection.

public void BindFunction(


SQLiteFunctionAttribute functionAttribute,
SQLiteFunction function
);

Parameters
functionAttribute
The SQLiteFunctionAttribute object instance containing the metadata
for the function to be bound.
function
The SQLiteFunction object instance that implements the function to be
bound.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.BindFunction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.BindFunction(SQLiteFunctionAttribute,
Delegate, Delegate) Method

Attempts to bind the specified SQLiteFunction object instance to this


connection.

public void BindFunction(


SQLiteFunctionAttribute functionAttribute,
Delegate callback1,
Delegate callback2
);

Parameters
functionAttribute
The SQLiteFunctionAttribute object instance containing the metadata
for the function to be bound.
callback1
A Delegate object instance that helps implement the function to be
bound. For scalar functions, this corresponds to the
SQLiteInvokeDelegate type. For aggregate functions, this corresponds
to the SQLiteStepDelegate type. For collation functions, this
corresponds to the SQLiteCompareDelegate type.
callback2
A Delegate object instance that helps implement the function to be
bound. For aggregate functions, this corresponds to the
SQLiteFinalDelegate type. For other callback types, it is not used and
must be null.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.BindFunction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Cancel Method

This method causes any pending database operation to abort and return at
its earliest opportunity. This routine is typically called in response to a
user action such as pressing "Cancel" or Ctrl-C where the user wants a
long query operation to halt immediately. It is safe to call this routine from
any thread. However, it is not safe to call this routine with a database
connection that is closed or might close before this method returns.

public void Cancel();

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ChangeDatabase Method

This method is not implemented; however, the Changed event will still be
raised.

public override void ChangeDatabase(


string databaseName
);

Parameters
databaseName

Implements
IDbConnection.ChangeDatabase

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ChangePassword Method

Change the password (or assign a password) to an open database.

Overload List
Change the password (or assign a password) to an open database.
public void ChangePassword(byte[])
Change the password (or assign a password) to an open database.
public void ChangePassword(string)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ChangePassword(Byte) Method

Change the password (or assign a password) to an open database.

public void ChangePassword(


byte[] newPassword
);

Parameters
newPassword
The new password to assign to the database

Remarks
No readers or writers may be active for this process. The database must
already be open and if it already was password protected, the existing
password must already have been supplied.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.ChangePassword Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ChangePassword(String) Method

Change the password (or assign a password) to an open database.

public void ChangePassword(


string newPassword
);

Parameters
newPassword
The new password to assign to the database

Remarks
No readers or writers may be active for this process. The database must
already be open and if it already was password protected, the existing
password must already have been supplied.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.ChangePassword Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ClearAllPools Method

Clears all connection pools. Any active connections will be discarded


instead of sent to the pool when they are closed.

public static void ClearAllPools();

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ClearCachedSettings Method

Clears the per-connection cached settings.

public int ClearCachedSettings();

Return Value
The total number of per-connection settings cleared.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ClearPool Method

Clears the connection pool associated with the connection. Any other
active connections using the same database file will be discarded instead
of returned to the pool when they are closed.

public static void ClearPool(


SQLiteConnection connection
);

Parameters
connection

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ClearTypeCallbacks Method

Clears the per-connection type callbacks.

public int ClearTypeCallbacks();

Return Value
The total number of per-connection type callbacks cleared.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ClearTypeMappings Method

Clears the per-connection type mappings.

public int ClearTypeMappings();

Return Value
The total number of per-connection type mappings cleared.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Clone Method

Creates a clone of the connection. All attached databases and user-defined


functions are cloned. If the existing connection is open, the cloned
connection will also be opened.

public object Clone();

Return Value

Implements
ICloneable.Clone

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Close Method

When the database connection is closed, all commands linked to this


connection are automatically reset.

public override void Close();

Implements
IDbConnection.Close

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.CreateCommand Method

Create a new SQLiteCommand and associate it with this connection.

new public SQLiteCommand CreateCommand();

Return Value
Returns a new command object already assigned to this connection.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.CreateDbCommand Method

Forwards to the local CreateCommand function.

protected override DbCommand CreateDbCommand();

Return Value

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.CreateFile Method

Creates a database file. This just creates a zero-byte file which SQLite will
turn into a database when the file is opened properly.

public static void CreateFile(


string databaseFileName
);

Parameters
databaseFileName
The file to create

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.CreateHandle Method

Creates and returns a new managed database connection handle. This


method is intended to be used by implementations of the
ISQLiteConnectionPool interface only. In theory, it could be used by other
classes; however, that usage is not supported.

public static object CreateHandle(


IntPtr nativeHandle
);

Parameters
nativeHandle
This must be a native database connection handle returned by the
SQLite core library and it must remain valid and open during the entire
duration of the calling method.

Return Value
The new managed database connection handle or null if it cannot be
created.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.CreateModule Method

Creates a disposable module containing the implementation of a virtual


table.

public void CreateModule(


SQLiteModule module
);

Parameters
module
The module object to be used when creating the disposable module.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Dispose Method

Disposes and finalizes the connection, if applicable.

Overload List
Disposes and finalizes the connection, if applicable.
new public void Dispose()
Cleans up resources (native and managed) associated with the current
instance.
protected override void Dispose(bool)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Dispose() Method

Disposes and finalizes the connection, if applicable.

new public void Dispose();

Implements
IDisposable.Dispose

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Dispose(Boolean) Method

Cleans up resources (native and managed) associated with the current


instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Zero when being disposed via garbage collection; otherwise, non-zero.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.EnableExtensions Method

Enables or disabled extension loading.

public void EnableExtensions(


bool enable
);

Parameters
enable
True to enable loading of extensions, false to disable.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.EnlistTransaction Method

Manual distributed transaction enlistment support

public override void EnlistTransaction(


Transaction transaction
);

Parameters
transaction
The distributed transaction to enlist in

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ExtendedResultCode Method

Enables or disabled extended result codes returned by SQLite

public SQLiteErrorCode ExtendedResultCode();

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.GetMemoryStatistics Method

Returns various global memory statistics for the SQLite core library via a
dictionary of key/value pairs. Currently, only the "MemoryUsed" and
"MemoryHighwater" keys are returned and they have values that
correspond to the values that could be obtained via the MemoryUsed and
MemoryHighwater connection properties.

public static void GetMemoryStatistics(


ref IDictionary<string, long> statistics
);

Parameters
statistics
This dictionary will be populated with the global memory statistics. It
will be created if necessary.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.GetSchema Method

The following commands are used to extract schema information out of the
database. Valid schema types are:
MetaDataCollections
DataSourceInformation
Catalogs
Columns
ForeignKeys
Indexes
IndexColumns
Tables
Views
ViewColumns

Overload List
Returns the MetaDataCollections schema
public override DataTable GetSchema()
Returns schema information of the specified collection
public override DataTable GetSchema(string)
Retrieves schema information using the specified constraint(s) for the
specified collection
public override DataTable GetSchema(string,string[])

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.GetSchema() Method

Returns the MetaDataCollections schema

public override DataTable GetSchema();

Return Value
A DataTable of the MetaDataCollections schema

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.GetSchema Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.GetSchema(String) Method

Returns schema information of the specified collection

public override DataTable GetSchema(


string collectionName
);

Parameters
collectionName
The schema collection to retrieve

Return Value
A DataTable of the specified collection

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.GetSchema Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.GetSchema(String, String) Method

Retrieves schema information using the specified constraint(s) for the


specified collection

public override DataTable GetSchema(


string collectionName,
string[] restrictionValues
);

Parameters
collectionName
The collection to retrieve.
restrictionValues
The restrictions to impose. Typically, this may include:
restrictionValues element
index usage
0 The database (or catalog) name,
if applicable.
1 The schema name. This is not
used by this provider.
2 The table name, if applicable.
3 Depends on collectionName. When
"IndexColumns", it is the index
name; otherwise, it is the column
name.
4 Depends on collectionName. When
"IndexColumns", it is the column
name; otherwise, it is not used.

Return Value
A DataTable of the specified collection

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.GetSchema Overload List
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.GetTypeMappings Method

Returns the per-connection type mappings.

public Dictionary<string, object> GetTypeMappings();

Return Value
The per-connection type mappings -OR- null if they are unavailable.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.IsReadOnly Method

Checks if this connection to the specified database should be considered


read-only. An exception will be thrown if the database name specified via
name cannot be found.

public bool IsReadOnly(


string name
);

Parameters
name
The name of a database associated with this connection -OR- null for
the main database.

Return Value
Non-zero if this connection to the specified database should be considered
read-only.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.LoadExtension Method

Loads a SQLite extension library from the named dynamic link library file.

Overload List
Loads a SQLite extension library from the named dynamic link library file.
public void LoadExtension(string)
Loads a SQLite extension library from the named dynamic link library file.
public void LoadExtension(string,string)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.LoadExtension(String) Method

Loads a SQLite extension library from the named dynamic link library file.

public void LoadExtension(


string fileName
);

Parameters
fileName
The name of the dynamic link library file containing the extension.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.LoadExtension Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.LoadExtension(String, String) Method

Loads a SQLite extension library from the named dynamic link library file.

public void LoadExtension(


string fileName,
string procName
);

Parameters
fileName
The name of the dynamic link library file containing the extension.
procName
The name of the exported function used to initialize the extension. If
null, the default "sqlite3_extension_init" will be used.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.LoadExtension Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.LogMessage Method

Add a log message via the SQLite sqlite3_log interface.

Overload List
Add a log message via the SQLite sqlite3_log interface.
public void LogMessage(SQLiteErrorCode,string)
Add a log message via the SQLite sqlite3_log interface.
public void LogMessage(int,string)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.LogMessage(SQLiteErrorCode, String)
Method

Add a log message via the SQLite sqlite3_log interface.

public void LogMessage(


SQLiteErrorCode iErrCode,
string zMessage
);

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.LogMessage Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.LogMessage(Int32, String) Method

Add a log message via the SQLite sqlite3_log interface.

public void LogMessage(


int iErrCode,
string zMessage
);

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.LogMessage Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Open Method

Opens the connection using the parameters found in the ConnectionString.

public override void Open();

Implements
IDbConnection.Open

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.OpenAndReturn Method

Opens the connection using the parameters found in the ConnectionString


and then returns it.

public SQLiteConnection OpenAndReturn();

Return Value
The current connection object.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ReleaseMemory Method

Attempts to free as much heap memory as possible for this database


connection.

Overload List
Attempts to free as much heap memory as possible for this database
connection.
public void ReleaseMemory()
Attempts to free N bytes of heap memory by deallocating non-essential
memory allocations held by the database library. Memory used to cache
database pages to improve performance is an example of non-essential
memory. This is a no-op returning zero if the SQLite core library was not
compiled with the compile-time option
SQLITE_ENABLE_MEMORY_MANAGEMENT. Optionally, attempts to reset
and/or compact the Win32 native heap, if applicable.
public static SQLiteErrorCode ReleaseMemory(int,bool,bool,ref int,ref bool,r

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ReleaseMemory() Method

Attempts to free as much heap memory as possible for this database


connection.

public void ReleaseMemory();

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.ReleaseMemory Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ReleaseMemory(Int32, Boolean, Boolean,
Int32, Boolean, UInt32) Method

Attempts to free N bytes of heap memory by deallocating non-essential


memory allocations held by the database library. Memory used to cache
database pages to improve performance is an example of non-essential
memory. This is a no-op returning zero if the SQLite core library was not
compiled with the compile-time option
SQLITE_ENABLE_MEMORY_MANAGEMENT. Optionally, attempts to reset
and/or compact the Win32 native heap, if applicable.

public static SQLiteErrorCode ReleaseMemory(


int nBytes,
bool reset,
bool compact,
ref int nFree,
ref bool resetOk,
ref uint nLargest
);

Parameters
nBytes
The requested number of bytes to free.
reset
Non-zero to attempt a heap reset.
compact
Non-zero to attempt heap compaction.
nFree
The number of bytes actually freed. This value may be zero.
resetOk
This value will be non-zero if the heap reset was successful.
nLargest
The size of the largest committed free block in the heap, in bytes. This
value will be zero unless heap compaction is enabled.

Return Value
A standard SQLite return code (i.e. zero for success and non-zero for
failure).
See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.ReleaseMemory Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.ResultCode Method

Enables or disabled extended result codes returned by SQLite

public SQLiteErrorCode ResultCode();

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetAvRetry Method

Queries or modifies the number of retries or the retry interval (in


milliseconds) for certain I/O operations that may fail due to anti-virus
software.

public SQLiteErrorCode SetAvRetry(


ref int count,
ref int interval
);

Parameters
count
The number of times to retry the I/O operation. A negative value will
cause the current count to be queried and replace that negative value.
interval
The number of milliseconds to wait before retrying the I/O operation.
This number is multiplied by the number of retry attempts so far to
come up with the final number of milliseconds to wait. A negative value
will cause the current interval to be queried and replace that negative
value.

Return Value
Zero for success, non-zero for error.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetChunkSize Method

Sets the chunk size for the primary file associated with this database
connection.

public SQLiteErrorCode SetChunkSize(


int size
);

Parameters
size
The new chunk size for the main database, in bytes.

Return Value
Zero for success, non-zero for error.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetConfigurationOption Method

Enables or disables a configuration option for the database.

public void SetConfigurationOption(


SQLiteConfigDbOpsEnum option,
bool enable
);

Parameters
option
The database configuration option to enable or disable.
enable
True to enable loading of extensions, false to disable.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetExtendedResultCodes Method

Enables or disabled extended result codes returned by SQLite

public void SetExtendedResultCodes(


bool bOnOff
);

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetMemoryStatus Method

Sets the status of the memory usage tracking subsystem in the SQLite
core library. By default, this is enabled. If this is disabled, memory usage
tracking will not be performed. This is not really a per-connection value, it
is global to the process.

public static SQLiteErrorCode SetMemoryStatus(


bool value
);

Parameters
value
Non-zero to enable memory usage tracking, zero otherwise.

Return Value
A standard SQLite return code (i.e. zero for success and non-zero for
failure).

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetPassword Method

Sets the password for a password-protected database. A password-


protected database is unusable for any operation until the password has
been set.

Overload List
Sets the password for a password-protected database. A password-
protected database is unusable for any operation until the password has
been set.
public void SetPassword(byte[])
Sets the password for a password-protected database. A password-
protected database is unusable for any operation until the password has
been set.
public void SetPassword(string)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetPassword(Byte) Method

Sets the password for a password-protected database. A password-


protected database is unusable for any operation until the password has
been set.

public void SetPassword(


byte[] databasePassword
);

Parameters
databasePassword
The password for the database

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.SetPassword Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetPassword(String) Method

Sets the password for a password-protected database. A password-


protected database is unusable for any operation until the password has
been set.

public void SetPassword(


string databasePassword
);

Parameters
databasePassword
The password for the database

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.SetPassword Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.SetTypeCallbacks Method

Sets, resets, or clears the per-connection type callbacks for the specified
database type name.

public bool SetTypeCallbacks(


string typeName,
SQLiteTypeCallbacks callbacks
);

Parameters
typeName
The database type name.
callbacks
The object holding the callbacks for the database type name. If this
parameter is null, any callbacks for the database type name will be
removed if they are present.

Return Value
Non-zero if callbacks were set or removed; otherwise, zero.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Shutdown Method

Passes a shutdown request to the SQLite core library. Does not throw an
exception if the shutdown request fails.

Overload List
Passes a shutdown request to the SQLite core library. Does not throw an
exception if the shutdown request fails.
public SQLiteErrorCode Shutdown()
Passes a shutdown request to the SQLite core library. Throws an exception
if the shutdown request fails and the no-throw parameter is non-zero.
public static void Shutdown(bool,bool)

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Shutdown() Method

Passes a shutdown request to the SQLite core library. Does not throw an
exception if the shutdown request fails.

public SQLiteErrorCode Shutdown();

Return Value
A standard SQLite return code (i.e. zero for success and non-zero for
failure).

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.Shutdown Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Shutdown(Boolean, Boolean) Method

Passes a shutdown request to the SQLite core library. Throws an exception


if the shutdown request fails and the no-throw parameter is non-zero.

public static void Shutdown(


bool directories,
bool noThrow
);

Parameters
directories
Non-zero to reset the database and temporary directories to their
default values, which should be null for both.
noThrow
When non-zero, throw an exception if the shutdown request fails.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace |
SQLiteConnection.Shutdown Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.TryGetTypeCallbacks Method

Attempts to get the per-connection type callbacks for the specified


database type name.

public bool TryGetTypeCallbacks(


string typeName,
out SQLiteTypeCallbacks callbacks
);

Parameters
typeName
The database type name.
callbacks
Upon success, this parameter will contain the object holding the
callbacks for the database type name. Upon failure, this parameter will
be null.

Return Value
Non-zero upon success; otherwise, zero.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.UnbindAllFunctions Method

This method unbinds all registered (known) functions -OR- all previously
bound user-defined functions from this connection.

public bool UnbindAllFunctions(


bool registered
);

Parameters
registered
Non-zero to unbind all registered (known) functions -OR- zero to
unbind all functions currently bound to the connection.

Return Value
Non-zero if all the specified user-defined functions were unbound.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.UnbindFunction Method

Attempts to unbind the specified SQLiteFunction object instance to this


connection.

public bool UnbindFunction(


SQLiteFunctionAttribute functionAttribute
);

Parameters
functionAttribute
The SQLiteFunctionAttribute object instance containing the metadata
for the function to be unbound.

Return Value
Non-zero if the function was unbound.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection Events

The events of the SQLiteConnection class are listed below. For a


complete list of SQLiteConnection class members, see the
SQLiteConnection Members topic.

Public Static Events


Changed This event is raised when events
related to the lifecycle of a
SQLiteConnection object occur.

Public Instance Events


Authorize This event is raised whenever
SQLite encounters an action
covered by the authorizer during
query preparation. Changing the
value of the ReturnCode property
will determine if the specific action
will be allowed, ignored, or denied.
For the entire duration of the
event, the associated connection
and statement objects must not be
modified, either directly or
indirectly, by the called code.
Commit This event is raised whenever
SQLite is committing a transaction.
Return non-zero to trigger a
rollback.
Disposed (inherited from Occurs when the component is
Component) disposed by a call to the Dispose
method.
Progress This event is raised periodically
during long running queries.
Changing the value of the
ReturnCode property will determine
if the operation in progress will
continue or be interrupted. For the
entire duration of the event, the
associated connection and
statement objects must not be
modified, either directly or
indirectly, by the called code.
RollBack This event is raised whenever
SQLite is rolling back a transaction.
StateChange This event is raised whenever the
database is opened or closed.
Trace This event is raised whenever
SQLite statement first begins
executing on this connection. It
only applies to the given
connection.
Update This event is raised whenever
SQLite makes an
update/delete/insert into the
database on this connection. It only
applies to the given connection.

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Authorize Event

This event is raised whenever SQLite encounters an action covered by the


authorizer during query preparation. Changing the value of the
ReturnCode property will determine if the specific action will be allowed,
ignored, or denied. For the entire duration of the event, the associated
connection and statement objects must not be modified, either directly or
indirectly, by the called code.

public event SQLiteAuthorizerEventHandler Authorize;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Changed Event

This event is raised when events related to the lifecycle of a


SQLiteConnection object occur.

public static event SQLiteConnectionEventHandler Changed

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Commit Event

This event is raised whenever SQLite is committing a transaction. Return


non-zero to trigger a rollback.

public event SQLiteCommitHandler Commit;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Progress Event

This event is raised periodically during long running queries. Changing the
value of the ReturnCode property will determine if the operation in
progress will continue or be interrupted. For the entire duration of the
event, the associated connection and statement objects must not be
modified, either directly or indirectly, by the called code.

public event SQLiteProgressEventHandler Progress;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.RollBack Event

This event is raised whenever SQLite is rolling back a transaction.

public event EventHandler RollBack;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.StateChange Event

This event is raised whenever the database is opened or closed.

public event StateChangeEventHandler StateChange;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Trace Event

This event is raised whenever SQLite statement first begins executing on


this connection. It only applies to the given connection.

public event SQLiteTraceEventHandler Trace;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnection.Update Event

This event is raised whenever SQLite makes an update/delete/insert into


the database on this connection. It only applies to the given connection.

public event SQLiteUpdateEventHandler Update;

See Also
SQLiteConnection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionEventHandler Delegate

Raised when an event pertaining to a connection occurs.

public delegate void SQLiteConnectionEventHandler(


object sender,
ConnectionEventArgs e
);

Parameters
sender
The connection involved.
e
Extra information about the event.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionEventType Enumeration

These are the event types associated with the


SQLiteConnectionEventHandler delegate (and its corresponding event) and
the ConnectionEventArgs class.

public enum SQLiteConnectionEventType

Members
Member Name Description
Invalid Not used.
Unknown Not used.
Opening The connection is being opened.
ConnectionString The connection string has been
parsed.
Opened The connection was opened.
ChangeDatabase The ChangeDatabase method was
called on the connection.
NewTransaction A transaction was created using the
connection.
EnlistTransaction The connection was enlisted into a
transaction.
NewCommand A command was created using the
connection.
NewDataReader A data reader was created using
the connection.
NewCriticalHandle An instance of a CriticalHandle
derived class has been created to
wrap a native resource.
Closing The connection is being closed.
Closed The connection was closed.
DisposingCommand A command is being disposed.
DisposingDataReader A data reader is being disposed.
ClosingDataReader A data reader is being closed.
OpenedFromPool A native resource was opened (i.e.
obtained) from the pool.
ClosedToPool A native resource was closed (i.e.
released) to the pool.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionFlags Enumeration

The extra behavioral flags that can be applied to a connection.


This enumeration has a FlagsAttribute attribute that allows a bitwise
combination of its member values.

public enum SQLiteConnectionFlags : long

Members
Member Name Description Va
None No extra flags. 0
LogPrepare Enable logging of all SQL 1
statements to be
prepared.
LogPreBind Enable logging of all 2
bound parameter types
and raw values.
LogBind Enable logging of all 4
bound parameter
strongly typed values.
LogCallbackException Enable logging of all 8
exceptions caught from
user-provided managed
code called from native
code via delegates.
LogBackup Enable logging of backup 16
API errors.
NoExtensionFunctions Skip adding the 32
extension functions
provided by the native
interop assembly.
BindUInt32AsInt64 When binding parameter 64
values with the UInt32
type, use the interop
method that accepts an
Int64 value.
BindAllAsText When binding parameter 12
values, always bind them
as though they were
plain text (i.e. no
numeric, date/time, or
other conversions should
be attempted).
GetAllAsText When returning column 25
values, always return
them as though they
were plain text (i.e. no
numeric, date/time, or
other conversions should
be attempted).
NoLoadExtension Prevent this 51
SQLiteConnection object
instance from loading
extensions.
NoCreateModule Prevent this 10
SQLiteConnection object
instance from creating
virtual table modules.
NoBindFunctions Skip binding any 20
functions provided by
other managed
assemblies when
opening the connection.
NoLogModule Skip setting the logging 40
related properties of the
SQLiteModule object
instance that was passed
to the CreateModule
method.
LogModuleError Enable logging of all 81
virtual table module
errors seen by the
SetTableError method.
LogModuleException Enable logging of certain 16
virtual table module
exceptions that cannot
be easily discovered via
other means.
TraceWarning Enable tracing of 32
potentially important
[non-fatal] error
conditions that cannot be
easily reported through
other means.
ConvertInvariantText When binding parameter 65
values, always use the
invariant culture when
converting their values
from strings.
BindInvariantText When binding parameter 13
values, always use the
invariant culture when
converting their values
to strings.
NoConnectionPool Disable using the 26
connection pool by
default. If the "Pooling"
connection string
property is specified, its
value will override this
flag. The precise
outcome of combining
this flag with the
UseConnectionPool flag
is unspecified; however,
one of the flags will be in
effect.
UseConnectionPool Enable using the 52
connection pool by
default. If the "Pooling"
connection string
property is specified, its
value will override this
flag. The precise
outcome of combining
this flag with the
NoConnectionPool flag is
unspecified; however,
one of the flags will be in
effect.
UseConnectionTypes Enable using per- 10
connection mappings
between type names and
DbType values. Also see
the ClearTypeMappings,
GetTypeMappings, and
AddTypeMapping
methods. These per-
connection mappings,
when present, override
the corresponding global
mappings.
NoGlobalTypes Disable using global 20
mappings between type
names and DbType
values. This may be
useful in some very
narrow cases; however,
if there are no per-
connection type
mappings, the fallback
defaults will be used for
both type names and
their associated DbType
values. Therefore, use of
this flag is not
recommended.
StickyHasRows When the HasRows 41
property is used, it
should return non-zero if
there were ever any
rows in the associated
result sets.
StrictEnlistment Enable "strict" 83
transaction enlistment
semantics. Setting this
flag will cause an
exception to be thrown if
an attempt is made to
enlist in a transaction
with an unavailable or
unsupported isolation
level. In the future,
more extensive checks
may be enabled by this
flag as well.

MapIsolationLevels Enable mapping of 16


unsupported transaction
isolation levels to the
closest supported
transaction isolation
level.
DetectTextAffinity When returning column 33
values, attempt to detect
the affinity of textual
values by checking if
they fully conform to
those of the Null, Int64,
Double, or DateTime
types.
DetectStringType When returning column 67
values, attempt to detect
the type of string values
by checking if they fully
conform to those of the
Null, Int64, Double, or
DateTime types.
NoConvertSettings Skip querying runtime 13
configuration settings for
use by the
SQLiteConvert class,
including the default
DbType value and default
database type name.
NOTE: If the
DefaultDbType and/or
DefaultTypeName
properties are not set
explicitly nor set via
their connection string
properties and
repeated calls to
determine these
runtime configuration
settings are seen to be
a problem, this flag
should be set.
BindDateTimeWithKind When binding parameter 26
values with the DateTime
type, take their
DateTimeKind into
account as well as that
of the associated
SQLiteConnection.
RollbackOnException If an exception is caught 53
when raising the Commit
event, the transaction
should be rolled back. If
this is not specified, the
transaction will continue
the commit process
instead.
DenyOnException If an exception is caught 10
when raising the
Authorize event, the
action should should be
denied. If this is not
specified, the action will
be allowed instead.
InterruptOnException If an exception is caught 21
when raising the
Progress event, the
operation should be
interrupted. If this is not
specified, the operation
will simply continue.

UnbindFunctionsOnClose Attempt to unbind all 42


functions provided by
other managed
assemblies when closing
the connection.
NoVerifyTextAffinity When returning column 85
values as a String, skip
verifying their affinity.
UseConnectionBindValueCallbacks Enable using per- 17
connection mappings
between type names and
SQLiteBindValueCallback
values. Also see the
ClearTypeCallbacks,
TryGetTypeCallbacks,
and SetTypeCallbacks
methods.
UseConnectionReadValueCallbacks Enable using per- 34
connection mappings
between type names and
SQLiteReadValueCallback
values. Also see the
ClearTypeCallbacks,
TryGetTypeCallbacks,
and SetTypeCallbacks
methods.
UseParameterNameForTypeName If the database type 68
name has not been
explicitly set for the
parameter specified,
fallback to using the
parameter name.
UseParameterDbTypeForTypeName If the database type 13
name has not been
explicitly set for the
parameter specified,
fallback to using the
database type name
associated with the
DbType value.
NoVerifyTypeAffinity When returning column 27
values, skip verifying
their affinity.
AllowNestedTransactions Allow transactions to be 54
nested. The outermost
transaction still controls
whether or not any
changes are ultimately
committed or rolled
back. All non-outermost
transactions are
implemented using the
SAVEPOINT construct.
BindAndGetAllAsText When binding parameter 38
values or returning
column values, always
treat them as though
they were plain text (i.e.
no numeric, date/time,
or other conversions
should be attempted).
ConvertAndBindInvariantText When binding parameter 19
values, always use the
invariant culture when
converting their values
to strings or from
strings.
BindAndGetAllAsInvariantText When binding parameter 13
values or returning
column values, always
treat them as though
they were plain text (i.e.
no numeric, date/time,
or other conversions
should be attempted)
and always use the
invariant culture when
converting their values
to strings.

ConvertAndBindAndGetAllAsInvariantText When binding parameter 19


values or returning
column values, always
treat them as though
they were plain text (i.e.
no numeric, date/time,
or other conversions
should be attempted)
and always use the
invariant culture when
converting their values
to strings or from
strings.
UseConnectionAllValueCallbacks Enables use of all per- 51
connection value
handling callbacks.
UseParameterAnythingForTypeName Enables use of all 20
applicable
SQLiteParameter
properties as fallbacks
for the database type
name.
LogAll Enable all logging. 24
Default The default extra flags 16
for new connections.
DefaultAndLogAll The default extra flags 24
for new connections with
all logging enabled.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)
See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder Class

SQLite implementation of DbConnectionStringBuilder.


For a list of all members of this type, see SQLiteConnectionStringBuilder
Members .
System.Object DbConnectionStringBuilder
SQLiteConnectionStringBuilder

public sealed class SQLiteConnectionStringBuilder :


DbConnectionStringBuilder

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteConnectionStringBuilder Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder Members

SQLiteConnectionStringBuilder overview

Public Instance Constructors


SQLiteConnectionStringBuilder Overloaded. Constructs a new
instance of the class

Public Instance Properties


BaseSchemaName Gets/Sets the placeholder base
schema name used for .NET
Framework compatibility purposes.
BinaryGUID Gets/Sets whethor not to store
GUID's in binary format. The
default is True which saves space in
the database.
BrowsableConnectionString Gets or sets a value that indicates
(inherited from whether the ConnectionString
DbConnectionStringBuilder) property is visible in Visual Studio
designers.
BusyTimeout Gets/sets the busy timeout to use
with the SQLite core library.
CacheSize Gets/Sets the cache size for the
connection.
ConnectionString (inherited from Gets or sets the connection string
DbConnectionStringBuilder) associated with the
DbConnectionStringBuilder.
Count (inherited from Gets the current number of keys
DbConnectionStringBuilder) that are contained within the
ConnectionString property.
DataSource Gets/Sets the filename to open on
the connection string.
DateTimeFormat Gets/Sets the DateTime format for
the connection.
DateTimeFormatString Gets/sets the DateTime format
string used for formatting and
parsing purposes.
DateTimeKind Gets/Sets the DateTime kind for
the connection.
DefaultDbType Gets/sets the default database type
for the connection.
DefaultIsolationLevel Sets the default isolation level for
transactions on the connection.
DefaultTimeout Gets/sets the default command
timeout for newly-created
commands. This is especially useful
for commands used internally such
as inside a SQLiteTransaction,
where setting the timeout is not
possible.
DefaultTypeName Gets/sets the default type name for
the connection.
Enlist Determines whether or not the
connection will automatically
participate in the current
distributed transaction (if one
exists)
FailIfMissing If set to true, will throw an
exception if the database specified
in the connection string does not
exist. If false, the database will be
created automatically.
Flags Gets/Sets the extra behavioral
flags.
ForeignKeys If enabled, use foreign key
constraints
FullUri An alternate to the data source
property that uses the SQLite URI
syntax.
HexPassword Gets/sets the database encryption
hexadecimal password
IsFixedSize (inherited from Gets a value that indicates whether
DbConnectionStringBuilder) the DbConnectionStringBuilder has
a fixed size.
IsReadOnly (inherited from Gets a value that indicates whether
DbConnectionStringBuilder) the DbConnectionStringBuilder is
read-only.
Item (inherited from Gets or sets the value associated
DbConnectionStringBuilder) with the specified key.
JournalMode Determines how SQLite handles the
transaction journal file.
Keys (inherited from Gets an ICollection that contains
DbConnectionStringBuilder) the keys in the
DbConnectionStringBuilder.
LegacyFormat If enabled, uses the legacy 3.xx
format for maximum compatibility,
but results in larger database sizes.
MaxPageCount Gets/Sets the maximum number of
pages the database may hold
NoDefaultFlags If enabled, skip using the
configured default connection flags.
NoSharedFlags If enabled, skip using the
configured shared connection flags.
PageSize Gets/Sets the page size for the
connection.
Password Gets/sets the database encryption
password
Pooling Gets/Sets whether or not to use
connection pooling. The default is
"False"
PrepareRetries Gets/sets the maximum number of
retries when preparing SQL to be
executed. This normally only
applies to preparation errors
resulting from the database schema
being changed.
ProgressOps Gets/sets the approximate number
of virtual machine instructions
between progress events. In order
for progress events to actually fire,
the event handler must be added to
the Progress event as well.

ReadOnly When enabled, the database will be


opened for read-only access and
writing will be disabled.
RecursiveTriggers Enable or disable the recursive
trigger capability.
SetDefaults If enabled, apply the default
connection settings to opened
databases.
SyncMode Gets/Sets the synchronization
mode (file flushing) of the
connection string. Default is
"Normal".
ToFullPath If enabled, attempt to resolve the
provided data source file name to a
full path before opening.
Uri An alternate to the data source
property
UseUTF16Encoding Gets/Sets the encoding for the
connection string. The default is
"False" which indicates UTF-8
encoding.
Values (inherited from Gets an ICollection that contains
DbConnectionStringBuilder) the values in the
DbConnectionStringBuilder.
Version Gets/Sets the default version of the
SQLite engine to instantiate.
Currently the only valid value is 3,
indicating version 3 of the sqlite
library.
VfsName Gets/sets the VFS name for the
connection.
ZipVfsVersion If non-null, this is the version of
ZipVFS to use. This requires the
System.Data.SQLite interop
assembly -AND- primary managed
assembly to be compiled with the
INTEROP_INCLUDE_ZIPVFS option;
otherwise, this property does
nothing.

Public Instance Methods


Add (inherited from Adds an entry with the specified
DbConnectionStringBuilder) key and value into the
DbConnectionStringBuilder.
Clear (inherited from Clears the contents of the
DbConnectionStringBuilder) DbConnectionStringBuilder
instance.
ContainsKey (inherited from Determines whether the
DbConnectionStringBuilder) DbConnectionStringBuilder
contains a specific key.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
EquivalentTo (inherited from Compares the connection
DbConnectionStringBuilder) information in this
DbConnectionStringBuilder object
with the connection information in
the supplied object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Remove (inherited from Removes the entry with the
DbConnectionStringBuilder) specified key from the
DbConnectionStringBuilder
instance.
ShouldSerialize (inherited from Indicates whether the specified key
DbConnectionStringBuilder) exists in this
DbConnectionStringBuilder
instance.
ToString (inherited from Returns the connection string
DbConnectionStringBuilder) associated with this
DbConnectionStringBuilder.
TryGetValue Helper function for retrieving
values from the connectionstring

Protected Instance Methods


ClearPropertyDescriptors Clears the collection of
(inherited from PropertyDescriptor objects on the
DbConnectionStringBuilder) associated
DbConnectionStringBuilder.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
GetProperties (inherited from Fills a supplied Hashtable with
DbConnectionStringBuilder) information about all the properties
of this DbConnectionStringBuilder.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder Constructor

Constructs a new instance of the class

Overload List
Default constructor
public SQLiteConnectionStringBuilder()
Constructs a new instance of the class using the specified connection
string.
public SQLiteConnectionStringBuilder(string)

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder Constructor

Default constructor

SQLiteConnectionStringBuilder();

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace |
SQLiteConnectionStringBuilder Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder Constructor

Constructs a new instance of the class using the specified connection


string.

SQLiteConnectionStringBuilder(
string connectionString
);

Parameters
connectionString
The connection string to parse

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace |
SQLiteConnectionStringBuilder Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder Properties

The properties of the SQLiteConnectionStringBuilder class are listed


below. For a complete list of SQLiteConnectionStringBuilder class
members, see the SQLiteConnectionStringBuilder Members topic.

Public Instance Properties


BaseSchemaName Gets/Sets the placeholder base
schema name used for .NET
Framework compatibility purposes.
BinaryGUID Gets/Sets whethor not to store
GUID's in binary format. The
default is True which saves space in
the database.
BrowsableConnectionString Gets or sets a value that indicates
(inherited from whether the ConnectionString
DbConnectionStringBuilder) property is visible in Visual Studio
designers.
BusyTimeout Gets/sets the busy timeout to use
with the SQLite core library.
CacheSize Gets/Sets the cache size for the
connection.
ConnectionString (inherited from Gets or sets the connection string
DbConnectionStringBuilder) associated with the
DbConnectionStringBuilder.
Count (inherited from Gets the current number of keys
DbConnectionStringBuilder) that are contained within the
ConnectionString property.
DataSource Gets/Sets the filename to open on
the connection string.
DateTimeFormat Gets/Sets the DateTime format for
the connection.
DateTimeFormatString Gets/sets the DateTime format
string used for formatting and
parsing purposes.
DateTimeKind Gets/Sets the DateTime kind for
the connection.
DefaultDbType Gets/sets the default database type
for the connection.
DefaultIsolationLevel Sets the default isolation level for
transactions on the connection.
DefaultTimeout Gets/sets the default command
timeout for newly-created
commands. This is especially useful
for commands used internally such
as inside a SQLiteTransaction,
where setting the timeout is not
possible.
DefaultTypeName Gets/sets the default type name for
the connection.
Enlist Determines whether or not the
connection will automatically
participate in the current
distributed transaction (if one
exists)
FailIfMissing If set to true, will throw an
exception if the database specified
in the connection string does not
exist. If false, the database will be
created automatically.
Flags Gets/Sets the extra behavioral
flags.
ForeignKeys If enabled, use foreign key
constraints
FullUri An alternate to the data source
property that uses the SQLite URI
syntax.
HexPassword Gets/sets the database encryption
hexadecimal password
IsFixedSize (inherited from Gets a value that indicates whether
DbConnectionStringBuilder) the DbConnectionStringBuilder has
a fixed size.
IsReadOnly (inherited from Gets a value that indicates whether
DbConnectionStringBuilder) the DbConnectionStringBuilder is
read-only.
Item (inherited from Gets or sets the value associated
DbConnectionStringBuilder) with the specified key.
JournalMode Determines how SQLite handles the
transaction journal file.
Keys (inherited from Gets an ICollection that contains
DbConnectionStringBuilder) the keys in the
DbConnectionStringBuilder.
LegacyFormat If enabled, uses the legacy 3.xx
format for maximum compatibility,
but results in larger database sizes.
MaxPageCount Gets/Sets the maximum number of
pages the database may hold
NoDefaultFlags If enabled, skip using the
configured default connection flags.
NoSharedFlags If enabled, skip using the
configured shared connection flags.
PageSize Gets/Sets the page size for the
connection.
Password Gets/sets the database encryption
password
Pooling Gets/Sets whether or not to use
connection pooling. The default is
"False"
PrepareRetries Gets/sets the maximum number of
retries when preparing SQL to be
executed. This normally only
applies to preparation errors
resulting from the database schema
being changed.
ProgressOps Gets/sets the approximate number
of virtual machine instructions
between progress events. In order
for progress events to actually fire,
the event handler must be added to
the Progress event as well.
ReadOnly When enabled, the database will be
opened for read-only access and
writing will be disabled.
RecursiveTriggers Enable or disable the recursive
trigger capability.
SetDefaults If enabled, apply the default
connection settings to opened
databases.
SyncMode Gets/Sets the synchronization
mode (file flushing) of the
connection string. Default is
"Normal".
ToFullPath If enabled, attempt to resolve the
provided data source file name to a
full path before opening.
Uri An alternate to the data source
property
UseUTF16Encoding Gets/Sets the encoding for the
connection string. The default is
"False" which indicates UTF-8
encoding.
Values (inherited from Gets an ICollection that contains
DbConnectionStringBuilder) the values in the
DbConnectionStringBuilder.
Version Gets/Sets the default version of the
SQLite engine to instantiate.
Currently the only valid value is 3,
indicating version 3 of the sqlite
library.
VfsName Gets/sets the VFS name for the
connection.
ZipVfsVersion If non-null, this is the version of
ZipVFS to use. This requires the
System.Data.SQLite interop
assembly -AND- primary managed
assembly to be compiled with the
INTEROP_INCLUDE_ZIPVFS option;
otherwise, this property does
nothing.

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.BaseSchemaName Property

Gets/Sets the placeholder base schema name used for .NET Framework
compatibility purposes.

public string BaseSchemaName { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.BinaryGUID Property

Gets/Sets whethor not to store GUID's in binary format. The default is


True which saves space in the database.

public bool BinaryGUID { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.BusyTimeout Property

Gets/sets the busy timeout to use with the SQLite core library.

public int BusyTimeout { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.CacheSize Property

Gets/Sets the cache size for the connection.

public int CacheSize { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DataSource Property

Gets/Sets the filename to open on the connection string.

public string DataSource { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DateTimeFormat Property

Gets/Sets the DateTime format for the connection.

public SQLiteDateFormats DateTimeFormat { public get; pu

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DateTimeFormatString
Property

Gets/sets the DateTime format string used for formatting and parsing
purposes.

public string DateTimeFormatString { public get; public

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DateTimeKind Property

Gets/Sets the DateTime kind for the connection.

public DateTimeKind DateTimeKind { public get; public se

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DefaultDbType Property

Gets/sets the default database type for the connection.

public DbType DefaultDbType { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DefaultIsolationLevel
Property

Sets the default isolation level for transactions on the connection.

public IsolationLevel DefaultIsolationLevel { public get

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DefaultTimeout Property

Gets/sets the default command timeout for newly-created commands. This


is especially useful for commands used internally such as inside a
SQLiteTransaction, where setting the timeout is not possible.

public int DefaultTimeout { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.DefaultTypeName Property

Gets/sets the default type name for the connection.

public string DefaultTypeName { public get; public set;

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.Enlist Property

Determines whether or not the connection will automatically participate in


the current distributed transaction (if one exists)

public bool Enlist { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.FailIfMissing Property

If set to true, will throw an exception if the database specified in the


connection string does not exist. If false, the database will be created
automatically.

public bool FailIfMissing { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.Flags Property

Gets/Sets the extra behavioral flags.

public SQLiteConnectionFlags Flags { public get; public

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.ForeignKeys Property

If enabled, use foreign key constraints

public bool ForeignKeys { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.FullUri Property

An alternate to the data source property that uses the SQLite URI syntax.

public string FullUri { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.HexPassword Property

Gets/sets the database encryption hexadecimal password

public byte[] HexPassword { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.JournalMode Property

Determines how SQLite handles the transaction journal file.

public SQLiteJournalModeEnum JournalMode { public get; p

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.LegacyFormat Property

If enabled, uses the legacy 3.xx format for maximum compatibility, but
results in larger database sizes.

public bool LegacyFormat { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.MaxPageCount Property

Gets/Sets the maximum number of pages the database may hold

public int MaxPageCount { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.NoDefaultFlags Property

If enabled, skip using the configured default connection flags.

public bool NoDefaultFlags { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.NoSharedFlags Property

If enabled, skip using the configured shared connection flags.

public bool NoSharedFlags { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.PageSize Property

Gets/Sets the page size for the connection.

public int PageSize { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.Password Property

Gets/sets the database encryption password

public string Password { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.Pooling Property

Gets/Sets whether or not to use connection pooling. The default is "False"

public bool Pooling { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.PrepareRetries Property

Gets/sets the maximum number of retries when preparing SQL to be


executed. This normally only applies to preparation errors resulting from
the database schema being changed.

public int PrepareRetries { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.ProgressOps Property

Gets/sets the approximate number of virtual machine instructions between


progress events. In order for progress events to actually fire, the event
handler must be added to the Progress event as well.

public int ProgressOps { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.ReadOnly Property

When enabled, the database will be opened for read-only access and
writing will be disabled.

public bool ReadOnly { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.RecursiveTriggers Property

Enable or disable the recursive trigger capability.

public bool RecursiveTriggers { public get; public set;

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.SetDefaults Property

If enabled, apply the default connection settings to opened databases.

public bool SetDefaults { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.SyncMode Property

Gets/Sets the synchronization mode (file flushing) of the connection


string. Default is "Normal".

public SynchronizationModes SyncMode { public get; publi

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.ToFullPath Property

If enabled, attempt to resolve the provided data source file name to a full
path before opening.

public bool ToFullPath { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.Uri Property

An alternate to the data source property

public string Uri { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.UseUTF16Encoding Property

Gets/Sets the encoding for the connection string. The default is "False"
which indicates UTF-8 encoding.

public bool UseUTF16Encoding { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.Version Property

Gets/Sets the default version of the SQLite engine to instantiate.


Currently the only valid value is 3, indicating version 3 of the sqlite
library.

public int Version { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.VfsName Property

Gets/sets the VFS name for the connection.

public string VfsName { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.ZipVfsVersion Property

If non-null, this is the version of ZipVFS to use. This requires the


System.Data.SQLite interop assembly -AND- primary managed assembly
to be compiled with the INTEROP_INCLUDE_ZIPVFS option; otherwise, this
property does nothing.

public string ZipVfsVersion { public get; public set; }

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder Methods

The methods of the SQLiteConnectionStringBuilder class are listed


below. For a complete list of SQLiteConnectionStringBuilder class
members, see the SQLiteConnectionStringBuilder Members topic.

Public Instance Methods


Add (inherited from Adds an entry with the specified
DbConnectionStringBuilder) key and value into the
DbConnectionStringBuilder.
Clear (inherited from Clears the contents of the
DbConnectionStringBuilder) DbConnectionStringBuilder
instance.
ContainsKey (inherited from Determines whether the
DbConnectionStringBuilder) DbConnectionStringBuilder
contains a specific key.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
EquivalentTo (inherited from Compares the connection
DbConnectionStringBuilder) information in this
DbConnectionStringBuilder object
with the connection information in
the supplied object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Remove (inherited from Removes the entry with the
DbConnectionStringBuilder) specified key from the
DbConnectionStringBuilder
instance.
ShouldSerialize (inherited from Indicates whether the specified key
DbConnectionStringBuilder) exists in this
DbConnectionStringBuilder
instance.
ToString (inherited from Returns the connection string
DbConnectionStringBuilder) associated with this
DbConnectionStringBuilder.
TryGetValue Helper function for retrieving
values from the connectionstring

Protected Instance Methods


ClearPropertyDescriptors Clears the collection of
(inherited from PropertyDescriptor objects on the
DbConnectionStringBuilder) associated
DbConnectionStringBuilder.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
GetProperties (inherited from Fills a supplied Hashtable with
DbConnectionStringBuilder) information about all the properties
of this DbConnectionStringBuilder.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConnectionStringBuilder.TryGetValue Method

Helper function for retrieving values from the connectionstring

public override bool TryGetValue(


string keyword,
out object value
);

Parameters
keyword
The keyword to retrieve settings for
value
The resulting parameter value

Return Value
Returns true if the value was found and returned

See Also
SQLiteConnectionStringBuilder Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext Class

This class represents a context from the SQLite core library that can be
passed to the sqlite3_result_*() and associated functions.
For a list of all members of this type, see SQLiteContext Members .
System.Object SQLiteContext

public sealed class SQLiteContext :


ISQLiteNativeHandle

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteContext Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext Members

SQLiteContext overview

Public Instance Properties


NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
SetBlob Sets the context result to the
specified Byte array value.
SetDouble Sets the context result to the
specified Double value.
SetError Sets the context result to the
specified String value containing an
error message.
SetErrorCode Sets the context result to the
specified SQLiteErrorCode value.
SetErrorNoMemory Sets the context result to contain
the error code SQLITE_NOMEM.
SetErrorTooBig Sets the context result to contain
the error code SQLITE_TOOBIG.
SetInt Sets the context result to the
specified Int32 value.
SetInt64 Sets the context result to the
specified Int64 value.
SetNull Sets the context result to NULL.
SetString Sets the context result to the
specified String value.
SetValue Sets the context result to the
specified SQLiteValue.
SetZeroBlob Sets the context result to a BLOB
of zeros of the specified size.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext Properties

The properties of the SQLiteContext class are listed below. For a complete
list of SQLiteContext class members, see the SQLiteContext Members
topic.

Public Instance Properties


NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.NativeHandle Property

Returns the underlying SQLite native handle associated with this object
instance.

public IntPtr NativeHandle { public get; }

Implements
ISQLiteNativeHandle.NativeHandle

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext Methods

The methods of the SQLiteContext class are listed below. For a complete
list of SQLiteContext class members, see the SQLiteContext Members
topic.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
SetBlob Sets the context result to the
specified Byte array value.
SetDouble Sets the context result to the
specified Double value.
SetError Sets the context result to the
specified String value containing an
error message.
SetErrorCode Sets the context result to the
specified SQLiteErrorCode value.
SetErrorNoMemory Sets the context result to contain
the error code SQLITE_NOMEM.
SetErrorTooBig Sets the context result to contain
the error code SQLITE_TOOBIG.
SetInt Sets the context result to the
specified Int32 value.
SetInt64 Sets the context result to the
specified Int64 value.
SetNull Sets the context result to NULL.
SetString Sets the context result to the
specified String value.
SetValue Sets the context result to the
specified SQLiteValue.
SetZeroBlob Sets the context result to a BLOB
of zeros of the specified size.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetBlob Method

Sets the context result to the specified Byte array value.

public void SetBlob(


byte[] value
);

Parameters
value
The Byte array value to use.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetDouble Method

Sets the context result to the specified Double value.

public void SetDouble(


double value
);

Parameters
value
The Double value to use.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetError Method

Sets the context result to the specified String value containing an error
message.

public void SetError(


string value
);

Parameters
value
The String value containing the error message text. This value will be
converted to the UTF-8 encoding prior to being used.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetErrorCode Method

Sets the context result to the specified SQLiteErrorCode value.

public void SetErrorCode(


SQLiteErrorCode value
);

Parameters
value
The SQLiteErrorCode value to use.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetErrorNoMemory Method

Sets the context result to contain the error code SQLITE_NOMEM.

public void SetErrorNoMemory();

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetErrorTooBig Method

Sets the context result to contain the error code SQLITE_TOOBIG.

public void SetErrorTooBig();

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetInt Method

Sets the context result to the specified Int32 value.

public void SetInt(


int value
);

Parameters
value
The Int32 value to use.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetInt64 Method

Sets the context result to the specified Int64 value.

public void SetInt64(


long value
);

Parameters
value
The Int64 value to use.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetNull Method

Sets the context result to NULL.

public void SetNull();

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetString Method

Sets the context result to the specified String value.

public void SetString(


string value
);

Parameters
value
The String value to use. This value will be converted to the UTF-8
encoding prior to being used.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetValue Method

Sets the context result to the specified SQLiteValue.

public void SetValue(


SQLiteValue value
);

Parameters
value
The SQLiteValue to use.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteContext.SetZeroBlob Method

Sets the context result to a BLOB of zeros of the specified size.

public void SetZeroBlob(


int value
);

Parameters
value
The number of zero bytes to use for the BLOB context result.

See Also
SQLiteContext Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert Class

This base class provides datatype conversion services for the SQLite
provider.
For a list of all members of this type, see SQLiteConvert Members .
System.Object SQLiteConvert

public abstract class SQLiteConvert

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteConvert Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert Members

SQLiteConvert overview

Public Static Methods


GetStringOrNull Converts the object value, which is
assumed to have originated from a
DataRow, to a string value.
Split Smart method of splitting a string.
Skips quoted elements, removes
the quotes.
ToBoolean Overloaded. Convert a value to
true or false.
ToDateTime Overloaded. Converts a string into
a DateTime, using the specified
DateTimeFormat, DateTimeKind and
DateTimeFormatString.
ToJulianDay Converts a DateTime struct to a
JulianDay double
ToString Overloaded. Converts a string into
a DateTime, using the
DateTimeFormat, DateTimeKind,
and DateTimeFormatString
specified for the connection when it
was opened.
ToStringWithProvider Queries and returns the string
representation for an object, using
the specified (or current) format
provider.
ToUnixEpoch Converts a DateTime struct to the
whole number of seconds since the
Unix epoch.
ToUTF8 Overloaded. Converts a string to a
UTF-8 encoded byte array sized to
include a null-terminating
character.
UTF8ToString Converts a UTF-8 encoded IntPtr of
the specified length into a .NET
string

Protected Static Fields


UnixEpoch The value for the Unix epoch (e.g.
January 1, 1970 at midnight, in
UTC).

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToDateTime Overloaded. Converts a string into
a DateTime, using the
DateTimeFormat, DateTimeKind,
and DateTimeFormatString
specified for the connection when it
was opened.
ToString Overloaded. Converts a UTF-8
encoded IntPtr of the specified
length into a .NET string
ToString (inherited from Object) Overloaded. Returns a String that
represents the current Object.
ToUTF8 Overloaded. Convert a DateTime to
a UTF-8 encoded, zero-terminated
byte array.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert Fields

The fields of the SQLiteConvert class are listed below. For a complete list
of SQLiteConvert class members, see the SQLiteConvert Members topic.

Protected Static Fields


UnixEpoch The value for the Unix epoch (e.g.
January 1, 1970 at midnight, in
UTC).

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.UnixEpoch Field

The value for the Unix epoch (e.g. January 1, 1970 at midnight, in UTC).

protected static readonly DateTime UnixEpoch;

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert Methods

The methods of the SQLiteConvert class are listed below. For a complete
list of SQLiteConvert class members, see the SQLiteConvert Members
topic.

Public Static Methods


GetStringOrNull Converts the object value, which is
assumed to have originated from a
DataRow, to a string value.
Split Smart method of splitting a string.
Skips quoted elements, removes
the quotes.
ToBoolean Overloaded. Convert a value to
true or false.
ToDateTime Overloaded. Converts a string into
a DateTime, using the specified
DateTimeFormat, DateTimeKind and
DateTimeFormatString.
ToJulianDay Converts a DateTime struct to a
JulianDay double
ToString Overloaded. Converts a string into
a DateTime, using the
DateTimeFormat, DateTimeKind,
and DateTimeFormatString
specified for the connection when it
was opened.
ToStringWithProvider Queries and returns the string
representation for an object, using
the specified (or current) format
provider.
ToUnixEpoch Converts a DateTime struct to the
whole number of seconds since the
Unix epoch.
ToUTF8 Overloaded. Converts a string to a
UTF-8 encoded byte array sized to
include a null-terminating
character.
UTF8ToString Converts a UTF-8 encoded IntPtr of
the specified length into a .NET
string

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToDateTime Overloaded. Converts a string into
a DateTime, using the
DateTimeFormat, DateTimeKind,
and DateTimeFormatString
specified for the connection when it
was opened.
ToString Overloaded. Converts a UTF-8
encoded IntPtr of the specified
length into a .NET string
ToString (inherited from Object) Overloaded. Returns a String that
represents the current Object.
ToUTF8 Overloaded. Convert a DateTime to
a UTF-8 encoded, zero-terminated
byte array.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.GetStringOrNull Method

Converts the object value, which is assumed to have originated from a


DataRow, to a string value.

public static string GetStringOrNull(


object value
);

Parameters
value
The value to be converted to a string.

Return Value
A null value will be returned if the original value is null -OR- the original
value is Value. Otherwise, the original value will be converted to a string,
using its (possibly overridden) ToString method and then returned.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.Split Method

Smart method of splitting a string. Skips quoted elements, removes the


quotes.

public static string[] Split(


string source,
char separator
);

Parameters
source
Source string to split apart
separator
Separator character

Return Value
A string array of the split up elements

Remarks
This split function works somewhat like the String.Split() function in that it
breaks apart a string into pieces and returns the pieces as an array. The
primary differences are:
Only one character can be provided as a separator character
Quoted text inside the string is skipped over when searching
for the separator, and the quotes are removed.
Thus, if splitting the following string looking for a comma:
One,Two, "Three, Four", Five

The resulting array would contain


[0] One
[1] Two
[2] Three, Four
[3] Five

Note that the leading and trailing spaces were removed from each item
during the split.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToBoolean Method

Convert a value to true or false.

Overload List
Convert a value to true or false.
public static bool ToBoolean(object)
Attempts to convert a String into a Boolean.
public static bool ToBoolean(string)

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToBoolean(Object) Method

Convert a value to true or false.

public static bool ToBoolean(


object source
);

Parameters
source
A string or number representing true or false

Return Value

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToBoolean Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToBoolean(String) Method

Attempts to convert a String into a Boolean.

public static bool ToBoolean(


string source
);

Parameters
source
The String to convert, cannot be null.

Return Value
The converted Boolean value.

Remarks
The supported strings are "yes", "no", "y", "n", "on", "off", "0", "1", as well
as any prefix of the strings FalseString and TrueString. All strings are
treated in a case-insensitive manner.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToBoolean Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToDateTime Method

Converts a julianday value into a DateTime

Overload List
Converts a julianday value into a DateTime
public DateTime ToDateTime(double)
Converts a julianday value into a DateTime
public static DateTime ToDateTime(double,DateTimeKind)
Converts a string into a DateTime, using the DateTimeFormat,
DateTimeKind, and DateTimeFormatString specified for the connection
when it was opened.
public DateTime ToDateTime(string)
Converts a string into a DateTime, using the specified DateTimeFormat,
DateTimeKind and DateTimeFormatString.
public static DateTime ToDateTime(string,SQLiteDateFormats,DateTimeKind

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToDateTime(Double) Method

Converts a julianday value into a DateTime

public DateTime ToDateTime(


double julianDay
);

Parameters
julianDay
The value to convert

Return Value
A .NET DateTime

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToDateTime Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToDateTime(Double, DateTimeKind) Method

Converts a julianday value into a DateTime

public static DateTime ToDateTime(


double julianDay,
DateTimeKind kind
);

Parameters
julianDay
The value to convert
kind
The DateTimeKind to use.

Return Value
A .NET DateTime

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToDateTime Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToDateTime(String) Method

Converts a string into a DateTime, using the DateTimeFormat,


DateTimeKind, and DateTimeFormatString specified for the connection
when it was opened.

public DateTime ToDateTime(


string dateText
);

Parameters
dateText
The string containing either a long integer number of 100-nanosecond
units since System.DateTime.MinValue, a Julian day double, an integer
number of seconds since the Unix epoch, a culture-independent
formatted date and time string, a formatted date and time string in the
current culture, or an ISO8601-format string.

Return Value
A DateTime value

Remarks
Acceptable ISO8601 DateTime formats are:
THHmmssK
THHmmK
HH:mm:ss.FFFFFFFK
HH:mm:ssK
HH:mmK
yyyy-MM-dd HH:mm:ss.FFFFFFFK
yyyy-MM-dd HH:mm:ssK
yyyy-MM-dd HH:mmK
yyyy-MM-ddTHH:mm:ss.FFFFFFFK
yyyy-MM-ddTHH:mmK
yyyy-MM-ddTHH:mm:ssK
yyyyMMddHHmmssK
yyyyMMddHHmmK
yyyyMMddTHHmmssFFFFFFFK
THHmmss
THHmm
HH:mm:ss.FFFFFFF
HH:mm:ss
HH:mm
yyyy-MM-dd HH:mm:ss.FFFFFFF
yyyy-MM-dd HH:mm:ss
yyyy-MM-dd HH:mm
yyyy-MM-ddTHH:mm:ss.FFFFFFF
yyyy-MM-ddTHH:mm
yyyy-MM-ddTHH:mm:ss
yyyyMMddHHmmss
yyyyMMddHHmm
yyyyMMddTHHmmssFFFFFFF
yyyy-MM-dd
yyyyMMdd
yy-MM-dd
If the string cannot be matched to one of the above formats -OR- the
DateTimeFormatString if one was provided, an exception will be thrown.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToDateTime Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToDateTime(String, SQLiteDateFormats,
DateTimeKind, String) Method

Converts a string into a DateTime, using the specified DateTimeFormat,


DateTimeKind and DateTimeFormatString.

public static DateTime ToDateTime(


string dateText,
SQLiteDateFormats format,
DateTimeKind kind,
string formatString
);

Parameters
dateText
The string containing either a long integer number of 100-nanosecond
units since System.DateTime.MinValue, a Julian day double, an integer
number of seconds since the Unix epoch, a culture-independent
formatted date and time string, a formatted date and time string in the
current culture, or an ISO8601-format string.
format
The SQLiteDateFormats to use.
kind
The DateTimeKind to use.
formatString
The DateTime format string to use.

Return Value
A DateTime value

Remarks
Acceptable ISO8601 DateTime formats are:
THHmmssK
THHmmK
HH:mm:ss.FFFFFFFK
HH:mm:ssK
HH:mmK
yyyy-MM-dd HH:mm:ss.FFFFFFFK
yyyy-MM-dd HH:mm:ssK
yyyy-MM-dd HH:mmK
yyyy-MM-ddTHH:mm:ss.FFFFFFFK
yyyy-MM-ddTHH:mmK
yyyy-MM-ddTHH:mm:ssK
yyyyMMddHHmmssK
yyyyMMddHHmmK
yyyyMMddTHHmmssFFFFFFFK
THHmmss
THHmm
HH:mm:ss.FFFFFFF
HH:mm:ss
HH:mm
yyyy-MM-dd HH:mm:ss.FFFFFFF
yyyy-MM-dd HH:mm:ss
yyyy-MM-dd HH:mm
yyyy-MM-ddTHH:mm:ss.FFFFFFF
yyyy-MM-ddTHH:mm
yyyy-MM-ddTHH:mm:ss
yyyyMMddHHmmss
yyyyMMddHHmm
yyyyMMddTHHmmssFFFFFFF
yyyy-MM-dd
yyyyMMdd
yy-MM-dd
If the string cannot be matched to one of the above formats -OR- the
DateTimeFormatString if one was provided, an exception will be thrown.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToDateTime Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToJulianDay Method

Converts a DateTime struct to a JulianDay double

public static double ToJulianDay(


DateTime value
);

Parameters
value
The DateTime to convert

Return Value
The JulianDay value the Datetime represents

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToString Method

Converts a string into a DateTime, using the DateTimeFormat,


DateTimeKind, and DateTimeFormatString specified for the connection
when it was opened.

Overload List
Inherited from Object.
public virtual string ToString()
Converts a string into a DateTime, using the DateTimeFormat,
DateTimeKind, and DateTimeFormatString specified for the connection
when it was opened.
public string ToString(DateTime)
Converts a string into a DateTime, using the DateTimeFormat,
DateTimeKind, and DateTimeFormatString specified for the connection
when it was opened.
public static string ToString(DateTime,SQLiteDateFormats,DateTimeKind,str
Converts a UTF-8 encoded IntPtr of the specified length into a .NET string
public virtual string ToString(IntPtr,int)

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToString(DateTime) Method

Converts a string into a DateTime, using the DateTimeFormat,


DateTimeKind, and DateTimeFormatString specified for the connection
when it was opened.

public string ToString(


DateTime dateValue
);

Parameters
dateValue
The DateTime value to convert

Return Value
Either a string containing the long integer number of 100-nanosecond
units since System.DateTime.MinValue, a Julian day double, an integer
number of seconds since the Unix epoch, a culture-independent formatted
date and time string, a formatted date and time string in the current
culture, or an ISO8601-format date/time string.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToString Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToString(DateTime, SQLiteDateFormats,
DateTimeKind, String) Method

Converts a string into a DateTime, using the DateTimeFormat,


DateTimeKind, and DateTimeFormatString specified for the connection
when it was opened.

public static string ToString(


DateTime dateValue,
SQLiteDateFormats format,
DateTimeKind kind,
string formatString
);

Parameters
dateValue
The DateTime value to convert
format
The SQLiteDateFormats to use.
kind
The DateTimeKind to use.
formatString
The DateTime format string to use.

Return Value
Either a string containing the long integer number of 100-nanosecond
units since System.DateTime.MinValue, a Julian day double, an integer
number of seconds since the Unix epoch, a culture-independent formatted
date and time string, a formatted date and time string in the current
culture, or an ISO8601-format date/time string.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToString Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToString(IntPtr, Int32) Method

Converts a UTF-8 encoded IntPtr of the specified length into a .NET string

public virtual string ToString(


IntPtr nativestring,
int nativestringlen
);

Parameters
nativestring
The pointer to the memory where the UTF-8 string is encoded
nativestringlen
The number of bytes to decode

Return Value
A string containing the translated character(s)

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToString Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToStringWithProvider Method

Queries and returns the string representation for an object, using the
specified (or current) format provider.

public static string ToStringWithProvider(


object obj,
IFormatProvider provider
);

Parameters
obj
The object instance to return the string representation for.
provider
The format provider to use -OR- null if the current format provider for
the thread should be used instead.

Return Value
The string representation for the object instance -OR- null if the object
instance is also null.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToUnixEpoch Method

Converts a DateTime struct to the whole number of seconds since the Unix
epoch.

public static long ToUnixEpoch(


DateTime value
);

Parameters
value
The DateTime to convert

Return Value
The whole number of seconds since the Unix epoch

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToUTF8 Method

Convert a DateTime to a UTF-8 encoded, zero-terminated byte array.

Overload List
Convert a DateTime to a UTF-8 encoded, zero-terminated byte array.
public byte[] ToUTF8(DateTime)
Converts a string to a UTF-8 encoded byte array sized to include a null-
terminating character.
public static byte[] ToUTF8(string)

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToUTF8(DateTime) Method

Convert a DateTime to a UTF-8 encoded, zero-terminated byte array.

public byte[] ToUTF8(


DateTime dateTimeValue
);

Parameters
dateTimeValue
The DateTime to convert.

Return Value
The UTF-8 encoded string, including a 0 terminating byte at the end of the
array.

Remarks
This function is a convenience function, which first calls ToString() on the
DateTime, and then calls ToUTF8() with the string result.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToUTF8 Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.ToUTF8(String) Method

Converts a string to a UTF-8 encoded byte array sized to include a null-


terminating character.

public static byte[] ToUTF8(


string sourceText
);

Parameters
sourceText
The string to convert to UTF-8

Return Value
A byte array containing the converted string plus an extra 0 terminating
byte at the end of the array.

See Also
SQLiteConvert Class | System.Data.SQLite Namespace |
SQLiteConvert.ToUTF8 Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteConvert.UTF8ToString Method

Converts a UTF-8 encoded IntPtr of the specified length into a .NET string

public static string UTF8ToString(


IntPtr nativestring,
int nativestringlen
);

Parameters
nativestring
The pointer to the memory where the UTF-8 string is encoded
nativestringlen
The number of bytes to decode

Return Value
A string containing the translated character(s)

See Also
SQLiteConvert Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Class

SQLite implementation of DbDataAdapter.


For a list of all members of this type, see SQLiteDataAdapter Members .
System.Object MarshalByRefObject
Component
DataAdapter
DbDataAdapter
SQLiteDataAdapter

public sealed class SQLiteDataAdapter : DbDataAdapter

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteDataAdapter Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Members

SQLiteDataAdapter overview

Public Instance Constructors


SQLiteDataAdapter Overloaded. This class is just a
shell around the DbDataAdapter.
Nothing from DbDataAdapter is
overridden here, just a few
constructors are defined.

Public Instance Properties


AcceptChangesDuringFill Gets or sets a value indicating
(inherited from DataAdapter) whether AcceptChanges is called on
a DataRow after it is added to the
DataTable during any of the Fill
operations.
AcceptChangesDuringUpdate Gets or sets whether
(inherited from DataAdapter) AcceptChanges is called during a
Update.
Container (inherited from Gets the IContainer that contains
Component) the Component.
ContinueUpdateOnError Gets or sets a value that specifies
(inherited from DataAdapter) whether to generate an exception
when an error is encountered
during a row update.
DeleteCommand Overloaded. Gets/sets the delete
command for this DataAdapter
FillLoadOption (inherited from Gets or sets the LoadOption that
DataAdapter) determines how the adapter fills
the DataTable from the
DbDataReader.
InsertCommand Overloaded. Gets/sets the insert
command for this DataAdapter
MissingMappingAction (inherited Determines the action to take when
from DataAdapter) incoming data does not have a
matching table or column.
MissingSchemaAction (inherited Determines the action to take when
from DataAdapter) existing DataSet schema does not
match incoming data.
ReturnProviderSpecificTypes Gets or sets whether the Fill
(inherited from DataAdapter) method should return provider-
specific values or common CLS-
compliant values.
SelectCommand Overloaded. Gets/sets the select
command for this DataAdapter
Site (inherited from Component) Gets or sets the ISite of the
Component.
TableMappings (inherited from Gets a collection that provides the
DataAdapter) master mapping between a source
table and a DataTable.
UpdateBatchSize (inherited from Gets or sets a value that enables or
DbDataAdapter) disables batch processing support,
and specifies the number of
commands that can be executed in
a batch.
UpdateCommand Overloaded. Gets/sets the update
command for this DataAdapter

Public Instance Methods


CreateObjRef (inherited from Creates an object that contains
MarshalByRefObject) all the relevant information
required to generate a proxy
used to communicate with a
remote object.
Dispose (inherited from Component) Overloaded. Releases all
resources used by the
Component.
Equals (inherited from Object) Determines whether the
specified Object is equal to the
current Object.
Fill (inherited from DbDataAdapter) Overloaded. Adds or refreshes
rows in the DataSet to match
those in the data source using
the DataSet and DataTable
names.
FillSchema (inherited from Overloaded. Configures the
DbDataAdapter) schema of the specified
DataTable based on the
specified SchemaType.
GetFillParameters (inherited from Gets the parameters set by the
DbDataAdapter) user when executing an SQL
SELECT statement.
GetHashCode (inherited from Object) Serves as a hash function for a
particular type. GetHashCode
is suitable for use in hashing
algorithms and data structures
like a hash table.
GetLifetimeService (inherited from Retrieves the current lifetime
MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService (inherited Obtains a lifetime service
from MarshalByRefObject) object to control the lifetime
policy for this instance.
ResetFillLoadOption (inherited from Resets FillLoadOption to its
DataAdapter) default state and causes Fill to
honor
AcceptChangesDuringFill.
Determines whether the
ShouldSerializeAcceptChangesDuringFill AcceptChangesDuringFill
(inherited from DataAdapter) property should be persisted.
ShouldSerializeFillLoadOption Determines whether the
(inherited from DataAdapter) FillLoadOption property should
be persisted.
ToString (inherited from Component) Returns a String containing the
name of the Component, if any.
This method should not be
overridden.
Update (inherited from Overloaded. Calls the
DbDataAdapter) respective INSERT, UPDATE, or
DELETE statements for each
inserted, updated, or deleted
row in the specified DataSet.

Public Instance Events


Disposed (inherited from Occurs when the component is
Component) disposed by a call to the Dispose
method.
FillError (inherited from Returned when an error occurs
DataAdapter) during a fill operation.
RowUpdated Row updated event handler
RowUpdating Row updating event handler

Protected Instance Properties


CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.
FillCommandBehavior (inherited Gets or sets the behavior of the
from DbDataAdapter) command used to fill the data
adapter.

Protected Instance Methods


AddToBatch (inherited from Adds a IDbCommand to the current
DbDataAdapter) batch.
ClearBatch (inherited from Removes all IDbCommand objects
DbDataAdapter) from the batch.
CloneInternals (inherited from Obsolete. Creates a copy of this
DataAdapter) instance of DataAdapter.
CreateRowUpdatedEvent Initializes a new instance of the
(inherited from DbDataAdapter) RowUpdatedEventArgs class.
CreateRowUpdatingEvent Initializes a new instance of the
(inherited from DbDataAdapter) RowUpdatingEventArgs class.
CreateTableMappings (inherited Creates a new
from DataAdapter) DataTableMappingCollection.
Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
ExecuteBatch (inherited from Executes the current batch.
DbDataAdapter)
Fill (inherited from Overloaded. Adds or refreshes rows
DbDataAdapter) in a DataTable to match those in
the data source using the specified
DataTable, IDbCommand and
CommandBehavior.
Fill (inherited from Overloaded. Adds or refreshes rows
DataAdapter) in a specified range in the DataSet
to match those in the data source
using the DataSet and DataTable
names.
FillSchema (inherited from Overloaded. Adds a DataTable to
DbDataAdapter) the specified DataSet and
configures the schema to match
that in the data source based on
the specified SchemaType.
FillSchema (inherited from Overloaded. Adds a DataTable to
DataAdapter) the specified DataSet.
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetBatchedParameter (inherited Returns a IDataParameter from one
from DbDataAdapter) of the commands in the current
batch.
GetBatchedRecordsAffected Returns information about an
(inherited from DbDataAdapter) individual update attempt within a
larger batched update.
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
HasTableMappings (inherited from Indicates whether a
DataAdapter) DataTableMappingCollection has
been created.
InitializeBatching (inherited from Initializes batching for the
DbDataAdapter) DbDataAdapter.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
OnFillError (inherited from Invoked when an error occurs
DataAdapter) during a Fill.
OnRowUpdated Raised by DbDataAdapter after a
row is updated
OnRowUpdating Raised by the underlying
DbDataAdapter when a row is being
updated
ShouldSerializeTableMappings Determines whether one or more
(inherited from DataAdapter) DataTableMapping objects exist and
they should be persisted.
TerminateBatching (inherited Ends batching for the
from DbDataAdapter) DbDataAdapter.
Update (inherited from Overloaded. Calls the respective
DbDataAdapter) INSERT, UPDATE, or DELETE
statements for each inserted,
updated, or deleted row in the
specified array of DataRow objects.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Constructor

This class is just a shell around the DbDataAdapter. Nothing from


DbDataAdapter is overridden here, just a few constructors are defined.

Overload List
Default constructor.
public SQLiteDataAdapter()
Constructs a data adapter using the specified select command.
public SQLiteDataAdapter(SQLiteCommand)
Constructs a data adapter with the supplied select command text and
associated with the specified connection.
public SQLiteDataAdapter(string,SQLiteConnection)
Constructs a data adapter with the specified select command text, and
using the specified database connection string.
public SQLiteDataAdapter(string,string)
Constructs a data adapter with the specified select command text, and
using the specified database connection string.
public SQLiteDataAdapter(string,string,bool)

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Constructor

Default constructor.

SQLiteDataAdapter();

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace |
SQLiteDataAdapter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Constructor

Constructs a data adapter using the specified select command.

SQLiteDataAdapter(
SQLiteCommand cmd
);

Parameters
cmd
The select command to associate with the adapter.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace |
SQLiteDataAdapter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Constructor

Constructs a data adapter with the supplied select command text and
associated with the specified connection.

SQLiteDataAdapter(
string commandText,
SQLiteConnection connection
);

Parameters
commandText
The select command text to associate with the data adapter.
connection
The connection to associate with the select command.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace |
SQLiteDataAdapter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Constructor

Constructs a data adapter with the specified select command text, and
using the specified database connection string.

SQLiteDataAdapter(
string commandText,
string connectionString
);

Parameters
commandText
The select command text to use to construct a select command.
connectionString
A connection string suitable for passing to a new SQLiteConnection,
which is associated with the select command.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace |
SQLiteDataAdapter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Constructor

Constructs a data adapter with the specified select command text, and
using the specified database connection string.

SQLiteDataAdapter(
string commandText,
string connectionString,
bool parseViaFramework
);

Parameters
commandText
The select command text to use to construct a select command.
connectionString
A connection string suitable for passing to a new SQLiteConnection,
which is associated with the select command.
parseViaFramework
Non-zero to parse the connection string using the built-in (i.e.
framework provided) parser when opening the connection.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace |
SQLiteDataAdapter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Properties

The properties of the SQLiteDataAdapter class are listed below. For a


complete list of SQLiteDataAdapter class members, see the
SQLiteDataAdapter Members topic.

Public Instance Properties


AcceptChangesDuringFill Gets or sets a value indicating
(inherited from DataAdapter) whether AcceptChanges is called on
a DataRow after it is added to the
DataTable during any of the Fill
operations.
AcceptChangesDuringUpdate Gets or sets whether
(inherited from DataAdapter) AcceptChanges is called during a
Update.
Container (inherited from Gets the IContainer that contains
Component) the Component.
ContinueUpdateOnError Gets or sets a value that specifies
(inherited from DataAdapter) whether to generate an exception
when an error is encountered
during a row update.
DeleteCommand Overloaded. Gets/sets the delete
command for this DataAdapter
FillLoadOption (inherited from Gets or sets the LoadOption that
DataAdapter) determines how the adapter fills
the DataTable from the
DbDataReader.
InsertCommand Overloaded. Gets/sets the insert
command for this DataAdapter
MissingMappingAction (inherited Determines the action to take when
from DataAdapter) incoming data does not have a
matching table or column.
MissingSchemaAction (inherited Determines the action to take when
from DataAdapter) existing DataSet schema does not
match incoming data.
ReturnProviderSpecificTypes Gets or sets whether the Fill
(inherited from DataAdapter) method should return provider-
specific values or common CLS-
compliant values.
SelectCommand Overloaded. Gets/sets the select
command for this DataAdapter
Site (inherited from Component) Gets or sets the ISite of the
Component.
TableMappings (inherited from Gets a collection that provides the
DataAdapter) master mapping between a source
table and a DataTable.
UpdateBatchSize (inherited from Gets or sets a value that enables or
DbDataAdapter) disables batch processing support,
and specifies the number of
commands that can be executed in
a batch.
UpdateCommand Overloaded. Gets/sets the update
command for this DataAdapter

Protected Instance Properties


CanRaiseEvents (inherited from Gets a value indicating whether the
Component) component can raise an event.
DesignMode (inherited from Gets a value that indicates whether
Component) the Component is currently in
design mode.
Events (inherited from Gets the list of event handlers that
Component) are attached to this Component.
FillCommandBehavior (inherited Gets or sets the behavior of the
from DbDataAdapter) command used to fill the data
adapter.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.DeleteCommand Property

Gets/sets the delete command for this DataAdapter

new public SQLiteCommand DeleteCommand { public get; pub

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.InsertCommand Property

Gets/sets the insert command for this DataAdapter

new public SQLiteCommand InsertCommand { public get; pub

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.SelectCommand Property

Gets/sets the select command for this DataAdapter

new public SQLiteCommand SelectCommand { public get; pub

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.UpdateCommand Property

Gets/sets the update command for this DataAdapter

new public SQLiteCommand UpdateCommand { public get; pub

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Methods

The methods of the SQLiteDataAdapter class are listed below. For a


complete list of SQLiteDataAdapter class members, see the
SQLiteDataAdapter Members topic.

Public Instance Methods


CreateObjRef (inherited from Creates an object that contains
MarshalByRefObject) all the relevant information
required to generate a proxy
used to communicate with a
remote object.
Dispose (inherited from Component) Overloaded. Releases all
resources used by the
Component.
Equals (inherited from Object) Determines whether the
specified Object is equal to the
current Object.
Fill (inherited from DbDataAdapter) Overloaded. Adds or refreshes
rows in the DataSet to match
those in the data source using
the DataSet and DataTable
names.
FillSchema (inherited from Overloaded. Configures the
DbDataAdapter) schema of the specified
DataTable based on the
specified SchemaType.
GetFillParameters (inherited from Gets the parameters set by the
DbDataAdapter) user when executing an SQL
SELECT statement.
GetHashCode (inherited from Object) Serves as a hash function for a
particular type. GetHashCode
is suitable for use in hashing
algorithms and data structures
like a hash table.
GetLifetimeService (inherited from Retrieves the current lifetime
MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService (inherited Obtains a lifetime service
from MarshalByRefObject) object to control the lifetime
policy for this instance.
ResetFillLoadOption (inherited from Resets FillLoadOption to its
DataAdapter) default state and causes Fill to
honor
AcceptChangesDuringFill.
Determines whether the
ShouldSerializeAcceptChangesDuringFill AcceptChangesDuringFill
(inherited from DataAdapter) property should be persisted.
ShouldSerializeFillLoadOption Determines whether the
(inherited from DataAdapter) FillLoadOption property should
be persisted.
ToString (inherited from Component) Returns a String containing the
name of the Component, if any.
This method should not be
overridden.
Update (inherited from Overloaded. Calls the
DbDataAdapter) respective INSERT, UPDATE, or
DELETE statements for each
inserted, updated, or deleted
row in the specified DataSet.

Protected Instance Methods


AddToBatch (inherited from Adds a IDbCommand to the current
DbDataAdapter) batch.
ClearBatch (inherited from Removes all IDbCommand objects
DbDataAdapter) from the batch.
CloneInternals (inherited from Obsolete. Creates a copy of this
DataAdapter) instance of DataAdapter.
CreateRowUpdatedEvent Initializes a new instance of the
(inherited from DbDataAdapter) RowUpdatedEventArgs class.
CreateRowUpdatingEvent Initializes a new instance of the
(inherited from DbDataAdapter) RowUpdatingEventArgs class.
CreateTableMappings (inherited Creates a new
from DataAdapter) DataTableMappingCollection.
Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
ExecuteBatch (inherited from Executes the current batch.
DbDataAdapter)
Fill (inherited from Overloaded. Adds or refreshes rows
DbDataAdapter) in a DataTable to match those in
the data source using the specified
DataTable, IDbCommand and
CommandBehavior.
Fill (inherited from Overloaded. Adds or refreshes rows
DataAdapter) in a specified range in the DataSet
to match those in the data source
using the DataSet and DataTable
names.
FillSchema (inherited from Overloaded. Adds a DataTable to
DbDataAdapter) the specified DataSet and
configures the schema to match
that in the data source based on
the specified SchemaType.
FillSchema (inherited from Overloaded. Adds a DataTable to
DataAdapter) the specified DataSet.
Finalize (inherited from Releases unmanaged resources and
Component) performs other cleanup operations
before the Component is reclaimed
by garbage collection.
GetBatchedParameter (inherited Returns a IDataParameter from one
from DbDataAdapter) of the commands in the current
batch.
GetBatchedRecordsAffected Returns information about an
(inherited from DbDataAdapter) individual update attempt within a
larger batched update.
GetService (inherited from Returns an object that represents a
Component) service provided by the Component
or by its Container.
HasTableMappings (inherited from Indicates whether a
DataAdapter) DataTableMappingCollection has
been created.

InitializeBatching (inherited from Initializes batching for the


DbDataAdapter) DbDataAdapter.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
OnFillError (inherited from Invoked when an error occurs
DataAdapter) during a Fill.
OnRowUpdated Raised by DbDataAdapter after a
row is updated
OnRowUpdating Raised by the underlying
DbDataAdapter when a row is being
updated
ShouldSerializeTableMappings Determines whether one or more
(inherited from DataAdapter) DataTableMapping objects exist and
they should be persisted.
TerminateBatching (inherited Ends batching for the
from DbDataAdapter) DbDataAdapter.
Update (inherited from Overloaded. Calls the respective
DbDataAdapter) INSERT, UPDATE, or DELETE
statements for each inserted,
updated, or deleted row in the
specified array of DataRow objects.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.Dispose Method

Cleans up resources (native and managed) associated with the current


instance.

Overload List
Inherited from Component.
public void Dispose()
Cleans up resources (native and managed) associated with the current
instance.
protected override void Dispose(bool)

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.Dispose(Boolean) Method

Cleans up resources (native and managed) associated with the current


instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Zero when being disposed via garbage collection; otherwise, non-zero.

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace |
SQLiteDataAdapter.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.OnRowUpdated Method

Raised by DbDataAdapter after a row is updated

protected override void OnRowUpdated(


RowUpdatedEventArgs value
);

Parameters
value
The event's specifics

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.OnRowUpdating Method

Raised by the underlying DbDataAdapter when a row is being updated

protected override void OnRowUpdating(


RowUpdatingEventArgs value
);

Parameters
value
The event's specifics

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter Events

The events of the SQLiteDataAdapter class are listed below. For a


complete list of SQLiteDataAdapter class members, see the
SQLiteDataAdapter Members topic.

Public Instance Events


Disposed (inherited from Occurs when the component is
Component) disposed by a call to the Dispose
method.
FillError (inherited from Returned when an error occurs
DataAdapter) during a fill operation.
RowUpdated Row updated event handler
RowUpdating Row updating event handler

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.RowUpdated Event

Row updated event handler

public event EventHandler<RowUpdatedEventArgs> RowUpdate

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataAdapter.RowUpdating Event

Row updating event handler

public event EventHandler<RowUpdatingEventArgs> RowUpdat

See Also
SQLiteDataAdapter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader Class

SQLite implementation of DbDataReader.


For a list of all members of this type, see SQLiteDataReader Members .
System.Object MarshalByRefObject
DbDataReader
SQLiteDataReader

public sealed class SQLiteDataReader : DbDataReader

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteDataReader Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader Members

SQLiteDataReader overview

Public Instance Properties


Depth Not implemented. Returns 0
FieldCount Returns the number of columns in
the current resultset
HasRows Returns True if the resultset has
rows that can be fetched
IsClosed Returns True if the data reader is
closed
Item Overloaded. Indexer to retrieve
data from a column given its name
RecordsAffected Returns the number of rows
affected by the statement being
executed. The value returned may
not be accurate for DDL
statements. Also, it will be -1 for
any statement that does not modify
the database (e.g. SELECT). If an
otherwise read-only statement
modifies the database indirectly
(e.g. via a virtual table or user-
defined function), the value
returned is undefined.
StepCount Returns the number of rows seen
so far in the current result set.
VisibleFieldCount Returns the number of visible fields
in the current resultset

Public Instance Methods


Close Closes the datareader, potentially
closing the connection as well if
CommandBehavior.CloseConnection
was specified.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases all resources
DbDataReader) used by the current instance of the
DbDataReader class.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetBlob Retrieves the column as a
SQLiteBlob object. This will not
work for tables that were created
WITHOUT ROWID -OR- if the query
does not include the "rowid"
column or one of its aliases -OR- if
the SQLiteDataReader was not
created with the KeyInfo flag.
GetBoolean Retrieves the column as a boolean
value
GetByte Retrieves the column as a single
byte value
GetBytes Retrieves a column as an array of
bytes (blob)
GetChar Returns the column as a single
character
GetChars Retrieves a column as an array of
chars (blob)
GetData (inherited from Returns a DbDataReader object for
DbDataReader) the requested column ordinal.
GetDatabaseName Returns the name of the database
associated with the specified
column.
GetDataTypeName Retrieves the name of the back-end
datatype of the column
GetDateTime Retrieve the column as a date/time
value
GetDecimal Retrieve the column as a decimal
value

GetDouble Returns the column as a double


GetEnumerator Enumerator support
GetFieldType Returns the .NET type of a given
column
GetFloat Returns a column as a float value
GetGuid Returns the column as a Guid
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetInt16 Returns the column as a short
GetInt32 Retrieves the column as an int
GetInt64 Retrieves the column as a long
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetName Retrieves the name of the column
GetOrdinal Retrieves the i of a column, given
its name
GetOriginalName Returns the original name of the
specified column.
GetProviderSpecificFieldType Returns the provider-specific field
(inherited from DbDataReader) type of the specified column.
GetProviderSpecificValue Gets the value of the specified
(inherited from DbDataReader) column as an instance of Object.
GetProviderSpecificValues Gets all provider-specific attribute
(inherited from DbDataReader) columns in the collection for the
current row.
GetSchemaTable Schema information in SQLite is
difficult to map into .NET
conventions, so a lot of work must
be done to gather the necessary
information so it can be
represented in an ADO.NET
manner.
GetString Retrieves the column as a string
GetTableName Returns the name of the table
associated with the specified
column.
GetType (inherited from Object) Gets the Type of the current
instance.
GetValue Retrieves the column as an object
corresponding to the underlying
datatype of the column
GetValues Overloaded. Retreives the values of
multiple columns, up to the size of
the supplied array
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
IsDBNull Returns True if the specified column
is null
NextResult Moves to the next resultset in
multiple row-returning SQL
command.
Read Reads the next row from the
resultset
RefreshFlags Forces the connection flags cached
by this data reader to be refreshed
from the underlying connection.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Dispose of all
resources used by this datareader.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
GetDbDataReader (inherited from Returns a DbDataReader object for
DbDataReader) the requested column ordinal that
can be overridden with a provider-
specific implementation.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader Properties

The properties of the SQLiteDataReader class are listed below. For a


complete list of SQLiteDataReader class members, see the
SQLiteDataReader Members topic.

Public Instance Properties


Depth Not implemented. Returns 0
FieldCount Returns the number of columns in
the current resultset
HasRows Returns True if the resultset has
rows that can be fetched
IsClosed Returns True if the data reader is
closed
Item Overloaded. Indexer to retrieve
data from a column given its name
RecordsAffected Returns the number of rows
affected by the statement being
executed. The value returned may
not be accurate for DDL
statements. Also, it will be -1 for
any statement that does not modify
the database (e.g. SELECT). If an
otherwise read-only statement
modifies the database indirectly
(e.g. via a virtual table or user-
defined function), the value
returned is undefined.
StepCount Returns the number of rows seen
so far in the current result set.
VisibleFieldCount Returns the number of visible fields
in the current resultset

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Depth Property

Not implemented. Returns 0

public override int Depth { public get; }

Implements
IDataReader.Depth

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.FieldCount Property

Returns the number of columns in the current resultset

public override int FieldCount { public get; }

Implements
IDataRecord.FieldCount

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.HasRows Property

Returns True if the resultset has rows that can be fetched

public override bool HasRows { public get; }

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.IsClosed Property

Returns True if the data reader is closed

public override bool IsClosed { public get; }

Implements
IDataReader.IsClosed

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Object Property

Indexer to retrieve data from a column given its i

Overload List
Indexer to retrieve data from a column given its i
public override object this[int] { public get; }
Indexer to retrieve data from a column given its name
public override object this[string] { public get; }

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Item Property

Indexer to retrieve data from a column given its i

public override object this[


int i
] { public get; }

Parameters
i
The index of the column.

Implements
IDataRecord.Item

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace |
SQLiteDataReader.Item Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Item Property

Indexer to retrieve data from a column given its name

public override object this[


string name
] { public get; }

Parameters
name
The name of the column to retrieve data for

Implements
IDataRecord.Item

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace |
SQLiteDataReader.Item Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.RecordsAffected Property

Returns the number of rows affected by the statement being executed. The
value returned may not be accurate for DDL statements. Also, it will be -1
for any statement that does not modify the database (e.g. SELECT). If an
otherwise read-only statement modifies the database indirectly (e.g. via a
virtual table or user-defined function), the value returned is undefined.

public override int RecordsAffected { public get; }

Implements
IDataReader.RecordsAffected

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.StepCount Property

Returns the number of rows seen so far in the current result set.

public int StepCount { public get; }

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.VisibleFieldCount Property

Returns the number of visible fields in the current resultset

public override int VisibleFieldCount { public get; }

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader Methods

The methods of the SQLiteDataReader class are listed below. For a


complete list of SQLiteDataReader class members, see the
SQLiteDataReader Members topic.

Public Instance Methods


Close Closes the datareader, potentially
closing the connection as well if
CommandBehavior.CloseConnection
was specified.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases all resources
DbDataReader) used by the current instance of the
DbDataReader class.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetBlob Retrieves the column as a
SQLiteBlob object. This will not
work for tables that were created
WITHOUT ROWID -OR- if the query
does not include the "rowid"
column or one of its aliases -OR- if
the SQLiteDataReader was not
created with the KeyInfo flag.
GetBoolean Retrieves the column as a boolean
value
GetByte Retrieves the column as a single
byte value
GetBytes Retrieves a column as an array of
bytes (blob)
GetChar Returns the column as a single
character
GetChars Retrieves a column as an array of
chars (blob)
GetData (inherited from Returns a DbDataReader object for
DbDataReader) the requested column ordinal.
GetDatabaseName Returns the name of the database
associated with the specified
column.
GetDataTypeName Retrieves the name of the back-end
datatype of the column
GetDateTime Retrieve the column as a date/time
value
GetDecimal Retrieve the column as a decimal
value
GetDouble Returns the column as a double
GetEnumerator Enumerator support
GetFieldType Returns the .NET type of a given
column
GetFloat Returns a column as a float value
GetGuid Returns the column as a Guid
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetInt16 Returns the column as a short
GetInt32 Retrieves the column as an int
GetInt64 Retrieves the column as a long
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetName Retrieves the name of the column
GetOrdinal Retrieves the i of a column, given
its name
GetOriginalName Returns the original name of the
specified column.

GetProviderSpecificFieldType Returns the provider-specific field


(inherited from DbDataReader) type of the specified column.
GetProviderSpecificValue Gets the value of the specified
(inherited from DbDataReader) column as an instance of Object.
GetProviderSpecificValues Gets all provider-specific attribute
(inherited from DbDataReader) columns in the collection for the
current row.
GetSchemaTable Schema information in SQLite is
difficult to map into .NET
conventions, so a lot of work must
be done to gather the necessary
information so it can be
represented in an ADO.NET
manner.
GetString Retrieves the column as a string
GetTableName Returns the name of the table
associated with the specified
column.
GetType (inherited from Object) Gets the Type of the current
instance.
GetValue Retrieves the column as an object
corresponding to the underlying
datatype of the column
GetValues Overloaded. Retreives the values of
multiple columns, up to the size of
the supplied array
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
IsDBNull Returns True if the specified column
is null
NextResult Moves to the next resultset in
multiple row-returning SQL
command.
Read Reads the next row from the
resultset

RefreshFlags Forces the connection flags cached


by this data reader to be refreshed
from the underlying connection.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Dispose of all
resources used by this datareader.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
GetDbDataReader (inherited from Returns a DbDataReader object for
DbDataReader) the requested column ordinal that
can be overridden with a provider-
specific implementation.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Close Method

Closes the datareader, potentially closing the connection as well if


CommandBehavior.CloseConnection was specified.

public override void Close();

Implements
IDataReader.Close

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Dispose Method

Dispose of all resources used by this datareader.

Overload List
Inherited from DbDataReader.
public void Dispose()
Dispose of all resources used by this datareader.
protected override void Dispose(bool)

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Dispose(Boolean) Method

Dispose of all resources used by this datareader.

protected override void Dispose(


bool disposing
);

Parameters
disposing

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace |
SQLiteDataReader.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetBlob Method

Retrieves the column as a SQLiteBlob object. This will not work for tables
that were created WITHOUT ROWID -OR- if the query does not include the
"rowid" column or one of its aliases -OR- if the SQLiteDataReader was not
created with the KeyInfo flag.

public SQLiteBlob GetBlob(


int i,
bool readOnly
);

Parameters
i
The index of the column.
readOnly
Non-zero to open the blob object for read-only access.

Return Value
A new SQLiteBlob object.

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetBoolean Method

Retrieves the column as a boolean value

public override bool GetBoolean(


int i
);

Parameters
i
The index of the column.

Return Value
bool

Implements
IDataRecord.GetBoolean

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetByte Method

Retrieves the column as a single byte value

public override byte GetByte(


int i
);

Parameters
i
The index of the column.

Return Value
byte

Implements
IDataRecord.GetByte

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetBytes Method

Retrieves a column as an array of bytes (blob)

public override long GetBytes(


int i,
long fieldOffset,
byte[] buffer,
int bufferoffset,
int length
);

Parameters
i
The index of the column.
fieldOffset
The zero-based index of where to begin reading the data
buffer
The buffer to write the bytes into
bufferoffset
The zero-based index of where to begin writing into the array
length
The number of bytes to retrieve

Return Value
The actual number of bytes written into the array

Implements
IDataRecord.GetBytes

Remarks
To determine the number of bytes in the column, pass a null value for the
buffer. The total length will be returned.

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetChar Method

Returns the column as a single character

public override char GetChar(


int i
);

Parameters
i
The index of the column.

Return Value
char

Implements
IDataRecord.GetChar

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetChars Method

Retrieves a column as an array of chars (blob)

public override long GetChars(


int i,
long fieldoffset,
char[] buffer,
int bufferoffset,
int length
);

Parameters
i
The index of the column.
fieldoffset
The zero-based index of where to begin reading the data
buffer
The buffer to write the characters into
bufferoffset
The zero-based index of where to begin writing into the array
length
The number of bytes to retrieve

Return Value
The actual number of characters written into the array

Implements
IDataRecord.GetChars

Remarks
To determine the number of characters in the column, pass a null value for
the buffer. The total length will be returned.

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetDatabaseName Method

Returns the name of the database associated with the specified column.

public string GetDatabaseName(


int i
);

Parameters
i
The index of the column.

Return Value
string

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetDataTypeName Method

Retrieves the name of the back-end datatype of the column

public override string GetDataTypeName(


int i
);

Parameters
i
The index of the column.

Return Value
string

Implements
IDataRecord.GetDataTypeName

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetDateTime Method

Retrieve the column as a date/time value

public override DateTime GetDateTime(


int i
);

Parameters
i
The index of the column.

Return Value
DateTime

Implements
IDataRecord.GetDateTime

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetDecimal Method

Retrieve the column as a decimal value

public override decimal GetDecimal(


int i
);

Parameters
i
The index of the column.

Return Value
decimal

Implements
IDataRecord.GetDecimal

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetDouble Method

Returns the column as a double

public override double GetDouble(


int i
);

Parameters
i
The index of the column.

Return Value
double

Implements
IDataRecord.GetDouble

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetEnumerator Method

Enumerator support

public override IEnumerator GetEnumerator();

Return Value
Returns a DbEnumerator object.

Implements
IEnumerable.GetEnumerator

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetFieldType Method

Returns the .NET type of a given column

public override Type GetFieldType(


int i
);

Parameters
i
The index of the column.

Return Value
Type

Implements
IDataRecord.GetFieldType

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetFloat Method

Returns a column as a float value

public override float GetFloat(


int i
);

Parameters
i
The index of the column.

Return Value
float

Implements
IDataRecord.GetFloat

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetGuid Method

Returns the column as a Guid

public override Guid GetGuid(


int i
);

Parameters
i
The index of the column.

Return Value
Guid

Implements
IDataRecord.GetGuid

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetInt16 Method

Returns the column as a short

public override short GetInt16(


int i
);

Parameters
i
The index of the column.

Return Value
Int16

Implements
IDataRecord.GetInt16

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetInt32 Method

Retrieves the column as an int

public override int GetInt32(


int i
);

Parameters
i
The index of the column.

Return Value
Int32

Implements
IDataRecord.GetInt32

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetInt64 Method

Retrieves the column as a long

public override long GetInt64(


int i
);

Parameters
i
The index of the column.

Return Value
Int64

Implements
IDataRecord.GetInt64

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetName Method

Retrieves the name of the column

public override string GetName(


int i
);

Parameters
i
The index of the column.

Return Value
string

Implements
IDataRecord.GetName

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetOrdinal Method

Retrieves the i of a column, given its name

public override int GetOrdinal(


string name
);

Parameters
name
The name of the column to retrieve

Return Value
The int i of the column

Implements
IDataRecord.GetOrdinal

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetOriginalName Method

Returns the original name of the specified column.

public string GetOriginalName(


int i
);

Parameters
i
The index of the column.

Return Value
string

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetSchemaTable Method

Schema information in SQLite is difficult to map into .NET conventions, so


a lot of work must be done to gather the necessary information so it can
be represented in an ADO.NET manner.

public override DataTable GetSchemaTable();

Return Value
Returns a DataTable containing the schema information for the active
SELECT statement being processed.

Implements
IDataReader.GetSchemaTable

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetString Method

Retrieves the column as a string

public override string GetString(


int i
);

Parameters
i
The index of the column.

Return Value
string

Implements
IDataRecord.GetString

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetTableName Method

Returns the name of the table associated with the specified column.

public string GetTableName(


int i
);

Parameters
i
The index of the column.

Return Value
string

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetValue Method

Retrieves the column as an object corresponding to the underlying


datatype of the column

public override object GetValue(


int i
);

Parameters
i
The index of the column.

Return Value
object

Implements
IDataRecord.GetValue

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetValues Method

Returns a collection containing all the column names and values for the
current row of data in the current resultset, if any. If there is no current
row or no current resultset, an exception may be thrown.

Overload List
Returns a collection containing all the column names and values for the
current row of data in the current resultset, if any. If there is no current
row or no current resultset, an exception may be thrown.
public NameValueCollection GetValues()
Retreives the values of multiple columns, up to the size of the supplied
array
public override int GetValues(object[])

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetValues() Method

Returns a collection containing all the column names and values for the
current row of data in the current resultset, if any. If there is no current
row or no current resultset, an exception may be thrown.

public NameValueCollection GetValues();

Return Value
The collection containing the column name and value information for the
current row of data in the current resultset or null if this information
cannot be obtained.

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace |
SQLiteDataReader.GetValues Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.GetValues(Object) Method

Retreives the values of multiple columns, up to the size of the supplied


array

public override int GetValues(


object[] values
);

Parameters
values
The array to fill with values from the columns in the current resultset

Return Value
The number of columns retrieved

Implements
IDataRecord.GetValues

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace |
SQLiteDataReader.GetValues Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.IsDBNull Method

Returns True if the specified column is null

public override bool IsDBNull(


int i
);

Parameters
i
The index of the column.

Return Value
True or False

Implements
IDataRecord.IsDBNull

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.NextResult Method

Moves to the next resultset in multiple row-returning SQL command.

public override bool NextResult();

Return Value
True if the command was successful and a new resultset is available, False
otherwise.

Implements
IDataReader.NextResult

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.Read Method

Reads the next row from the resultset

public override bool Read();

Return Value
True if a new row was successfully loaded and is ready for processing

Implements
IDataReader.Read

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReader.RefreshFlags Method

Forces the connection flags cached by this data reader to be refreshed


from the underlying connection.

public void RefreshFlags();

See Also
SQLiteDataReader Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue Class

This class represents a single value to be returned from the


SQLiteDataReader class via its GetBlob, GetBoolean, GetByte, GetBytes,
GetChar, GetChars, GetDateTime, GetDecimal, GetDouble, GetFloat,
GetGuid, GetInt16, GetInt32, GetInt64, GetString, or GetValue method. If
the value of the associated public field of this class is null upon returning
from the callback, the null value will only be used if the return type for the
SQLiteDataReader method called is not a value type. If the value to be
returned from the SQLiteDataReader method is unsuitable (e.g. null with
a value type), an exception will be thrown.
For a list of all members of this type, see SQLiteDataReaderValue Members
.
System.Object SQLiteDataReaderValue

public sealed class SQLiteDataReaderValue

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteDataReaderValue Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue Members

SQLiteDataReaderValue overview

Public Instance Constructors


SQLiteDataReaderValue Initializes a new instance of the
Constructor SQLiteDataReaderValue class.

Public Instance Fields


BlobValue The value to be returned from the
GetBlob method -OR- null to
indicate an error.
BooleanValue The value to be returned from the
GetBoolean method -OR- null to
indicate an error.
BytesValue The value to be returned from the
GetBytes method.
ByteValue The value to be returned from the
GetByte method -OR- null to
indicate an error.
CharsValue The value to be returned from the
GetChars method.
CharValue The value to be returned from the
GetChar method -OR- null to
indicate an error.
DateTimeValue The value to be returned from the
GetDateTime method -OR- null to
indicate an error.
DecimalValue The value to be returned from the
GetDecimal method -OR- null to
indicate an error.
DoubleValue The value to be returned from the
GetDouble method -OR- null to
indicate an error.
FloatValue The value to be returned from the
GetFloat method -OR- null to
indicate an error.
GuidValue The value to be returned from the
GetGuid method -OR- null to
indicate an error.
Int16Value The value to be returned from the
GetInt16 method -OR- null to
indicate an error.
Int32Value The value to be returned from the
GetInt32 method -OR- null to
indicate an error.
Int64Value The value to be returned from the
GetInt64 method -OR- null to
indicate an error.
StringValue The value to be returned from the
GetString method.
Value The value to be returned from the
GetValue method.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue Constructor

Initializes a new instance of the SQLiteDataReaderValue class.

SQLiteDataReaderValue();

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue Fields

The fields of the SQLiteDataReaderValue class are listed below. For a


complete list of SQLiteDataReaderValue class members, see the
SQLiteDataReaderValue Members topic.

Public Instance Fields


BlobValue The value to be returned from the
GetBlob method -OR- null to
indicate an error.
BooleanValue The value to be returned from the
GetBoolean method -OR- null to
indicate an error.
BytesValue The value to be returned from the
GetBytes method.
ByteValue The value to be returned from the
GetByte method -OR- null to
indicate an error.
CharsValue The value to be returned from the
GetChars method.
CharValue The value to be returned from the
GetChar method -OR- null to
indicate an error.
DateTimeValue The value to be returned from the
GetDateTime method -OR- null to
indicate an error.
DecimalValue The value to be returned from the
GetDecimal method -OR- null to
indicate an error.
DoubleValue The value to be returned from the
GetDouble method -OR- null to
indicate an error.
FloatValue The value to be returned from the
GetFloat method -OR- null to
indicate an error.
GuidValue The value to be returned from the
GetGuid method -OR- null to
indicate an error.
Int16Value The value to be returned from the
GetInt16 method -OR- null to
indicate an error.
Int32Value The value to be returned from the
GetInt32 method -OR- null to
indicate an error.
Int64Value The value to be returned from the
GetInt64 method -OR- null to
indicate an error.
StringValue The value to be returned from the
GetString method.
Value The value to be returned from the
GetValue method.

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.BlobValue Field

The value to be returned from the GetBlob method -OR- null to indicate an
error.

public SQLiteBlob BlobValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.BooleanValue Field

The value to be returned from the GetBoolean method -OR- null to


indicate an error.

public bool? BooleanValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.BytesValue Field

The value to be returned from the GetBytes method.

public byte[] BytesValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.ByteValue Field

The value to be returned from the GetByte method -OR- null to indicate
an error.

public byte? ByteValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.CharsValue Field

The value to be returned from the GetChars method.

public char[] CharsValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.CharValue Field

The value to be returned from the GetChar method -OR- null to indicate
an error.

public char? CharValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.DateTimeValue Field

The value to be returned from the GetDateTime method -OR- null to


indicate an error.

public DateTime? DateTimeValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.DecimalValue Field

The value to be returned from the GetDecimal method -OR- null to


indicate an error.

public decimal? DecimalValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.DoubleValue Field

The value to be returned from the GetDouble method -OR- null to indicate
an error.

public double? DoubleValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.FloatValue Field

The value to be returned from the GetFloat method -OR- null to indicate
an error.

public float? FloatValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.GuidValue Field

The value to be returned from the GetGuid method -OR- null to indicate
an error.

public Guid? GuidValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.Int16Value Field

The value to be returned from the GetInt16 method -OR- null to indicate
an error.

public short? Int16Value;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.Int32Value Field

The value to be returned from the GetInt32 method -OR- null to indicate
an error.

public int? Int32Value;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.Int64Value Field

The value to be returned from the GetInt64 method -OR- null to indicate
an error.

public long? Int64Value;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.StringValue Field

The value to be returned from the GetString method.

public string StringValue;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDataReaderValue.Value Field

The value to be returned from the GetValue method.

public object Value;

See Also
SQLiteDataReaderValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDateFormats Enumeration

This implementation of SQLite for ADO.NET can process date/time fields in


databases in one of six formats.

public enum SQLiteDateFormats

Remarks
ISO8601 format is more compatible, readable, fully-processable, but less
accurate as it does not provide time down to fractions of a second.
JulianDay is the numeric format the SQLite uses internally and is arguably
the most compatible with 3rd party tools. It is not readable as text without
post-processing. Ticks less compatible with 3rd party tools that query the
database, and renders the DateTime field unreadable as text without post-
processing. UnixEpoch is more compatible with Unix systems.
InvariantCulture allows the configured format for the invariant culture
format to be used and is human readable. CurrentCulture allows the
configured format for the current culture to be used and is also human
readable. The preferred order of choosing a DateTime format is JulianDay,
ISO8601, and then Ticks. Ticks is mainly present for legacy code support.

Members
Member Name Description
Ticks Use the value of DateTime.Ticks.
This value is not recommended and
is not well supported with LINQ.
ISO8601 Use the ISO-8601 format. Uses the
"yyyy-MM-dd HH:mm:ss.FFFFFFFK"
format for UTC DateTime values
and "yyyy-MM-dd
HH:mm:ss.FFFFFFF" format for
local DateTime values).
JulianDay The interval of time in days and
fractions of a day since January 1,
4713 BC.
UnixEpoch The whole number of seconds since
the Unix epoch (January 1, 1970).
InvariantCulture Any culture-independent string
value that the .NET Framework can
interpret as a valid DateTime.
CurrentCulture Any string value that the .NET
Framework can interpret as a valid
DateTime using the current culture.
Default The default format for this provider.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction Class

This class implements a SQLite function using a Delegate. All the virtual
methods of the SQLiteFunction class are implemented using calls to the
SQLiteInvokeDelegate, SQLiteStepDelegate, SQLiteFinalDelegate, and
SQLiteCompareDelegate strongly typed delegate types or via the
DynamicInvoke method. The arguments are presented in the same order
they appear in the associated SQLiteFunction methods with one
exception: the first argument is the name of the virtual method being
implemented.
For a list of all members of this type, see SQLiteDelegateFunction
Members .
System.Object SQLiteFunction
SQLiteDelegateFunction

public class SQLiteDelegateFunction : SQLiteFunction

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteDelegateFunction Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction Members

SQLiteDelegateFunction overview

Public Instance Constructors


SQLiteDelegateFunction Overloaded. Initializes a new
instance of the
SQLiteDelegateFunction class.

Public Instance Properties


Callback1 The Delegate to be used for all calls
into the Invoke, Step, and Compare
virtual methods needed by the
SQLiteFunction base class.
Callback2 The Delegate to be used for all calls
into the Final virtual methods
needed by the SQLiteFunction base
class.
SQLiteConvert (inherited from Returns a reference to the
SQLiteFunction) underlying connection's
SQLiteConvert class, which can be
used to convert strings and
DateTime's into the current
connection's encoding schema.

Public Instance Methods


Compare This virtual method is part of the
implementation for collating
sequences. See the Compare
method for more details.
Dispose (inherited from Overloaded. Disposes of any active
SQLiteFunction) contextData variables that were not
automatically cleaned up.
Sometimes this can happen if
someone closes the connection
while a DataReader is open.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Final This virtual method is part of the
implementation for aggregate
functions. See the Final method for
more details.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Invoke This virtual method is the
implementation for scalar
functions. See the Invoke method
for more details.
Step This virtual method is part of the
implementation for aggregate
functions. See the Step method for
more details.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose (inherited from Overloaded. Placeholder for a user-
SQLiteFunction) defined disposal routine
Finalize (inherited from Cleans up resources associated with
SQLiteFunction) the current instance.
GetCompareArgs Returns the list of arguments for
the Compare method, as an Array
of Object. The first argument is
always the literal string "Compare".
GetFinalArgs Returns the list of arguments for
the Final method, as an Array of
Object. The first argument is
always the literal string "Final".
GetInvokeArgs Returns the list of arguments for
the Invoke method, as an Array of
Object. The first argument is
always the literal string "Invoke".
GetStepArgs Returns the list of arguments for
the Step method, as an Array of
Object. The first argument is
always the literal string "Step".
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
UpdateStepArgs Updates the output arguments for
the Step method, using an Array of
Object. The first argument is
always the literal string "Step".
Currently, only the contextData
parameter is updated.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction Constructor

Constructs an empty instance of this class.

Overload List
Constructs an empty instance of this class.
public SQLiteDelegateFunction()
Constructs an instance of this class using the specified Delegate as the
SQLiteFunction implementation.
public SQLiteDelegateFunction(Delegate,Delegate)

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction Constructor

Constructs an empty instance of this class.

SQLiteDelegateFunction();

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace |
SQLiteDelegateFunction Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction Constructor

Constructs an instance of this class using the specified Delegate as the


SQLiteFunction implementation.

SQLiteDelegateFunction(
Delegate callback1,
Delegate callback2
);

Parameters
callback1
The Delegate to be used for all calls into the Invoke, Step, and
Compare virtual methods needed by the SQLiteFunction base class.
callback2
The Delegate to be used for all calls into the Final virtual methods
needed by the SQLiteFunction base class.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace |
SQLiteDelegateFunction Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction Properties

The properties of the SQLiteDelegateFunction class are listed below. For


a complete list of SQLiteDelegateFunction class members, see the
SQLiteDelegateFunction Members topic.

Public Instance Properties


Callback1 The Delegate to be used for all calls
into the Invoke, Step, and Compare
virtual methods needed by the
SQLiteFunction base class.
Callback2 The Delegate to be used for all calls
into the Final virtual methods
needed by the SQLiteFunction base
class.
SQLiteConvert (inherited from Returns a reference to the
SQLiteFunction) underlying connection's
SQLiteConvert class, which can be
used to convert strings and
DateTime's into the current
connection's encoding schema.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.Callback1 Property

The Delegate to be used for all calls into the Invoke, Step, and Compare
virtual methods needed by the SQLiteFunction base class.

public virtual Delegate Callback1 { public get; public s

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.Callback2 Property

The Delegate to be used for all calls into the Final virtual methods needed
by the SQLiteFunction base class.

public virtual Delegate Callback2 { public get; public s

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction Methods

The methods of the SQLiteDelegateFunction class are listed below. For a


complete list of SQLiteDelegateFunction class members, see the
SQLiteDelegateFunction Members topic.

Public Instance Methods


Compare This virtual method is part of the
implementation for collating
sequences. See the Compare
method for more details.
Dispose (inherited from Overloaded. Disposes of any active
SQLiteFunction) contextData variables that were not
automatically cleaned up.
Sometimes this can happen if
someone closes the connection
while a DataReader is open.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Final This virtual method is part of the
implementation for aggregate
functions. See the Final method for
more details.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Invoke This virtual method is the
implementation for scalar
functions. See the Invoke method
for more details.
Step This virtual method is part of the
implementation for aggregate
functions. See the Step method for
more details.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose (inherited from Overloaded. Placeholder for a user-
SQLiteFunction) defined disposal routine
Finalize (inherited from Cleans up resources associated with
SQLiteFunction) the current instance.
GetCompareArgs Returns the list of arguments for
the Compare method, as an Array
of Object. The first argument is
always the literal string "Compare".
GetFinalArgs Returns the list of arguments for
the Final method, as an Array of
Object. The first argument is
always the literal string "Final".
GetInvokeArgs Returns the list of arguments for
the Invoke method, as an Array of
Object. The first argument is
always the literal string "Invoke".
GetStepArgs Returns the list of arguments for
the Step method, as an Array of
Object. The first argument is
always the literal string "Step".
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
UpdateStepArgs Updates the output arguments for
the Step method, using an Array of
Object. The first argument is
always the literal string "Step".
Currently, only the contextData
parameter is updated.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.Compare Method

This virtual method is part of the implementation for collating sequences.


See the Compare method for more details.

public override int Compare(


string param1,
string param2
);

Parameters
param1
The first string to compare.
param2
The second strnig to compare.

Return Value
A positive integer if the param1 parameter is greater than the param2
parameter, a negative integer if the param1 parameter is less than the
param2 parameter, or zero if they are equal.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.Final Method

This virtual method is part of the implementation for aggregate functions.


See the Final method for more details.

public override object Final(


object contextData
);

Parameters
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.

Return Value
The result of the aggregate function.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.GetCompareArgs Method

Returns the list of arguments for the Compare method, as an Array of


Object. The first argument is always the literal string "Compare".

protected virtual object[] GetCompareArgs(


string param1,
string param2,
bool earlyBound
);

Parameters
param1
The first string to compare.
param2
The second strnig to compare.
earlyBound
Non-zero if the returned arguments are going to be used with the
SQLiteCompareDelegate type; otherwise, zero.

Return Value
The arguments to pass to the configured Delegate.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.GetFinalArgs Method

Returns the list of arguments for the Final method, as an Array of Object.
The first argument is always the literal string "Final".

protected virtual object[] GetFinalArgs(


object contextData,
bool earlyBound
);

Parameters
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.
earlyBound
Non-zero if the returned arguments are going to be used with the
SQLiteFinalDelegate type; otherwise, zero.

Return Value
The arguments to pass to the configured Delegate.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.GetInvokeArgs Method

Returns the list of arguments for the Invoke method, as an Array of


Object. The first argument is always the literal string "Invoke".

protected virtual object[] GetInvokeArgs(


object[] args,
bool earlyBound
);

Parameters
args
The original arguments received by the Invoke method.
earlyBound
Non-zero if the returned arguments are going to be used with the
SQLiteInvokeDelegate type; otherwise, zero.

Return Value
The arguments to pass to the configured Delegate.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.GetStepArgs Method

Returns the list of arguments for the Step method, as an Array of Object.
The first argument is always the literal string "Step".

protected virtual object[] GetStepArgs(


object[] args,
int stepNumber,
object contextData,
bool earlyBound
);

Parameters
args
The original arguments received by the Step method.
stepNumber
The step number (one based). This is incrememted each time the Step
method is called.
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.
earlyBound
Non-zero if the returned arguments are going to be used with the
SQLiteStepDelegate type; otherwise, zero.

Return Value
The arguments to pass to the configured Delegate.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.Invoke Method

This virtual method is the implementation for scalar functions. See the
Invoke method for more details.

public override object Invoke(


object[] args
);

Parameters
args
The arguments for the scalar function.

Return Value
The result of the scalar function.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.Step Method

This virtual method is part of the implementation for aggregate functions.


See the Step method for more details.

public override void Step(


object[] args,
int stepNumber,
ref object contextData
);

Parameters
args
The arguments for the aggregate function.
stepNumber
The step number (one based). This is incrememted each time the Step
method is called.
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteDelegateFunction.UpdateStepArgs Method

Updates the output arguments for the Step method, using an Array of
Object. The first argument is always the literal string "Step". Currently,
only the contextData parameter is updated.

protected virtual void UpdateStepArgs(


object[] args,
ref object contextData,
bool earlyBound
);

Parameters
args
The original arguments received by the Step method.
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.
earlyBound
Non-zero if the returned arguments are going to be used with the
SQLiteStepDelegate type; otherwise, zero.

Return Value
The arguments to pass to the configured Delegate.

See Also
SQLiteDelegateFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteErrorCode Enumeration

SQLite error codes. Actually, this enumeration represents a return code,


which may also indicate success in one of several ways (e.g. SQLITE_OK,
SQLITE_ROW, and SQLITE_DONE). Therefore, the name of this
enumeration is something of a misnomer.

public enum SQLiteErrorCode

Members
Member Name Description
Unknown The error code is unknown. This
error code is only used by the
managed wrapper itself.
Ok Successful result
Error SQL error or missing database
Internal Internal logic error in SQLite
Perm Access permission denied
Abort Callback routine requested an abort
Busy The database file is locked
Locked A table in the database is locked
NoMem A malloc() failed
ReadOnly Attempt to write a readonly
database
Interrupt Operation terminated by
sqlite3_interrupt()
IoErr Some kind of disk I/O error
occurred
Corrupt The database disk image is
malformed
NotFound Unknown opcode in
sqlite3_file_control()
Full Insertion failed because database is
full
CantOpen Unable to open the database file
Protocol Database lock protocol error
Empty Database is empty
Schema The database schema changed
TooBig String or BLOB exceeds size limit
Constraint Abort due to constraint violation
Mismatch Data type mismatch
Misuse Library used incorrectly
NoLfs Uses OS features not supported on
host
Auth Authorization denied
Format Auxiliary database format error
Range 2nd parameter to sqlite3_bind out
of range
NotADb File opened that is not a database
file
Notice Notifications from sqlite3_log()
Warning Warnings from sqlite3_log()
Row sqlite3_step() has another row
ready
Done sqlite3_step() has finished
executing
NonExtendedMask Used to mask off extended result
codes
IoErr_Read A file read operation failed.
IoErr_Short_Read A file read operation returned less
data than requested.
IoErr_Write A file write operation failed.
IoErr_Fsync A file synchronization operation
failed.
IoErr_Dir_Fsync A directory synchronization
operation failed.
IoErr_Truncate A file truncate operation failed.
IoErr_Fstat A file metadata operation failed.
IoErr_Unlock A file unlock operation failed.
IoErr_RdLock A file lock operation failed.
IoErr_Delete A file delete operation failed.
IoErr_Blocked Not currently used.
IoErr_NoMem Out-of-memory during a file
operation.
IoErr_Access A file existence/status operation
failed.
IoErr_CheckReservedLock A check for a reserved lock failed.
IoErr_Lock A file lock operation failed.
IoErr_Close A file close operation failed.
IoErr_Dir_Close A directory close operation failed.
IoErr_ShmOpen A shared memory open operation
failed.
IoErr_ShmSize A shared memory size operation
failed.
IoErr_ShmLock A shared memory lock operation
failed.
IoErr_ShmMap A shared memory map operation
failed.
IoErr_Seek A file seek operation failed.
IoErr_Delete_NoEnt A file delete operation failed
because it does not exist.
IoErr_Mmap A file memory mapping operation
failed.
IoErr_GetTempPath The temporary directory path could
not be obtained.
IoErr_ConvPath A path string conversion operation
failed.
IoErr_VNode Reserved.
IoErr_Auth An attempt to authenticate failed.
Locked_SharedCache A database table is locked in
shared-cache mode.
Busy_Recovery A database file is locked due to a
recovery operation.
Busy_Snapshot A database file is locked due to
snapshot semantics.
CantOpen_NoTempDir A database file cannot be opened
because no temporary directory is
available.
CantOpen_IsDir A database file cannot be opened
because its path represents a
directory.
CantOpen_FullPath A database file cannot be opened
because its full path could not be
obtained.
CantOpen_ConvPath A database file cannot be opened
because a path string conversion
operation failed.
Corrupt_Vtab A virtual table is malformed.
ReadOnly_Recovery A database file is read-only due to
a recovery operation.
ReadOnly_CantLock A database file is read-only because
a lock could not be obtained.
ReadOnly_Rollback A database file is read-only because
it needs rollback processing.
ReadOnly_DbMoved A database file is read-only because
it was moved while open.
Abort_Rollback An operation is being aborted due
to rollback processing.
Constraint_Check A CHECK constraint failed.
Constraint_CommitHook A commit hook produced a
unsuccessful return code.
Constraint_ForeignKey A FOREIGN KEY constraint failed.
Constraint_Function Not currently used.

Constraint_NotNull A NOT NULL constraint failed.


Constraint_PrimaryKey A PRIMARY KEY constraint failed.
Constraint_Trigger The RAISE function was used by a
trigger-program.
Constraint_Unique A UNIQUE constraint failed.
Constraint_Vtab Not currently used.
Constraint_RowId A ROWID constraint failed.
Notice_Recover_Wal Frames were recovered from the
WAL log file.
Notice_Recover_Rollback Pages were recovered from the
journal file.
Warning_AutoIndex An automatic index was created to
process a query.
Auth_User User authentication failed.
Ok_Load_Permanently Success. Prevents the extension
from unloading until the process
terminates.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Class

SQLite exception class.


For a list of all members of this type, see SQLiteException Members .
System.Object Exception
SystemException
ExternalException
DbException
SQLiteException

public sealed class SQLiteException : DbException

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteException Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Members

SQLiteException overview

Public Instance Constructors


SQLiteException Overloaded. Initializes a new
instance of the SQLiteException
class.

Public Instance Properties


Data (inherited from Exception) Gets a collection of key/value pairs
that provide additional, user-
defined information about the
exception.
ErrorCode Gets the associated SQLite return
code for this exception as an Int32.
For desktop versions of the .NET
Framework, this property overrides
the property of the same name
within the ExternalException class.
This property returns the same
underlying value as the ResultCode
property.
HelpLink (inherited from Gets or sets a link to the help file
Exception) associated with this exception.
InnerException (inherited from Gets the Exception instance that
Exception) caused the current exception.
Message (inherited from Gets a message that describes the
Exception) current exception.
ResultCode Gets the associated SQLite result
code for this exception as a
SQLiteErrorCode. This property
returns the same underlying value
as the ErrorCode property.
Source (inherited from Gets or sets the name of the
Exception) application or the object that
causes the error.
StackTrace (inherited from Gets a string representation of the
Exception) frames on the call stack at the time
the current exception was thrown.
TargetSite (inherited from Gets the method that throws the
Exception) current exception.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetBaseException (inherited from When overridden in a derived class,
Exception) returns the Exception that is the
root cause of one or more
subsequent exceptions.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetObjectData Adds extra information to the
serialized object data specific to
this class type. This is only used for
serialization.
GetType (inherited from Gets the runtime type of the
Exception) current instance.
ToString (inherited from Creates and returns a string
Exception) representation of the current
exception.

Protected Instance Properties


HResult (inherited from Gets or sets HRESULT, a coded
Exception) numerical value that is assigned to
a specific exception.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteException Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Constructor

Public constructor for generating a SQLite exception given the error code
and message.

Overload List
Public constructor that uses the default base class constructor.
public SQLiteException()
Public constructor for generating a SQLite exception given the error code
and message.
public SQLiteException(SQLiteErrorCode,string)
Public constructor that uses the base class constructor for the error
message.
public SQLiteException(string)
Public constructor that uses the base class constructor for the error
message and inner exception.
public SQLiteException(string,Exception)

See Also
SQLiteException Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Constructor

Public constructor for generating a SQLite exception given the error code
and message.

SQLiteException(
SQLiteErrorCode errorCode,
string message
);

Parameters
errorCode
The SQLite return code to report.
message
Message text to go along with the return code message text.

See Also
SQLiteException Class | System.Data.SQLite Namespace | SQLiteException
Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Constructor

Public constructor that uses the base class constructor for the error
message.

SQLiteException(
string message
);

Parameters
message
Error message text.

See Also
SQLiteException Class | System.Data.SQLite Namespace | SQLiteException
Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Constructor

Public constructor that uses the default base class constructor.

SQLiteException();

See Also
SQLiteException Class | System.Data.SQLite Namespace | SQLiteException
Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Constructor

Public constructor that uses the base class constructor for the error
message and inner exception.

SQLiteException(
string message,
Exception innerException
);

Parameters
message
Error message text.
innerException
The original (inner) exception.

See Also
SQLiteException Class | System.Data.SQLite Namespace | SQLiteException
Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Properties

The properties of the SQLiteException class are listed below. For a


complete list of SQLiteException class members, see the SQLiteException
Members topic.

Public Instance Properties


Data (inherited from Exception) Gets a collection of key/value pairs
that provide additional, user-
defined information about the
exception.
ErrorCode Gets the associated SQLite return
code for this exception as an Int32.
For desktop versions of the .NET
Framework, this property overrides
the property of the same name
within the ExternalException class.
This property returns the same
underlying value as the ResultCode
property.
HelpLink (inherited from Gets or sets a link to the help file
Exception) associated with this exception.
InnerException (inherited from Gets the Exception instance that
Exception) caused the current exception.
Message (inherited from Gets a message that describes the
Exception) current exception.
ResultCode Gets the associated SQLite result
code for this exception as a
SQLiteErrorCode. This property
returns the same underlying value
as the ErrorCode property.
Source (inherited from Gets or sets the name of the
Exception) application or the object that
causes the error.
StackTrace (inherited from Gets a string representation of the
Exception) frames on the call stack at the time
the current exception was thrown.
TargetSite (inherited from Gets the method that throws the
Exception) current exception.

Protected Instance Properties


HResult (inherited from Gets or sets HRESULT, a coded
Exception) numerical value that is assigned to
a specific exception.

See Also
SQLiteException Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException.ErrorCode Property

Gets the associated SQLite return code for this exception as an Int32. For
desktop versions of the .NET Framework, this property overrides the
property of the same name within the ExternalException class. This
property returns the same underlying value as the ResultCode property.

public override int ErrorCode { public get; }

See Also
SQLiteException Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException.ResultCode Property

Gets the associated SQLite result code for this exception as a


SQLiteErrorCode. This property returns the same underlying value as the
ErrorCode property.

public SQLiteErrorCode ResultCode { public get; }

See Also
SQLiteException Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException Methods

The methods of the SQLiteException class are listed below. For a


complete list of SQLiteException class members, see the SQLiteException
Members topic.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetBaseException (inherited from When overridden in a derived class,
Exception) returns the Exception that is the
root cause of one or more
subsequent exceptions.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetObjectData Adds extra information to the
serialized object data specific to
this class type. This is only used for
serialization.
GetType (inherited from Gets the runtime type of the
Exception) current instance.
ToString (inherited from Creates and returns a string
Exception) representation of the current
exception.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
See Also
SQLiteException Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteException.GetObjectData Method

Adds extra information to the serialized object data specific to this class
type. This is only used for serialization.

public override void GetObjectData(


SerializationInfo info,
StreamingContext context
);

Parameters
info
Holds the serialized object data about the exception being thrown.
context
Contains contextual information about the source or destination.

Implements
ISerializable.GetObjectData

See Also
SQLiteException Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteExecuteType Enumeration

The requested command execution type. This controls which method of the
SQLiteCommand object will be called.

public enum SQLiteExecuteType

Members
Member Name Description
None Do nothing. No method will be
called.
NonQuery The command is not expected to
return a result -OR- the result is
not needed. The ExecuteNonQuery
or ExecuteNonQuery method will
be called.
Scalar The command is expected to return
a scalar result -OR- the result
should be limited to a scalar result.
The ExecuteScalar or
ExecuteScalar method will be
called.
Reader The command is expected to return
SQLiteDataReader result. The
ExecuteReader or ExecuteReader
method will be called.
Default Use the default command execution
type. Using this value is the same
as using the NonQuery value.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory Class

SQLite implementation of DbProviderFactory.


SQLite implementation of IServiceProvider.
For a list of all members of this type, see SQLiteFactory Members .
System.Object DbProviderFactory
SQLiteFactory

public sealed class SQLiteFactory :


DbProviderFactory, IDisposable, IServiceProvider

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteFactory Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory Members

SQLiteFactory overview

Public Static Fields


Instance Static instance member which
returns an instanced SQLiteFactory
class.

Public Instance Constructors


SQLiteFactory Constructor Constructs a new instance.

Public Instance Properties


CanCreateDataSourceEnumerator Specifies whether the specific
(inherited from DbProviderFactory supports the
DbProviderFactory) DbDataSourceEnumerator class.

Public Instance Methods


CreateCommand Creates and returns a new
SQLiteCommand object.
CreateCommandBuilder Creates and returns a new
SQLiteCommandBuilder object.
CreateConnection Creates and returns a new
SQLiteConnection object.
CreateConnectionStringBuilder Creates and returns a new
SQLiteConnectionStringBuilder
object.
CreateDataAdapter Creates and returns a new
SQLiteDataAdapter object.
CreateDataSourceEnumerator Returns a new instance of the
(inherited from provider's class that implements
DbProviderFactory) the DbDataSourceEnumerator
class.
CreateParameter Creates and returns a new
SQLiteParameter object.
CreatePermission (inherited from Returns a new instance of the
DbProviderFactory) provider's class that implements
the provider's version of the
CodeAccessPermission class.
Dispose Cleans up resources (native and
managed) associated with the
current instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Public Instance Events


Log This event is raised whenever
SQLite raises a logging event. Note
that this should be set as one of
the first things in the application.
This event is provided for backward
compatibility only. New code should
use the SQLiteLog class instead.

Protected Instance Methods


Finalize Cleans up resources associated with
the current instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory Constructor

Constructs a new instance.

SQLiteFactory();

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory Fields

The fields of the SQLiteFactory class are listed below. For a complete list
of SQLiteFactory class members, see the SQLiteFactory Members topic.

Public Static Fields


Instance Static instance member which
returns an instanced SQLiteFactory
class.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.Instance Field

Static instance member which returns an instanced SQLiteFactory class.

public static readonly SQLiteFactory Instance;

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory Methods

The methods of the SQLiteFactory class are listed below. For a complete
list of SQLiteFactory class members, see the SQLiteFactory Members
topic.

Public Instance Methods


CreateCommand Creates and returns a new
SQLiteCommand object.
CreateCommandBuilder Creates and returns a new
SQLiteCommandBuilder object.
CreateConnection Creates and returns a new
SQLiteConnection object.
CreateConnectionStringBuilder Creates and returns a new
SQLiteConnectionStringBuilder
object.
CreateDataAdapter Creates and returns a new
SQLiteDataAdapter object.
CreateDataSourceEnumerator Returns a new instance of the
(inherited from provider's class that implements
DbProviderFactory) the DbDataSourceEnumerator
class.
CreateParameter Creates and returns a new
SQLiteParameter object.
CreatePermission (inherited from Returns a new instance of the
DbProviderFactory) provider's class that implements
the provider's version of the
CodeAccessPermission class.
Dispose Cleans up resources (native and
managed) associated with the
current instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize Cleans up resources associated with
the current instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.CreateCommand Method

Creates and returns a new SQLiteCommand object.

public override DbCommand CreateCommand();

Return Value
The new object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.CreateCommandBuilder Method

Creates and returns a new SQLiteCommandBuilder object.

public override DbCommandBuilder CreateCommandBuilder();

Return Value
The new object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.CreateConnection Method

Creates and returns a new SQLiteConnection object.

public override DbConnection CreateConnection();

Return Value
The new object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.CreateConnectionStringBuilder Method

Creates and returns a new SQLiteConnectionStringBuilder object.

public override DbConnectionStringBuilder CreateConnecti

Return Value
The new object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.CreateDataAdapter Method

Creates and returns a new SQLiteDataAdapter object.

public override DbDataAdapter CreateDataAdapter();

Return Value
The new object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.CreateParameter Method

Creates and returns a new SQLiteParameter object.

public override DbParameter CreateParameter();

Return Value
The new object.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.Dispose Method

Cleans up resources (native and managed) associated with the current


instance.

public void Dispose();

Implements
IDisposable.Dispose

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.Finalize Method

Cleans up resources associated with the current instance.

protected override void Finalize();

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory Events

The events of the SQLiteFactory class are listed below. For a complete list
of SQLiteFactory class members, see the SQLiteFactory Members topic.

Public Instance Events


Log This event is raised whenever
SQLite raises a logging event. Note
that this should be set as one of
the first things in the application.
This event is provided for backward
compatibility only. New code should
use the SQLiteLog class instead.

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFactory.Log Event

This event is raised whenever SQLite raises a logging event. Note that this
should be set as one of the first things in the application. This event is
provided for backward compatibility only. New code should use the
SQLiteLog class instead.

public event SQLiteLogEventHandler Log;

See Also
SQLiteFactory Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFinalDelegate Delegate

This Delegate type is used with the Final method.

public delegate object SQLiteFinalDelegate(


string param0,
object contextData
);

Parameters
param0
This is always the string literal "Final".
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.

Return Value
The result of the aggregate function.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction Class

This abstract class is designed to handle user-defined functions easily. An


instance of the derived class is made for each connection to the database.
For a list of all members of this type, see SQLiteFunction Members .
System.Object SQLiteFunction
SQLiteDelegateFunction
SQLiteFunctionEx

public abstract class SQLiteFunction : IDisposable

Remarks
Although there is one instance of a class derived from SQLiteFunction per
database connection, the derived class has no access to the underlying
connection. This is necessary to deter implementers from thinking it would
be a good idea to make database calls during processing. It is important to
distinguish between a per-connection instance, and a per-SQL statement
context. One instance of this class services all SQL statements being
stepped through on that connection, and there can be many. One should
never store per-statement information in member variables of user-
defined function classes. For aggregate functions, always create and store
your per-statement data in the contextData object on the 1st step. This
data will be automatically freed for you (and Dispose() called if the item
supports IDisposable) when the statement completes.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteFunction Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction Members

SQLiteFunction overview

Public Static Methods


RegisterFunction Overloaded. Manual method of
registering a function. The type
must still have the
SQLiteFunctionAttributes in order
to work properly, but this is a
workaround for the Compact
Framework where enumerating
assemblies is not currently
supported.

Public Instance Properties


SQLiteConvert Returns a reference to the
underlying connection's
SQLiteConvert class, which can be
used to convert strings and
DateTime's into the current
connection's encoding schema.

Public Instance Methods


Compare User-defined collating sequences
override this method to provide a
custom string sorting algorithm.
Dispose Overloaded. Disposes of any active
contextData variables that were not
automatically cleaned up.
Sometimes this can happen if
someone closes the connection
while a DataReader is open.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Final Aggregate functions override this
method to finish their aggregate
processing.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Invoke Scalar functions override this
method to do their magic.
Step Aggregate functions override this
method to do their magic.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Constructors


SQLiteFunction Overloaded. Initializes a new
instance of the SQLiteFunction
class.

Protected Instance Methods


Dispose Overloaded. Placeholder for a user-
defined disposal routine
Finalize Cleans up resources associated with
the current instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction Constructor

Internal constructor, initializes the function's internal variables.

Overload List
Internal constructor, initializes the function's internal variables.
protected SQLiteFunction()
Constructs an instance of this class using the specified data-type
conversion parameters.
protected SQLiteFunction(SQLiteDateFormats,DateTimeKind,string,bool)

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction Constructor

Internal constructor, initializes the function's internal variables.

SQLiteFunction();

See Also
SQLiteFunction Class | System.Data.SQLite Namespace | SQLiteFunction
Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction Constructor

Constructs an instance of this class using the specified data-type


conversion parameters.

SQLiteFunction(
SQLiteDateFormats format,
DateTimeKind kind,
string formatString,
bool utf16
);

Parameters
format
The DateTime format to be used when converting string values to a
DateTime and binding DateTime parameters.
kind
The DateTimeKind to be used when creating DateTime values.
formatString
The format string to be used when parsing and formatting DateTime
values.
utf16
Non-zero to create a UTF-16 data-type conversion context; otherwise,
a UTF-8 data-type conversion context will be created.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace | SQLiteFunction
Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction Properties

The properties of the SQLiteFunction class are listed below. For a


complete list of SQLiteFunction class members, see the SQLiteFunction
Members topic.

Public Instance Properties


SQLiteConvert Returns a reference to the
underlying connection's
SQLiteConvert class, which can be
used to convert strings and
DateTime's into the current
connection's encoding schema.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.SQLiteConvert Property

Returns a reference to the underlying connection's SQLiteConvert class,


which can be used to convert strings and DateTime's into the current
connection's encoding schema.

public SQLiteConvert SQLiteConvert { public get; }

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction Methods

The methods of the SQLiteFunction class are listed below. For a complete
list of SQLiteFunction class members, see the SQLiteFunction Members
topic.

Public Static Methods


RegisterFunction Overloaded. Manual method of
registering a function. The type
must still have the
SQLiteFunctionAttributes in order
to work properly, but this is a
workaround for the Compact
Framework where enumerating
assemblies is not currently
supported.

Public Instance Methods


Compare User-defined collating sequences
override this method to provide a
custom string sorting algorithm.
Dispose Overloaded. Disposes of any active
contextData variables that were not
automatically cleaned up.
Sometimes this can happen if
someone closes the connection
while a DataReader is open.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Final Aggregate functions override this
method to finish their aggregate
processing.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Invoke Scalar functions override this
method to do their magic.
Step Aggregate functions override this
method to do their magic.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Placeholder for a user-
defined disposal routine
Finalize Cleans up resources associated with
the current instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Compare Method

User-defined collating sequences override this method to provide a custom


string sorting algorithm.

public virtual int Compare(


string param1,
string param2
);

Parameters
param1
The first string to compare.
param2
The second strnig to compare.

Return Value
1 if param1 is greater than param2, 0 if they are equal, or -1 if param1 is
less than param2.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Dispose Method

Disposes of any active contextData variables that were not automatically


cleaned up. Sometimes this can happen if someone closes the connection
while a DataReader is open.

Overload List
Disposes of any active contextData variables that were not automatically
cleaned up. Sometimes this can happen if someone closes the connection
while a DataReader is open.
public void Dispose()
Placeholder for a user-defined disposal routine
protected virtual void Dispose(bool)

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Dispose() Method

Disposes of any active contextData variables that were not automatically


cleaned up. Sometimes this can happen if someone closes the connection
while a DataReader is open.

public void Dispose();

Implements
IDisposable.Dispose

See Also
SQLiteFunction Class | System.Data.SQLite Namespace |
SQLiteFunction.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Dispose(Boolean) Method

Placeholder for a user-defined disposal routine

protected virtual void Dispose(


bool disposing
);

Parameters
disposing
True if the object is being disposed explicitly

See Also
SQLiteFunction Class | System.Data.SQLite Namespace |
SQLiteFunction.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Final Method

Aggregate functions override this method to finish their aggregate


processing.

public virtual object Final(


object contextData
);

Parameters
contextData
Your own assigned contextData, provided for you so you can return
your final results.

Return Value
You may return most simple types as a return value, null or DBNull.Value
to return null, DateTime, or you may return an Exception-derived class if
you wish to return an error to SQLite. Do not actually throw the error, just
return it!

Remarks
If you implemented your aggregate function properly, you've been
recording and keeping track of your data in the contextData object
provided, and now at this stage you should have all the information you
need in there to figure out what to return. NOTE: It is possible to arrive
here without receiving a previous call to Step(), in which case the
contextData will be null. This can happen when no rows were returned.
You can either return null, or 0 or some other custom return value if that
is the case.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Finalize Method

Cleans up resources associated with the current instance.

protected override void Finalize();

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Invoke Method

Scalar functions override this method to do their magic.

public virtual object Invoke(


object[] args
);

Parameters
args
The arguments for the command to process

Return Value
You may return most simple types as a return value, null or DBNull.Value
to return null, DateTime, or you may return an Exception-derived class if
you wish to return an error to SQLite. Do not actually throw the error, just
return it!

Remarks
Parameters passed to functions have only an affinity for a certain data
type, there is no underlying schema available to force them into a certain
type. Therefore the only types you will ever see as parameters are
DBNull.Value, Int64, Double, String or byte[] array.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.RegisterFunction Method

Alternative method of registering a function. This method does not require


the specified type to be annotated with SQLiteFunctionAttribute.

Overload List
Alternative method of registering a function. This method does not require
the specified type to be annotated with SQLiteFunctionAttribute.
public static void RegisterFunction(string,int,FunctionType,Type,Delegate,De
Manual method of registering a function. The type must still have the
SQLiteFunctionAttributes in order to work properly, but this is a
workaround for the Compact Framework where enumerating assemblies is
not currently supported.
public static void RegisterFunction(Type)

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.RegisterFunction(String, Int32,
FunctionType, Type, Delegate, Delegate) Method

Alternative method of registering a function. This method does not require


the specified type to be annotated with SQLiteFunctionAttribute.

public static void RegisterFunction(


string name,
int argumentCount,
FunctionType functionType,
Type instanceType,
Delegate callback1,
Delegate callback2
);

Parameters
name
The name of the function to register.
argumentCount
The number of arguments accepted by the function.
functionType
The type of SQLite function being resitered (e.g. scalar, aggregate, or
collating sequence).
instanceType
The Type that actually implements the function. This will only be used if
the callback1 and callback2 parameters are null.
callback1
The Delegate to be used for all calls into the Invoke, Step, and
Compare virtual methods.
callback2
The Delegate to be used for all calls into the Final virtual method. This
parameter is only necessary for aggregate functions.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace |
SQLiteFunction.RegisterFunction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.RegisterFunction(Type) Method

Manual method of registering a function. The type must still have the
SQLiteFunctionAttributes in order to work properly, but this is a
workaround for the Compact Framework where enumerating assemblies is
not currently supported.

public static void RegisterFunction(


Type typ
);

Parameters
typ
The type of the function to register

See Also
SQLiteFunction Class | System.Data.SQLite Namespace |
SQLiteFunction.RegisterFunction Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunction.Step Method

Aggregate functions override this method to do their magic.

public virtual void Step(


object[] args,
int stepNumber,
ref object contextData
);

Parameters
args
The arguments for the command to process
stepNumber
The 1-based step number. This is incrememted each time the step
method is called.
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.

Remarks
Typically you'll be updating whatever you've placed in the contextData
field and returning as quickly as possible.

See Also
SQLiteFunction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute Class

A simple custom attribute to enable us to easily find user-defined functions


in the loaded assemblies and initialize them in SQLite as connections are
made.
For a list of all members of this type, see SQLiteFunctionAttribute
Members .
System.Object Attribute
SQLiteFunctionAttribute

public sealed class SQLiteFunctionAttribute :


Attribute

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteFunctionAttribute Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute Members

SQLiteFunctionAttribute overview

Public Instance Constructors


SQLiteFunctionAttribute Overloaded. Initializes a new
instance of the
SQLiteFunctionAttribute class.

Public Instance Properties


Arguments The number of arguments this
function expects. -1 if the number
of arguments is variable.
FuncType The type of function this
implementation will be.
Name The function's name as it will be
used in SQLite command text.
TypeId (inherited from Attribute) When implemented in a derived
class, gets a unique identifier for
this Attribute.

Public Instance Methods


Equals (inherited from Attribute) Returns a value that indicates
whether this instance is equal to a
specified object.
GetHashCode (inherited from Returns the hash code for this
Attribute) instance.
GetType (inherited from Object) Gets the Type of the current
instance.
IsDefaultAttribute (inherited from When overridden in a derived class,
Attribute) indicates whether the value of this
instance is the default value for the
derived class.
Match (inherited from Attribute) When overridden in a derived class,
returns a value that indicates
whether this instance equals a
specified object.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute Constructor

Default constructor, initializes the internal variables for the function.

Overload List
Default constructor, initializes the internal variables for the function.
public SQLiteFunctionAttribute()
Constructs an instance of this class. This sets the initial InstanceType,
Callback1, and Callback2 properties to null.
public SQLiteFunctionAttribute(string,int,FunctionType)

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute Constructor

Default constructor, initializes the internal variables for the function.

SQLiteFunctionAttribute();

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace |
SQLiteFunctionAttribute Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute Constructor

Constructs an instance of this class. This sets the initial InstanceType,


Callback1, and Callback2 properties to null.

SQLiteFunctionAttribute(
string name,
int argumentCount,
FunctionType functionType
);

Parameters
name
The name of the function, as seen by the SQLite core library.
argumentCount
The number of arguments that the function will accept.
functionType
The type of function being declared. This will either be Scalar,
Aggregate, or Collation.

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace |
SQLiteFunctionAttribute Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute Properties

The properties of the SQLiteFunctionAttribute class are listed below. For


a complete list of SQLiteFunctionAttribute class members, see the
SQLiteFunctionAttribute Members topic.

Public Instance Properties


Arguments The number of arguments this
function expects. -1 if the number
of arguments is variable.
FuncType The type of function this
implementation will be.
Name The function's name as it will be
used in SQLite command text.
TypeId (inherited from Attribute) When implemented in a derived
class, gets a unique identifier for
this Attribute.

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute.Arguments Property

The number of arguments this function expects. -1 if the number of


arguments is variable.

public int Arguments { public get; public set; }

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute.FuncType Property

The type of function this implementation will be.

public FunctionType FuncType { public get; public set; }

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionAttribute.Name Property

The function's name as it will be used in SQLite command text.

public string Name { public get; public set; }

See Also
SQLiteFunctionAttribute Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionEx Class

Extends SQLiteFunction and allows an inherited class to obtain the


collating sequence associated with a function call.
For a list of all members of this type, see SQLiteFunctionEx Members .
System.Object SQLiteFunction
SQLiteFunctionEx

public class SQLiteFunctionEx : SQLiteFunction

Remarks
User-defined functions can call the GetCollationSequence() method in this
class and use it to compare strings and char arrays.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteFunctionEx Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionEx Members

SQLiteFunctionEx overview

Public Instance Constructors


SQLiteFunctionEx Constructor Initializes a new instance of the
SQLiteFunctionEx class.

Public Instance Properties


SQLiteConvert (inherited from Returns a reference to the
SQLiteFunction) underlying connection's
SQLiteConvert class, which can be
used to convert strings and
DateTime's into the current
connection's encoding schema.

Public Instance Methods


Compare (inherited from User-defined collating sequences
SQLiteFunction) override this method to provide a
custom string sorting algorithm.
Dispose (inherited from Overloaded. Disposes of any active
SQLiteFunction) contextData variables that were not
automatically cleaned up.
Sometimes this can happen if
someone closes the connection
while a DataReader is open.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Final (inherited from Aggregate functions override this
SQLiteFunction) method to finish their aggregate
processing.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Invoke (inherited from Scalar functions override this
SQLiteFunction) method to do their magic.
Step (inherited from Aggregate functions override this
SQLiteFunction) method to do their magic.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
Finalize (inherited from Cleans up resources associated with
SQLiteFunction) the current instance.
GetCollationSequence Obtains the collating sequence in
effect for the given function.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteFunctionEx Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionEx Constructor

Initializes a new instance of the SQLiteFunctionEx class.

SQLiteFunctionEx();

See Also
SQLiteFunctionEx Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionEx Methods

The methods of the SQLiteFunctionEx class are listed below. For a


complete list of SQLiteFunctionEx class members, see the
SQLiteFunctionEx Members topic.

Public Instance Methods


Compare (inherited from User-defined collating sequences
SQLiteFunction) override this method to provide a
custom string sorting algorithm.
Dispose (inherited from Overloaded. Disposes of any active
SQLiteFunction) contextData variables that were not
automatically cleaned up.
Sometimes this can happen if
someone closes the connection
while a DataReader is open.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Final (inherited from Aggregate functions override this
SQLiteFunction) method to finish their aggregate
processing.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Invoke (inherited from Scalar functions override this
SQLiteFunction) method to do their magic.
Step (inherited from Aggregate functions override this
SQLiteFunction) method to do their magic.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Cleans up resources
(native and managed) associated
with the current instance.
Finalize (inherited from Cleans up resources associated with
SQLiteFunction) the current instance.
GetCollationSequence Obtains the collating sequence in
effect for the given function.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteFunctionEx Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionEx.Dispose Method

Cleans up resources (native and managed) associated with the current


instance.

Overload List
Inherited from SQLiteFunction.
public void Dispose()
Cleans up resources (native and managed) associated with the current
instance.
protected override void Dispose(bool)

See Also
SQLiteFunctionEx Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionEx.Dispose(Boolean) Method

Cleans up resources (native and managed) associated with the current


instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Zero when being disposed via garbage collection; otherwise, non-zero.

See Also
SQLiteFunctionEx Class | System.Data.SQLite Namespace |
SQLiteFunctionEx.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteFunctionEx.GetCollationSequence Method

Obtains the collating sequence in effect for the given function.

protected CollationSequence GetCollationSequence();

Return Value

See Also
SQLiteFunctionEx Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndex Class

This class represents the various inputs and outputs used with the
BestIndex method.
For a list of all members of this type, see SQLiteIndex Members .
System.Object SQLiteIndex

public sealed class SQLiteIndex

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteIndex Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndex Members

SQLiteIndex overview

Public Instance Properties


Inputs The SQLiteIndexInputs object
instance containing the inputs to
the BestIndex method.
Outputs The SQLiteIndexOutputs object
instance containing the outputs
from the BestIndex method.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteIndex Class | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndex Properties

The properties of the SQLiteIndex class are listed below. For a complete
list of SQLiteIndex class members, see the SQLiteIndex Members topic.

Public Instance Properties


Inputs The SQLiteIndexInputs object
instance containing the inputs to
the BestIndex method.
Outputs The SQLiteIndexOutputs object
instance containing the outputs
from the BestIndex method.

See Also
SQLiteIndex Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndex.Inputs Property

The SQLiteIndexInputs object instance containing the inputs to the


BestIndex method.

public SQLiteIndexInputs Inputs { public get; }

See Also
SQLiteIndex Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndex.Outputs Property

The SQLiteIndexOutputs object instance containing the outputs from the


BestIndex method.

public SQLiteIndexOutputs Outputs { public get; }

See Also
SQLiteIndex Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraint Class

This class represents the native sqlite3_index_constraint structure from


the SQLite core library.
For a list of all members of this type, see SQLiteIndexConstraint Members
.
System.Object SQLiteIndexConstraint

public sealed class SQLiteIndexConstraint

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteIndexConstraint Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraint Members

SQLiteIndexConstraint overview

Public Instance Fields


iColumn Column on left-hand side of
constraint.
iTermOffset Used internally - BestIndex should
ignore.
op Constraint operator
(SQLiteIndexConstraintOp).
usable True if this constraint is usable.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteIndexConstraint Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraint Fields

The fields of the SQLiteIndexConstraint class are listed below. For a


complete list of SQLiteIndexConstraint class members, see the
SQLiteIndexConstraint Members topic.

Public Instance Fields


iColumn Column on left-hand side of
constraint.
iTermOffset Used internally - BestIndex should
ignore.
op Constraint operator
(SQLiteIndexConstraintOp).
usable True if this constraint is usable.

See Also
SQLiteIndexConstraint Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraint.iColumn Field

Column on left-hand side of constraint.

public int iColumn;

See Also
SQLiteIndexConstraint Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraint.iTermOffset Field

Used internally - BestIndex should ignore.

public int iTermOffset;

See Also
SQLiteIndexConstraint Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraint.op Field

Constraint operator (SQLiteIndexConstraintOp).

public SQLiteIndexConstraintOp op;

See Also
SQLiteIndexConstraint Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraint.usable Field

True if this constraint is usable.

public byte usable;

See Also
SQLiteIndexConstraint Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraintOp Enumeration

These are the allowed values for the operators that are part of a constraint
term in the WHERE clause of a query that uses a virtual table.

public enum SQLiteIndexConstraintOp : byte

Members
Member Name Description
EqualTo This value represents the equality
operator.
GreaterThan This value represents the greater
than operator.
LessThanOrEqualTo This value represents the less than
or equal to operator.
LessThan This value represents the less than
operator.
GreaterThanOrEqualTo This value represents the greater
than or equal to operator.
Match This value represents the MATCH
operator.
Like This value represents the LIKE
operator.
Glob This value represents the GLOB
operator.
Regexp This value represents the REGEXP
operator.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraintUsage Class

This class represents the native sqlite3_index_constraint_usage structure


from the SQLite core library.
For a list of all members of this type, see SQLiteIndexConstraintUsage
Members .
System.Object SQLiteIndexConstraintUsage

public sealed class SQLiteIndexConstraintUsage

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteIndexConstraintUsage Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraintUsage Members

SQLiteIndexConstraintUsage overview

Public Instance Fields


argvIndex If greater than 0, constraint is part
of argv to xFilter.
omit Do not code a test for this
constraint.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteIndexConstraintUsage Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraintUsage Fields

The fields of the SQLiteIndexConstraintUsage class are listed below. For


a complete list of SQLiteIndexConstraintUsage class members, see the
SQLiteIndexConstraintUsage Members topic.

Public Instance Fields


argvIndex If greater than 0, constraint is part
of argv to xFilter.
omit Do not code a test for this
constraint.

See Also
SQLiteIndexConstraintUsage Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraintUsage.argvIndex Field

If greater than 0, constraint is part of argv to xFilter.

public int argvIndex;

See Also
SQLiteIndexConstraintUsage Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexConstraintUsage.omit Field

Do not code a test for this constraint.

public byte omit;

See Also
SQLiteIndexConstraintUsage Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexFlags Enumeration

These are the allowed values for the index flags from the BestIndex
method.
This enumeration has a FlagsAttribute attribute that allows a bitwise
combination of its member values.

public enum SQLiteIndexFlags

Members
Member Name Description Value
None No special handling. This is 0
the default.
ScanUnique This value indicates that the 1
scan of the index will visit
at most one row.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexInputs Class

This class represents the various inputs provided by the SQLite core
library to the BestIndex method.
For a list of all members of this type, see SQLiteIndexInputs Members .
System.Object SQLiteIndexInputs

public sealed class SQLiteIndexInputs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteIndexInputs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexInputs Members

SQLiteIndexInputs overview

Public Instance Properties


Constraints An array of SQLiteIndexConstraint
object instances, each containing
information supplied by the SQLite
core library.
OrderBys An array of SQLiteIndexOrderBy
object instances, each containing
information supplied by the SQLite
core library.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteIndexInputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexInputs Properties

The properties of the SQLiteIndexInputs class are listed below. For a


complete list of SQLiteIndexInputs class members, see the
SQLiteIndexInputs Members topic.

Public Instance Properties


Constraints An array of SQLiteIndexConstraint
object instances, each containing
information supplied by the SQLite
core library.
OrderBys An array of SQLiteIndexOrderBy
object instances, each containing
information supplied by the SQLite
core library.

See Also
SQLiteIndexInputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexInputs.Constraints Property

An array of SQLiteIndexConstraint object instances, each containing


information supplied by the SQLite core library.

public SQLiteIndexConstraint[] Constraints { public get;

See Also
SQLiteIndexInputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexInputs.OrderBys Property

An array of SQLiteIndexOrderBy object instances, each containing


information supplied by the SQLite core library.

public SQLiteIndexOrderBy[] OrderBys { public get; }

See Also
SQLiteIndexInputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOrderBy Class

This class represents the native sqlite3_index_orderby structure from the


SQLite core library.
For a list of all members of this type, see SQLiteIndexOrderBy Members .
System.Object SQLiteIndexOrderBy

public sealed class SQLiteIndexOrderBy

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteIndexOrderBy Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOrderBy Members

SQLiteIndexOrderBy overview

Public Instance Fields


desc True for DESC. False for ASC.
iColumn Column number.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteIndexOrderBy Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOrderBy Fields

The fields of the SQLiteIndexOrderBy class are listed below. For a


complete list of SQLiteIndexOrderBy class members, see the
SQLiteIndexOrderBy Members topic.

Public Instance Fields


desc True for DESC. False for ASC.
iColumn Column number.

See Also
SQLiteIndexOrderBy Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOrderBy.desc Field

True for DESC. False for ASC.

public byte desc;

See Also
SQLiteIndexOrderBy Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOrderBy.iColumn Field

Column number.

public int iColumn;

See Also
SQLiteIndexOrderBy Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs Class

This class represents the various outputs provided to the SQLite core
library by the BestIndex method.
For a list of all members of this type, see SQLiteIndexOutputs Members .
System.Object SQLiteIndexOutputs

public sealed class SQLiteIndexOutputs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteIndexOutputs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs Members

SQLiteIndexOutputs overview

Public Instance Properties


ColumnsUsed Indicates which columns of the virtual table may be
current scan. Virtual table columns are numbered fro
order in which they appear within the CREATE TABLE
passed to sqlite3_declare_vtab(). For the first 63 col
0-62), the corresponding bit is set within the bit mas
may be required by SQLite. If the table has at least
any column to the right of the first 63 is required, th
colUsed is also set. In other words, column iCol may
the expression
(colUsed & ((sqlite3_uint64)1 << (iCol>=63 ?

evaluates to non-zero. Using a null value here indica


default flags value should be used. This property has
SQLite core library is not at least version 3.10.0.
ConstraintUsages An array of SQLiteIndexConstraintUsage object insta
containing information to be supplied to the SQLite c
EstimatedCost Estimated cost of using this index. Using a null value
that a default estimated cost value should be used.
EstimatedRows Estimated number of rows returned. Using a null val
indicates that a default estimated rows value should
property has no effect if the SQLite core library is no
version 3.8.2.
IndexFlags The flags that should be used with this index. Using
here indicates that a default flags value should be us
property has no effect if the SQLite core library is no
version 3.9.0.
IndexNumber Number used to help identify the selected index. Thi
later be provided to the Filter method.
IndexString String used to help identify the selected index. This
be provided to the Filter method.
Non-zero if the index string must be freed by the SQ
NeedToFreeIndexString library.
OrderByConsumed True if output is already ordered.

Public Instance Methods


CanUseColumnsUsed Determines if the native flags field
can be used, based on the available
version of the SQLite core library.
CanUseEstimatedRows Determines if the native
estimatedRows field can be used,
based on the available version of
the SQLite core library.
CanUseIndexFlags Determines if the native flags field
can be used, based on the available
version of the SQLite core library.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs Properties

The properties of the SQLiteIndexOutputs class are listed below. For a


complete list of SQLiteIndexOutputs class members, see the
SQLiteIndexOutputs Members topic.

Public Instance Properties


ColumnsUsed Indicates which columns of the virtual table may be
current scan. Virtual table columns are numbered fro
order in which they appear within the CREATE TABLE
passed to sqlite3_declare_vtab(). For the first 63 col
0-62), the corresponding bit is set within the bit mas
may be required by SQLite. If the table has at least
any column to the right of the first 63 is required, th
colUsed is also set. In other words, column iCol may
the expression
(colUsed & ((sqlite3_uint64)1 << (iCol>=63 ?

evaluates to non-zero. Using a null value here indica


default flags value should be used. This property has
SQLite core library is not at least version 3.10.0.
ConstraintUsages An array of SQLiteIndexConstraintUsage object insta
containing information to be supplied to the SQLite c
EstimatedCost Estimated cost of using this index. Using a null value
that a default estimated cost value should be used.
EstimatedRows Estimated number of rows returned. Using a null val
indicates that a default estimated rows value should
property has no effect if the SQLite core library is no
version 3.8.2.
IndexFlags The flags that should be used with this index. Using
here indicates that a default flags value should be us
property has no effect if the SQLite core library is no
version 3.9.0.
IndexNumber Number used to help identify the selected index. Thi
later be provided to the Filter method.
IndexString String used to help identify the selected index. This
be provided to the Filter method.
Non-zero if the index string must be freed by the SQ
NeedToFreeIndexString library.
OrderByConsumed True if output is already ordered.

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.ColumnsUsed Property

Indicates which columns of the virtual table may be required by the


current scan. Virtual table columns are numbered from zero in the order
in which they appear within the CREATE TABLE statement passed to
sqlite3_declare_vtab(). For the first 63 columns (columns 0-62), the
corresponding bit is set within the bit mask if the column may be required
by SQLite. If the table has at least 64 columns and any column to the right
of the first 63 is required, then bit 63 of colUsed is also set. In other
words, column iCol may be required if the expression
(colUsed & ((sqlite3_uint64)1 << (iCol>=63 ? 63 : iCol)))

evaluates to non-zero. Using a null value here indicates that a default


flags value should be used. This property has no effect if the SQLite core
library is not at least version 3.10.0.

public long? ColumnsUsed { public get; public set; }

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.ConstraintUsages Property

An array of SQLiteIndexConstraintUsage object instances, each containing


information to be supplied to the SQLite core library.

public SQLiteIndexConstraintUsage[] ConstraintUsages { p

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.EstimatedCost Property

Estimated cost of using this index. Using a null value here indicates that a
default estimated cost value should be used.

public double? EstimatedCost { public get; public set; }

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.EstimatedRows Property

Estimated number of rows returned. Using a null value here indicates that
a default estimated rows value should be used. This property has no effect
if the SQLite core library is not at least version 3.8.2.

public long? EstimatedRows { public get; public set; }

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.IndexFlags Property

The flags that should be used with this index. Using a null value here
indicates that a default flags value should be used. This property has no
effect if the SQLite core library is not at least version 3.9.0.

public SQLiteIndexFlags? IndexFlags { public get; public

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.IndexNumber Property

Number used to help identify the selected index. This value will later be
provided to the Filter method.

public int IndexNumber { public get; public set; }

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.IndexString Property

String used to help identify the selected index. This value will later be
provided to the Filter method.

public string IndexString { public get; public set; }

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.NeedToFreeIndexString Property

Non-zero if the index string must be freed by the SQLite core library.

public int NeedToFreeIndexString { public get; public se

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.OrderByConsumed Property

True if output is already ordered.

public int OrderByConsumed { public get; public set; }

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs Methods

The methods of the SQLiteIndexOutputs class are listed below. For a


complete list of SQLiteIndexOutputs class members, see the
SQLiteIndexOutputs Members topic.

Public Instance Methods


CanUseColumnsUsed Determines if the native flags field
can be used, based on the available
version of the SQLite core library.
CanUseEstimatedRows Determines if the native
estimatedRows field can be used,
based on the available version of
the SQLite core library.
CanUseIndexFlags Determines if the native flags field
can be used, based on the available
version of the SQLite core library.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.CanUseColumnsUsed Method

Determines if the native flags field can be used, based on the available
version of the SQLite core library.

public bool CanUseColumnsUsed();

Return Value
Non-zero if the ColumnsUsed property is supported by the SQLite core
library.

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.CanUseEstimatedRows Method

Determines if the native estimatedRows field can be used, based on the


available version of the SQLite core library.

public bool CanUseEstimatedRows();

Return Value
Non-zero if the EstimatedRows property is supported by the SQLite core
library.

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteIndexOutputs.CanUseIndexFlags Method

Determines if the native flags field can be used, based on the available
version of the SQLite core library.

public bool CanUseIndexFlags();

Return Value
Non-zero if the IndexFlags property is supported by the SQLite core
library.

See Also
SQLiteIndexOutputs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteInvokeDelegate Delegate

This Delegate type is used with the Invoke method.

public delegate object SQLiteInvokeDelegate(


string param0,
object[] args
);

Parameters
param0
This is always the string literal "Invoke".
args
The arguments for the scalar function.

Return Value
The result of the scalar function.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteJournalModeEnum Enumeration

This enum determines how SQLite treats its journal file.

public enum SQLiteJournalModeEnum

Remarks
By default SQLite will create and delete the journal file when needed
during a transaction. However, for some computers running certain
filesystem monitoring tools, the rapid creation and deletion of the journal
file can cause those programs to fail, or to interfere with SQLite. If a
program or virus scanner is interfering with SQLite's journal file, you may
receive errors like "unable to open database file" when starting a
transaction. If this is happening, you may want to change the default
journal mode to Persist.

Members
Member Name Description
Default The default mode, this causes
SQLite to use the existing
journaling mode for the database.
Delete SQLite will create and destroy the
journal file as-needed.
Persist When this is set, SQLite will keep
the journal file even after a
transaction has completed. It's
contents will be erased, and the
journal re-used as often as needed.
If it is deleted, it will be recreated
the next time it is needed.
Off This option disables the rollback
journal entirely. Interrupted
transactions or a program crash
can cause database corruption in
this mode!
Truncate SQLite will truncate the journal file
to zero-length instead of deleting
it.
Memory SQLite will store the journal in
volatile RAM. This saves disk I/O
but at the expense of database
safety and integrity. If the
application using SQLite crashes in
the middle of a transaction when
the MEMORY journaling mode is
set, then the database file will very
likely go corrupt.
Wal SQLite uses a write-ahead log
instead of a rollback journal to
implement transactions. The WAL
journaling mode is persistent; after
being set it stays in effect across
multiple database connections and
after closing and reopening the
database. A database in WAL
journaling mode can only be
accessed by SQLite version 3.7.0 or
later.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog Class

Manages the SQLite custom logging functionality and the associated


callback for the whole process.
For a list of all members of this type, see SQLiteLog Members .
System.Object SQLiteLog

public static class SQLiteLog

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteLog Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog Members

SQLiteLog overview

Public Static Properties


Enabled If this property is true, logging is
enabled; otherwise, logging is
disabled. When logging is disabled,
no logging events will fire.

Public Static Methods


AddDefaultHandler Adds the default log event handler
to the list of handlers.
Initialize Initializes the SQLite logging
facilities.
LogMessage Overloaded. Log a message to all
the registered log event handlers
without going through the SQLite
library.
RemoveDefaultHandler Removes the default log event
handler from the list of handlers.

Public Static Events


Log This event is raised whenever
SQLite raises a logging event. Note
that this should be set as one of
the first things in the application.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog Properties

The properties of the SQLiteLog class are listed below. For a complete list
of SQLiteLog class members, see the SQLiteLog Members topic.

Public Static Properties


Enabled If this property is true, logging is
enabled; otherwise, logging is
disabled. When logging is disabled,
no logging events will fire.

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.Enabled Property

If this property is true, logging is enabled; otherwise, logging is disabled.


When logging is disabled, no logging events will fire.

public static bool Enabled { public get; public set; }

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog Methods

The methods of the SQLiteLog class are listed below. For a complete list
of SQLiteLog class members, see the SQLiteLog Members topic.

Public Static Methods


AddDefaultHandler Adds the default log event handler
to the list of handlers.
Initialize Initializes the SQLite logging
facilities.
LogMessage Overloaded. Log a message to all
the registered log event handlers
without going through the SQLite
library.
RemoveDefaultHandler Removes the default log event
handler from the list of handlers.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.AddDefaultHandler Method

Adds the default log event handler to the list of handlers.

public static void AddDefaultHandler();

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.Initialize Method

Initializes the SQLite logging facilities.

public static void Initialize();

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.LogMessage Method

Log a message to all the registered log event handlers without going
through the SQLite library.

Overload List
Log a message to all the registered log event handlers without going
through the SQLite library.
public static void LogMessage(SQLiteErrorCode,string)
Log a message to all the registered log event handlers without going
through the SQLite library.
public static void LogMessage(int,string)
Log a message to all the registered log event handlers without going
through the SQLite library.
public static void LogMessage(string)

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.LogMessage(SQLiteErrorCode, String) Method

Log a message to all the registered log event handlers without going
through the SQLite library.

public static void LogMessage(


SQLiteErrorCode errorCode,
string message
);

Parameters
errorCode
The SQLite error code.
message
The message to be logged.

See Also
SQLiteLog Class | System.Data.SQLite Namespace | SQLiteLog.LogMessage
Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.LogMessage(Int32, String) Method

Log a message to all the registered log event handlers without going
through the SQLite library.

public static void LogMessage(


int errorCode,
string message
);

Parameters
errorCode
The integer error code.
message
The message to be logged.

See Also
SQLiteLog Class | System.Data.SQLite Namespace | SQLiteLog.LogMessage
Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.LogMessage(String) Method

Log a message to all the registered log event handlers without going
through the SQLite library.

public static void LogMessage(


string message
);

Parameters
message
The message to be logged.

See Also
SQLiteLog Class | System.Data.SQLite Namespace | SQLiteLog.LogMessage
Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.RemoveDefaultHandler Method

Removes the default log event handler from the list of handlers.

public static void RemoveDefaultHandler();

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog Events

The events of the SQLiteLog class are listed below. For a complete list of
SQLiteLog class members, see the SQLiteLog Members topic.

Public Static Events


Log This event is raised whenever
SQLite raises a logging event. Note
that this should be set as one of
the first things in the application.

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLog.Log Event

This event is raised whenever SQLite raises a logging event. Note that this
should be set as one of the first things in the application.

public static event SQLiteLogEventHandler Log;

See Also
SQLiteLog Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteLogEventHandler Delegate

Raised when a log event occurs.

public delegate void SQLiteLogEventHandler(


object sender,
LogEventArgs e
);

Parameters
sender
The current connection
e
Event arguments of the trace

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames Class

MetaDataCollections specific to SQLite


For a list of all members of this type, see SQLiteMetaDataCollectionNames
Members .
System.Object SQLiteMetaDataCollectionNames

public static class SQLiteMetaDataCollectionNames

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteMetaDataCollectionNames Members | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames Members

SQLiteMetaDataCollectionNames overview

Public Static Fields


Catalogs Returns a list of databases attached
to the connection
Columns Returns column information for the
specified table
ForeignKeys Returns foreign key information for
the given catalog
IndexColumns Returns base columns for the given
index
Indexes Returns index information for the
optionally-specified table
Tables Returns the tables in the given
catalog
Triggers Returns the triggers on the
database
ViewColumns Returns underlying column
information on the given view
Views Returns user-defined views in the
given catalog

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames Fields

The fields of the SQLiteMetaDataCollectionNames class are listed


below. For a complete list of SQLiteMetaDataCollectionNames class
members, see the SQLiteMetaDataCollectionNames Members topic.

Public Static Fields


Catalogs Returns a list of databases attached
to the connection
Columns Returns column information for the
specified table
ForeignKeys Returns foreign key information for
the given catalog
IndexColumns Returns base columns for the given
index
Indexes Returns index information for the
optionally-specified table
Tables Returns the tables in the given
catalog
Triggers Returns the triggers on the
database
ViewColumns Returns underlying column
information on the given view
Views Returns user-defined views in the
given catalog

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.Catalogs Field

Returns a list of databases attached to the connection

public static readonly string Catalogs;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.Columns Field

Returns column information for the specified table

public static readonly string Columns;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.ForeignKeys Field

Returns foreign key information for the given catalog

public static readonly string ForeignKeys;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.IndexColumns Field

Returns base columns for the given index

public static readonly string IndexColumns;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.Indexes Field

Returns index information for the optionally-specified table

public static readonly string Indexes;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.Tables Field

Returns the tables in the given catalog

public static readonly string Tables;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.Triggers Field

Returns the triggers on the database

public static readonly string Triggers;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.ViewColumns Field

Returns underlying column information on the given view

public static readonly string ViewColumns;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteMetaDataCollectionNames.Views Field

Returns user-defined views in the given catalog

public static readonly string Views;

See Also
SQLiteMetaDataCollectionNames Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule Class

This class represents a managed virtual table module implementation. It is


not sealed and must be used as the base class for any user-defined virtual
table module classes implemented in managed code.
For a list of all members of this type, see SQLiteModule Members .
System.Object SQLiteModule
SQLiteModuleNoop

public abstract class SQLiteModule :


ISQLiteManagedModule, IDisposable

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteModule Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule Members

SQLiteModule overview

Public Instance Constructors


SQLiteModule Constructor Constructs an instance of this class.

Public Instance Properties


Declared Returns non-zero if the schema for
the virtual table has been declared.
LogErrors Returns or sets a boolean value
indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptions Returns or sets a boolean value
indicating whether exceptions
caught in the xDisconnect method,
xDestroy method, and the Dispose
method should be logged using the
SQLiteLog class.
Name Returns the name of the module as
it was registered with the SQLite
core library.

Public Instance Methods


Begin This method is called in response to
the xBegin method.
BestIndex This method is called in response to
the xBestIndex method.
Close This method is called in response to
the xClose method.
Column This method is called in response to
the xColumn method.
Commit This method is called in response to
the xCommit method.
Connect This method is called in response to
the xConnect method.
Create This method is called in response to
the xCreate method.
Destroy This method is called in response to
the xDestroy method.
Disconnect This method is called in response to
the xDisconnect method.
Dispose Overloaded. Disposes of this object
instance.
Eof This method is called in response to
the xEof method.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter This method is called in response to
the xFilter method.
FindFunction This method is called in response to
the xFindFunction method.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next This method is called in response to
the xNext method.
Open This method is called in response to
the xOpen method.
Release This method is called in response to
the xRelease method.
Rename This method is called in response to
the xRename method.
Rollback This method is called in response to
the xRollback method.
RollbackTo This method is called in response to
the xRollbackTo method.
RowId This method is called in response to
the xRowId method.
Savepoint This method is called in response to
the xSavepoint method.
Sync This method is called in response to
the xSync method.
ToString (inherited from Object) Returns a String that represents
the current Object.
Update This method is called in response to
the xUpdate method.

Protected Instance Properties


LogErrorsNoThrow Returns or sets a boolean value
indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptionsNoThrow Returns or sets a boolean value
indicating whether exceptions
caught in the xDisconnect method,
the xDestroy method, the
SetTableError method, the
SetTableError method, and the
Dispose method should be logged
using the SQLiteLog class.

Protected Instance Methods


AllocateCursor Allocates a native
sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable Allocates a native sqlite3_vtab
derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorFromIntPtr Looks up and returns the
SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr Allocates and returns a native
pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
DeclareFunction Calls the native SQLite core library
in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable Attempts to declare the schema for
the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize Finalizes this object instance.
FreeCursor Frees a native sqlite3_vtab_cursor
structure using the provided native
pointer to it.
FreeTable Frees a native sqlite3_vtab
structure using the provided native
pointer to it.
GetFunctionKey Deterimines the key that should be
used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetNativeModuleImpl Gets and returns the
ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.

MemberwiseClone (inherited from Creates a shallow copy of the


Object) current Object.
SetCursorError Arranges for the specified error
message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost Overloaded. Modifies the specified
SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows Overloaded. Modifies the specified
SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags Overloaded.
SetTableError Overloaded. Arranges for the
specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor Reads and returns the native
pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr Looks up and returns the
SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr Allocates and returns a native
pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.

ZeroTable Zeros out the fields of a native


sqlite3_vtab derived structure.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule Constructor

Constructs an instance of this class.

SQLiteModule(
string name
);

Parameters
name
The name of the module. This parameter cannot be null.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule Properties

The properties of the SQLiteModule class are listed below. For a complete
list of SQLiteModule class members, see the SQLiteModule Members
topic.

Public Instance Properties


Declared Returns non-zero if the schema for
the virtual table has been declared.
LogErrors Returns or sets a boolean value
indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptions Returns or sets a boolean value
indicating whether exceptions
caught in the xDisconnect method,
xDestroy method, and the Dispose
method should be logged using the
SQLiteLog class.
Name Returns the name of the module as
it was registered with the SQLite
core library.

Protected Instance Properties


LogErrorsNoThrow Returns or sets a boolean value
indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptionsNoThrow Returns or sets a boolean value
indicating whether exceptions
caught in the xDisconnect method,
the xDestroy method, the
SetTableError method, the
SetTableError method, and the
Dispose method should be logged
using the SQLiteLog class.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Declared Property

Returns non-zero if the schema for the virtual table has been declared.

public virtual bool Declared { public get; internal set;

Implements
ISQLiteManagedModule.Declared

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.LogErrors Property

Returns or sets a boolean value indicating whether virtual table errors


should be logged using the SQLiteLog class.

public virtual bool LogErrors { public get; public set;

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.LogErrorsNoThrow Property

Returns or sets a boolean value indicating whether virtual table errors


should be logged using the SQLiteLog class.

protected virtual bool LogErrorsNoThrow { protected get;

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.LogExceptions Property

Returns or sets a boolean value indicating whether exceptions caught in


the xDisconnect method, xDestroy method, and the Dispose method
should be logged using the SQLiteLog class.

public virtual bool LogExceptions { public get; public s

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.LogExceptionsNoThrow Property

Returns or sets a boolean value indicating whether exceptions caught in


the xDisconnect method, the xDestroy method, the SetTableError method,
the SetTableError method, and the Dispose method should be logged using
the SQLiteLog class.

protected virtual bool LogExceptionsNoThrow { protected

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Name Property

Returns the name of the module as it was registered with the SQLite core
library.

public virtual string Name { public get; }

Implements
ISQLiteManagedModule.Name

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule Methods

The methods of the SQLiteModule class are listed below. For a complete
list of SQLiteModule class members, see the SQLiteModule Members
topic.

Public Instance Methods


Begin This method is called in response to
the xBegin method.
BestIndex This method is called in response to
the xBestIndex method.
Close This method is called in response to
the xClose method.
Column This method is called in response to
the xColumn method.
Commit This method is called in response to
the xCommit method.
Connect This method is called in response to
the xConnect method.
Create This method is called in response to
the xCreate method.
Destroy This method is called in response to
the xDestroy method.
Disconnect This method is called in response to
the xDisconnect method.
Dispose Overloaded. Disposes of this object
instance.
Eof This method is called in response to
the xEof method.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter This method is called in response to
the xFilter method.
FindFunction This method is called in response to
the xFindFunction method.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next This method is called in response to
the xNext method.
Open This method is called in response to
the xOpen method.
Release This method is called in response to
the xRelease method.
Rename This method is called in response to
the xRename method.
Rollback This method is called in response to
the xRollback method.
RollbackTo This method is called in response to
the xRollbackTo method.
RowId This method is called in response to
the xRowId method.
Savepoint This method is called in response to
the xSavepoint method.
Sync This method is called in response to
the xSync method.
ToString (inherited from Object) Returns a String that represents
the current Object.
Update This method is called in response to
the xUpdate method.

Protected Instance Methods


AllocateCursor Allocates a native
sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable Allocates a native sqlite3_vtab
derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorFromIntPtr Looks up and returns the
SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr Allocates and returns a native
pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
DeclareFunction Calls the native SQLite core library
in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable Attempts to declare the schema for
the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize Finalizes this object instance.
FreeCursor Frees a native sqlite3_vtab_cursor
structure using the provided native
pointer to it.
FreeTable Frees a native sqlite3_vtab
structure using the provided native
pointer to it.
GetFunctionKey Deterimines the key that should be
used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).

GetNativeModuleImpl Gets and returns the


ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
SetCursorError Arranges for the specified error
message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost Overloaded. Modifies the specified
SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows Overloaded. Modifies the specified
SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags Overloaded.
SetTableError Overloaded. Arranges for the
specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor Reads and returns the native
pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr Looks up and returns the
SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr Allocates and returns a native
pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable Zeros out the fields of a native
sqlite3_vtab derived structure.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.AllocateCursor Method

Allocates a native sqlite3_vtab_cursor derived structure and returns a


native pointer to it.

protected virtual IntPtr AllocateCursor();

Return Value
A native pointer to a native sqlite3_vtab_cursor derived structure.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.AllocateTable Method

Allocates a native sqlite3_vtab derived structure and returns a native


pointer to it.

protected virtual IntPtr AllocateTable();

Return Value
A native pointer to a native sqlite3_vtab derived structure.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Begin Method

This method is called in response to the xBegin method.

public abstract SQLiteErrorCode Begin(


SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Begin

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.BestIndex Method

This method is called in response to the xBestIndex method.

public abstract SQLiteErrorCode BestIndex(


SQLiteVirtualTable table,
SQLiteIndex index
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
index
The SQLiteIndex object instance containing all the data for the inputs
and outputs relating to index selection.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.BestIndex

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Close Method

This method is called in response to the xClose method.

public abstract SQLiteErrorCode Close(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Close

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Column Method

This method is called in response to the xColumn method.

public abstract SQLiteErrorCode Column(


SQLiteVirtualTableCursor cursor,
SQLiteContext context,
int index
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
context
The SQLiteContext object instance to be used for returning the
specified column value to the SQLite core library.
index
The zero-based index corresponding to the column containing the value
to be returned.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Column

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Commit Method

This method is called in response to the xCommit method.

public abstract SQLiteErrorCode Commit(


SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Commit

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Connect Method

This method is called in response to the xConnect method.

public abstract SQLiteErrorCode Connect(


SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
The SQLiteConnection object instance associated with the virtual table.
pClientData
The native user-data pointer associated with this module, as it was
provided to the SQLite core library when the native module instance
was created.
arguments
The module name, database name, virtual table name, and all other
arguments passed to the CREATE VIRTUAL TABLE statement.
table
Upon success, this parameter must be modified to contain the
SQLiteVirtualTable object instance associated with the virtual table.
error
Upon failure, this parameter must be modified to contain an error
message.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Connect

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Create Method

This method is called in response to the xCreate method.

public abstract SQLiteErrorCode Create(


SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
The SQLiteConnection object instance associated with the virtual table.
pClientData
The native user-data pointer associated with this module, as it was
provided to the SQLite core library when the native module instance
was created.
arguments
The module name, database name, virtual table name, and all other
arguments passed to the CREATE VIRTUAL TABLE statement.
table
Upon success, this parameter must be modified to contain the
SQLiteVirtualTable object instance associated with the virtual table.
error
Upon failure, this parameter must be modified to contain an error
message.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Create

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.CreateNativeModuleImpl Method

Creates and returns the ISQLiteNativeModule interface implementation


corresponding to the current SQLiteModule object instance.

protected virtual ISQLiteNativeModule CreateNativeModule

Return Value
The ISQLiteNativeModule interface implementation corresponding to the
current SQLiteModule object instance.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.CursorFromIntPtr Method

Looks up and returns the SQLiteVirtualTableCursor object instance based


on the native pointer to the sqlite3_vtab_cursor derived structure.

protected virtual SQLiteVirtualTableCursor CursorFromInt


IntPtr pVtab,
IntPtr pCursor
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure.

Return Value
The SQLiteVirtualTableCursor object instance or null if the corresponding
one cannot be found.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.CursorToIntPtr Method

Allocates and returns a native pointer to a sqlite3_vtab_cursor derived


structure and creates an association between it and the specified
SQLiteVirtualTableCursor object instance.

protected virtual IntPtr CursorToIntPtr(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance to be used when creating
the association.

Return Value
The native pointer to a sqlite3_vtab_cursor derived structure or Zero if the
method fails for any reason.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.DeclareFunction Method

Calls the native SQLite core library in order to declare a virtual table
function in response to a call into the xCreate or xConnect virtual table
methods.

protected virtual SQLiteErrorCode DeclareFunction(


SQLiteConnection connection,
int argumentCount,
string name,
ref string error
);

Parameters
connection
The SQLiteConnection object instance to use when declaring the
schema of the virtual table.
argumentCount
The number of arguments to the function being declared.
name
The name of the function being declared.
error
Upon success, the contents of this parameter are undefined. Upon
failure, it should contain an appropriate error message.

Return Value
A standard SQLite return code.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.DeclareTable Method

Attempts to declare the schema for the virtual table using the specified
database connection.

protected virtual SQLiteErrorCode DeclareTable(


SQLiteConnection connection,
string sql,
ref string error
);

Parameters
connection
The SQLiteConnection object instance to use when declaring the
schema of the virtual table. This parameter may not be null.
sql
The string containing the CREATE TABLE statement that completely
describes the schema for the virtual table. This parameter may not be
null.
error
Upon failure, this parameter must be modified to contain an error
message.

Return Value
A standard SQLite return code.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Destroy Method

This method is called in response to the xDestroy method.

public abstract SQLiteErrorCode Destroy(


SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Destroy

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Disconnect Method

This method is called in response to the xDisconnect method.

public abstract SQLiteErrorCode Disconnect(


SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Disconnect

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Dispose Method

Disposes of this object instance.

Overload List
Disposes of this object instance.
public void Dispose()
Disposes of this object instance.
protected virtual void Dispose(bool)

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Dispose() Method

Disposes of this object instance.

public void Dispose();

Implements
IDisposable.Dispose

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Dispose(Boolean) Method

Disposes of this object instance.

protected virtual void Dispose(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Eof Method

This method is called in response to the xEof method.

public abstract bool Eof(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.

Return Value
Non-zero if no more rows are available; zero otherwise.

Implements
ISQLiteManagedModule.Eof

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Filter Method

This method is called in response to the xFilter method.

public abstract SQLiteErrorCode Filter(


SQLiteVirtualTableCursor cursor,
int indexNumber,
string indexString,
SQLiteValue[] values
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
indexNumber
Number used to help identify the selected index.
indexString
String used to help identify the selected index.
values
The values corresponding to each column in the selected index.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Filter

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Finalize Method

Finalizes this object instance.

protected override void Finalize();

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.FindFunction Method

This method is called in response to the xFindFunction method.

public abstract bool FindFunction(


SQLiteVirtualTable table,
int argumentCount,
string name,
ref SQLiteFunction function,
ref IntPtr pClientData
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
argumentCount
The number of arguments to the function being sought.
name
The name of the function being sought.
function
Upon success, this parameter must be modified to contain the
SQLiteFunction object instance responsible for implementing the
specified function.
pClientData
Upon success, this parameter must be modified to contain the native
user-data pointer associated with function.

Return Value
Non-zero if the specified function was found; zero otherwise.

Implements
ISQLiteManagedModule.FindFunction

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.FreeCursor Method

Frees a native sqlite3_vtab_cursor structure using the provided native


pointer to it.

protected virtual void FreeCursor(


IntPtr pCursor
);

Parameters
pCursor
A native pointer to a native sqlite3_vtab_cursor derived structure.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.FreeTable Method

Frees a native sqlite3_vtab structure using the provided native pointer to


it.

protected virtual void FreeTable(


IntPtr pVtab
);

Parameters
pVtab
A native pointer to a native sqlite3_vtab derived structure.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.GetFunctionKey Method

Deterimines the key that should be used to identify and store the
SQLiteFunction object instance for the virtual table (i.e. to be returned via
the xFindFunction method).

protected virtual string GetFunctionKey(


int argumentCount,
string name,
SQLiteFunction function
);

Parameters
argumentCount
The number of arguments to the virtual table function.
name
The name of the virtual table function.
function
The SQLiteFunction object instance associated with this virtual table
function.

Return Value
The string that should be used to identify and store the virtual table
function instance. This method cannot return null. If null is returned from
this method, the behavior is undefined.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.GetNativeModuleImpl Method

Gets and returns the ISQLiteNativeModule interface implementation to be


used when creating the native sqlite3_module structure. Derived classes
may override this method to supply an alternate implementation for the
ISQLiteNativeModule interface.

protected virtual ISQLiteNativeModule GetNativeModuleImp

Return Value
The ISQLiteNativeModule interface implementation to be used when
populating the native sqlite3_module structure. If the returned value is
null, the private methods provided by the SQLiteModule class and relating
to the ISQLiteNativeModule interface will be used to create the
necessary delegates.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Next Method

This method is called in response to the xNext method.

public abstract SQLiteErrorCode Next(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Next

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Open Method

This method is called in response to the xOpen method.

public abstract SQLiteErrorCode Open(


SQLiteVirtualTable table,
ref SQLiteVirtualTableCursor cursor
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
cursor
Upon success, this parameter must be modified to contain the
SQLiteVirtualTableCursor object instance associated with the newly
opened virtual table cursor.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Open

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Release Method

This method is called in response to the xRelease method.

public abstract SQLiteErrorCode Release(


SQLiteVirtualTable table,
int savepoint
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
savepoint
This is an integer used to indicate that any saved states with an
identifier greater than or equal to this should be deleted by the virtual
table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Release

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Rename Method

This method is called in response to the xRename method.

public abstract SQLiteErrorCode Rename(


SQLiteVirtualTable table,
string newName
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
newName
The new name for the virtual table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Rename

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Rollback Method

This method is called in response to the xRollback method.

public abstract SQLiteErrorCode Rollback(


SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Rollback

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.RollbackTo Method

This method is called in response to the xRollbackTo method.

public abstract SQLiteErrorCode RollbackTo(


SQLiteVirtualTable table,
int savepoint
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
savepoint
This is an integer identifier used to specify a specific saved state for the
virtual table for it to restore itself back to, which should also have the
effect of deleting all saved states with an integer identifier greater than
this one.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.RollbackTo

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.RowId Method

This method is called in response to the xRowId method.

public abstract SQLiteErrorCode RowId(


SQLiteVirtualTableCursor cursor,
ref long rowId
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
rowId
Upon success, this parameter must be modified to contain the unique
integer row identifier for the current row for the specified cursor.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.RowId

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Savepoint Method

This method is called in response to the xSavepoint method.

public abstract SQLiteErrorCode Savepoint(


SQLiteVirtualTable table,
int savepoint
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
savepoint
This is an integer identifier under which the the current state of the
virtual table should be saved.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Savepoint

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetCursorError Method

Arranges for the specified error message to be placed into the zErrMsg
field of a sqlite3_vtab derived structure, freeing the existing error
message, if any.

protected virtual bool SetCursorError(


SQLiteVirtualTableCursor cursor,
string error
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance used to lookup the native
pointer to the sqlite3_vtab derived structure.
error
The error message.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetEstimatedCost Method

Modifies the specified SQLiteIndex object instance to contain the default


estimated cost.

Overload List
Modifies the specified SQLiteIndex object instance to contain the default
estimated cost.
protected virtual bool SetEstimatedCost(SQLiteIndex)
Modifies the specified SQLiteIndex object instance to contain the specified
estimated cost.
protected virtual bool SetEstimatedCost(SQLiteIndex,double?)

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetEstimatedCost(SQLiteIndex) Method

Modifies the specified SQLiteIndex object instance to contain the default


estimated cost.

protected virtual bool SetEstimatedCost(


SQLiteIndex index
);

Parameters
index
The SQLiteIndex object instance to modify.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetEstimatedCost Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetEstimatedCost(SQLiteIndex, Double)
Method

Modifies the specified SQLiteIndex object instance to contain the specified


estimated cost.

protected virtual bool SetEstimatedCost(


SQLiteIndex index,
double? estimatedCost
);

Parameters
index
The SQLiteIndex object instance to modify.
estimatedCost
The estimated cost value to use. Using a null value means that the
default value provided by the SQLite core library should be used.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetEstimatedCost Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetEstimatedRows Method

Modifies the specified SQLiteIndex object instance to contain the default


estimated rows.

Overload List
Modifies the specified SQLiteIndex object instance to contain the default
estimated rows.
protected virtual bool SetEstimatedRows(SQLiteIndex)
Modifies the specified SQLiteIndex object instance to contain the specified
estimated rows.
protected virtual bool SetEstimatedRows(SQLiteIndex,long?)

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetEstimatedRows(SQLiteIndex) Method

Modifies the specified SQLiteIndex object instance to contain the default


estimated rows.

protected virtual bool SetEstimatedRows(


SQLiteIndex index
);

Parameters
index
The SQLiteIndex object instance to modify.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetEstimatedRows Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetEstimatedRows(SQLiteIndex, Int64)
Method

Modifies the specified SQLiteIndex object instance to contain the specified


estimated rows.

protected virtual bool SetEstimatedRows(


SQLiteIndex index,
long? estimatedRows
);

Parameters
index
The SQLiteIndex object instance to modify.
estimatedRows
The estimated rows value to use. Using a null value means that the
default value provided by the SQLite core library should be used.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetEstimatedRows Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetIndexFlags Method

Modifies the specified SQLiteIndex object instance to contain the default


index flags.

Overload List
Modifies the specified SQLiteIndex object instance to contain the default
index flags.
protected virtual bool SetIndexFlags(SQLiteIndex)
protected virtual bool SetIndexFlags(SQLiteIndex,SQLiteIndexFlags?)

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetIndexFlags(SQLiteIndex) Method

Modifies the specified SQLiteIndex object instance to contain the default


index flags.

protected virtual bool SetIndexFlags(


SQLiteIndex index
);

Parameters
index
The SQLiteIndex object instance to modify.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetIndexFlags Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetIndexFlags(SQLiteIndex,
SQLiteIndexFlags) Method

protected virtual bool SetIndexFlags(


SQLiteIndex index,
SQLiteIndexFlags? indexFlags
);

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetIndexFlags Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetTableError Method

Arranges for the specified error message to be placed into the zErrMsg
field of a sqlite3_vtab derived structure, freeing the existing error
message, if any.

Overload List
Arranges for the specified error message to be placed into the zErrMsg
field of a sqlite3_vtab derived structure, freeing the existing error
message, if any.
protected virtual bool SetTableError(SQLiteVirtualTable,string)
Arranges for the specified error message to be placed into the zErrMsg
field of a sqlite3_vtab derived structure, freeing the existing error
message, if any.
protected virtual bool SetTableError(IntPtr,string)

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetTableError(SQLiteVirtualTable, String)
Method

Arranges for the specified error message to be placed into the zErrMsg
field of a sqlite3_vtab derived structure, freeing the existing error
message, if any.

protected virtual bool SetTableError(


SQLiteVirtualTable table,
string error
);

Parameters
table
The SQLiteVirtualTable object instance used to lookup the native
pointer to the sqlite3_vtab derived structure.
error
The error message.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetTableError Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.SetTableError(IntPtr, String) Method

Arranges for the specified error message to be placed into the zErrMsg
field of a sqlite3_vtab derived structure, freeing the existing error
message, if any.

protected virtual bool SetTableError(


IntPtr pVtab,
string error
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.
error
The error message.

Return Value
Non-zero upon success.

See Also
SQLiteModule Class | System.Data.SQLite Namespace |
SQLiteModule.SetTableError Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Sync Method

This method is called in response to the xSync method.

public abstract SQLiteErrorCode Sync(


SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Sync

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.TableFromCursor Method

Reads and returns the native pointer to the sqlite3_vtab derived structure
based on the native pointer to the sqlite3_vtab_cursor derived structure.

protected virtual IntPtr TableFromCursor(


IntPtr pCursor
);

Parameters
pCursor
The native pointer to the sqlite3_vtab_cursor derived structure from
which to read the native pointer to the sqlite3_vtab derived structure.

Return Value
The native pointer to the sqlite3_vtab derived structure -OR- Zero if it
cannot be determined.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.TableFromIntPtr Method

Looks up and returns the SQLiteVirtualTable object instance based on the


native pointer to the sqlite3_vtab derived structure.

protected virtual SQLiteVirtualTable TableFromIntPtr(


IntPtr pVtab
);

Parameters
pVtab
The native pointer to the sqlite3_vtab derived structure.

Return Value
The SQLiteVirtualTable object instance or null if the corresponding one
cannot be found.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.TableToIntPtr Method

Allocates and returns a native pointer to a sqlite3_vtab derived structure


and creates an association between it and the specified SQLiteVirtualTable
object instance.

protected virtual IntPtr TableToIntPtr(


SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance to be used when creating the
association.

Return Value
The native pointer to a sqlite3_vtab derived structure or Zero if the
method fails for any reason.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.Update Method

This method is called in response to the xUpdate method.

public abstract SQLiteErrorCode Update(


SQLiteVirtualTable table,
SQLiteValue[] values,
ref long rowId
);

Parameters
table
The SQLiteVirtualTable object instance associated with this virtual
table.
values
The array of SQLiteValue object instances containing the new or
modified column values, if any.
rowId
Upon success, this parameter must be modified to contain the unique
integer row identifier for the row that was inserted, if any.

Return Value
A standard SQLite return code.

Implements
ISQLiteManagedModule.Update

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModule.ZeroTable Method

Zeros out the fields of a native sqlite3_vtab derived structure.

protected virtual void ZeroTable(


IntPtr pVtab
);

Parameters
pVtab
The native pointer to the native sqlite3_vtab derived structure to zero.

See Also
SQLiteModule Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon Class

This class contains some virtual methods that may be useful for other
virtual table classes. It specifically does NOT implement any of the
ISQLiteManagedModule interface methods.
For a list of all members of this type, see SQLiteModuleCommon Members .
System.Object SQLiteModule
SQLiteModuleNoop
SQLiteModuleCommon
SQLiteModuleEnumerable

public class SQLiteModuleCommon : SQLiteModuleNoop

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteModuleCommon Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon Members

SQLiteModuleCommon overview

Public Instance Constructors


SQLiteModuleCommon Overloaded. Initializes a new
instance of the
SQLiteModuleCommon class.

Public Instance Properties


Declared (inherited from Returns non-zero if the schema for
SQLiteModule) the virtual table has been declared.
LogErrors (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptions (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
xDestroy method, and the Dispose
method should be logged using the
SQLiteLog class.
Name (inherited from Returns the name of the module as
SQLiteModule) it was registered with the SQLite
core library.

Public Instance Methods


Begin (inherited from See the Begin method.
SQLiteModuleNoop)
BestIndex (inherited from See the BestIndex method.
SQLiteModuleNoop)
Close (inherited from See the Close method.
SQLiteModuleNoop)
Column (inherited from See the Column method.
SQLiteModuleNoop)
Commit (inherited from See the Commit method.
SQLiteModuleNoop)
Connect (inherited from See the Connect method.
SQLiteModuleNoop)
Create (inherited from See the Create method.
SQLiteModuleNoop)
Destroy (inherited from See the Destroy method.
SQLiteModuleNoop)
Disconnect (inherited from See the Disconnect method.
SQLiteModuleNoop)
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof (inherited from See the Eof method.
SQLiteModuleNoop)
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter (inherited from See the Filter method.
SQLiteModuleNoop)
FindFunction (inherited from See the FindFunction method.
SQLiteModuleNoop)
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next (inherited from See the Next method.
SQLiteModuleNoop)
Open (inherited from See the Open method.
SQLiteModuleNoop)
Release (inherited from See the Release method.
SQLiteModuleNoop)
Rename (inherited from See the Rename method.
SQLiteModuleNoop)
Rollback (inherited from See the Rollback method.
SQLiteModuleNoop)
RollbackTo (inherited from See the RollbackTo method.
SQLiteModuleNoop)
RowId (inherited from See the RowId method.
SQLiteModuleNoop)
Savepoint (inherited from See the Savepoint method.
SQLiteModuleNoop)
Sync (inherited from See the Sync method.
SQLiteModuleNoop)
ToString (inherited from Object) Returns a String that represents
the current Object.
Update (inherited from See the Update method.
SQLiteModuleNoop)

Protected Instance Properties


LogErrorsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptionsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
the xDestroy method, the
SetTableError method, the
SetTableError method, and the
Dispose method should be logged
using the SQLiteLog class.

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
CursorTypeMismatchError Sets the table error message to one
that indicates the virtual table
cursor is of the wrong type.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.
FreeTable (inherited from Frees a native sqlite3_vtab
SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode (inherited Determines the default
from SQLiteModuleNoop) SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetMethodResultCode (inherited Determines the SQLiteErrorCode
from SQLiteModuleNoop) value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is available
(or set) for the specified method,
the SQLiteErrorCode value
returned by the
GetDefaultResultCode method will
be returned instead.
GetNativeModuleImpl (inherited Gets and returns the
from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
GetRowIdFromObject Determines the unique row
identifier for the current row.
GetSqlForDeclareTable Determines the SQL statement
used to declare the virtual table.
This method should be overridden
in derived classes if they require a
custom virtual table schema.
GetStringFromObject Determines the string to return as
the column value for the object
instance value.

MakeRowId Constructs an Int64 unique row


identifier from two Int32 values.
The first Int32 value must contain
the row sequence number for the
current row and the second value
must contain the hash code of the
key column value for the current
row.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
ResultCodeToEofResult (inherited Converts a SQLiteErrorCode value
from SQLiteModuleNoop) into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
(inherited from into a boolean return value for use
SQLiteModuleNoop) with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode (inherited Sets the SQLiteErrorCode value
from SQLiteModuleNoop) that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.

SetTableError (inherited from Overloaded. Arranges for the


SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor (inherited from Reads and returns the native
SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon Constructor

Constructs an instance of this class.

Overload List
Constructs an instance of this class.
public SQLiteModuleCommon(string)
Constructs an instance of this class.
public SQLiteModuleCommon(string,bool)

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon Constructor

Constructs an instance of this class.

SQLiteModuleCommon(
string name
);

Parameters
name
The name of the module. This parameter cannot be null.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace |
SQLiteModuleCommon Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon Constructor

Constructs an instance of this class.

SQLiteModuleCommon(
string name,
bool objectIdentity
);

Parameters
name
The name of the module. This parameter cannot be null.
objectIdentity
Non-zero if different object instances with the same value should
generate different row identifiers, where applicable. This parameter has
no effect on the .NET Compact Framework.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace |
SQLiteModuleCommon Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon Methods

The methods of the SQLiteModuleCommon class are listed below. For a


complete list of SQLiteModuleCommon class members, see the
SQLiteModuleCommon Members topic.

Public Instance Methods


Begin (inherited from See the Begin method.
SQLiteModuleNoop)
BestIndex (inherited from See the BestIndex method.
SQLiteModuleNoop)
Close (inherited from See the Close method.
SQLiteModuleNoop)
Column (inherited from See the Column method.
SQLiteModuleNoop)
Commit (inherited from See the Commit method.
SQLiteModuleNoop)
Connect (inherited from See the Connect method.
SQLiteModuleNoop)
Create (inherited from See the Create method.
SQLiteModuleNoop)
Destroy (inherited from See the Destroy method.
SQLiteModuleNoop)
Disconnect (inherited from See the Disconnect method.
SQLiteModuleNoop)
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof (inherited from See the Eof method.
SQLiteModuleNoop)
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter (inherited from See the Filter method.
SQLiteModuleNoop)
FindFunction (inherited from See the FindFunction method.
SQLiteModuleNoop)
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next (inherited from See the Next method.
SQLiteModuleNoop)
Open (inherited from See the Open method.
SQLiteModuleNoop)
Release (inherited from See the Release method.
SQLiteModuleNoop)
Rename (inherited from See the Rename method.
SQLiteModuleNoop)
Rollback (inherited from See the Rollback method.
SQLiteModuleNoop)
RollbackTo (inherited from See the RollbackTo method.
SQLiteModuleNoop)
RowId (inherited from See the RowId method.
SQLiteModuleNoop)
Savepoint (inherited from See the Savepoint method.
SQLiteModuleNoop)
Sync (inherited from See the Sync method.
SQLiteModuleNoop)
ToString (inherited from Object) Returns a String that represents
the current Object.
Update (inherited from See the Update method.
SQLiteModuleNoop)

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
CursorTypeMismatchError Sets the table error message to one
that indicates the virtual table
cursor is of the wrong type.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.

FreeTable (inherited from Frees a native sqlite3_vtab


SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode (inherited Determines the default
from SQLiteModuleNoop) SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetMethodResultCode (inherited Determines the SQLiteErrorCode
from SQLiteModuleNoop) value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is available
(or set) for the specified method,
the SQLiteErrorCode value
returned by the
GetDefaultResultCode method will
be returned instead.
GetNativeModuleImpl (inherited Gets and returns the
from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
GetRowIdFromObject Determines the unique row
identifier for the current row.
GetSqlForDeclareTable Determines the SQL statement
used to declare the virtual table.
This method should be overridden
in derived classes if they require a
custom virtual table schema.

GetStringFromObject Determines the string to return as


the column value for the object
instance value.
MakeRowId Constructs an Int64 unique row
identifier from two Int32 values.
The first Int32 value must contain
the row sequence number for the
current row and the second value
must contain the hash code of the
key column value for the current
row.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
ResultCodeToEofResult (inherited Converts a SQLiteErrorCode value
from SQLiteModuleNoop) into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
(inherited from into a boolean return value for use
SQLiteModuleNoop) with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode (inherited Sets the SQLiteErrorCode value
from SQLiteModuleNoop) that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.
SetTableError (inherited from Overloaded. Arranges for the
SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor (inherited from Reads and returns the native
SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon.CursorTypeMismatchError Method

Sets the table error message to one that indicates the virtual table cursor
is of the wrong type.

protected virtual SQLiteErrorCode CursorTypeMismatchErro


SQLiteVirtualTableCursor cursor,
Type type
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance.
type
The Type that the virtual table cursor should be.

Return Value
The value of Error.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon.Dispose Method

Disposes of this object instance.

Overload List
Inherited from SQLiteModule.
public void Dispose()
Disposes of this object instance.
protected override void Dispose(bool)

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon.Dispose(Boolean) Method

Disposes of this object instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace |
SQLiteModuleCommon.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon.GetRowIdFromObject Method

Determines the unique row identifier for the current row.

protected virtual long GetRowIdFromObject(


SQLiteVirtualTableCursor cursor,
object value
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
value
The object instance to return a unique row identifier for.

Return Value
The unique row identifier or zero upon failure.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon.GetSqlForDeclareTable Method

Determines the SQL statement used to declare the virtual table. This
method should be overridden in derived classes if they require a custom
virtual table schema.

protected virtual string GetSqlForDeclareTable();

Return Value
The SQL statement used to declare the virtual table -OR- null if it cannot
be determined.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon.GetStringFromObject Method

Determines the string to return as the column value for the object
instance value.

protected virtual string GetStringFromObject(


SQLiteVirtualTableCursor cursor,
object value
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance associated with the
previously opened virtual table cursor to be used.
value
The object instance to return a string representation for.

Return Value
The string representation of the specified object instance or null upon
failure.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleCommon.MakeRowId Method

Constructs an Int64 unique row identifier from two Int32 values. The first
Int32 value must contain the row sequence number for the current row
and the second value must contain the hash code of the key column value
for the current row.

protected virtual long MakeRowId(


int rowIndex,
int hashCode
);

Parameters
rowIndex
The integer row sequence number for the current row.
hashCode
The hash code of the key column value for the current row.

Return Value
The unique row identifier or zero upon failure.

See Also
SQLiteModuleCommon Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable Class

This class implements a virtual table module that exposes an IEnumerable


object instance as a read-only virtual table. It is not sealed and may be
used as the base class for any user-defined virtual table class that wraps
an IEnumerable object instance. The following short example shows it
being used to treat an array of strings as a table data source:
public static class Sample
{
public static void Main()
{
using (SQLiteConnection connection = new SQLiteConnection(
"Data Source=:memory:;"))
{
connection.Open();

connection.CreateModule(new SQLiteModuleEnumerable(
"sampleModule", new string[] { "one", "two", "three" })

using (SQLiteCommand command = connection.CreateCommand()


{
command.CommandText =
"CREATE VIRTUAL TABLE t1 USING sampleModule;";

command.ExecuteNonQuery();
}

using (SQLiteCommand command = connection.CreateCommand()


{
command.CommandText = "SELECT * FROM t1;";

using (SQLiteDataReader dataReader = command.ExecuteRea


{
while (dataReader.Read())
Console.WriteLine(dataReader[0].ToString());
}
}

connection.Close();
}
}
}
For a list of all members of this type, see SQLiteModuleEnumerable
Members .
System.Object SQLiteModule
SQLiteModuleNoop
SQLiteModuleCommon
SQLiteModuleEnumerable
SQLiteModuleEnumerable(T)

public class SQLiteModuleEnumerable :


SQLiteModuleCommon

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteModuleEnumerable Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable Members

SQLiteModuleEnumerable overview

Public Instance Constructors


SQLiteModuleEnumerable Overloaded. Initializes a new
instance of the
SQLiteModuleEnumerable class.

Public Instance Properties


Declared (inherited from Returns non-zero if the schema for
SQLiteModule) the virtual table has been declared.
LogErrors (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptions (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
xDestroy method, and the Dispose
method should be logged using the
SQLiteLog class.
Name (inherited from Returns the name of the module as
SQLiteModule) it was registered with the SQLite
core library.

Public Instance Methods


Begin (inherited from See the Begin method.
SQLiteModuleNoop)
BestIndex See the BestIndex method.
Close See the Close method.
Column See the Column method.
Commit (inherited from See the Commit method.
SQLiteModuleNoop)
Connect See the Connect method.
Create See the Create method.
Destroy See the Destroy method.
Disconnect See the Disconnect method.
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof See the Eof method.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter See the Filter method.
FindFunction (inherited from See the FindFunction method.
SQLiteModuleNoop)
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next See the Next method.
Open See the Open method.
Release (inherited from See the Release method.
SQLiteModuleNoop)
Rename See the Rename method.
Rollback (inherited from See the Rollback method.
SQLiteModuleNoop)
RollbackTo (inherited from See the RollbackTo method.
SQLiteModuleNoop)
RowId See the RowId method.
Savepoint (inherited from See the Savepoint method.
SQLiteModuleNoop)
Sync (inherited from See the Sync method.
SQLiteModuleNoop)
ToString (inherited from Object) Returns a String that represents
the current Object.

Update See the Update method.

Protected Instance Properties


LogErrorsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptionsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
the xDestroy method, the
SetTableError method, the
SetTableError method, and the
Dispose method should be logged
using the SQLiteLog class.

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorEndOfEnumeratorError Sets the table error message to one
that indicates the virtual table
cursor has no current row.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
CursorTypeMismatchError Sets the table error message to one
(inherited from that indicates the virtual table
SQLiteModuleCommon) cursor is of the wrong type.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.
FreeTable (inherited from Frees a native sqlite3_vtab
SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode (inherited Determines the default
from SQLiteModuleNoop) SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).

GetMethodResultCode (inherited Determines the SQLiteErrorCode


from SQLiteModuleNoop) value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is available
(or set) for the specified method,
the SQLiteErrorCode value
returned by the
GetDefaultResultCode method will
be returned instead.
GetNativeModuleImpl (inherited Gets and returns the
from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
GetRowIdFromObject (inherited Determines the unique row
from SQLiteModuleCommon) identifier for the current row.
GetSqlForDeclareTable (inherited Determines the SQL statement
from SQLiteModuleCommon) used to declare the virtual table.
This method should be overridden
in derived classes if they require a
custom virtual table schema.
GetStringFromObject (inherited Determines the string to return as
from SQLiteModuleCommon) the column value for the object
instance value.
MakeRowId (inherited from Constructs an Int64 unique row
SQLiteModuleCommon) identifier from two Int32 values.
The first Int32 value must contain
the row sequence number for the
current row and the second value
must contain the hash code of the
key column value for the current
row.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
ResultCodeToEofResult (inherited Converts a SQLiteErrorCode value
from SQLiteModuleNoop) into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
(inherited from into a boolean return value for use
SQLiteModuleNoop) with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode (inherited Sets the SQLiteErrorCode value
from SQLiteModuleNoop) that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.
SetTableError (inherited from Overloaded. Arranges for the
SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor (inherited from Reads and returns the native
SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.

TableFromIntPtr (inherited from Looks up and returns the


SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable Constructor

Constructs an instance of this class.

Overload List
Constructs an instance of this class.
public SQLiteModuleEnumerable(string,IEnumerable)
Constructs an instance of this class.
public SQLiteModuleEnumerable(string,IEnumerable,bool)

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable Constructor

Constructs an instance of this class.

SQLiteModuleEnumerable(
string name,
IEnumerable enumerable
);

Parameters
name
The name of the module. This parameter cannot be null.
enumerable
The IEnumerable instance to expose as a virtual table. This parameter
cannot be null.

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace |
SQLiteModuleEnumerable Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable Constructor

Constructs an instance of this class.

SQLiteModuleEnumerable(
string name,
IEnumerable enumerable,
bool objectIdentity
);

Parameters
name
The name of the module. This parameter cannot be null.
enumerable
The IEnumerable instance to expose as a virtual table. This parameter
cannot be null.
objectIdentity
Non-zero if different object instances with the same value should
generate different row identifiers, where applicable. This parameter has
no effect on the .NET Compact Framework.

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace |
SQLiteModuleEnumerable Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable Methods

The methods of the SQLiteModuleEnumerable class are listed below. For


a complete list of SQLiteModuleEnumerable class members, see the
SQLiteModuleEnumerable Members topic.

Public Instance Methods


Begin (inherited from See the Begin method.
SQLiteModuleNoop)
BestIndex See the BestIndex method.
Close See the Close method.
Column See the Column method.
Commit (inherited from See the Commit method.
SQLiteModuleNoop)
Connect See the Connect method.
Create See the Create method.
Destroy See the Destroy method.
Disconnect See the Disconnect method.
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof See the Eof method.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter See the Filter method.
FindFunction (inherited from See the FindFunction method.
SQLiteModuleNoop)
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next See the Next method.
Open See the Open method.
Release (inherited from See the Release method.
SQLiteModuleNoop)
Rename See the Rename method.
Rollback (inherited from See the Rollback method.
SQLiteModuleNoop)
RollbackTo (inherited from See the RollbackTo method.
SQLiteModuleNoop)
RowId See the RowId method.
Savepoint (inherited from See the Savepoint method.
SQLiteModuleNoop)
Sync (inherited from See the Sync method.
SQLiteModuleNoop)
ToString (inherited from Object) Returns a String that represents
the current Object.
Update See the Update method.

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorEndOfEnumeratorError Sets the table error message to one
that indicates the virtual table
cursor has no current row.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
CursorTypeMismatchError Sets the table error message to one
(inherited from that indicates the virtual table
SQLiteModuleCommon) cursor is of the wrong type.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.
FreeTable (inherited from Frees a native sqlite3_vtab
SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode (inherited Determines the default
from SQLiteModuleNoop) SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetMethodResultCode (inherited Determines the SQLiteErrorCode
from SQLiteModuleNoop) value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is available
(or set) for the specified method,
the SQLiteErrorCode value
returned by the
GetDefaultResultCode method will
be returned instead.
GetNativeModuleImpl (inherited Gets and returns the
from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
GetRowIdFromObject (inherited Determines the unique row
from SQLiteModuleCommon) identifier for the current row.
GetSqlForDeclareTable (inherited Determines the SQL statement
from SQLiteModuleCommon) used to declare the virtual table.
This method should be overridden
in derived classes if they require a
custom virtual table schema.
GetStringFromObject (inherited Determines the string to return as
from SQLiteModuleCommon) the column value for the object
instance value.
MakeRowId (inherited from Constructs an Int64 unique row
SQLiteModuleCommon) identifier from two Int32 values.
The first Int32 value must contain
the row sequence number for the
current row and the second value
must contain the hash code of the
key column value for the current
row.

MemberwiseClone (inherited from Creates a shallow copy of the


Object) current Object.
ResultCodeToEofResult (inherited Converts a SQLiteErrorCode value
from SQLiteModuleNoop) into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
(inherited from into a boolean return value for use
SQLiteModuleNoop) with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode (inherited Sets the SQLiteErrorCode value
from SQLiteModuleNoop) that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.
SetTableError (inherited from Overloaded. Arranges for the
SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor (inherited from Reads and returns the native
SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.BestIndex Method

See the BestIndex method.

public override SQLiteErrorCode BestIndex(


SQLiteVirtualTable table,
SQLiteIndex index
);

Parameters
table
See the BestIndex method.
index
See the BestIndex method.

Return Value
See the BestIndex method.

Implements
ISQLiteManagedModule.BestIndex

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Close Method

See the Close method.

public override SQLiteErrorCode Close(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
See the Close method.

Return Value
See the Close method.

Implements
ISQLiteManagedModule.Close

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Column Method

See the Column method.

public override SQLiteErrorCode Column(


SQLiteVirtualTableCursor cursor,
SQLiteContext context,
int index
);

Parameters
cursor
See the Column method.
context
See the Column method.
index
See the Column method.

Return Value
See the Column method.

Implements
ISQLiteManagedModule.Column

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Connect Method

See the Connect method.

public override SQLiteErrorCode Connect(


SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
See the Connect method.
pClientData
See the Connect method.
arguments
See the Connect method.
table
See the Connect method.
error
See the Connect method.

Return Value
See the Connect method.

Implements
ISQLiteManagedModule.Connect

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Create Method

See the Create method.

public override SQLiteErrorCode Create(


SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
See the Create method.
pClientData
See the Create method.
arguments
See the Create method.
table
See the Create method.
error
See the Create method.

Return Value
See the Create method.

Implements
ISQLiteManagedModule.Create

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.CursorEndOfEnumeratorError
Method

Sets the table error message to one that indicates the virtual table cursor
has no current row.

protected virtual SQLiteErrorCode CursorEndOfEnumeratorE


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
The SQLiteVirtualTableCursor object instance.

Return Value
The value of Error.

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Destroy Method

See the Destroy method.

public override SQLiteErrorCode Destroy(


SQLiteVirtualTable table
);

Parameters
table
See the Destroy method.

Return Value
See the Destroy method.

Implements
ISQLiteManagedModule.Destroy

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Disconnect Method

See the Disconnect method.

public override SQLiteErrorCode Disconnect(


SQLiteVirtualTable table
);

Parameters
table
See the Disconnect method.

Return Value
See the Disconnect method.

Implements
ISQLiteManagedModule.Disconnect

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Dispose Method

Disposes of this object instance.

Overload List
Inherited from SQLiteModule.
public void Dispose()
Disposes of this object instance.
protected override void Dispose(bool)

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Dispose(Boolean) Method

Disposes of this object instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace |
SQLiteModuleEnumerable.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Eof Method

See the Eof method.

public override bool Eof(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
See the Eof method.

Return Value
See the Eof method.

Implements
ISQLiteManagedModule.Eof

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Filter Method

See the Filter method.

public override SQLiteErrorCode Filter(


SQLiteVirtualTableCursor cursor,
int indexNumber,
string indexString,
SQLiteValue[] values
);

Parameters
cursor
See the Filter method.
indexNumber
See the Filter method.
indexString
See the Filter method.
values
See the Filter method.

Return Value
See the Filter method.

Implements
ISQLiteManagedModule.Filter

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Next Method

See the Next method.

public override SQLiteErrorCode Next(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
See the Next method.

Return Value
See the Next method.

Implements
ISQLiteManagedModule.Next

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Open Method

See the Open method.

public override SQLiteErrorCode Open(


SQLiteVirtualTable table,
ref SQLiteVirtualTableCursor cursor
);

Parameters
table
See the Open method.
cursor
See the Open method.

Return Value
See the Open method.

Implements
ISQLiteManagedModule.Open

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Rename Method

See the Rename method.

public override SQLiteErrorCode Rename(


SQLiteVirtualTable table,
string newName
);

Parameters
table
See the Rename method.
newName
See the Rename method.

Return Value
See the Rename method.

Implements
ISQLiteManagedModule.Rename

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.RowId Method

See the RowId method.

public override SQLiteErrorCode RowId(


SQLiteVirtualTableCursor cursor,
ref long rowId
);

Parameters
cursor
See the RowId method.
rowId
See the RowId method.

Return Value
See the RowId method.

Implements
ISQLiteManagedModule.RowId

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable.Update Method

See the Update method.

public override SQLiteErrorCode Update(


SQLiteVirtualTable table,
SQLiteValue[] values,
ref long rowId
);

Parameters
table
See the Update method.
values
See the Update method.
rowId
See the Update method.

Return Value
See the Update method.

Implements
ISQLiteManagedModule.Update

See Also
SQLiteModuleEnumerable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop Class

This class implements a virtual table module that does nothing by


providing "empty" implementations for all of the ISQLiteManagedModule
interface methods. The result codes returned by these "empty" method
implementations may be controlled on a per-method basis by using and/or
overriding the GetDefaultResultCode, ResultCodeToEofResult,
ResultCodeToFindFunctionResult, GetMethodResultCode, and
SetMethodResultCode methods from within derived classes.
For a list of all members of this type, see SQLiteModuleNoop Members .
System.Object SQLiteModule
SQLiteModuleNoop
SQLiteModuleCommon

public class SQLiteModuleNoop : SQLiteModule

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteModuleNoop Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop Members

SQLiteModuleNoop overview

Public Instance Constructors


SQLiteModuleNoop Constructor Constructs an instance of this class.

Public Instance Properties


Declared (inherited from Returns non-zero if the schema for
SQLiteModule) the virtual table has been declared.
LogErrors (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptions (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
xDestroy method, and the Dispose
method should be logged using the
SQLiteLog class.
Name (inherited from Returns the name of the module as
SQLiteModule) it was registered with the SQLite
core library.

Public Instance Methods


Begin See the Begin method.
BestIndex See the BestIndex method.
Close See the Close method.
Column See the Column method.
Commit See the Commit method.
Connect See the Connect method.
Create See the Create method.
Destroy See the Destroy method.
Disconnect See the Disconnect method.
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof See the Eof method.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter See the Filter method.
FindFunction See the FindFunction method.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next See the Next method.
Open See the Open method.
Release See the Release method.
Rename See the Rename method.
Rollback See the Rollback method.
RollbackTo See the RollbackTo method.
RowId See the RowId method.
Savepoint See the Savepoint method.
Sync See the Sync method.
ToString (inherited from Object) Returns a String that represents
the current Object.
Update See the Update method.

Protected Instance Properties


LogErrorsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptionsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
the xDestroy method, the
SetTableError method, the
SetTableError method, and the
Dispose method should be logged
using the SQLiteLog class.

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.
FreeTable (inherited from Frees a native sqlite3_vtab
SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode Determines the default
SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetMethodResultCode Determines the SQLiteErrorCode
value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is
available (or set) for the specified
method, the SQLiteErrorCode
value returned by the
GetDefaultResultCode method will
be returned instead.
GetNativeModuleImpl (inherited Gets and returns the
from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.

MemberwiseClone (inherited from Creates a shallow copy of the


Object) current Object.
ResultCodeToEofResult Converts a SQLiteErrorCode value
into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
into a boolean return value for use
with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode Sets the SQLiteErrorCode value
that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.
SetTableError (inherited from Overloaded. Arranges for the
SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.

TableFromCursor (inherited from Reads and returns the native


SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop Constructor

Constructs an instance of this class.

SQLiteModuleNoop(
string name
);

Parameters
name
The name of the module. This parameter cannot be null.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop Methods

The methods of the SQLiteModuleNoop class are listed below. For a


complete list of SQLiteModuleNoop class members, see the
SQLiteModuleNoop Members topic.

Public Instance Methods


Begin See the Begin method.
BestIndex See the BestIndex method.
Close See the Close method.
Column See the Column method.
Commit See the Commit method.
Connect See the Connect method.
Create See the Create method.
Destroy See the Destroy method.
Disconnect See the Disconnect method.
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof See the Eof method.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter See the Filter method.
FindFunction See the FindFunction method.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next See the Next method.
Open See the Open method.
Release See the Release method.
Rename See the Rename method.
Rollback See the Rollback method.
RollbackTo See the RollbackTo method.
RowId See the RowId method.
Savepoint See the Savepoint method.
Sync See the Sync method.
ToString (inherited from Object) Returns a String that represents
the current Object.
Update See the Update method.

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.
FreeTable (inherited from Frees a native sqlite3_vtab
SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode Determines the default
SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetMethodResultCode Determines the SQLiteErrorCode
value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is
available (or set) for the specified
method, the SQLiteErrorCode
value returned by the
GetDefaultResultCode method will
be returned instead.

GetNativeModuleImpl (inherited Gets and returns the


from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
ResultCodeToEofResult Converts a SQLiteErrorCode value
into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
into a boolean return value for use
with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode Sets the SQLiteErrorCode value
that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.

SetTableError (inherited from Overloaded. Arranges for the


SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor (inherited from Reads and returns the native
SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Begin Method

See the Begin method.

public override SQLiteErrorCode Begin(


SQLiteVirtualTable table
);

Parameters
table
See the Begin method.

Return Value
See the Begin method.

Implements
ISQLiteManagedModule.Begin

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.BestIndex Method

See the BestIndex method.

public override SQLiteErrorCode BestIndex(


SQLiteVirtualTable table,
SQLiteIndex index
);

Parameters
table
See the BestIndex method.
index
See the BestIndex method.

Return Value
See the BestIndex method.

Implements
ISQLiteManagedModule.BestIndex

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Close Method

See the Close method.

public override SQLiteErrorCode Close(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
See the Close method.

Return Value
See the Close method.

Implements
ISQLiteManagedModule.Close

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Column Method

See the Column method.

public override SQLiteErrorCode Column(


SQLiteVirtualTableCursor cursor,
SQLiteContext context,
int index
);

Parameters
cursor
See the Column method.
context
See the Column method.
index
See the Column method.

Return Value
See the Column method.

Implements
ISQLiteManagedModule.Column

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Commit Method

See the Commit method.

public override SQLiteErrorCode Commit(


SQLiteVirtualTable table
);

Parameters
table
See the Commit method.

Return Value
See the Commit method.

Implements
ISQLiteManagedModule.Commit

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Connect Method

See the Connect method.

public override SQLiteErrorCode Connect(


SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
See the Connect method.
pClientData
See the Connect method.
arguments
See the Connect method.
table
See the Connect method.
error
See the Connect method.

Return Value
See the Connect method.

Implements
ISQLiteManagedModule.Connect

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Create Method

See the Create method.

public override SQLiteErrorCode Create(


SQLiteConnection connection,
IntPtr pClientData,
string[] arguments,
ref SQLiteVirtualTable table,
ref string error
);

Parameters
connection
See the Create method.
pClientData
See the Create method.
arguments
See the Create method.
table
See the Create method.
error
See the Create method.

Return Value
See the Create method.

Implements
ISQLiteManagedModule.Create

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Destroy Method

See the Destroy method.

public override SQLiteErrorCode Destroy(


SQLiteVirtualTable table
);

Parameters
table
See the Destroy method.

Return Value
See the Destroy method.

Implements
ISQLiteManagedModule.Destroy

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Disconnect Method

See the Disconnect method.

public override SQLiteErrorCode Disconnect(


SQLiteVirtualTable table
);

Parameters
table
See the Disconnect method.

Return Value
See the Disconnect method.

Implements
ISQLiteManagedModule.Disconnect

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Dispose Method

Disposes of this object instance.

Overload List
Inherited from SQLiteModule.
public void Dispose()
Disposes of this object instance.
protected override void Dispose(bool)

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Dispose(Boolean) Method

Disposes of this object instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace |
SQLiteModuleNoop.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Eof Method

See the Eof method.

public override bool Eof(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
See the Eof method.

Return Value
See the Eof method.

Implements
ISQLiteManagedModule.Eof

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Filter Method

See the Filter method.

public override SQLiteErrorCode Filter(


SQLiteVirtualTableCursor cursor,
int indexNumber,
string indexString,
SQLiteValue[] values
);

Parameters
cursor
See the Filter method.
indexNumber
See the Filter method.
indexString
See the Filter method.
values
See the Filter method.

Return Value
See the Filter method.

Implements
ISQLiteManagedModule.Filter

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.FindFunction Method

See the FindFunction method.

public override bool FindFunction(


SQLiteVirtualTable table,
int argumentCount,
string name,
ref SQLiteFunction function,
ref IntPtr pClientData
);

Parameters
table
See the FindFunction method.
argumentCount
See the FindFunction method.
name
See the FindFunction method.
function
See the FindFunction method.
pClientData
See the FindFunction method.

Return Value
See the FindFunction method.

Implements
ISQLiteManagedModule.FindFunction

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.GetDefaultResultCode Method

Determines the default SQLiteErrorCode value to be returned by methods


of the ISQLiteManagedModule interface that lack an overridden
implementation in all classes derived from the SQLiteModuleNoop class.

protected virtual SQLiteErrorCode GetDefaultResultCode()

Return Value
The SQLiteErrorCode value that should be returned by all
ISQLiteManagedModule interface methods unless a more specific result
code has been set for that interface method.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.GetMethodResultCode Method

Determines the SQLiteErrorCode value that should be returned by the


specified ISQLiteManagedModule interface method if it lack an overridden
implementation. If no specific SQLiteErrorCode value is available (or set)
for the specified method, the SQLiteErrorCode value returned by the
GetDefaultResultCode method will be returned instead.

protected virtual SQLiteErrorCode GetMethodResultCode(


string methodName
);

Parameters
methodName
The name of the method. Currently, this method must be part of the
ISQLiteManagedModule interface.

Return Value
The SQLiteErrorCode value that should be returned by the
ISQLiteManagedModule interface method.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Next Method

See the Next method.

public override SQLiteErrorCode Next(


SQLiteVirtualTableCursor cursor
);

Parameters
cursor
See the Next method.

Return Value
See the Next method.

Implements
ISQLiteManagedModule.Next

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Open Method

See the Open method.

public override SQLiteErrorCode Open(


SQLiteVirtualTable table,
ref SQLiteVirtualTableCursor cursor
);

Parameters
table
See the Open method.
cursor
See the Open method.

Return Value
See the Open method.

Implements
ISQLiteManagedModule.Open

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Release Method

See the Release method.

public override SQLiteErrorCode Release(


SQLiteVirtualTable table,
int savepoint
);

Parameters
table
See the Release method.
savepoint
See the Release method.

Return Value
See the Release method.

Implements
ISQLiteManagedModule.Release

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Rename Method

See the Rename method.

public override SQLiteErrorCode Rename(


SQLiteVirtualTable table,
string newName
);

Parameters
table
See the Rename method.
newName
See the Rename method.

Return Value
See the Rename method.

Implements
ISQLiteManagedModule.Rename

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.ResultCodeToEofResult Method

Converts a SQLiteErrorCode value into a boolean return value for use with
the Eof method.

protected virtual bool ResultCodeToEofResult(


SQLiteErrorCode resultCode
);

Parameters
resultCode
The SQLiteErrorCode value to convert.

Return Value
The Boolean value.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.ResultCodeToFindFunctionResult Method

Converts a SQLiteErrorCode value into a boolean return value for use with
the FindFunction method.

protected virtual bool ResultCodeToFindFunctionResult(


SQLiteErrorCode resultCode
);

Parameters
resultCode
The SQLiteErrorCode value to convert.

Return Value
The Boolean value.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Rollback Method

See the Rollback method.

public override SQLiteErrorCode Rollback(


SQLiteVirtualTable table
);

Parameters
table
See the Rollback method.

Return Value
See the Rollback method.

Implements
ISQLiteManagedModule.Rollback

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.RollbackTo Method

See the RollbackTo method.

public override SQLiteErrorCode RollbackTo(


SQLiteVirtualTable table,
int savepoint
);

Parameters
table
See the RollbackTo method.
savepoint
See the RollbackTo method.

Return Value
See the RollbackTo method.

Implements
ISQLiteManagedModule.RollbackTo

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.RowId Method

See the RowId method.

public override SQLiteErrorCode RowId(


SQLiteVirtualTableCursor cursor,
ref long rowId
);

Parameters
cursor
See the RowId method.
rowId
See the RowId method.

Return Value
See the RowId method.

Implements
ISQLiteManagedModule.RowId

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Savepoint Method

See the Savepoint method.

public override SQLiteErrorCode Savepoint(


SQLiteVirtualTable table,
int savepoint
);

Parameters
table
See the Savepoint method.
savepoint
See the Savepoint method.

Return Value
See the Savepoint method.

Implements
ISQLiteManagedModule.Savepoint

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.SetMethodResultCode Method

Sets the SQLiteErrorCode value that should be returned by the specified


ISQLiteManagedModule interface method if it lack an overridden
implementation.

protected virtual bool SetMethodResultCode(


string methodName,
SQLiteErrorCode resultCode
);

Parameters
methodName
The name of the method. Currently, this method must be part of the
ISQLiteManagedModule interface.
resultCode
The SQLiteErrorCode value that should be returned by the
ISQLiteManagedModule interface method.

Return Value
Non-zero upon success.

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Sync Method

See the Sync method.

public override SQLiteErrorCode Sync(


SQLiteVirtualTable table
);

Parameters
table
See the Sync method.

Return Value
See the Sync method.

Implements
ISQLiteManagedModule.Sync

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleNoop.Update Method

See the Update method.

public override SQLiteErrorCode Update(


SQLiteVirtualTable table,
SQLiteValue[] values,
ref long rowId
);

Parameters
table
See the Update method.
values
See the Update method.
rowId
See the Update method.

Return Value
See the Update method.

Implements
ISQLiteManagedModule.Update

See Also
SQLiteModuleNoop Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Class

SQLite implementation of DbParameter.


For a list of all members of this type, see SQLiteParameter Members .
System.Object MarshalByRefObject
DbParameter
SQLiteParameter

public sealed class SQLiteParameter : DbParameter,


ICloneable

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteParameter Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Members

SQLiteParameter overview

Public Instance Constructors


SQLiteParameter Overloaded. Initializes a new
instance of the SQLiteParameter
class.

Public Instance Properties


Command The command associated with this
parameter.
DbType Returns the datatype of the
parameter
Direction Supports only input parameters
IsNullable Whether or not the parameter can
contain a null value
ParameterName Returns the parameter name
Size Returns the size of the parameter
SourceColumn Gets/sets the source column
SourceColumnNullMapping Used by DbCommandBuilder to
determine the mapping for nullable
fields
SourceVersion Gets and sets the row version
TypeName The database type name associated
with this parameter, if any.
Value Gets and sets the parameter value.
If no datatype was specified, the
datatype will assume the type from
the value given.

Public Instance Methods


Clone Clones a parameter
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
ResetDbType Resets the DbType of the parameter
so it can be inferred from the value
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Default constructor

Overload List
Default constructor
public SQLiteParameter()
Constructs an unnamed parameter of the specified data type
public SQLiteParameter(DbType)
Constructs an unnamed parameter of the specified type and size
public SQLiteParameter(DbType,int)
Constructs an unnamed parameter of the specified type, size, and source
column
public SQLiteParameter(DbType,int,string)
Constructs an unnamed parameter of the specified type, size, source
column and row version
public SQLiteParameter(DbType,int,string,DataRowVersion)
Constructs an unnamed parameter of the specified data type and sets the
initial value
public SQLiteParameter(DbType,object)
Constructs an unnamed parameter of the specified data type and source
column
public SQLiteParameter(DbType,string)
Constructs an unnamed parameter of the specified data type, source
column and row version
public SQLiteParameter(DbType,string,DataRowVersion)
Constructs a named parameter given the specified parameter name
public SQLiteParameter(string)
Constructs a named parameter of the specified type
public SQLiteParameter(string,DbType)
Constructs a named parameter of the specified type and size
public SQLiteParameter(string,DbType,int)
Constructs a named parameter of the specified type, size, source column
and row version
public SQLiteParameter(string,DbType,int,ParameterDirection,bool,byte,byt
Constructs a named parameter, yet another flavor
public SQLiteParameter(string,DbType,int,ParameterDirection,byte,byte,stri
Constructs a named parameter of the specified type, size and source
column
public SQLiteParameter(string,DbType,int,string)
Constructs a named parameter of the specified type, size, source column
and row version
public SQLiteParameter(string,DbType,int,string,DataRowVersion)
Constructs a named parameter of the specified type and source column
reference
public SQLiteParameter(string,DbType,string)
Constructs a named parameter of the specified type, source column and
row version
public SQLiteParameter(string,DbType,string,DataRowVersion)
Constructs a named parameter given the specified parameter name and
initial value
public SQLiteParameter(string,object)

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Default constructor

SQLiteParameter();

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter given the specified parameter name

SQLiteParameter(
string parameterName
);

Parameters
parameterName
The parameter name

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter given the specified parameter name and


initial value

SQLiteParameter(
string parameterName,
object value
);

Parameters
parameterName
The parameter name
value
The initial value of the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter of the specified type

SQLiteParameter(
string parameterName,
DbType dbType
);

Parameters
parameterName
The parameter name
dbType
The datatype of the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter of the specified type and source column


reference

SQLiteParameter(
string parameterName,
DbType dbType,
string sourceColumn
);

Parameters
parameterName
The parameter name
dbType
The data type
sourceColumn
The source column

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter of the specified type, source column and


row version

SQLiteParameter(
string parameterName,
DbType dbType,
string sourceColumn,
DataRowVersion rowVersion
);

Parameters
parameterName
The parameter name
dbType
The data type
sourceColumn
The source column
rowVersion
The row version information

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs an unnamed parameter of the specified data type

SQLiteParameter(
DbType dbType
);

Parameters
dbType
The datatype of the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs an unnamed parameter of the specified data type and sets the
initial value

SQLiteParameter(
DbType dbType,
object value
);

Parameters
dbType
The datatype of the parameter
value
The initial value of the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs an unnamed parameter of the specified data type and source


column

SQLiteParameter(
DbType dbType,
string sourceColumn
);

Parameters
dbType
The datatype of the parameter
sourceColumn
The source column

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs an unnamed parameter of the specified data type, source


column and row version

SQLiteParameter(
DbType dbType,
string sourceColumn,
DataRowVersion rowVersion
);

Parameters
dbType
The data type
sourceColumn
The source column
rowVersion
The row version information

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter of the specified type and size

SQLiteParameter(
string parameterName,
DbType parameterType,
int parameterSize
);

Parameters
parameterName
The parameter name
parameterType
The data type
parameterSize
The size of the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter of the specified type, size and source


column

SQLiteParameter(
string parameterName,
DbType parameterType,
int parameterSize,
string sourceColumn
);

Parameters
parameterName
The name of the parameter
parameterType
The data type
parameterSize
The size of the parameter
sourceColumn
The source column

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter of the specified type, size, source column


and row version

SQLiteParameter(
string parameterName,
DbType parameterType,
int parameterSize,
string sourceColumn,
DataRowVersion rowVersion
);

Parameters
parameterName
The name of the parameter
parameterType
The data type
parameterSize
The size of the parameter
sourceColumn
The source column
rowVersion
The row version information

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter of the specified type, size, source column


and row version

SQLiteParameter(
string parameterName,
DbType parameterType,
int parameterSize,
ParameterDirection direction,
bool isNullable,
byte precision,
byte scale,
string sourceColumn,
DataRowVersion rowVersion,
object value
);

Parameters
parameterName
The name of the parameter
parameterType
The data type
parameterSize
The size of the parameter
direction
Only input parameters are supported in SQLite
isNullable
Ignored
precision
Ignored
scale
Ignored
sourceColumn
The source column
rowVersion
The row version information
value
The initial value to assign the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs a named parameter, yet another flavor

SQLiteParameter(
string parameterName,
DbType parameterType,
int parameterSize,
ParameterDirection direction,
byte precision,
byte scale,
string sourceColumn,
DataRowVersion rowVersion,
bool sourceColumnNullMapping,
object value
);

Parameters
parameterName
The name of the parameter
parameterType
The data type
parameterSize
The size of the parameter
direction
Only input parameters are supported in SQLite
precision
Ignored
scale
Ignored
sourceColumn
The source column
rowVersion
The row version information
sourceColumnNullMapping
Whether or not this parameter is for comparing NULL's
value
The intial value to assign the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs an unnamed parameter of the specified type and size

SQLiteParameter(
DbType parameterType,
int parameterSize
);

Parameters
parameterType
The data type
parameterSize
The size of the parameter

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs an unnamed parameter of the specified type, size, and source


column

SQLiteParameter(
DbType parameterType,
int parameterSize,
string sourceColumn
);

Parameters
parameterType
The data type
parameterSize
The size of the parameter
sourceColumn
The source column

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Constructor

Constructs an unnamed parameter of the specified type, size, source


column and row version

SQLiteParameter(
DbType parameterType,
int parameterSize,
string sourceColumn,
DataRowVersion rowVersion
);

Parameters
parameterType
The data type
parameterSize
The size of the parameter
sourceColumn
The source column
rowVersion
The row version information

See Also
SQLiteParameter Class | System.Data.SQLite Namespace |
SQLiteParameter Constructor Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Properties

The properties of the SQLiteParameter class are listed below. For a


complete list of SQLiteParameter class members, see the
SQLiteParameter Members topic.

Public Instance Properties


Command The command associated with this
parameter.
DbType Returns the datatype of the
parameter
Direction Supports only input parameters
IsNullable Whether or not the parameter can
contain a null value
ParameterName Returns the parameter name
Size Returns the size of the parameter
SourceColumn Gets/sets the source column
SourceColumnNullMapping Used by DbCommandBuilder to
determine the mapping for nullable
fields
SourceVersion Gets and sets the row version
TypeName The database type name associated
with this parameter, if any.
Value Gets and sets the parameter value.
If no datatype was specified, the
datatype will assume the type from
the value given.

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.Command Property

The command associated with this parameter.

public IDbCommand Command { public get; public set; }

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.DbType Property

Returns the datatype of the parameter

public override DbType DbType { public get; public set;

Implements
IDataParameter.DbType

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.Direction Property

Supports only input parameters

public override ParameterDirection Direction { public ge

Implements
IDataParameter.Direction

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.IsNullable Property

Whether or not the parameter can contain a null value

public override bool IsNullable { public get; public set

Implements
IDataParameter.IsNullable

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.ParameterName Property

Returns the parameter name

public override string ParameterName { public get; publi

Implements
IDataParameter.ParameterName

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.Size Property

Returns the size of the parameter

public override int Size { public get; public set; }

Implements
IDbDataParameter.Size

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.SourceColumn Property

Gets/sets the source column

public override string SourceColumn { public get; public

Implements
IDataParameter.SourceColumn

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.SourceColumnNullMapping Property

Used by DbCommandBuilder to determine the mapping for nullable fields

public override bool SourceColumnNullMapping { public ge

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.SourceVersion Property

Gets and sets the row version

public override DataRowVersion SourceVersion { public ge

Implements
IDataParameter.SourceVersion

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.TypeName Property

The database type name associated with this parameter, if any.

public string TypeName { public get; public set; }

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.Value Property

Gets and sets the parameter value. If no datatype was specified, the
datatype will assume the type from the value given.

public override object Value { public get; public set; }

Implements
IDataParameter.Value

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter Methods

The methods of the SQLiteParameter class are listed below. For a


complete list of SQLiteParameter class members, see the
SQLiteParameter Members topic.

Public Instance Methods


Clone Clones a parameter
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
ResetDbType Resets the DbType of the parameter
so it can be inferred from the value
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.Clone Method

Clones a parameter

public object Clone();

Return Value
A new, unassociated SQLiteParameter

Implements
ICloneable.Clone

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameter.ResetDbType Method

Resets the DbType of the parameter so it can be inferred from the value

public override void ResetDbType();

See Also
SQLiteParameter Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection Class

SQLite implementation of DbParameterCollection.


For a list of all members of this type, see SQLiteParameterCollection
Members .
System.Object MarshalByRefObject
DbParameterCollection
SQLiteParameterCollection

public sealed class SQLiteParameterCollection :


DbParameterCollection

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteParameterCollection Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection Members

SQLiteParameterCollection overview

Public Instance Properties


Count Returns a count of parameters in
the collection
IsFixedSize Returns false
IsReadOnly Returns false
IsSynchronized Returns false
Item Overloaded. Overloaded to
specialize the return value of the
default indexer
SyncRoot Returns null

Public Instance Methods


Add Overloaded. Adds a parameter to
the collection
AddRange Overloaded. Adds an array of
parameters to the collection
AddWithValue Adds a named/unnamed parameter
and its value to the parameter
collection.
Clear Clears the array and resets the
collection
Contains Overloaded. Determines if the
named parameter exists in the
collection
CopyTo Not implemented
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetEnumerator Retrieves an enumerator for the
collection
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
IndexOf Overloaded. Returns the index of a
parameter given its name
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Insert Inserts a parameter into the array
at the specified location
Remove Removes a parameter from the
collection
RemoveAt Overloaded. Removes a parameter
from the collection given its name
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
GetParameter Overloaded. Retrieve a parameter
by name from the collection
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
SetParameter Overloaded. Re-assign the named
parameter to a new parameter
object

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection Properties

The properties of the SQLiteParameterCollection class are listed below.


For a complete list of SQLiteParameterCollection class members, see
the SQLiteParameterCollection Members topic.

Public Instance Properties


Count Returns a count of parameters in
the collection
IsFixedSize Returns false
IsReadOnly Returns false
IsSynchronized Returns false
Item Overloaded. Overloaded to
specialize the return value of the
default indexer
SyncRoot Returns null

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Count Property

Returns a count of parameters in the collection

public override int Count { public get; }

Implements
ICollection.Count

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.IsFixedSize Property

Returns false

public override bool IsFixedSize { public get; }

Implements
IList.IsFixedSize

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.IsReadOnly Property

Returns false

public override bool IsReadOnly { public get; }

Implements
IList.IsReadOnly

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.IsSynchronized Property

Returns false

public override bool IsSynchronized { public get; }

Implements
ICollection.IsSynchronized

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.SQLiteParameter Property

Overloaded to specialize the return value of the default indexer

Overload List
Overloaded to specialize the return value of the default indexer
public SQLiteParameter this[int] { public get; public set; }
Overloaded to specialize the return value of the default indexer
public SQLiteParameter this[string] { public get; public set; }

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Item Property

Overloaded to specialize the return value of the default indexer

public SQLiteParameter this[


int index
] { public get; public set; }

Parameters
index
The index of the parameter to get/set

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Item Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Item Property

Overloaded to specialize the return value of the default indexer

public SQLiteParameter this[


string parameterName
] { public get; public set; }

Parameters
parameterName
Name of the parameter to get/set

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Item Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.SyncRoot Property

Returns null

public override object SyncRoot { public get; }

Implements
ICollection.SyncRoot

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection Methods

The methods of the SQLiteParameterCollection class are listed below.


For a complete list of SQLiteParameterCollection class members, see
the SQLiteParameterCollection Members topic.

Public Instance Methods


Add Overloaded. Adds a parameter to
the collection
AddRange Overloaded. Adds an array of
parameters to the collection
AddWithValue Adds a named/unnamed parameter
and its value to the parameter
collection.
Clear Clears the array and resets the
collection
Contains Overloaded. Determines if the
named parameter exists in the
collection
CopyTo Not implemented
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetEnumerator Retrieves an enumerator for the
collection
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
IndexOf Overloaded. Returns the index of a
parameter given its name
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Insert Inserts a parameter into the array
at the specified location
Remove Removes a parameter from the
collection
RemoveAt Overloaded. Removes a parameter
from the collection given its name
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
GetParameter Overloaded. Retrieve a parameter
by name from the collection
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.
SetParameter Overloaded. Re-assign the named
parameter to a new parameter
object

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Add Method

Adds a parameter to the collection

Overload List
Adds a parameter to the collection
public int Add(SQLiteParameter)
Adds a parameter to the collection
public override int Add(object)
Adds a parameter to the collection
public SQLiteParameter Add(string,DbType)
Adds a parameter to the collection
public SQLiteParameter Add(string,DbType,int)
Adds a parameter to the collection
public SQLiteParameter Add(string,DbType,int,string)

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Add(SQLiteParameter) Method

Adds a parameter to the collection

public int Add(


SQLiteParameter parameter
);

Parameters
parameter
The parameter to add

Return Value
A zero-based index of where the parameter is located in the array

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Add Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Add(Object) Method

Adds a parameter to the collection

public override int Add(


object value
);

Parameters
value
The parameter to add

Return Value
A zero-based index of where the parameter is located in the array

Implements
IList.Add

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Add Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Add(String, DbType) Method

Adds a parameter to the collection

public SQLiteParameter Add(


string parameterName,
DbType parameterType
);

Parameters
parameterName
The parameter name
parameterType
The data type

Return Value
A SQLiteParameter object

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Add Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Add(String, DbType, Int32)
Method

Adds a parameter to the collection

public SQLiteParameter Add(


string parameterName,
DbType parameterType,
int parameterSize
);

Parameters
parameterName
The parameter name
parameterType
The data type
parameterSize
The size of the value

Return Value
A SQLiteParameter object

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Add Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Add(String, DbType, Int32,
String) Method

Adds a parameter to the collection

public SQLiteParameter Add(


string parameterName,
DbType parameterType,
int parameterSize,
string sourceColumn
);

Parameters
parameterName
The parameter name
parameterType
The data type
parameterSize
The size of the value
sourceColumn
The source column

Return Value
A SQLiteParameter object

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Add Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.AddRange Method

Adds an array of parameters to the collection

Overload List
Adds an array of parameters to the collection
public override void AddRange(Array)
Adds an array of parameters to the collection
public void AddRange(SQLiteParameter[])

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.AddRange(Array) Method

Adds an array of parameters to the collection

public override void AddRange(


Array values
);

Parameters
values
The array of parameters to add

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.AddRange Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.AddRange(SQLiteParameter)
Method

Adds an array of parameters to the collection

public void AddRange(


SQLiteParameter[] values
);

Parameters
values
The array of parameters to add

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.AddRange Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.AddWithValue Method

Adds a named/unnamed parameter and its value to the parameter


collection.

public SQLiteParameter AddWithValue(


string parameterName,
object value
);

Parameters
parameterName
Name of the parameter, or null to indicate an unnamed parameter
value
The initial value of the parameter

Return Value
Returns the SQLiteParameter object created during the call.

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Clear Method

Clears the array and resets the collection

public override void Clear();

Implements
IList.Clear

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Contains Method

Determines if the parameter exists in the collection

Overload List
Determines if the parameter exists in the collection
public override bool Contains(object)
Determines if the named parameter exists in the collection
public override bool Contains(string)

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Contains(Object) Method

Determines if the parameter exists in the collection

public override bool Contains(


object value
);

Parameters
value
The SQLiteParameter to check

Return Value
True if the parameter is in the collection

Implements
IList.Contains

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Contains Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Contains(String) Method

Determines if the named parameter exists in the collection

public override bool Contains(


string parameterName
);

Parameters
parameterName
The name of the parameter to check

Return Value
True if the parameter is in the collection

Implements
IDataParameterCollection.Contains

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.Contains Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.CopyTo Method

Not implemented

public override void CopyTo(


Array array,
int index
);

Parameters
array
index

Implements
ICollection.CopyTo

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.GetEnumerator Method

Retrieves an enumerator for the collection

public override IEnumerator GetEnumerator();

Return Value
An enumerator for the underlying array

Implements
IEnumerable.GetEnumerator

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.GetParameter Method

Retrieves a parameter by its index in the collection

Overload List
Retrieves a parameter by its index in the collection
protected override DbParameter GetParameter(int)
Retrieve a parameter by name from the collection
protected override DbParameter GetParameter(string)

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.GetParameter(Int32) Method

Retrieves a parameter by its index in the collection

protected override DbParameter GetParameter(


int index
);

Parameters
index
The index of the parameter to retrieve

Return Value
A DbParameter object

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.GetParameter Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.GetParameter(String) Method

Retrieve a parameter by name from the collection

protected override DbParameter GetParameter(


string parameterName
);

Parameters
parameterName
The name of the parameter to fetch

Return Value
A DbParameter object

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.GetParameter Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.IndexOf Method

Returns the index of a parameter

Overload List
Returns the index of a parameter
public override int IndexOf(object)
Returns the index of a parameter given its name
public override int IndexOf(string)

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.IndexOf(Object) Method

Returns the index of a parameter

public override int IndexOf(


object value
);

Parameters
value
The parameter to find

Return Value
-1 if not found, otherwise a zero-based index of the parameter

Implements
IList.IndexOf

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.IndexOf Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.IndexOf(String) Method

Returns the index of a parameter given its name

public override int IndexOf(


string parameterName
);

Parameters
parameterName
The name of the parameter to find

Return Value
-1 if not found, otherwise a zero-based index of the parameter

Implements
IDataParameterCollection.IndexOf

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.IndexOf Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Insert Method

Inserts a parameter into the array at the specified location

public override void Insert(


int index,
object value
);

Parameters
index
The zero-based index to insert the parameter at
value
The parameter to insert

Implements
IList.Insert

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.Remove Method

Removes a parameter from the collection

public override void Remove(


object value
);

Parameters
value
The parameter to remove

Implements
IList.Remove

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.RemoveAt Method

Removes a parameter from the collection given its index

Overload List
Removes a parameter from the collection given its index
public override void RemoveAt(int)
Removes a parameter from the collection given its name
public override void RemoveAt(string)

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.RemoveAt(Int32) Method

Removes a parameter from the collection given its index

public override void RemoveAt(


int index
);

Parameters
index
The zero-based parameter index to remove

Implements
IList.RemoveAt

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.RemoveAt Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.RemoveAt(String) Method

Removes a parameter from the collection given its name

public override void RemoveAt(


string parameterName
);

Parameters
parameterName
The name of the parameter to remove

Implements
IDataParameterCollection.RemoveAt

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.RemoveAt Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.SetParameter Method

Re-assign a parameter at the specified index

Overload List
Re-assign a parameter at the specified index
protected override void SetParameter(int,DbParameter)
Re-assign the named parameter to a new parameter object
protected override void SetParameter(string,DbParameter)

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.SetParameter(Int32,
DbParameter) Method

Re-assign a parameter at the specified index

protected override void SetParameter(


int index,
DbParameter value
);

Parameters
index
The zero-based index of the parameter to replace
value
The new parameter

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.SetParameter Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteParameterCollection.SetParameter(String,
DbParameter) Method

Re-assign the named parameter to a new parameter object

protected override void SetParameter(


string parameterName,
DbParameter value
);

Parameters
parameterName
The name of the parameter to replace
value
The new parameter

See Also
SQLiteParameterCollection Class | System.Data.SQLite Namespace |
SQLiteParameterCollection.SetParameter Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteProgressEventHandler Delegate

Raised each time the number of virtual machine instructions is


approximately equal to the value of the ProgressOps property.

public delegate void SQLiteProgressEventHandler(


object sender,
ProgressEventArgs e
);

Parameters
sender
The connection performing the operation.
e
A ProgressEventArgs that contains the event data.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteProgressReturnCode Enumeration

The possible return codes for the progress callback.

public enum SQLiteProgressReturnCode

Members
Member Name Description
Continue The operation should continue.
Interrupt The operation should be
interrupted.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs Class

This class represents the parameters that are provided to the GetBytes
and GetChars methods, with the exception of the column index (provided
separately).
For a list of all members of this type, see SQLiteReadArrayEventArgs
Members .
System.Object EventArgs
SQLiteReadEventArgs
SQLiteReadArrayEventArgs

public class SQLiteReadArrayEventArgs :


SQLiteReadEventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteReadArrayEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs Members

SQLiteReadArrayEventArgs overview

Public Instance Properties


BufferOffset The value that was originally
specified for the "bufferOffset"
parameter to the GetBytes or
GetChars methods.
ByteBuffer The value that was originally
specified for the "buffer" parameter
to the GetBytes method.
CharBuffer The value that was originally
specified for the "buffer" parameter
to the GetChars method.
DataOffset The value that was originally
specified for the "dataOffset"
parameter to the GetBytes or
GetChars methods.
Length The value that was originally
specified for the "length" parameter
to the GetBytes or GetChars
methods.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.
Protected Instance Methods
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteReadArrayEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs Properties

The properties of the SQLiteReadArrayEventArgs class are listed below.


For a complete list of SQLiteReadArrayEventArgs class members, see
the SQLiteReadArrayEventArgs Members topic.

Public Instance Properties


BufferOffset The value that was originally
specified for the "bufferOffset"
parameter to the GetBytes or
GetChars methods.
ByteBuffer The value that was originally
specified for the "buffer" parameter
to the GetBytes method.
CharBuffer The value that was originally
specified for the "buffer" parameter
to the GetChars method.
DataOffset The value that was originally
specified for the "dataOffset"
parameter to the GetBytes or
GetChars methods.
Length The value that was originally
specified for the "length" parameter
to the GetBytes or GetChars
methods.

See Also
SQLiteReadArrayEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs.BufferOffset Property

The value that was originally specified for the "bufferOffset" parameter to
the GetBytes or GetChars methods.

public int BufferOffset { public get; public set; }

See Also
SQLiteReadArrayEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs.ByteBuffer Property

The value that was originally specified for the "buffer" parameter to the
GetBytes method.

public byte[] ByteBuffer { public get; }

See Also
SQLiteReadArrayEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs.CharBuffer Property

The value that was originally specified for the "buffer" parameter to the
GetChars method.

public char[] CharBuffer { public get; }

See Also
SQLiteReadArrayEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs.DataOffset Property

The value that was originally specified for the "dataOffset" parameter to
the GetBytes or GetChars methods.

public long DataOffset { public get; public set; }

See Also
SQLiteReadArrayEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadArrayEventArgs.Length Property

The value that was originally specified for the "length" parameter to the
GetBytes or GetChars methods.

public int Length { public get; public set; }

See Also
SQLiteReadArrayEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadBlobEventArgs Class

This class represents the parameters that are provided to the GetBlob
method, with the exception of the column index (provided separately).
For a list of all members of this type, see SQLiteReadBlobEventArgs
Members .
System.Object EventArgs
SQLiteReadEventArgs
SQLiteReadBlobEventArgs

public class SQLiteReadBlobEventArgs :


SQLiteReadEventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteReadBlobEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadBlobEventArgs Members

SQLiteReadBlobEventArgs overview

Public Instance Properties


ReadOnly The value that was originally
specified for the "readOnly"
parameter to the GetBlob method.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteReadBlobEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadBlobEventArgs Properties

The properties of the SQLiteReadBlobEventArgs class are listed below.


For a complete list of SQLiteReadBlobEventArgs class members, see the
SQLiteReadBlobEventArgs Members topic.

Public Instance Properties


ReadOnly The value that was originally
specified for the "readOnly"
parameter to the GetBlob method.

See Also
SQLiteReadBlobEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadBlobEventArgs.ReadOnly Property

The value that was originally specified for the "readOnly" parameter to the
GetBlob method.

public bool ReadOnly { public get; public set; }

See Also
SQLiteReadBlobEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadEventArgs Class

This class represents the parameters that are provided to the


SQLiteDataReader methods, with the exception of the column index
(provided separately).
For a list of all members of this type, see SQLiteReadEventArgs Members .
System.Object EventArgs
SQLiteReadEventArgs
SQLiteReadArrayEventArgs
SQLiteReadBlobEventArgs
SQLiteReadValueEventArgs

public abstract class SQLiteReadEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteReadEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadEventArgs Members

SQLiteReadEventArgs overview

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Constructors


SQLiteReadEventArgs Initializes a new instance of the
Constructor SQLiteReadEventArgs class.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteReadEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadEventArgs Constructor

Initializes a new instance of the SQLiteReadEventArgs class.

SQLiteReadEventArgs();

See Also
SQLiteReadEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadValueCallback Delegate

This represents a method that will be called in response to a request to


read a value from a data reader. If an exception is thrown, it will cause the
data reader operation to fail -AND- it will continue to unwind the call
stack.

public delegate void SQLiteReadValueCallback(


SQLiteConvert convert,
SQLiteDataReader dataReader,
SQLiteConnectionFlags flags,
SQLiteReadEventArgs eventArgs,
string typeName,
int index,
object userData,
out bool complete
);

Parameters
convert
The SQLiteConvert instance in use.
dataReader
The SQLiteDataReader instance in use.
flags
The flags associated with the SQLiteConnection instance in use.
eventArgs
The parameter and return type data for the column being read from the
data reader.
typeName
The database type name associated with this callback.
index
The zero based index of the column being read from the data reader.
userData
The data originally used when registering this callback.
complete
Non-zero if the default handling for the data reader call should be
skipped. If this is set to non-zero and the necessary return value is
unavailable or unsuitable, an exception will be thrown.
Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadValueEventArgs Class

This class represents the parameters and return values for the GetBlob,
GetBoolean, GetByte, GetBytes, GetChar, GetChars, GetDateTime,
GetDecimal, GetDouble, GetFloat, GetGuid, GetInt16, GetInt32, GetInt64,
GetString, and GetValue methods.
For a list of all members of this type, see SQLiteReadValueEventArgs
Members .
System.Object EventArgs
SQLiteReadEventArgs
SQLiteReadValueEventArgs

public class SQLiteReadValueEventArgs :


SQLiteReadEventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteReadValueEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadValueEventArgs Members

SQLiteReadValueEventArgs overview

Public Instance Properties


ExtraEventArgs If the GetBytes or GetChars
method is being called, this object
will contain the array related
parameters for that method. If the
GetBlob method is being called, this
object will contain the blob related
parameters for that method.
MethodName The name of the SQLiteDataReader
method that was responsible for
invoking this callback.
Value This may be used by the callback to
set the return value for the called
SQLiteDataReader method.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteReadValueEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadValueEventArgs Properties

The properties of the SQLiteReadValueEventArgs class are listed below.


For a complete list of SQLiteReadValueEventArgs class members, see
the SQLiteReadValueEventArgs Members topic.

Public Instance Properties


ExtraEventArgs If the GetBytes or GetChars
method is being called, this object
will contain the array related
parameters for that method. If the
GetBlob method is being called, this
object will contain the blob related
parameters for that method.
MethodName The name of the SQLiteDataReader
method that was responsible for
invoking this callback.
Value This may be used by the callback to
set the return value for the called
SQLiteDataReader method.

See Also
SQLiteReadValueEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadValueEventArgs.ExtraEventArgs Property

If the GetBytes or GetChars method is being called, this object will contain
the array related parameters for that method. If the GetBlob method is
being called, this object will contain the blob related parameters for that
method.

public SQLiteReadEventArgs ExtraEventArgs { public get;

See Also
SQLiteReadValueEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadValueEventArgs.MethodName Property

The name of the SQLiteDataReader method that was responsible for


invoking this callback.

public string MethodName { public get; }

See Also
SQLiteReadValueEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteReadValueEventArgs.Value Property

This may be used by the callback to set the return value for the called
SQLiteDataReader method.

public SQLiteDataReaderValue Value { public get; }

See Also
SQLiteReadValueEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteStepDelegate Delegate

This Delegate type is used with the Step method.

public delegate void SQLiteStepDelegate(


string param0,
object[] args,
int stepNumber,
ref object contextData
);

Parameters
param0
This is always the string literal "Step".
args
The arguments for the aggregate function.
stepNumber
The step number (one based). This is incrememted each time the Step
method is called.
contextData
A placeholder for implementers to store contextual data pertaining to
the current context.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTraceEventHandler Delegate

Raised when a statement first begins executing on a given connection

public delegate void SQLiteTraceEventHandler(


object sender,
TraceEventArgs e
);

Parameters
sender
The connection executing the statement
e
Event arguments of the trace

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction Class

SQLite implementation of DbTransaction that does not support nested


transactions.
For a list of all members of this type, see SQLiteTransaction Members .
System.Object MarshalByRefObject
DbTransaction
SQLiteTransactionBase
SQLiteTransaction
SQLiteTransaction2

public class SQLiteTransaction :


SQLiteTransactionBase

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteTransaction Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction Members

SQLiteTransaction overview

Public Instance Properties


Connection (inherited from Returns the underlying connection
SQLiteTransactionBase) to which this transaction applies.
IsolationLevel (inherited from Gets the isolation level of the
SQLiteTransactionBase) transaction. SQLite only supports
Serializable transactions.

Public Instance Methods


Commit Commits the current transaction.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases the
DbTransaction) unmanaged resources used by the
DbTransaction.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Rollback (inherited from Rolls back the active transaction.
SQLiteTransactionBase)
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Properties


DbConnection (inherited from Forwards to the local Connection
SQLiteTransactionBase) property

Protected Instance Methods


Begin Attempts to start a transaction. An
exception will be thrown if the
transaction cannot be started for
any reason.
Dispose Overloaded. Disposes the
transaction. If it is currently active,
any changes are rolled back.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
IssueRollback Issue a ROLLBACK command
against the database connection,
optionally re-throwing any caught
exception.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteTransaction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction Methods

The methods of the SQLiteTransaction class are listed below. For a


complete list of SQLiteTransaction class members, see the
SQLiteTransaction Members topic.

Public Instance Methods


Commit Commits the current transaction.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases the
DbTransaction) unmanaged resources used by the
DbTransaction.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Rollback (inherited from Rolls back the active transaction.
SQLiteTransactionBase)
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Begin Attempts to start a transaction. An
exception will be thrown if the
transaction cannot be started for
any reason.
Dispose Overloaded. Disposes the
transaction. If it is currently active,
any changes are rolled back.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
IssueRollback Issue a ROLLBACK command
against the database connection,
optionally re-throwing any caught
exception.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteTransaction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction.Begin Method

Attempts to start a transaction. An exception will be thrown if the


transaction cannot be started for any reason.

protected override void Begin(


bool deferredLock
);

Parameters
deferredLock
TRUE to defer the writelock, or FALSE to lock immediately

See Also
SQLiteTransaction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction.Commit Method

Commits the current transaction.

public override void Commit();

Implements
IDbTransaction.Commit

See Also
SQLiteTransaction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction.Dispose Method

Disposes the transaction. If it is currently active, any changes are rolled


back.

Overload List
Inherited from DbTransaction.
public void Dispose()
Disposes the transaction. If it is currently active, any changes are rolled
back.
protected override void Dispose(bool)

See Also
SQLiteTransaction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction.Dispose(Boolean) Method

Disposes the transaction. If it is currently active, any changes are rolled


back.

protected override void Dispose(


bool disposing
);

See Also
SQLiteTransaction Class | System.Data.SQLite Namespace |
SQLiteTransaction.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction.IssueRollback Method

Issue a ROLLBACK command against the database connection, optionally


re-throwing any caught exception.

protected override void IssueRollback(


bool throwError
);

Parameters
throwError
Non-zero to re-throw caught exceptions.

See Also
SQLiteTransaction Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2 Class

SQLite implementation of DbTransaction that does support nested


transactions.
For a list of all members of this type, see SQLiteTransaction2 Members .
System.Object MarshalByRefObject
DbTransaction
SQLiteTransactionBase
SQLiteTransaction
SQLiteTransaction2

public sealed class SQLiteTransaction2 :


SQLiteTransaction

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteTransaction2 Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2 Members

SQLiteTransaction2 overview

Public Instance Properties


Connection (inherited from Returns the underlying connection
SQLiteTransactionBase) to which this transaction applies.
IsolationLevel (inherited from Gets the isolation level of the
SQLiteTransactionBase) transaction. SQLite only supports
Serializable transactions.

Public Instance Methods


Commit Commits the current transaction.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases the
DbTransaction) unmanaged resources used by the
DbTransaction.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Rollback (inherited from Rolls back the active transaction.
SQLiteTransactionBase)
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Properties


DbConnection (inherited from Forwards to the local Connection
SQLiteTransactionBase) property

Protected Instance Methods


Begin Attempts to start a transaction. An
exception will be thrown if the
transaction cannot be started for
any reason.
Dispose Overloaded. Disposes the
transaction. If it is currently active,
any changes are rolled back.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
IssueRollback Issue a ROLLBACK command
against the database connection,
optionally re-throwing any caught
exception.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteTransaction2 Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2 Methods

The methods of the SQLiteTransaction2 class are listed below. For a


complete list of SQLiteTransaction2 class members, see the
SQLiteTransaction2 Members topic.

Public Instance Methods


Commit Commits the current transaction.
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases the
DbTransaction) unmanaged resources used by the
DbTransaction.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Rollback (inherited from Rolls back the active transaction.
SQLiteTransactionBase)
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Begin Attempts to start a transaction. An
exception will be thrown if the
transaction cannot be started for
any reason.
Dispose Overloaded. Disposes the
transaction. If it is currently active,
any changes are rolled back.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
IssueRollback Issue a ROLLBACK command
against the database connection,
optionally re-throwing any caught
exception.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteTransaction2 Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2.Begin Method

Attempts to start a transaction. An exception will be thrown if the


transaction cannot be started for any reason.

protected override void Begin(


bool deferredLock
);

Parameters
deferredLock
TRUE to defer the writelock, or FALSE to lock immediately

See Also
SQLiteTransaction2 Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2.Commit Method

Commits the current transaction.

public override void Commit();

Implements
IDbTransaction.Commit

See Also
SQLiteTransaction2 Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2.Dispose Method

Disposes the transaction. If it is currently active, any changes are rolled


back.

Overload List
Inherited from DbTransaction.
public void Dispose()
Disposes the transaction. If it is currently active, any changes are rolled
back.
protected override void Dispose(bool)

See Also
SQLiteTransaction2 Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2.Dispose(Boolean) Method

Disposes the transaction. If it is currently active, any changes are rolled


back.

protected override void Dispose(


bool disposing
);

See Also
SQLiteTransaction2 Class | System.Data.SQLite Namespace |
SQLiteTransaction2.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransaction2.IssueRollback Method

Issue a ROLLBACK command against the database connection, optionally


re-throwing any caught exception.

protected override void IssueRollback(


bool throwError
);

Parameters
throwError
Non-zero to re-throw caught exceptions.

See Also
SQLiteTransaction2 Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase Class

Base class used by to implement DbTransaction for SQLite.


For a list of all members of this type, see SQLiteTransactionBase Members .
System.Object MarshalByRefObject
DbTransaction
SQLiteTransactionBase
SQLiteTransaction

public abstract class SQLiteTransactionBase :


DbTransaction

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteTransactionBase Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase Members

SQLiteTransactionBase overview

Public Instance Properties


Connection Overloaded. Returns the underlying
connection to which this
transaction applies.
IsolationLevel Gets the isolation level of the
transaction. SQLite only supports
Serializable transactions.

Public Instance Methods


Commit (inherited from Commits the database transaction.
DbTransaction)
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases the
DbTransaction) unmanaged resources used by the
DbTransaction.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Rollback Rolls back the active transaction.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Properties


DbConnection Forwards to the local Connection
property

Protected Instance Methods


Begin Attempts to start a transaction. An
exception will be thrown if the
transaction cannot be started for
any reason.
Dispose Overloaded. Disposes the
transaction. If it is currently active,
any changes are rolled back.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
IssueRollback Issue a ROLLBACK command
against the database connection,
optionally re-throwing any caught
exception.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase Properties

The properties of the SQLiteTransactionBase class are listed below. For


a complete list of SQLiteTransactionBase class members, see the
SQLiteTransactionBase Members topic.

Public Instance Properties


Connection Overloaded. Returns the underlying
connection to which this
transaction applies.
IsolationLevel Gets the isolation level of the
transaction. SQLite only supports
Serializable transactions.

Protected Instance Properties


DbConnection Forwards to the local Connection
property

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.Connection Property

Returns the underlying connection to which this transaction applies.

new public SQLiteConnection Connection { public get; }

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.DbConnection Property

Forwards to the local Connection property

protected override DbConnection DbConnection { protected

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.IsolationLevel Property

Gets the isolation level of the transaction. SQLite only supports


Serializable transactions.

public override IsolationLevel IsolationLevel { public g

Implements
IDbTransaction.IsolationLevel

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase Methods

The methods of the SQLiteTransactionBase class are listed below. For a


complete list of SQLiteTransactionBase class members, see the
SQLiteTransactionBase Members topic.

Public Instance Methods


Commit (inherited from Commits the database transaction.
DbTransaction)
CreateObjRef (inherited from Creates an object that contains all
MarshalByRefObject) the relevant information required
to generate a proxy used to
communicate with a remote object.
Dispose (inherited from Overloaded. Releases the
DbTransaction) unmanaged resources used by the
DbTransaction.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetLifetimeService (inherited Retrieves the current lifetime
from MarshalByRefObject) service object that controls the
lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current
instance.
InitializeLifetimeService Obtains a lifetime service object to
(inherited from control the lifetime policy for this
MarshalByRefObject) instance.
Rollback Rolls back the active transaction.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Begin Attempts to start a transaction. An
exception will be thrown if the
transaction cannot be started for
any reason.
Dispose Overloaded. Disposes the
transaction. If it is currently active,
any changes are rolled back.
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
IssueRollback Issue a ROLLBACK command
against the database connection,
optionally re-throwing any caught
exception.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
MarshalByRefObject) of the current MarshalByRefObject
object.
MemberwiseClone (inherited from Overloaded. Creates a shallow copy
Object) of the current Object.

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.Begin Method

Attempts to start a transaction. An exception will be thrown if the


transaction cannot be started for any reason.

protected abstract void Begin(


bool deferredLock
);

Parameters
deferredLock
TRUE to defer the writelock, or FALSE to lock immediately

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.Dispose Method

Disposes the transaction. If it is currently active, any changes are rolled


back.

Overload List
Inherited from DbTransaction.
public void Dispose()
Disposes the transaction. If it is currently active, any changes are rolled
back.
protected override void Dispose(bool)

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.Dispose(Boolean) Method

Disposes the transaction. If it is currently active, any changes are rolled


back.

protected override void Dispose(


bool disposing
);

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace |
SQLiteTransactionBase.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.IssueRollback Method

Issue a ROLLBACK command against the database connection, optionally


re-throwing any caught exception.

protected abstract void IssueRollback(


bool throwError
);

Parameters
throwError
Non-zero to re-throw caught exceptions.

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTransactionBase.Rollback Method

Rolls back the active transaction.

public override void Rollback();

Implements
IDbTransaction.Rollback

See Also
SQLiteTransactionBase Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks Class

This class represents the custom data type handling callbacks for a single
type name.
For a list of all members of this type, see SQLiteTypeCallbacks Members .
System.Object SQLiteTypeCallbacks

public sealed class SQLiteTypeCallbacks

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteTypeCallbacks Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks Members

SQLiteTypeCallbacks overview

Public Static Methods


Create Creates an instance of the
SQLiteTypeCallbacks class.

Public Instance Properties


BindValueCallback The custom paramater binding
callback. This value may be null.
BindValueUserData The extra data to pass into the
parameter binding callback. This
value may be null.
ReadValueCallback The custom data reader value
callback. This value may be null.
ReadValueUserData The extra data to pass into the data
reader value callback. This value
may be null.
TypeName The database type name that the
callbacks contained in this class will
apply to. This value may not be
null.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.
Protected Instance Methods
Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks Properties

The properties of the SQLiteTypeCallbacks class are listed below. For a


complete list of SQLiteTypeCallbacks class members, see the
SQLiteTypeCallbacks Members topic.

Public Instance Properties


BindValueCallback The custom paramater binding
callback. This value may be null.
BindValueUserData The extra data to pass into the
parameter binding callback. This
value may be null.
ReadValueCallback The custom data reader value
callback. This value may be null.
ReadValueUserData The extra data to pass into the data
reader value callback. This value
may be null.
TypeName The database type name that the
callbacks contained in this class will
apply to. This value may not be
null.

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks.BindValueCallback Property

The custom paramater binding callback. This value may be null.

public SQLiteBindValueCallback BindValueCallback { publi

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks.BindValueUserData Property

The extra data to pass into the parameter binding callback. This value may
be null.

public object BindValueUserData { public get; }

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks.ReadValueCallback Property

The custom data reader value callback. This value may be null.

public SQLiteReadValueCallback ReadValueCallback { publi

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks.ReadValueUserData Property

The extra data to pass into the data reader value callback. This value may
be null.

public object ReadValueUserData { public get; }

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks.TypeName Property

The database type name that the callbacks contained in this class will
apply to. This value may not be null.

public string TypeName { public get; internal set; }

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks Methods

The methods of the SQLiteTypeCallbacks class are listed below. For a


complete list of SQLiteTypeCallbacks class members, see the
SQLiteTypeCallbacks Members topic.

Public Static Methods


Create Creates an instance of the
SQLiteTypeCallbacks class.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteTypeCallbacks.Create Method

Creates an instance of the SQLiteTypeCallbacks class.

public static SQLiteTypeCallbacks Create(


SQLiteBindValueCallback bindValueCallback,
SQLiteReadValueCallback readValueCallback,
object bindValueUserData,
object readValueUserData
);

Parameters
bindValueCallback
The custom paramater binding callback. This parameter may be null.
readValueCallback
The custom data reader value callback. This parameter may be null.
bindValueUserData
The extra data to pass into the parameter binding callback. This
parameter may be null.
readValueUserData
The extra data to pass into the data reader value callback. This
parameter may be null.

See Also
SQLiteTypeCallbacks Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteUpdateEventHandler Delegate

Raised when data is inserted, updated and deleted on a given connection

public delegate void SQLiteUpdateEventHandler(


object sender,
UpdateEventArgs e
);

Parameters
sender
The connection committing the transaction
e
The event parameters which triggered the event

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue Class

This class represents a value from the SQLite core library that can be
passed to the sqlite3_value_*() and associated functions.
For a list of all members of this type, see SQLiteValue Members .
System.Object SQLiteValue

public sealed class SQLiteValue : ISQLiteNativeHandle

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteValue Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue Members

SQLiteValue overview

Public Instance Properties


NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.
Persisted Returns non-zero if the native
SQLite value has been successfully
persisted as a managed value
within this object instance (i.e. the
Value property may then be read
successfully).
Value If the managed value for this object
instance is available (i.e. it has
been previously persisted via the
Persist) method, that value is
returned; otherwise, an exception
is thrown. The returned value may
be null.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetBlob Gets and returns the Byte array
associated with this value.
GetBytes Gets and returns the number of
bytes associated with this value, if
it refers to a UTF-8 encoded string.
GetDouble Gets and returns the Double
associated with this value.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetInt Gets and returns the Int32
associated with this value.
GetInt64 Gets and returns the Int64
associated with this value.
GetString Gets and returns the String
associated with this value.
GetType (inherited from Object) Gets the Type of the current
instance.
GetTypeAffinity Gets and returns the type affinity
associated with this value.
Persist Uses the native value handle to
obtain and store the managed
value for this object instance, thus
saving it for later use. The type of
the managed value is determined
by the type affinity of the native
value. If the type affinity is not
recognized by this method, no work
is done and false is returned.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue Properties

The properties of the SQLiteValue class are listed below. For a complete
list of SQLiteValue class members, see the SQLiteValue Members topic.

Public Instance Properties


NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.
Persisted Returns non-zero if the native
SQLite value has been successfully
persisted as a managed value
within this object instance (i.e. the
Value property may then be read
successfully).
Value If the managed value for this object
instance is available (i.e. it has
been previously persisted via the
Persist) method, that value is
returned; otherwise, an exception
is thrown. The returned value may
be null.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.NativeHandle Property

Returns the underlying SQLite native handle associated with this object
instance.

public IntPtr NativeHandle { public get; }

Implements
ISQLiteNativeHandle.NativeHandle

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.Persisted Property

Returns non-zero if the native SQLite value has been successfully


persisted as a managed value within this object instance (i.e. the Value
property may then be read successfully).

public bool Persisted { public get; }

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.Value Property

If the managed value for this object instance is available (i.e. it has been
previously persisted via the Persist) method, that value is returned;
otherwise, an exception is thrown. The returned value may be null.

public object Value { public get; }

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue Methods

The methods of the SQLiteValue class are listed below. For a complete list
of SQLiteValue class members, see the SQLiteValue Members topic.

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetBlob Gets and returns the Byte array
associated with this value.
GetBytes Gets and returns the number of
bytes associated with this value, if
it refers to a UTF-8 encoded string.
GetDouble Gets and returns the Double
associated with this value.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetInt Gets and returns the Int32
associated with this value.
GetInt64 Gets and returns the Int64
associated with this value.
GetString Gets and returns the String
associated with this value.
GetType (inherited from Object) Gets the Type of the current
instance.
GetTypeAffinity Gets and returns the type affinity
associated with this value.
Persist Uses the native value handle to
obtain and store the managed
value for this object instance, thus
saving it for later use. The type of
the managed value is determined
by the type affinity of the native
value. If the type affinity is not
recognized by this method, no work
is done and false is returned.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.GetBlob Method

Gets and returns the Byte array associated with this value.

public byte[] GetBlob();

Return Value
The Byte array associated with this value.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.GetBytes Method

Gets and returns the number of bytes associated with this value, if it
refers to a UTF-8 encoded string.

public int GetBytes();

Return Value
The number of bytes associated with this value. The returned value may
be zero.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.GetDouble Method

Gets and returns the Double associated with this value.

public double GetDouble();

Return Value
The Double associated with this value.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.GetInt Method

Gets and returns the Int32 associated with this value.

public int GetInt();

Return Value
The Int32 associated with this value.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.GetInt64 Method

Gets and returns the Int64 associated with this value.

public long GetInt64();

Return Value
The Int64 associated with this value.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.GetString Method

Gets and returns the String associated with this value.

public string GetString();

Return Value
The String associated with this value. The value is converted from the
UTF-8 encoding prior to being returned.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.GetTypeAffinity Method

Gets and returns the type affinity associated with this value.

public TypeAffinity GetTypeAffinity();

Return Value
The type affinity associated with this value.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteValue.Persist Method

Uses the native value handle to obtain and store the managed value for
this object instance, thus saving it for later use. The type of the managed
value is determined by the type affinity of the native value. If the type
affinity is not recognized by this method, no work is done and false is
returned.

public bool Persist();

Return Value
Non-zero if the native value was persisted successfully.

See Also
SQLiteValue Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable Class

This class represents a managed virtual table implementation. It is not


sealed and should be used as the base class for any user-defined virtual
table classes implemented in managed code.
For a list of all members of this type, see SQLiteVirtualTable Members .
System.Object SQLiteVirtualTable

public class SQLiteVirtualTable :


ISQLiteNativeHandle, IDisposable

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteVirtualTable Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable Members

SQLiteVirtualTable overview

Public Instance Constructors


SQLiteVirtualTable Constructor Constructs an instance of this class.

Public Instance Properties


Arguments The original array of strings
provided to the Create and Connect
methods.
DatabaseName The name of the database
containing this virtual table.
Index The SQLiteIndex object instance
containing all the data for the
inputs and outputs relating to the
most recent index selection.
ModuleName The name of the module
implementing this virtual table.
NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.
TableName The name of the virtual table.

Public Instance Methods


BestIndex This method should normally be
used by the BestIndex method in
order to perform index selection
based on the constraints provided
by the SQLite core library.
Dispose Overloaded. Disposes of this object
instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Rename Attempts to record the renaming of
the virtual table associated with
this object instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize Finalizes this object instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable Constructor

Constructs an instance of this class.

SQLiteVirtualTable(
string[] arguments
);

Parameters
arguments
The original array of strings provided to the Create and Connect
methods.

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable Properties

The properties of the SQLiteVirtualTable class are listed below. For a


complete list of SQLiteVirtualTable class members, see the
SQLiteVirtualTable Members topic.

Public Instance Properties


Arguments The original array of strings
provided to the Create and Connect
methods.
DatabaseName The name of the database
containing this virtual table.
Index The SQLiteIndex object instance
containing all the data for the
inputs and outputs relating to the
most recent index selection.
ModuleName The name of the module
implementing this virtual table.
NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.
TableName The name of the virtual table.

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.Arguments Property

The original array of strings provided to the Create and Connect methods.

public virtual string[] Arguments { public get; }

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.DatabaseName Property

The name of the database containing this virtual table.

public virtual string DatabaseName { public get; }

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.Index Property

The SQLiteIndex object instance containing all the data for the inputs and
outputs relating to the most recent index selection.

public virtual SQLiteIndex Index { public get; }

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.ModuleName Property

The name of the module implementing this virtual table.

public virtual string ModuleName { public get; }

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.NativeHandle Property

Returns the underlying SQLite native handle associated with this object
instance.

public virtual IntPtr NativeHandle { public get; interna

Implements
ISQLiteNativeHandle.NativeHandle

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.TableName Property

The name of the virtual table.

public virtual string TableName { public get; }

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable Methods

The methods of the SQLiteVirtualTable class are listed below. For a


complete list of SQLiteVirtualTable class members, see the
SQLiteVirtualTable Members topic.

Public Instance Methods


BestIndex This method should normally be
used by the BestIndex method in
order to perform index selection
based on the constraints provided
by the SQLite core library.
Dispose Overloaded. Disposes of this object
instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Rename Attempts to record the renaming of
the virtual table associated with
this object instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize Finalizes this object instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.BestIndex Method

This method should normally be used by the BestIndex method in order to


perform index selection based on the constraints provided by the SQLite
core library.

public virtual bool BestIndex(


SQLiteIndex index
);

Parameters
index
The SQLiteIndex object instance containing all the data for the inputs
and outputs relating to index selection.

Return Value
Non-zero upon success.

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.Dispose Method

Disposes of this object instance.

Overload List
Disposes of this object instance.
public void Dispose()
Disposes of this object instance.
protected virtual void Dispose(bool)

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.Dispose() Method

Disposes of this object instance.

public void Dispose();

Implements
IDisposable.Dispose

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace |
SQLiteVirtualTable.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.Dispose(Boolean) Method

Disposes of this object instance.

protected virtual void Dispose(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace |
SQLiteVirtualTable.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.Finalize Method

Finalizes this object instance.

protected override void Finalize();

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTable.Rename Method

Attempts to record the renaming of the virtual table associated with this
object instance.

public virtual bool Rename(


string name
);

Parameters
name
The new name for the virtual table.

Return Value
Non-zero upon success.

See Also
SQLiteVirtualTable Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor Class

This class represents a managed virtual table cursor implementation. It is


not sealed and should be used as the base class for any user-defined
virtual table cursor classes implemented in managed code.
For a list of all members of this type, see SQLiteVirtualTableCursor
Members .
System.Object SQLiteVirtualTableCursor
SQLiteVirtualTableCursorEnumerator

public class SQLiteVirtualTableCursor :


ISQLiteNativeHandle, IDisposable

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteVirtualTableCursor Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor Members

SQLiteVirtualTableCursor overview

Protected Static Fields


InvalidRowIndex This value represents an invalid
integer row sequence number.

Public Instance Constructors


SQLiteVirtualTableCursor Constructs an instance of this class.
Constructor

Public Instance Properties


IndexNumber Number used to help identify the
selected index. This value will be
set via the Filter method.
IndexString String used to help identify the
selected index. This value will be
set via the Filter method.
NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.
Table The SQLiteVirtualTable object
instance associated with this object
instance.
Values The values used to filter the rows
returned via this cursor object
instance. This value will be set via
the Filter method.

Public Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter This method should normally be
used by the Filter method in order
to perform filtering of the result
rows and/or to record the filtering
criteria provided by the SQLite core
library.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetRowIndex Determines the integer row
sequence number for the current
row.
GetType (inherited from Object) Gets the Type of the current
instance.
NextRowIndex Adjusts the integer row sequence
number so that it refers to the next
row.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize Finalizes this object instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
TryPersistValues Attempts to persist the specified
SQLiteValue object instances in
order to make them available after
the Filter method returns.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor Constructor

Constructs an instance of this class.

SQLiteVirtualTableCursor(
SQLiteVirtualTable table
);

Parameters
table
The SQLiteVirtualTable object instance associated with this object
instance.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor Fields

The fields of the SQLiteVirtualTableCursor class are listed below. For a


complete list of SQLiteVirtualTableCursor class members, see the
SQLiteVirtualTableCursor Members topic.

Protected Static Fields


InvalidRowIndex This value represents an invalid
integer row sequence number.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.InvalidRowIndex Field

This value represents an invalid integer row sequence number.

protected static readonly int InvalidRowIndex;

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor Properties

The properties of the SQLiteVirtualTableCursor class are listed below.


For a complete list of SQLiteVirtualTableCursor class members, see the
SQLiteVirtualTableCursor Members topic.

Public Instance Properties


IndexNumber Number used to help identify the
selected index. This value will be
set via the Filter method.
IndexString String used to help identify the
selected index. This value will be
set via the Filter method.
NativeHandle Returns the underlying SQLite
native handle associated with this
object instance.
Table The SQLiteVirtualTable object
instance associated with this object
instance.
Values The values used to filter the rows
returned via this cursor object
instance. This value will be set via
the Filter method.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.IndexNumber Property

Number used to help identify the selected index. This value will be set via
the Filter method.

public virtual int IndexNumber { public get; }

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.IndexString Property

String used to help identify the selected index. This value will be set via
the Filter method.

public virtual string IndexString { public get; }

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.NativeHandle Property

Returns the underlying SQLite native handle associated with this object
instance.

public virtual IntPtr NativeHandle { public get; interna

Implements
ISQLiteNativeHandle.NativeHandle

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.Table Property

The SQLiteVirtualTable object instance associated with this object instance.

public virtual SQLiteVirtualTable Table { public get; }

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.Values Property

The values used to filter the rows returned via this cursor object instance.
This value will be set via the Filter method.

public virtual SQLiteValue[] Values { public get; }

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor Methods

The methods of the SQLiteVirtualTableCursor class are listed below. For


a complete list of SQLiteVirtualTableCursor class members, see the
SQLiteVirtualTableCursor Members topic.

Public Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter This method should normally be
used by the Filter method in order
to perform filtering of the result
rows and/or to record the filtering
criteria provided by the SQLite core
library.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetRowIndex Determines the integer row
sequence number for the current
row.
GetType (inherited from Object) Gets the Type of the current
instance.
NextRowIndex Adjusts the integer row sequence
number so that it refers to the next
row.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize Finalizes this object instance.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
TryPersistValues Attempts to persist the specified
SQLiteValue object instances in
order to make them available after
the Filter method returns.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.Dispose Method

Disposes of this object instance.

Overload List
Disposes of this object instance.
public void Dispose()
Disposes of this object instance.
protected virtual void Dispose(bool)

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.Dispose() Method

Disposes of this object instance.

public void Dispose();

Implements
IDisposable.Dispose

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace |
SQLiteVirtualTableCursor.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.Dispose(Boolean) Method

Disposes of this object instance.

protected virtual void Dispose(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace |
SQLiteVirtualTableCursor.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.Filter Method

This method should normally be used by the Filter method in order to


perform filtering of the result rows and/or to record the filtering criteria
provided by the SQLite core library.

public virtual void Filter(


int indexNumber,
string indexString,
SQLiteValue[] values
);

Parameters
indexNumber
Number used to help identify the selected index.
indexString
String used to help identify the selected index.
values
The values corresponding to each column in the selected index.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.Finalize Method

Finalizes this object instance.

protected override void Finalize();

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.GetRowIndex Method

Determines the integer row sequence number for the current row.

public virtual int GetRowIndex();

Return Value
The integer row sequence number for the current row -OR- zero if it
cannot be determined.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.NextRowIndex Method

Adjusts the integer row sequence number so that it refers to the next row.

public virtual void NextRowIndex();

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursor.TryPersistValues Method

Attempts to persist the specified SQLiteValue object instances in order to


make them available after the Filter method returns.

protected virtual int TryPersistValues(


SQLiteValue[] values
);

Parameters
values
The array of SQLiteValue object instances to be persisted.

Return Value
The number of SQLiteValue object instances that were successfully
persisted.

See Also
SQLiteVirtualTableCursor Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator Class

This class represents a virtual table cursor to be used with the


SQLiteModuleEnumerable class. It is not sealed and may be used as the
base class for any user-defined virtual table cursor class that wraps an
IEnumerator object instance.
For a list of all members of this type, see
SQLiteVirtualTableCursorEnumerator Members .
System.Object SQLiteVirtualTableCursor
SQLiteVirtualTableCursorEnumerator
SQLiteVirtualTableCursorEnumerator(T)

public class SQLiteVirtualTableCursorEnumerator :


SQLiteVirtualTableCursor, IEnumerator

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteVirtualTableCursorEnumerator Members | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator Members

SQLiteVirtualTableCursorEnumerator overview

Public Instance Constructors


Constructs an instance of this
SQLiteVirtualTableCursorEnumerator class.
Constructor

Public Instance Properties


Current Returns the value for the current
row of the virtual table cursor using
the Current property of the
IEnumerator object instance.
EndOfEnumerator Returns non-zero if the end of the
virtual table cursor has been seen
(i.e. no more rows are available,
including the current one).
IndexNumber (inherited from Number used to help identify the
SQLiteVirtualTableCursor) selected index. This value will be
set via the Filter method.
IndexString (inherited from String used to help identify the
SQLiteVirtualTableCursor) selected index. This value will be
set via the Filter method.
IsOpen Returns non-zero if the virtual
table cursor is open.
NativeHandle (inherited from Returns the underlying SQLite
SQLiteVirtualTableCursor) native handle associated with this
object instance.
Table (inherited from The SQLiteVirtualTable object
SQLiteVirtualTableCursor) instance associated with this object
instance.
Values (inherited from The values used to filter the rows
SQLiteVirtualTableCursor) returned via this cursor object
instance. This value will be set via
the Filter method.

Public Instance Methods


CheckClosed Throws an
InvalidOperationException if the
virtual table cursor has been
closed.
Close Closes the virtual table cursor. This
method must not throw any
exceptions.
Dispose (inherited from Overloaded. Disposes of this object
SQLiteVirtualTableCursor) instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter (inherited from This method should normally be
SQLiteVirtualTableCursor) used by the Filter method in order
to perform filtering of the result
rows and/or to record the filtering
criteria provided by the SQLite core
library.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetRowIndex (inherited from Determines the integer row
SQLiteVirtualTableCursor) sequence number for the current
row.
GetType (inherited from Object) Gets the Type of the current
instance.
MoveNext Advances to the next row of the
virtual table cursor using the
MoveNext method of the
IEnumerator object instance.
NextRowIndex (inherited from Adjusts the integer row sequence
SQLiteVirtualTableCursor) number so that it refers to the next
row.
Reset Resets the virtual table cursor
position, also invalidating the
current row, using the Reset
method of the IEnumerator object
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteVirtualTableCursor)
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
TryPersistValues (inherited from Attempts to persist the specified
SQLiteVirtualTableCursor) SQLiteValue object instances in
order to make them available after
the Filter method returns.

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator Constructor

Constructs an instance of this class.

SQLiteVirtualTableCursorEnumerator(
SQLiteVirtualTable table,
IEnumerator enumerator
);

Parameters
table
The SQLiteVirtualTable object instance associated with this object
instance.
enumerator
The IEnumerator instance to expose as a virtual table cursor.

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator Properties

The properties of the SQLiteVirtualTableCursorEnumerator class are


listed below. For a complete list of
SQLiteVirtualTableCursorEnumerator class members, see the
SQLiteVirtualTableCursorEnumerator Members topic.

Public Instance Properties


Current Returns the value for the current
row of the virtual table cursor using
the Current property of the
IEnumerator object instance.
EndOfEnumerator Returns non-zero if the end of the
virtual table cursor has been seen
(i.e. no more rows are available,
including the current one).
IndexNumber (inherited from Number used to help identify the
SQLiteVirtualTableCursor) selected index. This value will be
set via the Filter method.
IndexString (inherited from String used to help identify the
SQLiteVirtualTableCursor) selected index. This value will be
set via the Filter method.
IsOpen Returns non-zero if the virtual
table cursor is open.
NativeHandle (inherited from Returns the underlying SQLite
SQLiteVirtualTableCursor) native handle associated with this
object instance.
Table (inherited from The SQLiteVirtualTable object
SQLiteVirtualTableCursor) instance associated with this object
instance.
Values (inherited from The values used to filter the rows
SQLiteVirtualTableCursor) returned via this cursor object
instance. This value will be set via
the Filter method.

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace
Send comments on this topic.
Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.Current Property

Returns the value for the current row of the virtual table cursor using the
Current property of the IEnumerator object instance.

public virtual object Current { public get; }

Implements
IEnumerator.Current

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.EndOfEnumerator
Property

Returns non-zero if the end of the virtual table cursor has been seen (i.e.
no more rows are available, including the current one).

public virtual bool EndOfEnumerator { public get; }

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.IsOpen Property

Returns non-zero if the virtual table cursor is open.

public virtual bool IsOpen { public get; }

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator Methods

The methods of the SQLiteVirtualTableCursorEnumerator class are


listed below. For a complete list of
SQLiteVirtualTableCursorEnumerator class members, see the
SQLiteVirtualTableCursorEnumerator Members topic.

Public Instance Methods


CheckClosed Throws an
InvalidOperationException if the
virtual table cursor has been
closed.
Close Closes the virtual table cursor. This
method must not throw any
exceptions.
Dispose (inherited from Overloaded. Disposes of this object
SQLiteVirtualTableCursor) instance.
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter (inherited from This method should normally be
SQLiteVirtualTableCursor) used by the Filter method in order
to perform filtering of the result
rows and/or to record the filtering
criteria provided by the SQLite core
library.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetRowIndex (inherited from Determines the integer row
SQLiteVirtualTableCursor) sequence number for the current
row.
GetType (inherited from Object) Gets the Type of the current
instance.
MoveNext Advances to the next row of the
virtual table cursor using the
MoveNext method of the
IEnumerator object instance.
NextRowIndex (inherited from Adjusts the integer row sequence
SQLiteVirtualTableCursor) number so that it refers to the next
row.
Reset Resets the virtual table cursor
position, also invalidating the
current row, using the Reset
method of the IEnumerator object
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteVirtualTableCursor)
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
TryPersistValues (inherited from Attempts to persist the specified
SQLiteVirtualTableCursor) SQLiteValue object instances in
order to make them available after
the Filter method returns.

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.CheckClosed Method

Throws an InvalidOperationException if the virtual table cursor has been


closed.

public virtual void CheckClosed();

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.Close Method

Closes the virtual table cursor. This method must not throw any
exceptions.

public virtual void Close();

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.Dispose Method

Disposes of this object instance.

Overload List
Inherited from SQLiteVirtualTableCursor.
public void Dispose()
Disposes of this object instance.
protected override void Dispose(bool)

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.Dispose(Boolean)
Method

Disposes of this object instance.

protected override void Dispose(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace | SQLiteVirtualTableCursorEnumerator.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.MoveNext Method

Advances to the next row of the virtual table cursor using the MoveNext
method of the IEnumerator object instance.

public virtual bool MoveNext();

Return Value
Non-zero if the current row is valid; zero otherwise. If zero is returned, no
further rows are available.

Implements
IEnumerator.MoveNext

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator.Reset Method

Resets the virtual table cursor position, also invalidating the current row,
using the Reset method of the IEnumerator object instance.

public virtual void Reset();

Implements
IEnumerator.Reset

See Also
SQLiteVirtualTableCursorEnumerator Class | System.Data.SQLite
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SynchronizationModes Enumeration

The I/O file cache flushing behavior for the connection

public enum SynchronizationModes

Members
Member Name Description
Normal Normal file flushing at critical
sections of the code
Full Full file flushing after every write
operation
Off Use the default operating system's
file flushing, SQLite does not
explicitly flush the file buffers after
writing

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
TraceEventArgs Class

Passed during an Trace callback, these event arguments contain the UTF-8
rendering of the SQL statement text
For a list of all members of this type, see TraceEventArgs Members .
System.Object EventArgs
TraceEventArgs

public class TraceEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
TraceEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
TraceEventArgs Members

TraceEventArgs overview

Public Instance Fields


Statement SQL statement text as the
statement first begins executing

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.

See Also
TraceEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
TraceEventArgs Fields

The fields of the TraceEventArgs class are listed below. For a complete
list of TraceEventArgs class members, see the TraceEventArgs Members
topic.

Public Instance Fields


Statement SQL statement text as the
statement first begins executing

See Also
TraceEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
TraceEventArgs.Statement Field

SQL statement text as the statement first begins executing

public readonly string Statement;

See Also
TraceEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
TypeAffinity Enumeration

SQLite has very limited types, and is inherently text-based. The first 5
types below represent the sum of all types SQLite understands. The
DateTime extension to the spec is for internal use only.

public enum TypeAffinity

Members
Member Name Description
Uninitialized Not used
Int64 All integers in SQLite default to
Int64
Double All floating point numbers in SQLite
default to double
Text The default data type of SQLite is
text
Blob Typically blob types are only seen
when returned from a function
Null Null types can be returned from
functions
DateTime Used internally by this provider
None Used internally by this provider

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventArgs Class

Passed during an Update callback, these event arguments detail the type
of update operation being performed on the given connection.
For a list of all members of this type, see UpdateEventArgs Members .
System.Object EventArgs
UpdateEventArgs

public class UpdateEventArgs : EventArgs

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
UpdateEventArgs Members | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventArgs Members

UpdateEventArgs overview

Public Instance Fields


Database The name of the database being
updated (usually "main" but can be
any attached or temporary
database)
Event The type of update being performed
(insert/update/delete)
RowId The RowId affected by this update.
Table The name of the table being
updated

Public Instance Methods


Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
ToString (inherited from Object) Returns a String that represents
the current Object.

Protected Instance Methods


Finalize (inherited from Object) Allows an Object to attempt to free
resources and perform other
cleanup operations before the
Object is reclaimed by garbage
collection.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
See Also
UpdateEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventArgs Fields

The fields of the UpdateEventArgs class are listed below. For a complete
list of UpdateEventArgs class members, see the UpdateEventArgs
Members topic.

Public Instance Fields


Database The name of the database being
updated (usually "main" but can be
any attached or temporary
database)
Event The type of update being performed
(insert/update/delete)
RowId The RowId affected by this update.
Table The name of the table being
updated

See Also
UpdateEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventArgs.Database Field

The name of the database being updated (usually "main" but can be any
attached or temporary database)

public readonly string Database;

See Also
UpdateEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventArgs.Event Field

The type of update being performed (insert/update/delete)

public readonly UpdateEventType Event;

See Also
UpdateEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventArgs.RowId Field

The RowId affected by this update.

public readonly long RowId;

See Also
UpdateEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventArgs.Table Field

The name of the table being updated

public readonly string Table;

See Also
UpdateEventArgs Class | System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
UpdateEventType Enumeration

Whenever an update event is triggered on a connection, this enum will


indicate exactly what type of operation is being performed.

public enum UpdateEventType

Members
Member Name Description
Delete A row is being deleted from the
given database and table
Insert A row is being inserted into the
table.
Update A row is being updated in the table.

Requirements
Namespace: System.Data.SQLite
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
System.Data.SQLite Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
System.Data.SQLite.Generic Namespace

Namespace Hierarchy

Classes
Class Description
SQLiteModuleEnumerable(T) This class implements a virtual
table module that exposes an
IEnumerable`1 object instance
as a read-only virtual table. It
is not sealed and may be used
as the base class for any user-
defined virtual table class that
wraps an IEnumerable`1
object instance.
SQLiteVirtualTableCursorEnumerator(T) This class represents a virtual
table cursor to be used with the
SQLiteModuleEnumerable class.
It is not sealed and may be
used as the base class for any
user-defined virtual table
cursor class that wraps an
IEnumerator`1 object instance.

Send comments on this topic.


SQLite ADO.NET Provider
SQLiteModuleEnumerable(T) Class

This class implements a virtual table module that exposes an


IEnumerable`1 object instance as a read-only virtual table. It is not sealed
and may be used as the base class for any user-defined virtual table class
that wraps an IEnumerable`1 object instance.
For a list of all members of this type, see SQLiteModuleEnumerable(T)
Members .
System.Object SQLiteModule
SQLiteModuleNoop
SQLiteModuleCommon
SQLiteModuleEnumerable
SQLiteModuleEnumerable(T)

public class SQLiteModuleEnumerable<T> :


SQLiteModuleEnumerable

Requirements
Namespace: System.Data.SQLite.Generic
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteModuleEnumerable(T) Members | System.Data.SQLite.Generic
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable(T) Members

SQLiteModuleEnumerable(T) overview

Public Instance Constructors


SQLiteModuleEnumerable(T) Constructs an instance of this class.
Constructor

Public Instance Properties


Declared (inherited from Returns non-zero if the schema for
SQLiteModule) the virtual table has been declared.
LogErrors (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptions (inherited from Returns or sets a boolean value
SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
xDestroy method, and the Dispose
method should be logged using the
SQLiteLog class.
Name (inherited from Returns the name of the module as
SQLiteModule) it was registered with the SQLite
core library.

Public Instance Methods


Begin (inherited from See the Begin method.
SQLiteModuleNoop)
BestIndex (inherited from See the BestIndex method.
SQLiteModuleEnumerable)
Close (inherited from See the Close method.
SQLiteModuleEnumerable)
Column See the Column method.
Commit (inherited from See the Commit method.
SQLiteModuleNoop)
Connect (inherited from See the Connect method.
SQLiteModuleEnumerable)
Create (inherited from See the Create method.
SQLiteModuleEnumerable)
Destroy (inherited from See the Destroy method.
SQLiteModuleEnumerable)
Disconnect (inherited from See the Disconnect method.
SQLiteModuleEnumerable)
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof (inherited from See the Eof method.
SQLiteModuleEnumerable)
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter (inherited from See the Filter method.
SQLiteModuleEnumerable)
FindFunction (inherited from See the FindFunction method.
SQLiteModuleNoop)
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next (inherited from See the Next method.
SQLiteModuleEnumerable)
Open See the Open method.
Release (inherited from See the Release method.
SQLiteModuleNoop)
Rename (inherited from See the Rename method.
SQLiteModuleEnumerable)
Rollback (inherited from See the Rollback method.
SQLiteModuleNoop)
RollbackTo (inherited from See the RollbackTo method.
SQLiteModuleNoop)
RowId (inherited from See the RowId method.
SQLiteModuleEnumerable)
Savepoint (inherited from See the Savepoint method.
SQLiteModuleNoop)
Sync (inherited from See the Sync method.
SQLiteModuleNoop)
ToString (inherited from Object) Returns a String that represents
the current Object.
Update (inherited from See the Update method.
SQLiteModuleEnumerable)

Protected Instance Properties


LogErrorsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether virtual table
errors should be logged using the
SQLiteLog class.
LogExceptionsNoThrow (inherited Returns or sets a boolean value
from SQLiteModule) indicating whether exceptions
caught in the xDisconnect method,
the xDestroy method, the
SetTableError method, the
SetTableError method, and the
Dispose method should be logged
using the SQLiteLog class.

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorEndOfEnumeratorError Sets the table error message to one
(inherited from that indicates the virtual table
SQLiteModuleEnumerable) cursor has no current row.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
CursorTypeMismatchError Sets the table error message to one
(inherited from that indicates the virtual table
SQLiteModuleCommon) cursor is of the wrong type.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.
FreeTable (inherited from Frees a native sqlite3_vtab
SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode (inherited Determines the default
from SQLiteModuleNoop) SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetMethodResultCode (inherited Determines the SQLiteErrorCode
from SQLiteModuleNoop) value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is available
(or set) for the specified method,
the SQLiteErrorCode value
returned by the
GetDefaultResultCode method will
be returned instead.
GetNativeModuleImpl (inherited Gets and returns the
from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
GetRowIdFromObject (inherited Determines the unique row
from SQLiteModuleCommon) identifier for the current row.
GetSqlForDeclareTable (inherited Determines the SQL statement
from SQLiteModuleCommon) used to declare the virtual table.
This method should be overridden
in derived classes if they require a
custom virtual table schema.

GetStringFromObject (inherited Determines the string to return as


from SQLiteModuleCommon) the column value for the object
instance value.
MakeRowId (inherited from Constructs an Int64 unique row
SQLiteModuleCommon) identifier from two Int32 values.
The first Int32 value must contain
the row sequence number for the
current row and the second value
must contain the hash code of the
key column value for the current
row.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
ResultCodeToEofResult (inherited Converts a SQLiteErrorCode value
from SQLiteModuleNoop) into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
(inherited from into a boolean return value for use
SQLiteModuleNoop) with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode (inherited Sets the SQLiteErrorCode value
from SQLiteModuleNoop) that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.
SetTableError (inherited from Overloaded. Arranges for the
SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor (inherited from Reads and returns the native
SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleEnumerable<T> Class | System.Data.SQLite.Generic
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable(T) Constructor

Constructs an instance of this class.

SQLiteModuleEnumerable<T>(
string name,
IEnumerable<T> enumerable
);

Parameters
name
The name of the module. This parameter cannot be null.
enumerable
The IEnumerable`1 instance to expose as a virtual table. This
parameter cannot be null.

See Also
SQLiteModuleEnumerable<T> Class | System.Data.SQLite.Generic
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable(T) Methods

The methods of the SQLiteModuleEnumerable(T) class are listed below.


For a complete list of SQLiteModuleEnumerable(T) class members, see
the SQLiteModuleEnumerable(T) Members topic.

Public Instance Methods


Begin (inherited from See the Begin method.
SQLiteModuleNoop)
BestIndex (inherited from See the BestIndex method.
SQLiteModuleEnumerable)
Close (inherited from See the Close method.
SQLiteModuleEnumerable)
Column See the Column method.
Commit (inherited from See the Commit method.
SQLiteModuleNoop)
Connect (inherited from See the Connect method.
SQLiteModuleEnumerable)
Create (inherited from See the Create method.
SQLiteModuleEnumerable)
Destroy (inherited from See the Destroy method.
SQLiteModuleEnumerable)
Disconnect (inherited from See the Disconnect method.
SQLiteModuleEnumerable)
Dispose (inherited from Overloaded. Disposes of this object
SQLiteModule) instance.
Eof (inherited from See the Eof method.
SQLiteModuleEnumerable)
Equals (inherited from Object) Determines whether the specified
Object is equal to the current
Object.
Filter (inherited from See the Filter method.
SQLiteModuleEnumerable)
FindFunction (inherited from See the FindFunction method.
SQLiteModuleNoop)
GetHashCode (inherited from Serves as a hash function for a
Object) particular type. GetHashCode is
suitable for use in hashing
algorithms and data structures like
a hash table.
GetType (inherited from Object) Gets the Type of the current
instance.
Next (inherited from See the Next method.
SQLiteModuleEnumerable)
Open See the Open method.
Release (inherited from See the Release method.
SQLiteModuleNoop)
Rename (inherited from See the Rename method.
SQLiteModuleEnumerable)
Rollback (inherited from See the Rollback method.
SQLiteModuleNoop)
RollbackTo (inherited from See the RollbackTo method.
SQLiteModuleNoop)
RowId (inherited from See the RowId method.
SQLiteModuleEnumerable)
Savepoint (inherited from See the Savepoint method.
SQLiteModuleNoop)
Sync (inherited from See the Sync method.
SQLiteModuleNoop)
ToString (inherited from Object) Returns a String that represents
the current Object.
Update (inherited from See the Update method.
SQLiteModuleEnumerable)

Protected Instance Methods


AllocateCursor (inherited from Allocates a native
SQLiteModule) sqlite3_vtab_cursor derived
structure and returns a native
pointer to it.
AllocateTable (inherited from Allocates a native sqlite3_vtab
SQLiteModule) derived structure and returns a
native pointer to it.
CreateNativeModuleImpl Creates and returns the
(inherited from SQLiteModule) ISQLiteNativeModule interface
implementation corresponding to
the current SQLiteModule object
instance.
CursorEndOfEnumeratorError Sets the table error message to one
(inherited from that indicates the virtual table
SQLiteModuleEnumerable) cursor has no current row.
CursorFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTableCursor object
instance based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
CursorToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab_cursor
derived structure and creates an
association between it and the
specified SQLiteVirtualTableCursor
object instance.
CursorTypeMismatchError Sets the table error message to one
(inherited from that indicates the virtual table
SQLiteModuleCommon) cursor is of the wrong type.
DeclareFunction (inherited from Calls the native SQLite core library
SQLiteModule) in order to declare a virtual table
function in response to a call into
the xCreate or xConnect virtual
table methods.
DeclareTable (inherited from Attempts to declare the schema for
SQLiteModule) the virtual table using the specified
database connection.
Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteModule)
FreeCursor (inherited from Frees a native sqlite3_vtab_cursor
SQLiteModule) structure using the provided native
pointer to it.

FreeTable (inherited from Frees a native sqlite3_vtab


SQLiteModule) structure using the provided native
pointer to it.
GetDefaultResultCode (inherited Determines the default
from SQLiteModuleNoop) SQLiteErrorCode value to be
returned by methods of the
ISQLiteManagedModule interface
that lack an overridden
implementation in all classes
derived from the
SQLiteModuleNoop class.
GetFunctionKey (inherited from Deterimines the key that should be
SQLiteModule) used to identify and store the
SQLiteFunction object instance for
the virtual table (i.e. to be returned
via the xFindFunction method).
GetMethodResultCode (inherited Determines the SQLiteErrorCode
from SQLiteModuleNoop) value that should be returned by
the specified
ISQLiteManagedModule interface
method if it lack an overridden
implementation. If no specific
SQLiteErrorCode value is available
(or set) for the specified method,
the SQLiteErrorCode value
returned by the
GetDefaultResultCode method will
be returned instead.
GetNativeModuleImpl (inherited Gets and returns the
from SQLiteModule) ISQLiteNativeModule interface
implementation to be used when
creating the native sqlite3_module
structure. Derived classes may
override this method to supply an
alternate implementation for the
ISQLiteNativeModule interface.
GetRowIdFromObject (inherited Determines the unique row
from SQLiteModuleCommon) identifier for the current row.

GetSqlForDeclareTable (inherited Determines the SQL statement


from SQLiteModuleCommon) used to declare the virtual table.
This method should be overridden
in derived classes if they require a
custom virtual table schema.
GetStringFromObject (inherited Determines the string to return as
from SQLiteModuleCommon) the column value for the object
instance value.
MakeRowId (inherited from Constructs an Int64 unique row
SQLiteModuleCommon) identifier from two Int32 values.
The first Int32 value must contain
the row sequence number for the
current row and the second value
must contain the hash code of the
key column value for the current
row.
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
ResultCodeToEofResult (inherited Converts a SQLiteErrorCode value
from SQLiteModuleNoop) into a boolean return value for use
with the Eof method.
ResultCodeToFindFunctionResult Converts a SQLiteErrorCode value
(inherited from into a boolean return value for use
SQLiteModuleNoop) with the FindFunction method.
SetCursorError (inherited from Arranges for the specified error
SQLiteModule) message to be placed into the
zErrMsg field of a sqlite3_vtab
derived structure, freeing the
existing error message, if any.
SetEstimatedCost (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
cost.
SetEstimatedRows (inherited from Overloaded. Modifies the specified
SQLiteModule) SQLiteIndex object instance to
contain the specified estimated
rows.
SetIndexFlags (inherited from Overloaded.
SQLiteModule)
SetMethodResultCode (inherited Sets the SQLiteErrorCode value
from SQLiteModuleNoop) that should be returned by the
specified ISQLiteManagedModule
interface method if it lack an
overridden implementation.
SetTableError (inherited from Overloaded. Arranges for the
SQLiteModule) specified error message to be
placed into the zErrMsg field of a
sqlite3_vtab derived structure,
freeing the existing error message,
if any.
TableFromCursor (inherited from Reads and returns the native
SQLiteModule) pointer to the sqlite3_vtab derived
structure based on the native
pointer to the sqlite3_vtab_cursor
derived structure.
TableFromIntPtr (inherited from Looks up and returns the
SQLiteModule) SQLiteVirtualTable object instance
based on the native pointer to the
sqlite3_vtab derived structure.
TableToIntPtr (inherited from Allocates and returns a native
SQLiteModule) pointer to a sqlite3_vtab derived
structure and creates an
association between it and the
specified SQLiteVirtualTable object
instance.
ZeroTable (inherited from Zeros out the fields of a native
SQLiteModule) sqlite3_vtab derived structure.

See Also
SQLiteModuleEnumerable<T> Class | System.Data.SQLite.Generic
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable(T).Column Method

See the Column method.

public override SQLiteErrorCode SQLiteModuleEnumerable(


SQLiteVirtualTableCursor cursor,
SQLiteContext context,
int index
);

Parameters
cursor
See the Column method.
context
See the Column method.
index
See the Column method.

Return Value
See the Column method.

Implements
ISQLiteManagedModule.Column

See Also
SQLiteModuleEnumerable<T> Class | System.Data.SQLite.Generic
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable`1.Dispose Method

Disposes of this object instance.

Overload List
Inherited from SQLiteModule.
public void Dispose()
Disposes of this object instance.
protected override void Dispose(bool)

See Also
SQLiteModuleEnumerable<T> Class | System.Data.SQLite.Generic
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable(T).Dispose(Boolean) Method

Disposes of this object instance.

protected override void SQLiteModuleEnumerable(


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteModuleEnumerable<T> Class | System.Data.SQLite.Generic
Namespace | SQLiteModuleEnumerable<T>.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteModuleEnumerable(T).Open Method

See the Open method.

public override SQLiteErrorCode SQLiteModuleEnumerable(


SQLiteVirtualTable table,
ref SQLiteVirtualTableCursor cursor
);

Parameters
table
See the Open method.
cursor
See the Open method.

Return Value
See the Open method.

Implements
ISQLiteManagedModule.Open

See Also
SQLiteModuleEnumerable<T> Class | System.Data.SQLite.Generic
Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator(T) Class

This class represents a virtual table cursor to be used with the


SQLiteModuleEnumerable class. It is not sealed and may be used as the
base class for any user-defined virtual table cursor class that wraps an
IEnumerator`1 object instance.
For a list of all members of this type, see
SQLiteVirtualTableCursorEnumerator(T) Members .
System.Object SQLiteVirtualTableCursor
SQLiteVirtualTableCursorEnumerator
SQLiteVirtualTableCursorEnumerator(T)

public class SQLiteVirtualTableCursorEnumerator<T> :


SQLiteVirtualTableCursorEnumerator, IEnumerator<T>

Requirements
Namespace: System.Data.SQLite.Generic
Assembly: System.Data.SQLite (in System.Data.SQLite.dll)

See Also
SQLiteVirtualTableCursorEnumerator(T) Members |
System.Data.SQLite.Generic Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator(T) Members

SQLiteVirtualTableCursorEnumerator(T) overview

Public Instance Constructors


Constructs an instance of this
SQLiteVirtualTableCursorEnumerator(T) class.
Constructor

Public Instance Properties


Current (inherited from Returns the value for the
SQLiteVirtualTableCursorEnumerator) current row of the virtual
table cursor using the
Current property of the
IEnumerator object instance.
EndOfEnumerator (inherited from Returns non-zero if the end
SQLiteVirtualTableCursorEnumerator) of the virtual table cursor has
been seen (i.e. no more rows
are available, including the
current one).
IndexNumber (inherited from Number used to help identify
SQLiteVirtualTableCursor) the selected index. This value
will be set via the Filter
method.
IndexString (inherited from String used to help identify
SQLiteVirtualTableCursor) the selected index. This value
will be set via the Filter
method.
IsOpen (inherited from Returns non-zero if the
SQLiteVirtualTableCursorEnumerator) virtual table cursor is open.
NativeHandle (inherited from Returns the underlying
SQLiteVirtualTableCursor) SQLite native handle
associated with this object
instance.
Table (inherited from The SQLiteVirtualTable object
SQLiteVirtualTableCursor) instance associated with this
object instance.
Values (inherited from The values used to filter the
SQLiteVirtualTableCursor) rows returned via this cursor
object instance. This value
will be set via the Filter
method.

Public Instance Methods


CheckClosed (inherited from Throws an
SQLiteVirtualTableCursorEnumerator) InvalidOperationException if
the virtual table cursor has
been closed.
Close Closes the virtual table
cursor. This method must not
throw any exceptions.
Dispose (inherited from Overloaded. Disposes of this
SQLiteVirtualTableCursor) object instance.
Equals (inherited from Object) Determines whether the
specified Object is equal to
the current Object.
Filter (inherited from This method should normally
SQLiteVirtualTableCursor) be used by the Filter method
in order to perform filtering
of the result rows and/or to
record the filtering criteria
provided by the SQLite core
library.
GetHashCode (inherited from Object) Serves as a hash function for
a particular type.
GetHashCode is suitable for
use in hashing algorithms
and data structures like a
hash table.
GetRowIndex (inherited from Determines the integer row
SQLiteVirtualTableCursor) sequence number for the
current row.
GetType (inherited from Object) Gets the Type of the current
instance.
MoveNext (inherited from Advances to the next row of
SQLiteVirtualTableCursorEnumerator) the virtual table cursor using
the MoveNext method of the
IEnumerator object instance.
NextRowIndex (inherited from Adjusts the integer row
SQLiteVirtualTableCursor) sequence number so that it
refers to the next row.
Reset (inherited from Resets the virtual table
SQLiteVirtualTableCursorEnumerator) cursor position, also
invalidating the current row,
using the Reset method of
the IEnumerator object
instance.
ToString (inherited from Object) Returns a String that
represents the current
Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteVirtualTableCursor)
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
TryPersistValues (inherited from Attempts to persist the specified
SQLiteVirtualTableCursor) SQLiteValue object instances in
order to make them available after
the Filter method returns.

See Also
SQLiteVirtualTableCursorEnumerator<T> Class |
System.Data.SQLite.Generic Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator(T) Constructor

Constructs an instance of this class.

SQLiteVirtualTableCursorEnumerator<T>(
SQLiteVirtualTable table,
IEnumerator<T> enumerator
);

Parameters
table
The SQLiteVirtualTable object instance associated with this object
instance.
enumerator
The IEnumerator`1 instance to expose as a virtual table cursor.

See Also
SQLiteVirtualTableCursorEnumerator<T> Class |
System.Data.SQLite.Generic Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator(T) Methods

The methods of the SQLiteVirtualTableCursorEnumerator(T) class are


listed below. For a complete list of
SQLiteVirtualTableCursorEnumerator(T) class members, see the
SQLiteVirtualTableCursorEnumerator(T) Members topic.

Public Instance Methods


CheckClosed (inherited from Throws an
SQLiteVirtualTableCursorEnumerator) InvalidOperationException if
the virtual table cursor has
been closed.
Close Closes the virtual table
cursor. This method must not
throw any exceptions.
Dispose (inherited from Overloaded. Disposes of this
SQLiteVirtualTableCursor) object instance.
Equals (inherited from Object) Determines whether the
specified Object is equal to
the current Object.
Filter (inherited from This method should normally
SQLiteVirtualTableCursor) be used by the Filter method
in order to perform filtering
of the result rows and/or to
record the filtering criteria
provided by the SQLite core
library.
GetHashCode (inherited from Object) Serves as a hash function for
a particular type.
GetHashCode is suitable for
use in hashing algorithms
and data structures like a
hash table.
GetRowIndex (inherited from Determines the integer row
SQLiteVirtualTableCursor) sequence number for the
current row.
GetType (inherited from Object) Gets the Type of the current
instance.
MoveNext (inherited from Advances to the next row of
SQLiteVirtualTableCursorEnumerator) the virtual table cursor using
the MoveNext method of the
IEnumerator object instance.
NextRowIndex (inherited from Adjusts the integer row
SQLiteVirtualTableCursor) sequence number so that it
refers to the next row.
Reset (inherited from Resets the virtual table
SQLiteVirtualTableCursorEnumerator) cursor position, also
invalidating the current row,
using the Reset method of
the IEnumerator object
instance.
ToString (inherited from Object) Returns a String that
represents the current
Object.

Protected Instance Methods


Dispose Overloaded. Disposes of this object
instance.
Finalize (inherited from Finalizes this object instance.
SQLiteVirtualTableCursor)
MemberwiseClone (inherited from Creates a shallow copy of the
Object) current Object.
TryPersistValues (inherited from Attempts to persist the specified
SQLiteVirtualTableCursor) SQLiteValue object instances in
order to make them available after
the Filter method returns.

See Also
SQLiteVirtualTableCursorEnumerator<T> Class |
System.Data.SQLite.Generic Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator(T).Close Method

Closes the virtual table cursor. This method must not throw any
exceptions.

public override void SQLiteVirtualTableCursorEnumerator(

See Also
SQLiteVirtualTableCursorEnumerator<T> Class |
System.Data.SQLite.Generic Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator`1.Dispose Method

Disposes of this object instance.

Overload List
Inherited from SQLiteVirtualTableCursor.
public void Dispose()
Disposes of this object instance.
protected override void Dispose(bool)

See Also
SQLiteVirtualTableCursorEnumerator<T> Class |
System.Data.SQLite.Generic Namespace

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
SQLite ADO.NET Provider
SQLiteVirtualTableCursorEnumerator(T).Dispose(Boolean)
Method

Disposes of this object instance.

protected override void SQLiteVirtualTableCursorEnumerat


bool disposing
);

Parameters
disposing
Non-zero if this method is being called from the Dispose method. Zero
if this method is being called from the finalizer.

See Also
SQLiteVirtualTableCursorEnumerator<T> Class |
System.Data.SQLite.Generic Namespace |
SQLiteVirtualTableCursorEnumerator<T>.Dispose Overload List

Send comments on this topic.


Generated from assembly System.Data.SQLite [1.0.104.0] by NDoc3
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
sql-stmt-list

References: sql-stmt
See also: lang.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
sql-stmt

Used by: sql-stmt-list


References: alter-table-stmt analyze-stmt attach-
stmt begin-stmt commit-stmt create-index-stmt
create-table-stmt create-trigger-stmt create-view-
stmt create-virtual-table-stmt delete-stmt delete-
stmt-limited detach-stmt drop-index-stmt drop-
table-stmt drop-trigger-stmt drop-view-stmt insert-
stmt pragma-stmt reindex-stmt release-stmt
rollback-stmt savepoint-stmt select-stmt update-
stmt update-stmt-limited vacuum-stmt
See also: lang.html lang_explain.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
alter-table-stmt

Used by: sql-stmt


References: column-def
See also: lang_altertable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
column-def

Used by: alter-table-stmt create-table-stmt


References: column-constraint type-name
See also: lang_altertable.html lang_createtable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
column-constraint

Used by: column-def


References: conflict-clause expr foreign-key-
clause literal-value signed-number
See also: lang_altertable.html lang_createtable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
conflict-clause

Used by: column-constraint table-constraint


See also: lang_altertable.html lang_conflict.html
lang_createtable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
expr
Used by: attach-stmt column-constraint compound-
select-stmt create-index-stmt create-trigger-stmt
delete-stmt delete-stmt-limited factored-select-
stmt indexed-column insert-stmt join-constraint
ordering-term result-column select-core select-
stmt simple-select-stmt table-constraint table-or-
subquery update-stmt update-stmt-limited
References: literal-value raise-function select-
stmt type-name
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
raise-function

Used by: expr


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
select-stmt

Used by: common-table-expression create-table-


stmt create-trigger-stmt create-view-stmt expr
insert-stmt sql-stmt table-or-subquery with-clause
References: common-table-expression compound-
operator expr join-clause ordering-term result-
column table-or-subquery
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
common-table-expression

Used by: compound-select-stmt factored-select-


stmt select-stmt simple-select-stmt
References: select-stmt
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
compound-operator

Used by: factored-select-stmt select-stmt


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
join-clause

Used by: select-core select-stmt table-or-subquery


References: join-constraint join-operator table-or-
subquery
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
join-constraint

Used by: join-clause


References: expr
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
join-operator

Used by: join-clause


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
ordering-term

Used by: compound-select-stmt delete-stmt-limited


factored-select-stmt select-stmt simple-select-stmt
update-stmt-limited
References: expr
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
result-column

Used by: select-core select-stmt


References: expr
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
table-or-subquery

Used by: join-clause select-core select-stmt


References: expr join-clause select-stmt
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
foreign-key-clause

Used by: column-constraint table-constraint


See also: lang_altertable.html lang_createtable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
literal-value

Used by: column-constraint expr


See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
signed-number

Used by: column-constraint pragma-value type-


name
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html pragma.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
type-name

Used by: column-def expr


References: signed-number
See also: lang_altertable.html lang_attach.html
lang_createindex.html lang_createtable.html
lang_createtrigger.html lang_createview.html
lang_delete.html lang_expr.html lang_insert.html
lang_select.html lang_update.html lang_with.html
partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
analyze-stmt

Used by: sql-stmt


See also: lang_analyze.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
attach-stmt

Used by: sql-stmt


References: expr
See also: lang_attach.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
comment-syntax

See also: lang_comment.html


Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
create-index-stmt

Used by: sql-stmt


References: expr indexed-column
See also: lang_createindex.html partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
indexed-column

Used by: create-index-stmt table-constraint


References: expr
See also: lang_createindex.html
lang_createtable.html partialindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
create-table-stmt

Used by: sql-stmt


References: column-def select-stmt table-
constraint
See also: lang_createtable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
table-constraint

Used by: create-table-stmt


References: conflict-clause expr foreign-key-
clause indexed-column
See also: lang_createtable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
create-trigger-stmt

Used by: sql-stmt


References: delete-stmt expr insert-stmt select-
stmt update-stmt
See also: lang_createtrigger.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
delete-stmt

Used by: create-trigger-stmt sql-stmt


References: expr qualified-table-name with-clause
See also: lang_createtrigger.html lang_delete.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
qualified-table-name

Used by: delete-stmt delete-stmt-limited update-


stmt update-stmt-limited
See also: lang_createtrigger.html lang_delete.html
lang_indexedby.html lang_update.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
with-clause

Used by: delete-stmt delete-stmt-limited insert-


stmt update-stmt update-stmt-limited
References: cte-table-name select-stmt
See also: lang_createtrigger.html lang_delete.html
lang_insert.html lang_update.html lang_with.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
cte-table-name

Used by: recursive-cte with-clause


See also: lang_createtrigger.html lang_delete.html
lang_insert.html lang_update.html lang_with.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
insert-stmt

Used by: create-trigger-stmt sql-stmt


References: expr select-stmt with-clause
See also: lang_createtrigger.html lang_insert.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
update-stmt

Used by: create-trigger-stmt sql-stmt


References: column-name-list expr qualified-table-
name with-clause
See also: lang_createtrigger.html lang_update.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
column-name-list

Used by: update-stmt update-stmt-limited


See also: lang_createtrigger.html lang_update.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
create-view-stmt

Used by: sql-stmt


References: select-stmt
See also: lang_createview.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
create-virtual-table-stmt

Used by: sql-stmt


See also: lang_createvtab.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
delete-stmt-limited

Used by: sql-stmt


References: expr ordering-term qualified-table-
name with-clause
See also: lang_delete.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
detach-stmt

Used by: sql-stmt


See also: lang_detach.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
drop-index-stmt

Used by: sql-stmt


See also: lang_dropindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
drop-table-stmt

Used by: sql-stmt


See also: lang_droptable.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
drop-trigger-stmt

Used by: sql-stmt


See also: lang_droptrigger.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
drop-view-stmt

Used by: sql-stmt


See also: lang_dropview.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
numeric-literal

See also: lang_expr.html


Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
reindex-stmt

Used by: sql-stmt


See also: lang_reindex.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
savepoint-stmt

Used by: sql-stmt


See also: lang_savepoint.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
release-stmt

Used by: sql-stmt


See also: lang_savepoint.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
rollback-stmt

Used by: sql-stmt


See also: lang_savepoint.html lang_transaction.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
factored-select-stmt

References: common-table-expression compound-


operator expr ordering-term select-core
See also: lang_select.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
select-core

Used by: compound-select-stmt factored-select-


stmt simple-select-stmt
References: expr join-clause result-column table-
or-subquery
See also: lang_select.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
simple-select-stmt

References: common-table-expression expr


ordering-term select-core
See also: lang_select.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
compound-select-stmt

References: common-table-expression expr


ordering-term select-core
See also: lang_select.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
begin-stmt

Used by: sql-stmt


See also: lang_transaction.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
commit-stmt

Used by: sql-stmt


See also: lang_transaction.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
update-stmt-limited

Used by: sql-stmt


References: column-name-list expr ordering-term
qualified-table-name with-clause
See also: lang_update.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
vacuum-stmt

Used by: sql-stmt


See also: lang_vacuum.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
recursive-cte

References: cte-table-name
See also: lang_with.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
pragma-stmt

Used by: sql-stmt


References: pragma-value
See also: pragma.html
Small. Fast. Reliable.
Choose any three.
Home Menu About Documentation Download
License Support Purchase Search
pragma-value

Used by: pragma-stmt


References: signed-number
See also: pragma.html
SQLite ADO.NET Provider
System.Data.SQLite Hierarchy
Object
Attribute
AssemblySourceIdAttribute
AssemblySourceTimeStampAttribute
SQLiteFunctionAttribute
DbConnectionStringBuilder ---- ICollection, IDictionary, IEnumerable,
ICustomTypeDescriptor
SQLiteConnectionStringBuilder
DbProviderFactory
SQLiteFactory ---- IDisposable, IServiceProvider
ISQLiteConnectionPool
ISQLiteManagedModule
ISQLiteNativeHandle
ISQLiteNativeModule
ISQLiteSchemaExtensions
SQLiteBlob ---- IDisposable
SQLiteContext ---- ISQLiteNativeHandle
SQLiteConvert
SQLiteDataReaderValue
SQLiteFunction ---- IDisposable
SQLiteDelegateFunction
SQLiteFunctionEx
SQLiteIndex
SQLiteIndexConstraint
SQLiteIndexConstraintUsage
SQLiteIndexInputs
SQLiteIndexOrderBy
SQLiteIndexOutputs
SQLiteLog
SQLiteMetaDataCollectionNames
SQLiteModule ---- ISQLiteManagedModule, IDisposable
SQLiteModuleNoop
SQLiteModuleCommon
SQLiteModuleEnumerable
SQLiteTypeCallbacks
SQLiteValue ---- ISQLiteNativeHandle
SQLiteVirtualTable ---- ISQLiteNativeHandle, IDisposable
SQLiteVirtualTableCursor ---- ISQLiteNativeHandle, IDisposable
SQLiteVirtualTableCursorEnumerator ---- IEnumerator
Delegate ---- ICloneable, ISerializable
MulticastDelegate
SQLiteAuthorizerEventHandler
SQLiteBackupCallback
SQLiteBindValueCallback
SQLiteCallback
SQLiteCommitHandler
SQLiteCompareDelegate
SQLiteConnectionEventHandler
SQLiteFinalDelegate
SQLiteInvokeDelegate
SQLiteLogEventHandler
SQLiteProgressEventHandler
SQLiteReadValueCallback
SQLiteStepDelegate
SQLiteTraceEventHandler
SQLiteUpdateEventHandler
EventArgs
AuthorizerEventArgs
CommitEventArgs
ConnectionEventArgs
LogEventArgs
ProgressEventArgs
SQLiteReadEventArgs
SQLiteReadArrayEventArgs
SQLiteReadBlobEventArgs
SQLiteReadValueEventArgs
TraceEventArgs
UpdateEventArgs
Exception ---- ISerializable
SystemException
ExternalException
DbException
SQLiteException
MarshalByRefObject
Component ---- IComponent, IDisposable
DataAdapter ---- IDataAdapter
DbDataAdapter ---- IDbDataAdapter, ICloneable
SQLiteDataAdapter
DbCommand ---- IDbCommand
SQLiteCommand ---- ICloneable
DbCommandBuilder
SQLiteCommandBuilder
DbConnection ---- IDbConnection
SQLiteConnection ---- ICloneable
DbDataReader ---- IEnumerable, IDataReader, IDataRecord,
IDisposable
SQLiteDataReader
DbParameter ---- IDataParameter, IDbDataParameter
SQLiteParameter ---- ICloneable
DbParameterCollection ---- ICollection, IEnumerable, IList,
IDataParameterCollection
SQLiteParameterCollection
DbTransaction ---- IDbTransaction, IDisposable
SQLiteTransactionBase
SQLiteTransaction
SQLiteTransaction2
ValueType
CollationSequence
Enum ---- IComparable, IConvertible, IFormattable
CollationEncodingEnum
CollationTypeEnum
FunctionType
SQLiteAuthorizerActionCode
SQLiteAuthorizerReturnCode
SQLiteConfigDbOpsEnum
SQLiteConnectionEventType
SQLiteConnectionFlags
SQLiteDateFormats
SQLiteErrorCode
SQLiteExecuteType
SQLiteIndexConstraintOp
SQLiteIndexFlags
SQLiteJournalModeEnum
SQLiteProgressReturnCode
SynchronizationModes
TypeAffinity
UpdateEventType
See Also
System.Data.SQLite Namespace

Send comments on this topic.


SQLite ADO.NET Provider
System.Data.SQLite.Generic Hierarchy
Object
SQLiteModule ---- ISQLiteManagedModule, IDisposable
SQLiteModuleNoop
SQLiteModuleCommon
SQLiteModuleEnumerable
SQLiteModuleEnumerable(T)
SQLiteVirtualTableCursor ---- ISQLiteNativeHandle, IDisposable
SQLiteVirtualTableCursorEnumerator ---- IEnumerator
SQLiteVirtualTableCursorEnumerator(T) ---- IEnumerator(T)

See Also
System.Data.SQLite.Generic Namespace

Send comments on this topic.

Вам также может понравиться