Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: Databases made easy

by erix (Vicar)
on Apr 26, 2012 at 17:45 UTC ( #967415=note: print w/ replies, xml ) Need Help??


in reply to Databases made easy

SQLite remains a toy-database, its limitations honestly admitted by the sqlite crew on the sqlite site.

IMHO, one might as well start out with a real database and conquer the teething problems that might be caused by installing PostgreSQL. You won't regret it.

To use PostgreSQL, replace the SQLite connection string ("dbi:SQLite:Test.sqlite") with a connection string for PostgreSQL, for instance: "dbi:Pg:port=6542;db=testdb". The three parts in the above tutorial (create table, insert rows, select rows) will run the same on this postgresql $dbh (data base handle).

The PostgreSQL flavour of SQL is here: sql-commands.html


Comment on Re: Databases made easy
Re^2: Databases made easy
by GrandFather (Cardinal) on Apr 26, 2012 at 20:59 UTC

    In the very first paragraph of the OP I explain why I use SQLite and PostgreSQL is an excellent example of why I suggest people start with SQLite.

    To suggest using PostgreSQL (or MySQL, or any of myriad other database engines) is a simple as replacing the connect string with a different connect string amounts to deliberate infliction of pain and suffering. None of the non-"toy" databases are trivial to install and get going. I have no experience with PostgreSQL, but I bet it is little different to install and configure than MySQL, and that can be a right royal PITA.

    The intent of the OP was to provide an easy introduction to database use and SQLite, with its trivial install and very easy configuration (i.e. none), is excellent for the purpose. Toys have their place and if SQLite is a toy, then it is an superb one where most of its widgets and gadgets work just like the real thing that grown-ups use.

    People almost always start learning on a toy or reduced functionality version of anything to reduce the barrier to learning. Should we make it harder to learn to use a database by requiring extra layers of set up before you can write a single line of code just so you can say you are using a professional strength version?

    True laziness is hard work

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://967415]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (13)
As of 2014-07-10 23:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (217 votes), past polls