Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

Re: DBI accessing SQLite with XML data

by Anonymous Monk
on Jan 01, 2013 at 18:17 UTC ( #1011173=note: print w/replies, xml ) Need Help??

in reply to DBI accessing SQLite with XML data

I would recommend redesigning your database schema. Parse xml and insert into table.
CREATE TABLE mytable ( id INTEGER PRIMARY KEY, element TEXT, items TEXT, item TEXT, data TEXT, UNIQUE(element, items, item, data) );
Then you can do the following:
sqlite> SELECT ("element" || "/" || "items" || "/" || "item" || "/" || + "data") AS source where source like '%some string%';

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1011173]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2016-10-22 08:29 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (294 votes). Check out past polls.