Обсуждение: iPad and Postgresql...

Поиск
Список
Период
Сортировка

iPad and Postgresql...

От
Jerry LeVan
Дата:
Hi,

I have an iPad and a small network of macs and fedora/windoze machines at home.

I am running pg 8.4.4 on all of the 'real' computers.

I have been hoping that some developer would create an iPad app that would allow me
to access my home database ( i am getting a bit long in the tooth and remembering
passwords for discussion groups and similar stuff is getting hard to remember).

I can securely access my home net via VPN (or ssh ).

I do have a terminal app on the iPad that groks ssh ( or just
use the VPN).

But psql on the terminal apps is not pleasant to use, I get a lot of
wrapping due to the screen size...

I recalled that I had written a 'cgi' that would let me connect to a pg database,
execute sql and display the results in a html table.

The bad news is that after 11 or so years my perl foo has vanished.

This afternoon I tried my hand at installing the necessary perl modules
to be able to talk to pg.

I am running the latest MacOSX and using the Apple installed perl.

I had to force install DBD::Pg and was afraid it would die when invoked.

Much to my surprise the cgi worked! I can access the db and execute
single sql statements and select results are displayed in a table.

I have a 'more' button in case there are more than 500 rows...

The cgi has two meta-commands, 'table' and 'describe <table>'. The
'table' command lists all of the tables in a db and the describe command
attempts to list the column names and data types ( does not work for
schema qualified table names).

So what I have does give me access to my Pg db from anywhere on my iPad but now that I have
a taste:

Is there an idiot installable package for MacOsX Snow Leopard that will
provide a 'better' user experience for accessing Pg via the web, especially
when viewed on the iPad?

I would be grateful if a Perl/Pg person would take a look at the rempgsql.pl
script and make it mo'better.

The script is located at http://homepage.mac.com/levanj/Perl/

Thanks,

Jerry





Re: iPad and Postgresql...

От
Andrej
Дата:
On 17 January 2011 13:34, Jerry LeVan <jerry.levan@gmail.com> wrote:
> Hi,
Hi Jerry,

> Is there an idiot installable package for MacOsX Snow Leopard that will
> provide a 'better' user experience for accessing Pg via the web, especially
> when viewed on the iPad?

It's not perl, but have you considered
http://phppgadmin.sourceforge.net/
?

> Thanks,
>
> Jerry

Cheers,
Andrej

Re: iPad and Postgresql...

От
John DeSoi
Дата:
On Jan 16, 2011, at 7:40 PM, Andrej wrote:

>> Is there an idiot installable package for MacOsX Snow Leopard that will
>> provide a 'better' user experience for accessing Pg via the web, especially
>> when viewed on the iPad?
>
> It's not perl, but have you considered
> http://phppgadmin.sourceforge.net/

I second this suggestion, but it is not as easy to install on the Mac as it should be. Snow Leopard has no PostgreSQL
supportin the standard PHP install. You can set it up yourself with the help of this article: 

http://www.gnegg.ch/2009/08/snow-leopard-and-php/

There also seems to be some nice looking native iPad/iPhone apps with the ability to perform ad-hoc queries using
PostgreSQL.


John DeSoi, Ph.D.





Re: iPad and Postgresql...

От
Jerry LeVan
Дата:
On Jan 17, 2011, at 10:48 AM, John DeSoi wrote:

>
> On Jan 16, 2011, at 7:40 PM, Andrej wrote:
>
>>> Is there an idiot installable package for MacOsX Snow Leopard that will
>>> provide a 'better' user experience for accessing Pg via the web, especially
>>> when viewed on the iPad?
>>
>> It's not perl, but have you considered
>> http://phppgadmin.sourceforge.net/
>
> I second this suggestion, but it is not as easy to install on the Mac as it should be. Snow Leopard has no PostgreSQL
supportin the standard PHP install. You can set it up yourself with the help of this article: 

Yes I was disappointed when the php-info function showed there was no pg support...
>
> http://www.gnegg.ch/2009/08/snow-leopard-and-php/
>
It sorta looks like the above might blow away the existing php stuff...

> There also seems to be some nice looking native iPad/iPhone apps with the ability to perform ad-hoc queries using
PostgreSQL.

Pointers to the apps if you please :)

Right now the rempgsql.pl cgi is starting to look better to me for read access to  my db...

