Description Usage Arguments Details Value Author(s) See Also Examples
gmRead
translates the R representation expr
of an SQL query into SQL and evaluates it in the database db
.
1 2 | gmRead(expr,envir=parent.frame(),EXPR=substitute(expr),limit=-1,db=getOption("gmDB"))
gmReadInternal(EXPR,sel=NULL,db,gmNameVarID=getGmNameVarID(db))
|
expr |
R expression of an SQL query. Expressions created with |
envir |
defines the environment used for evaluation of |
EXPR |
The quoted version of such an expression. |
sel |
The selection statement in R representation. |
limit |
defines the number of lines returned in the query. |
db |
defines the database, on which the query will be run. |
gmNameVarID |
The gmVarID in the gmDatabase of gmName for later referencing of an object by its name in the gmDatabase. |
gmRead
is the principal function of the gmDatabase package. It provides the main functionality: Receiving an R expression expr
of an SQL query, it returns a dataframe, containing the requested data. On the other hand, gmReadInternal
, indicated by its notation, is meant for in-package use only. During the execution of gmRead
it creates a call containing the R representation, which is used later in gmSQL
to create and run a proper SQL query against the database.
For gmRead
a dataframe is returned. It contains the requested data.
For gmReadInternal
a call is returned, consisting of an expression to be interpreted as
the R representation of SQL by gmSQL
. Furthermore a list of the asked variables in
EXPR
and the columns, where to look in the database tables are returned, too.
K. Gerald van den Boogaart, S. Matos Camacho
1 2 3 4 5 6 7 8 9 10 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.