Posted in Open Source, OpenERP, PostgreSQL

How to drop the database in OpenERP?


Do you want to drop database in OpenERp using Web Client? Here we provide step by step menthod to drop the PostgreSQL.

Click on the Manage Databases Link to drop Database (PostgreSQL).

Before you create any database, you need to install OpenERP.To install OpenERP 6.1 and OpenERP 6.0 on Windows Vista and Windows 7 in 10 Minutes, You may like to visit How to install OpenERP 6.1 and OpenERP 6.0 on Windows Vista and Windows 7 in 10 Minutes.

Once you finish the installation process, Open WebClient by using the URL: http://localhost:8069/web/webclient/home

Next step is to create the database,

Please visit our post on How to create database in OpenERP?

Once you have the database and in case you want to drop it then follow the steps given below:

Open WebClient by using the URL: http://localhost:8069/web/webclient/home

Click on the Manage Databases Link to drop Database (PostgreSQL).

Manage Databases in OpenERP Web Client
Manage Databases in OpenERP Web Client

Click on the Drop Link

Drop Database in OpenERP Web Client
Drop Database in OpenERP Web Client

Select the database to drop and provide the master password, in our case “admin” 🙂

Drop Database in OpenERP Web Client
Drop Database in OpenERP Web Client

It will ask for the confirmation to drop the postgreSQL database.

Drop Database confirmation in OpenERP Web Client
Drop Database confirmation in OpenERP Web Client

Click on Ok.

Done!!! 🙂

Posted in Open Source, OpenERP, PostgreSQL

How to create database in OpenERP?


Are you beginner and taking babysteps in OpenERP? We can help you in the very 1st step. It’s all about database and it is the central component in ERp systems so lets learn on how to create database in OpenERP…

Before you create any database, you need to install OpenERP.To install OpenERP 6.1 and OpenERP 6.0 on Windows Vista and Windows 7 in 10 Minutes, You may like to visit How to install OpenERP 6.1 and OpenERP 6.0 on Windows Vista and Windows 7 in 10 Minutes.

Once you finish the installation process, Open WebClient by using the URL: http://localhost:8069/web/webclient/home

Click on the Manage Databases Link to create Database (PostgreSQL).

Manage Databases in OpenERP Web Client
Manage Databases in OpenERP Web Client

In Create New Database screen of OpenERP Web Client, Give New database name and Password and Click on Create.

Create Database in OpenERP Web Client
Create Database in OpenERP Web Client

It will take some time to create a new database; once the database is created you will be redirected to the web console of OpenERP.

OpenERP Web Console
OpenERP Web Console

Done!!! 🙂

Posted in Open Source, OpenERP, OpenERP Installation, PostgreSQL

How to backup and restore OpenERP database ?


There are two methods to perform backup and restore operation for OpenERP database.

Lets go through step by step:

Method 1: Using GUI

Follow the steps to create backup and restoring database.

1) Goto Login page,
2) Click on Manage Databases,
3) There are various options available on left side bar.
4) Follow the screens displayed below.

OpenERP database backup
OpenERP database backup
OpenERP database restore
OpenERP database restore

Method 2: Using command prompt (Using PostgreSQL)

It is advisable that if backup has been taken from command prompt then restoring should be from command prompt only.

Follow the screen steps for creating backup and restore.

1) Executing following command will create a blank database.
Command: createdb –encoding=UTF-8 testdb

Create blank database
Create blank database

2) Executing following command will create a backup of database : openerp_61
Command: pg_dump -f backup_openerp_61 openerp_61

OpenERP database backup from command prompt
OpenERP database backup from command prompt

3) Execute following command will restore your db into blank database created in step 1.
Command: psql testdb < backup_openerp_61

OpenERP restore database from command prompt
OpenERP restore database from command prompt

Problem during restoring from command prompt :

Upto here, assume that everything is working in the same PC. Now let say, someone is trying to restore database using command prompt for which, the database has been backed up from another PC.

Please check following screenshots.

OpenERP database backup process
OpenERP backup database process

In above case, You can see the error message `role “john” does not exist`. It means that database has been backed up from another PC having name is ‘john’.

So now, in this case there are two solutions to restore this database as follows.

1) Either you can open dump file, and change the role name wherever you find name ‘john’ as your role displayed in following screen. Here I have changed name as ‘navrang’ in place of ‘john’.

OpenERP restore database process
OpenERP restore database process

2) Another option is, if dump file is too long to change role/owner name, then you can create a user in your PC named ‘john’ so it will work as it is.

And this way we can restore our database.

Posted in Open Source, PostgreSQL

How to make pgAdmin connection with PostgreSQL ?


I would like to discuss regarding pgAdmin connection with PostgreSQL.

We will go with screenshots one by one.

In first screen, I have opened pgAdmin, and clicked on “Connect” icon.

When we click on “Connect” button, following window will get appear in which we have to enter postgresql information.

Press “OK” button when done with information. You will get below error message because of PostgreSQL user authentication.

Now, lets solve this error by using following commands.

Once you completed this process from command line, do the same process for entering PostgreSQL information.

You will see the following screen with connection in pgadmin.