You can define a column to not accept null values and provide a default value for the column while creating
Continue readingHow to change Sort key of a table in Redshift database
To modify the existing sort key of a table: ALTER TABLE tablename ALTER SORTKEY (columnname); or ALTER TABLE tablename ALTER
Continue readingHow to Change owner of all tables in a Schema in Redshift database
Check the current owner of the tables using the below query where schema_name is the name of the schema in
Continue readingHow to move table from one schema to another in Redshift
Below are the steps to move table from one schema to another in Redshift database. Step 1: Create table in
Continue readingHow to drop a column from a table in Redshift database
Below is the syntax to drop a column from a table in Redshift database where tablename is the name of
Continue readingEBS Cheat Sheet
Elastic Block Store Used with EC2 Instances Network attached storage Block level storage Suitable for creating filesystems and running databases
Continue readingHow to list all external Schemas in Redshift database
svv_external_schemas system catalog view provides list of all external schemas in your Redshift database. SELECT * FROM svv_external_schemas;
Continue readingHow to connect to redshift database from Command Line using psql
Step1: Download and install psql tool from https://www.postgresql.org/download/ for your version of OS. For Linux: sudo yum install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm
Continue readingHow to get the ddl of an external table in Redshift database
Run the below query to obtain the ddl of an external table in Redshift database. If the view v_generate_external_tbl_ddl is not
Continue readingHow to get the ddl of a table in Redshift database
Run the below query to obtain the ddl of a table in Redshift database. select * from admin.v_generate_tbl_ddl where schemaname
Continue reading