Re: Migration from files to DBXML

Kimbro Staken <[email protected]> Fri, 14 May 2004 15:59:09 -0700
Newsgroups gmane.comp.web.syncato.general
Message-ID <[email protected]>
Look at importData.py. It accesses the DBXML database directly. It's 
designed to take a single XML file containing all the records and an 
XPath that is used to separate the file into individual records. You 
could make a /node() request through Syncato on the file database and 
store it into a single file with something like wget and then split it 
up again with /results/node(). Make sure nothing else has the DBXML 
database open when you do this.

On May 14, 2004, at 1:12 PM, darryl wrote:

> Kimbro,
>
> If you have a file based installation and want to migrate to DBXML how 
> would one go about doing that?
>
> Looking at db2files.py there does not seem to be an equivalent 
> files2db.py :)
>
> It seems to me that trying to convert them to DBXMl by POST-ing them
> as new documents would get the ID numbers screwed up. If you PUT them 
> it looks for an existing record first.
>
> I'm sure I could temporarily hack it into the updateDocument function 
> by mucking around this section here:
>
> ----------------
> document = self.getRecordDocument(txn, recordID)
>
> # Make sure the ID is set on the new content
> doc = XMLFragment(record)
> root = doc.getRootElement()
> root.setProp("id", str(recordID))
> ----------------
>
> But I was wondering if I was missing something obvious.
> -darryl
> -- 
> http://randomthoughts.vandorp.ca/WK/blog
>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: SourceForge.net Broadband
> Sign-up now for SourceForge Broadband and get the fastest
> 6.0/768 connection for only $19.95/mo for the first 3 months!
> http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click
> _______________________________________________
> Syncato-general mailing list
> Syncato-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
> https://lists.sourceforge.net/lists/listinfo/syncato-general
>
>
Kimbro Staken
Software, Consulting and Writing http://www.xmldatabases.org/



-------------------------------------------------------
This SF.Net email is sponsored by: SourceForge.net Broadband
Sign-up now for SourceForge Broadband and get the fastest
6.0/768 connection for only $19.95/mo for the first 3 months!
http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click