Learn R Programming

pgTools (version 1.0.2)

pg_renameColumn: Helper command to rename a column via ALTER TABLE.

Description

Helper command to rename a column via ALTER TABLE.

Usage

pg_renameColumn(column_name, new_column_name)

Value

A string, PostgreSQL helper statement to rename a column using ALTER TABLE.

Arguments

column_name

A string, the name of the column to change.

new_column_name

A string, the new name for the column.

Examples

Run this code
pg_renameColumn(
column_name = "newCol",
new_column_name = "col1"
)

Run the code above in your browser using DataLab