This is the SQL Data Frames Reference Manual, version 1.0.0, generated automatically by Declt version 4.0b2.
Copyright © 2019-2022 Steve Nunez
Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission notice are preserved on all copies.
Permission is granted to copy and distribute modified versions of this manual under the conditions for verbatim copying, provided also that the section entitled “Copying” is included exactly as in the original.
Permission is granted to copy and distribute translations of this manual into another language, under the above conditions for modified versions, except that this permission notice may be translated as well.
This program is distributed under the terms of the Microsoft Public License.
The main system appears first, followed by any subsystem dependency.
A wrapper for SQLite allowing querying of Data Frames
SQL queries for Data Frames
Steve Nunez <steve@symbolics.tech>
(GIT git://github.com/Lisp-Stat/sqldf)
MS-PL
SQLDF is a library for querying data frames using SQL, optimised for convenience over memory consumption. It uses an in-memory data base for transparent queries.
1.0.0
Files are sorted by type and then listed depth-first from the systems components trees.
pkgdcl.lisp (file).
sqldf (system).
utils.lisp (file).
sqldf (system).
create-df-table (function).
Packages are listed by definition order.
SQLDF is a facility for querying data frames with SQL
common-lisp.
Definitions are sorted by export status, category, package, and then by lexicographic order.
Read TABLE and return a data frame with the contents. Keys are interned in a package with the same name as TABLE.
Execute SQL (a string) on a data frame and return a new data frame with the results.
The data frame is identified by the word following FROM (case insensitive) in the SQL string. An in-memory SQLite database is creaetd, the contents of the data frame loaded, the query performed and a new DATA-FRAME returned with the results and the database deleted. In most cases, using this library is faster, from a developers time perspective, than writing the code to perform the same query. SQLDF has been tested with data frames of 350K rows with no slow-down noted. The R documentation for their version of SQLDF suggests that it could be faster than Lisp native queries. Note that the SQL query must use SQL style names for columns and not the Lisp versions, e.g. flight-time becomes flight_time.
Write data-frame DF to TABLE on connection DB. :na symbols are converted to "NA" strings in the database.
Create a database table of NAME in DB according to the schema of DF. This function is to create a table for DF prior to loading. Lisp style symbol names are converted to SQL compatible names.
Convert a string to a symbol, upcasing and replacing underscores with hyphens.
Return a format string for the most general type found in sequence
Use this for sequences of type T to determine how to declare the column to SQLite.
Return the type string of a column of a query statement
Convert a symbol or string into a name that can be a sql table, column, or operation name. Add quotes when escape-p is true, or escape-p is :auto and the name contains reserved words. Quoted or delimited identifiers can be used by passing :literal as the value of escape-p. If escape-p is :literal, and the name is a string then the string is still escaped but the symbol or string is not downcased, regardless of the setting for *downcase-symbols* and the hyphen and forward slash characters are not replaced with underscores. Ignore-reserved-words is only used internally for column names which are allowed to be reserved words, but it is not recommended.
Jump to: | C E F R S T W |
---|
Jump to: | C E F R S T W |
---|
Jump to: | *
S |
---|
Jump to: | *
S |
---|
Jump to: | F P S U |
---|
Jump to: | F P S U |
---|