Selecting data from XML - Mailing list pgsql-sql

From Victor Sterpu
Subject Selecting data from XML
Date
Msg-id a1dc56fc-9159-4f31-9c94-9c363757f031@caido
Whole thread Raw
Responses Re: Selecting data from XML
List pgsql-sql
If I have a XML like this
<?xml version="1.0" encoding="UTF-8"?>
<Errors>
<Error  code="CLIN102" validFrom="1980-02-23"/>
<Error  code="CLIN103" validFrom="1980-02-23" validTo="2012-01-01"/>
</Errors>

can I write a query that will output the columns names and values like this?

code;validFrom;validTo
------------------------------
CLIN102;1980-02-23;
CLIN103;1980-02-23;2012-01-01

Thank you


pgsql-sql by date:

Previous
From: Jasen Betts
Date:
Subject: Re: Simple Upgrade from PostgreSQL version 8.1.11 (With schemas)
Next
From: Craig Ringer
Date:
Subject: Re: Selecting data from XML