On 2/7/06, Andrew Stevens <[EMAIL PROTECTED]> wrote:
> >From: THUFIR HAWAT <[EMAIL PROTECTED]>
> >Date: Tue, 7 Feb 2006 16:26:58 -0500
> >
> >There's some data in an xhtml table which I'd like to import to a
> >database using mysqlimport, or similar.  Viewing the xhtml file from a
> >browser doesn't display all the data--the data I'm after are the
> >URL's.  If I copy/paste from what the browser shows, the URL's aren't
> >copied, but, of course, the links can be clicked on from the browser.
>
> You could always "View Source" and copy/paste from that, though you'd need
> to run it through a suitable editor macro or similar to strip out the rest
> of the markup.

Right, this works fine once, but this something I'd like to do in volume.

> >>I would need to do an XSLT transform, perhaps using cocoon, to extract
> >that data?
>
> That's another possibility.  Or, if you've got XMLSpy you could open the URL
> in one window, write some XSL in another, and even run it without leaving
> the program.  No doubt other XML/XSL editors could do the same; XMLSpy's
> just the one I've been using most recently so I know it's possible in that.
>

XMLSpy would work, I think, but I'd like to do it myself, and can't
afford the software at the moment.

> Or you could write the XSL and create a Cocoon pipeline to read the file (on
> disk or via HTTP) and apply it.  Whether it's worth the extra effort to
> configure that depends on how often you need to do and whether you need
> anything else from it.  If it's just a one-off and you can do it in an
> editor without worrying about installation & configuration, you may as well
> do that.  Or write a shell script to run it with Saxon and set up a cron
> job.  Unless you need to serve the results up over the web, Cocoon's
> probably overkill.
>
>
> Andrew.
..

I don't need to serve the results up over the web, but I do need to
use something like mysqlimport to get the results into a database.

Saxon sounds like it might be the way to go.  I'd expect to do this
about twice per day.  What'd be the starting point to do this with
Saxon, please?

That is, I need to write the transform document, and run it from the shell?


thanks,

Thufir

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to