Re: fetching text file from internet

From: Sean Davis <sdavis2(at)mail(dot)nih(dot)gov>
To: Dario Billo <rodario(at)libero(dot)it>
Cc: pgsqlnovice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: fetching text file from internet
Date: 2005-03-16 11:18:29
Message-ID: 7248b8ebcc4558193ab3b5dd73c38277@mail.nih.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

In pl/perlu (and likely python, maybe others), you can easily download
a file from the internet, parse it, and return results. If it is a
type of file parseable by DBD::AnyData, then you could use dbi-link to
make this file available as a table in your database.

Sean

On Mar 15, 2005, at 5:41 PM, Michael Fuhr wrote:

> On Tue, Mar 15, 2005 at 10:30:49PM +0100, Dario Billo wrote:
>
>> Hi to all. I need download text file from internet, and I'll use
>> plpgsql, but I don't know if this language can do this. Ideas?
>
> Is there a reason you want to do this in server code instead of in
> the client?
>
> If you must implement download functionality on the server side,
> then you could write a function in C or one of the other PLs (PL/Perl,
> PL/Tcl, PL/Python, etc.) and call it from PL/pgSQL.
>
> --
> Michael Fuhr
> http://www.fuhr.org/~mfuhr/
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 9: the planner will ignore your desire to choose an index scan if
> your
> joining column's datatypes do not match

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message John DeSoi 2005-03-16 13:08:18 Re: plpgsql allowing null fields in insert commands?
Previous Message Aarni Ruuhimäki 2005-03-16 08:27:01 Re: Uploading large files