dbGetQuery,AzureKustoConnection,character-method | R Documentation |
DBI methods for Kusto queries and commands
## S4 method for signature 'AzureKustoConnection,character'
dbGetQuery(conn, statement, ...)
## S4 method for signature 'AzureKustoConnection'
dbSendQuery(conn, statement, ...)
## S4 method for signature 'AzureKustoResult'
dbFetch(res, n = -1, ...)
## S4 method for signature 'AzureKustoConnection,character'
dbSendStatement(conn, statement, ...)
## S4 method for signature 'AzureKustoConnection,character'
dbExecute(conn, statement, ...)
## S4 method for signature 'AzureKustoConnection,character'
dbListFields(conn, name, ...)
## S4 method for signature 'AzureKustoResult'
dbColumnInfo(res, ...)
conn |
An AzureKustoConnection object. |
statement |
A string containing a Kusto query or control command. |
... |
Further arguments passed to |
res |
An AzureKustoResult resultset object |
n |
The number of rows to return. Not used. |
name |
For |
These are the basic DBI functions to query the database. Note that Kusto only supports synchronous queries and commands; in particular, dbSendQuery
and dbSendStatement
will wait for the query or statement to complete, rather than returning immediately.
dbSendStatement
and dbExecute
are meant for running Kusto control commands, and will throw an error if passed a regular query. dbExecute
also returns the entire result of running the command, rather than simply a row count.
dbConnect, dbReadTable, dbWriteTable, run_query
## Not run:
db <- DBI::dbConnect(AzureKusto(),
server="https://mycluster.location.kusto.windows.net", database="database"...)
DBI::dbGetQuery(db, "iris | count")
DBI::dbListFields(db, "iris")
# does the same thing as dbGetQuery, but returns an AzureKustoResult object
res <- DBI::dbSendQuery(db, "iris | count")
DBI::dbFetch(res)
DBI::dbColumnInfo(res)
DBI::dbExecute(db, ".show tables")
# does the same thing as dbExecute, but returns an AzureKustoResult object
res <- DBI::dbSendStatement(db, ".show tables")
DBI::dbFetch(res)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.