dbBuildTableDefinition

0th

Percentile

Build the SQL CREATE TABLE definition as a string

Build the SQL CREATE TABLE definition as a string for the input data.frame

Keywords
methods, interface, database
Usage
dbBuildTableDefinition(dbObj, name, value, field.types = NULL, row.names = TRUE, ...)
Arguments
dbObj
any DBI object (used only to dispatch according to the engine (e.g., MySQL, SQLite, Oracle)
name
name of the new SQL table
value
data.frame for which we want to create a table
field.types
optional named list of the types for each field in value
row.names
logical, should row.name of value be exported as a row_names field? Default is TRUE
...
reserved for future use
Details

The output SQL statement is a simple CREATE TABLE with suitable for dbGetQuery

Value

  • An SQL string

References

See the Database Interface definition document DBI.pdf in the base directory of this package or http://stat.bell-labs.com/RS-DBI.

See Also

SQLite, dbConnect, dbSendQuery, dbGetQuery, fetch, dbCommit, dbGetInfo, dbReadTable.

Aliases
  • dbBuildTableDefinition
Documentation reproduced from package RSQLite, version 0.6-4, License: LGPL version 2 or newer

Community examples

Looks like there are no examples yet.