Postgresql Code Samples



Filters


Connect to PostgreSQL in c# applications using Npgsql
harika | 1 year, 8 months
using System.Text;
using System.Threading.Tasks;
using IronPython.Hosting;
By default PostgreSql installed on 5432 port. If you have already configured the port while installi
c# csharp postgresql
How to copy a table from one database to another database in PostgreSQL?
Reshma | 1 year, 3 months
pg_dump -U user1 db_name_old_db | psql -U user2 db_name_target_db
It should be trigger in command prompt not from SQL tool
database postgresql copy table
How to connect to PostgreSQL database and display list of tables in python
kishore_kumar | 1 year, 11 months
import psycopg2

conn = psycopg2.connect(host="localhost", database="mydb", user="kishore", passwo
python psycopg2 postgresql
Adding a new auto increment column to a table in postgres
kishore_kumar | 1 year, 5 months
-- New versions of postgres
-- adding as primary key

sql postgres postgresql
Move a table to other schema in Postgres
kishore_kumar | 1 year, 11 months
ALTER TABLE table_name SET SCHEMA new_schema
sql postgresql
How to stop the PostgreSQL manually?
Reshma | 1 year, 6 months
show data_directory;   //To see the directory where the Postgresql data will be stored.

pg_ctl -D
manual stop postgresql mysql
How to delete SEQUENCE in postgresql
Reshma | 1 year, 5 months
drop sequence sequence_name;
sequence postgresql mysql
How to dump a database in postgresql
Reshma | 11 months, 1 week
sudo -i -u postgres

psql
dump postgresql sql