Maybe after a few days rest...I am still reeling from a firmware corruption problem in my airport
extreme base station, udp ports 500 and 4500 started to refuse to pass data in from the wan side.
This made it impossible to access the VPN server. It took a while to diagnose and fix the problem.
>
>
> John DeSoi, Ph.D.

Jerry

Re: iPad and Postgresql...

От
John DeSoi
Дата:
On Jan 17, 2011, at 11:19 AM, Jerry LeVan wrote:

>>
>> There also seems to be some nice looking native iPad/iPhone apps with the ability to perform ad-hoc queries using
PostgreSQL.
>
> Pointers to the apps if you please :)

I did not give links because I have not used any of them. But if you google "ipad postgresql" you'll see DataGlass on
thefirst page of the results. I'm sure you'll also find some with a search in the app store. 



John DeSoi, Ph.D.





Re: iPad and Postgresql...

От
Gary Chambers
Дата:
Jerry,

>> http://www.gnegg.ch/2009/08/snow-leopard-and-php/
> It sorta looks like the above might blow away the existing php stuff...

Have you considered using the MacPorts version?  That's what I use for
development on my Macs and I've never had a problem replicating my
production environments whether in Solaris or Linux.

> Pointers to the apps if you please :)

Search for postgres or postgresql in the iTunes store.  DataGlass PostgreSQL
is one of the apps.  I recall seeing another one a couple weeks back, but I
can't remember the name of it at the moment.

-- Gary Chambers

Re: iPad and Postgresql...

От
John DeSoi
Дата:
On Jan 17, 2011, at 11:30 AM, Gary Chambers wrote:

>>> http://www.gnegg.ch/2009/08/snow-leopard-and-php/
>> It sorta looks like the above might blow away the existing php stuff...
>
> Have you considered using the MacPorts version?  That's what I use for
> development on my Macs and I've never had a problem replicating my
> production environments whether in Solaris or Linux.

It does not blow anything away as far as I can tell :).

Yes, I tried MacPorts. I seemed get caught in some kind of dependency hell and could not get things to update
correctly. 



John DeSoi, Ph.D.





Re: iPad and Postgresql...

От
Gary Chambers
Дата:
Jerry,

> Yes, I tried MacPorts. I seemed get caught in some kind of dependency hell
> and could not get things to update correctly.

I agree that it can be somewhat tedious to keep the packages up-to-date, but
you'll face that problem (in varying degrees of difficulty, admittedly) no
matter what package manager you use.  If you feel you can reasonably do so,
I would just mv /opt/local to /opt/local-old and start over (declare
MacPorts bankruptcy).  Now you can execute:

sudo port install apache2 php5 php5-postgresql

To make it easier for me to manage the web server (and to avoid colliding
with the Apple apachectl script), I symlink /opt/local/apache2/bin/apachectl
-> /usr/local/bin/apache2ctl.

-- Gary Chambers

Re: iPad and Postgresql...

От
Arturo Perez
Дата:
Didn't someone make an iPod touch app version of pgadmin?

There's this
http://itunes.apple.com/us/app/dataglass-postgresql/id390298877?mt=8

Re: iPad and Postgresql...

От
Jerry LeVan
Дата:
On Jan 17, 2011, at 11:30 AM, Gary Chambers wrote:

> Jerry,
>
>>> http://www.gnegg.ch/2009/08/snow-leopard-and-php/
>> It sorta looks like the above might blow away the existing php stuff...
>
> Have you considered using the MacPorts version?  That's what I use for
> development on my Macs and I've never had a problem replicating my
> production environments whether in Solaris or Linux.
>
>> Pointers to the apps if you please :)
>
> Search for postgres or postgresql in the iTunes store.  DataGlass PostgreSQL
> is one of the apps.  I recall seeing another one a couple weeks back, but I
> can't remember the name of it at the moment.
>
> -- Gary Chambers

Sigh, I am trying to simplify life...

I tried the DataGlass Postgresql app ( even paid for the upgrade so I could
see more than a screen full of records).

Regrettably I don't think it is ready for prime time...The interface is a bit
clunky. It seemed to hang with trying to display pg_proc ;(

I know that if I had to build a parallel apache, php, perl, etc that madness
would just be a matter of weeks away...

I have one of the community pythons installed and have to remember that
when I build an extension for the Apple Python that I have to rename
the Python an Tcl frameworks for the community python so the linker will
not grab them instead of the apple specific frameworks...

Didn't some guy named Harry say "A man has to know his limitations"?

Jerry