if you are interested to contribute your LAB PROGRAM Please send mail to jkumaron@gmail.com

Database Create Delete Alert Basic MYSQL Postgres Tutorial

MY SQL Database Basic Tutorial
1)create database database_name;
2)use database_name; #select specific 
3)create table  table_name(variable_name varchar(50),variable2_name var_char(50));
4)show databases;#To show the database;
5)show table_name # To show table_name
6)disc table_name; #Get the variable details
7)select * from table_name;
8)drop table table_name; #delete the table name
9)drop database database_name; #delete dabase name
Note : if it is not working replace
table into TABLE
database into DATABASE

Postgres - SQL Database Basic
1)psql -U user-name
2)> create database database-name;
3)>\l # list out the database
4)>create user user-name with password 'Enter-password';
5)>grant all on database database-name on username;
6)To login into the particular database.
>psql -d database-name -U username;

postgresql - Remote Access - Database
To enable the client authentication.
1)Postgresql Configuration file - /var/lib/pgsql/data/pg_hbq.conf
host       all                       all    trust.

host       all                       all    md5 # anyone can login from any address.

For testing
$psql -h [IP] -U [user-name] -d [Database-name]

Related post