PostgreSQL as backend for HMG

General Help regarding HMG, Compilation, Linking, Samples

Moderator: Rathinagiri

Post Reply
User avatar
raumi75
Posts: 135
Joined: Wed Dec 17, 2008 2:31 am
Location: Lünen, Germany
Contact:

PostgreSQL as backend for HMG

Post by raumi75 »

Hello friends,

as promised, I have put together a little step-by-step howto for installing and using a PostgreSQL-Server with your HMG-Applications. I had to start my own blog to publish it.

http://raumi75.jimdo.com/howtos/postgresql-for-hmg/

I hope you like it. Some of you might know SQL better than I do. Please don't be mad, if you feel that I dumbed it down too much.

This is the way I like my instructions: Many screenshots and some explanations to get me to a point, where I can experiment on my own. The most important thing about hmg is the many samples that help you learn. And this forum, of course!!

Let me know if you liked it or not. You can use this forum or leave comments on my website.

Have fun and happy hmg/sql-ing!

Raumi
User avatar
Rathinagiri
Posts: 5482
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: PostgreSQL as backend for HMG

Post by Rathinagiri »

Fantastic Raumi. I will also try postregsql.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
apais
Posts: 441
Joined: Fri Aug 01, 2008 6:03 pm
DBs Used: DBF, Leto, MariaDB, SQLite
Location: uruguay
Contact:

Re: PostgreSQL as backend for HMG

Post by apais »

Thank you.
It will help a lot of people creating more professional software.

Yet I will help you install a postgresql server in a snap of your fingers, also a web admin page.
Once installed, this server consumes barely 150MB of memory
When You've mastered your postgresql installation, you can host it on the internet for very little money and all your admin troubles goes away.

Here's the magic: http://www.turnkeylinux.org/postgresql

Donwload burn a cd and install it on an old pc and you have your full fledged postgresql dedicated server.
You can even install it on a virtualbox partition on your windows installation during development or for demo apps.
Possibilities are endless.


HTH
Angel
Angel Pais
Web Apps consultant/architect/developer.
User avatar
Vanguarda
Posts: 543
Joined: Wed Feb 11, 2009 10:56 am
Location: Americana - SP
Contact:

Re: PostgreSQL as backend for HMG

Post by Vanguarda »

Hi friends,

Thansk Raumi, for this fantastic post. I like very much. It is very useful for me.

My best regards,
--
Paulo Sérgio Durço (Vanguarda)


http://hmglights.wordpress.com/
User avatar
Rathinagiri
Posts: 5482
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: PostgreSQL as backend for HMG

Post by Rathinagiri »

Thanks Angel for your nice ideas.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
User avatar
esgici
Posts: 4543
Joined: Wed Jul 30, 2008 9:17 pm
DBs Used: DBF
Location: iskenderun / Turkiye
Contact:

Re: PostgreSQL as backend for HMG

Post by esgici »

Thanks Raumi and Angel :)

Very useful works.


Regards

--

Esgici
Viva INTERNATIONAL HMG :D
User avatar
raumi75
Posts: 135
Joined: Wed Dec 17, 2008 2:31 am
Location: Lünen, Germany
Contact:

Re: PostgreSQL as backend for HMG

Post by raumi75 »

apais wrote:Thank you.
It will help a lot of people creating more professional software.

Yet I will help you install a postgresql server in a snap of your fingers, also a web admin page.
Once installed, this server consumes barely 150MB of memory
When You've mastered your postgresql installation, you can host it on the internet for very little money and all your admin troubles goes away.

Here's the magic: http://www.turnkeylinux.org/postgresql

Donwload burn a cd and install it on an old pc and you have your full fledged postgresql dedicated server.
You can even install it on a virtualbox partition on your windows installation during development or for demo apps.
Possibilities are endless.


HTH
Angel
Thank you for that link. I did not know turnkeylinux. Do you use PostgreSQL in your harbour-projects, too?

You are right. Of course, when you have a serious application, you will need a dedicated server. Edit pg_hba.conf, so other clients can connect. Postgresql will run on old hardware. But it scales very will. Give it a lot of memory, tweak the shared memory settings and it will be blazingly fast.

I run debian linux with postgresql and apache. I have written some php-applications for it. PhpAdmin is fine, but I still use PgAdmin III. BTW: You should take a look at the command-line tool psql, too! I absolutely love linux and never thought I would recommend using windows instead. :-)

To get you startet, however, I am happy, that the windows port exists. You can start very small, do not need extra hardware and have your server running in less than 10 Minutes! Don't let the long howto scare you. It basically consists of installer-screenshots where you only have to click "next". ;-)

But in one point I have to disagree: You do not need to install it on a virtual machine. Maybe if you want to code php-programs. But we are hmg-developers writing desktop-applications. The windows port is very stable and uses far less resources. It does everything the virtual machine could do for you. If you want it to listen to requests from clients other than localhost, you edit c:\programs\postgresql\data\pg_hba.conf. Add a line like

Code: Select all

host    postgres    all        all       md5
and restart the service. See the manual here: http://www.postgresql.org/docs/8.4/stat ... -conf.html. But I intentionally did not write that into the howto. I wanted to provide a quick start and leave out all the complicated stuff. If more people are interested, I can write some more about the differences between dbf and postgresql; or about migrating existing data to postgresql.

But I really 100 % agree with you: Possibilities are endless.

Since so many programs can access postgresql, you can write all kinds of programs. In our company, we currently use MS Access, PHP, Visual Basic and HMG-Applications. They all have one thing in common: They use the same database and it runs smoothly.

Raumi
Post Reply