Search Postgresql Archives

Re: connecting to server process via sockets

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Randall Smith <randall@xxxxxx> writes:

> For fun and learning, I would like to connect to the Postgresql
> backend and issue queries using sockets.  I'm using Python's socket
> module.  I'm new to socket programming, but I'm experienced with
> Python and Postgresql.  I've been using the JDBC driver and the online
> documentation as a guide, but I'm afraid my ignorance has led me to
> failure thus far.

[...]

No direct help, but a couple of suggestions:

1) Take a look at pg-dot-lisp, which does the same thing you are
   trying to do, but in Lisp.  You might find it more readable than
   the JDBC driver.  I am not sure which protocol versions it
   supports, though.  It's at: 

      http://www.chez.com/emarsden/downloads/

2) Write a simple libpq app (or use one of the existing Python
   interfaces linked against libpq) and watch the session with
   Etherial or tcpdump.  That'll show you the differences between your
   failing app and a working connection...

-Doug

---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux