cleanse_name()
Last updated
Last updated
Utility to make a string SQL safe so that it can be used as an alias for a new column.
Takes the following actions on a string:
remove double quotes
replace spaces and dashes with underscores
cast to upper case
delete anything that is not letters, numbers, or underscores
if first character is a number, add an underscore to the beginning
Type | Description |
---|---|
string
text to make SQL safe; works on column names, table names, row values, etc...