Description Usage Arguments Value Author(s) See Also Examples
Returns the number of rows and columns in the database table corresponding to the odbcDataset object
1 2 | ## S3 method for class 'odbcDataset'
dim(x)
|
x |
an odbcDataset object. |
The number of rows and columns in the odbcDataset object.
John Fox
odbcDataset
, odbcDriverConnect
, Prestige
.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | ## This example presupposes that the data set prestige is stored as a table
## in the database attached via odbcDriverConnect().
## This data set is supplied as the data frame Prestige in the dfdb.RODBC
## package.
## Depending upon your OS/DBMS, the call to odbcDriverConnect() may have
## to be modified.
## Not run:
channel <- odbcDriverConnect()
sqlTables(channel)
Prestige <- odbcDataset(channel, "prestige") # create a pseudo-dataframe
Prestige
dim(Prestige)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.