dbGetQuery() always returns a data.frame
with as many rows as records were fetched and as many
columns as fields in the result set,
even if the result is a single value
or has one
or zero rows.
An error is raised when issuing a query over a closed
or invalid connection,
if the syntax of the query is invalid,
or if the query is not a non-
n argument is not an atomic whole number
greater or equal to -1 or Inf, an error is raised,
but a subsequent call to
dbGetQuery() with proper
n argument succeeds.
The following arguments are not part of the
(to improve compatibility across backends)
but are part of the DBI specification:
They must be provided as named arguments. See the "Specification" and "Value" sections for details on their usage.
Fetching multi-row queries with one
or more columns be default returns the entire result.
A value of Inf for the
n argument is supported
and also returns the full result.
If more rows than available are fetched, the result is returned in full
If zero rows are fetched, the columns of the data frame are still fully
Fetching fewer rows than available is permitted,
no warning is issued.
A column named
row_names is treated like any other column.