M
Martin P. Hellwig
Hi all,
I'm playing a bit with PostgreSQL, in which I've set me the target to
create a python script which with user input creates a new user role and
a database with that owner (connecting to template1 since I know that at
least that db exists).
Ok so I installed PostGreSQL and pygresql since it looked like that this
is endorsed by PG, I had some trouble with the DB-API2 (complains about
there is already a connection to template1, even when I closed and
deleted the connector) so I solved it by using the pg api.
But I was intrigued by this problem and started googling and by that
time I've noticed that python projects like Django seem to favor the
psycopg module.
So I installed that one (the 1.1 version, since Django uses that too)
and it looked like it has the same problem of creating a user after a
database, I'm sure that there is a user error in there somewhere
However, given the choice, what in your opinion would be the reason why
someone would chose one over the other? Now I know this could easily get
into a flamewar, so if you comment (but please do so) I'll still
investigate that, since at this moment I don't even have a clue how they
differ and on what reason, why does PostgreSQL seem to favour pygresql
and Pythoneers psycopg?
Thanks in advance.
I'm playing a bit with PostgreSQL, in which I've set me the target to
create a python script which with user input creates a new user role and
a database with that owner (connecting to template1 since I know that at
least that db exists).
Ok so I installed PostGreSQL and pygresql since it looked like that this
is endorsed by PG, I had some trouble with the DB-API2 (complains about
there is already a connection to template1, even when I closed and
deleted the connector) so I solved it by using the pg api.
But I was intrigued by this problem and started googling and by that
time I've noticed that python projects like Django seem to favor the
psycopg module.
So I installed that one (the 1.1 version, since Django uses that too)
and it looked like it has the same problem of creating a user after a
database, I'm sure that there is a user error in there somewhere
However, given the choice, what in your opinion would be the reason why
someone would chose one over the other? Now I know this could easily get
into a flamewar, so if you comment (but please do so) I'll still
investigate that, since at this moment I don't even have a clue how they
differ and on what reason, why does PostgreSQL seem to favour pygresql
and Pythoneers psycopg?
Thanks in advance.