dbTalk Databases Forums  

Why PostgreSQL sucks.

comp.databases.postgresql comp.databases.postgresql


Discuss Why PostgreSQL sucks. in the comp.databases.postgresql forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
SM Ryan
 
Posts: n/a

Default Why PostgreSQL sucks. - 05-19-2007 , 12:55 AM






I'm trying to get some code to run with PostgreSQL
after succesfully getting it to run with MySQL and Sqlite,
and if I had known Postgres was going to be such as pain
in the butt, I would've refused. The current problem is
that obvious call PQoidValue() doesn't work. The solution
apparently is that currval(sequencename), which is just
nifty except the INSERT statement doesn't say which field
that is. Instead have I have to parse out the table name
and then look up in my own schema definitions for which
field that is. (Even though apparently I could get it in
5 to 10 queries if there was a clearly documented explanation
of how to SERIAL fields are scattered amongst those pg_%
tables. The again I gave up trying to extract primary
and unique constraints to recreate the simple functionality
of SHOW CREATE TABLE.) And of course I have to construct
a whole separate query just to get one piece of information
that the library should've already known since it's one of
the most obvious questions to be asked after an INSERT.

Fuck.

So why does PostgreSQL suck? It's not that some people
decided they could make a better wheel than anyone else.
Maybe they could. But if I can't fit that wheel on the
existing waggon, it's useless pile of crap. It has got to
be obvious by this time that going from something like
Sqlite to PostgreSQL is going to be a bloody pain in the
butt because Postgres is so pure and blessed and above
the other databases that they cannot be botherred to provide
an interface that allows a programmer to use standard
query language and adapt an existing library interface
that behaves in a similar fashion for every database.

I have learned too late that what I really need to do is
define a standard query language so that I can write the
bulk of my code independent of the databases. Then write
a per-database translator from the standard query language
to the specific SQL of each database. And yes I know what
the S of SQL stands for, it's a lie and very poor joke.

One thing I've already learned is not depend on pg_%
tables to discover the schema, but to retain the schema
definition I used to create the database and parse that.
Having all that stuff in a database is absolutely worthless
if you can't be botherred to document what the tables
really mean. I learned that lesson when I learned I have
to parse REPLACE statements to extract the table to
get the primary keys to translate the REPLACE into
a DELETE followed by an INSERT. Thanks for all the lovely
lectures on what Postgres thinks is proper query design
so that they don't have to implement a simple assignment
of x := v.

--
SM Ryan http://www.rawbw.com/~wyrmwif/
God's a skeeball fanatic.

Reply With Quote
  #2  
Old   
Helmholtz Ralf
 
Posts: n/a

Default Re: Why PostgreSQL sucks. - 05-19-2007 , 03:27 AM






SM Ryan schrieb:
Quote:
I'm trying to get some code to run with PostgreSQL
after succesfully getting it to run with MySQL and Sqlite,
You are comparing postgresql with mysql and sqlite. *ROFL*
If you need postgres, then SQLIte and probably MySQL aren't any choice.
So if SQLIte or MySQL ist suffiecient to you, then there is no need for
postgres on the other hand, everything you can do with mysql can be
easily done with postgres. If your design sucks then this is your problem.

Quote:
and if I had known Postgres was going to be such as pain
in the butt, I would've refused. The current problem is
that obvious call PQoidValue() doesn't work. The solution
apparently is that currval(sequencename), which is just
nifty except the INSERT statement doesn't say which field
that is. Instead have I have to parse out the table name
and then look up in my own schema definitions for which
field that is. (Even though apparently I could get it in
5 to 10 queries if there was a clearly documented explanation
of how to SERIAL fields are scattered amongst those pg_%
tables. The again I gave up trying to extract primary
and unique constraints to recreate the simple functionality
of SHOW CREATE TABLE.) And of course I have to construct
a whole separate query just to get one piece of information
that the library should've already known since it's one of
the most obvious questions to be asked after an INSERT.

Fuck.
This is clearly your fault, if you try to solve your problem in the
stupiest way withpout using postgres functionality properly, then noone
can help you
Quote:
So why does PostgreSQL suck? It's not that some people
decided they could make a better wheel than anyone else.
Maybe they could. But if I can't fit that wheel on the
existing waggon, it's useless pile of crap. It has got to
If you try to fit a good wheel on a broken wagon and then complain that
the vehicle won't run, you cannot blame the wheel.

Quote:
be obvious by this time that going from something like
Sqlite to PostgreSQL is going to be a bloody pain in the
butt because Postgres is so pure and blessed and above
the other databases that they cannot be botherred to provide
an interface that allows a programmer to use standard
query language and adapt an existing library interface
that behaves in a similar fashion for every database.

I have learned too late that what I really need to do is
define a standard query language so that I can write the
bulk of my code independent of the databases. Then write
a per-database translator from the standard query language
to the specific SQL of each database. And yes I know what
the S of SQL stands for, it's a lie and very poor joke.

One thing I've already learned is not depend on pg_%
tables to discover the schema, but to retain the schema
definition I used to create the database and parse that.
You don't seem like you have learnt a lot, you have no manners
and you rude, remember the "F###"?
No further discussion is needed on this. You are obviously not looking
for help with your design, but instead causing trouble letting your
anger about your own incapability spread to this list.

--Ralf


Reply With Quote
  #3  
Old   
Guido Neitzer
 
Posts: n/a

Default Re: Why PostgreSQL sucks. - 05-20-2007 , 01:00 PM



SM Ryan <wyrmwif (AT) tango-sierra-oscar-foxtrot-tango (DOT) fake.org> wrote:

Quote:
It's not that some people decided they could make a better wheel than
anyone else. Maybe they could. But if I can't fit that wheel on the
existing waggon, it's useless pile of crap.
Yeah. If you can't fit a SUV wheel on your cart, either the wheel or
your cart is shitty. What a conclusion ... I'd say, it just doesn't fit
and this is not necessarily the wheel's problem.

Quote:
I have learned too late that what I really need to do is
define a standard query language so that I can write the
bulk of my code independent of the databases.
No, it seems you haven't learned that at all. If you want database
independency, you use an abstraction layer. If this doesn't exist for
your programming tool, the tool is not the right one for the task.

Quote:
And yes I know what the S of SQL stands for, it's a lie and very poor
joke.
Obviously you don't even know that, because it's "Structured Query
Language". There is no "standard" in the name. But there are standards
out there like SQL92, SQL99 and so on.

So, what's the point of posting that crap here? Want to show, that
you're not able to develop a database independant system?

cug


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.