Collection of 'SQL' Utilities for 'T-SQL' and 'Postgresql'


[Up] [Top]

Documentation for package ‘sqlHelpers’ version 0.1.2

Help Pages

call_function Call a SQL function/procedure.
connect Connect to a database using a connection string via DBI/odbc.
create_table_from_data_frame Generate a CREATE TABLE statement based on a data.frame, optionally execute the statement if con is not NULL.
drop_table Generate a DROP TABLE statement, optionally execute the statement if con is not NULL.
fetch_columns Retrieve the columns/types in a table.
fetch_function_definition Retrieve the definition of a function/procedure.
fetch_function_output_parameters Retrieve the output parameters of a function/procedure.
fetch_function_parameters Retrieve the input parameters of a function/procedure.
fetch_tables Retrieve the tables in a schema
insert_batch_chunker Helper function for INSERT
insert_values Generate a INSERT statement, optionally execute the statement if con is not NULL.
quoteText2 Add single quotes to strings using stringi::stri_join, useful for converting R strings into SQL formatted strings.
sqlizeNames Convert a column name into a SQL compatible name.
sqlizeTypes Get the equivalent SQL data type for a given R object.
truncate_table Generate a TRUNCATE TABLE statement, optionally execute the statement if con is not NULL.
t_sql_bulk_insert Generate a BULK INSERT statement, optionally execute the statement if con is not NULL.
t_sql_script_create_table Generate a CREATE TABLE statement for an existing table in Microsoft SQL Server.
t_sql_script_proc_definition Fetch the object definition of a proc in Microsoft SQL Server.
update_values Generate a UPDATE statement, optionally execute the statement if con is not NULL.