View source: R/all_db_wrapper_fns.R
dbComment | R Documentation |
Comment on a table, a view or a schema.
dbComment(
conn,
name,
comment,
type = c("table", "view", "schema"),
display = TRUE,
exec = TRUE
)
conn |
A connection object. |
name |
A character string specifying a PostgreSQL table, view or schema name. |
comment |
A character string specifying the comment. |
type |
The type of the object to comment, either |
display |
Logical. Whether to display the query (defaults to
|
exec |
Logical. Whether to execute the query (defaults to
|
If exec = TRUE
, returns TRUE
if the comment was
successfully applied.
Mathieu Basille mathieu@basille.org
The PostgreSQL documentation: http://www.postgresql.org/docs/current/static/sql-comment.html
## examples use a dummy connection from DBI package
conn <- DBI::ANSI()
dbComment(conn, name = c("schema", "table"), comment = "Comment on a view.",
type = "view", exec = FALSE)
dbComment(conn, name = "test_schema", comment = "Comment on a schema.", type = "schema",
exec = FALSE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.