[Tutor] MySQL -->Python-->XML for JSviz

Picio picioslug at gmail.com
Tue Jul 3 16:07:53 CEST 2007


Hello all, I need some advice to choose an xml generator for jsviz a
tool in javascript to create some wonderful graphs (SnowFlake or Force
directed).

Starting from a SQL table (mysql) I need to create a XML file with a
structure like this:
<node root....>
      <node id... text... ></node>
      <node id... text... ></node>
      <node id... text... ></node>
                  <node id... text... ></node>
                  <node id... text... ></node>
      <node id... text... ></node>
</node>

Where nodes attributes are the MySQL table fields (the PK will be the
attribute).
I know there are a lot of good tools to do this in pyhton (some maybe
is already shipped with pyton itself), but since I need a lot of
flexibility for the future I'd like to use an Object relational mapper
like SQLAlchemy or SQLObject todo the job. When I say flexibility, I
have in mind a solution to have multiple formats coming outside of the
ORM:
json, csv, plain text etc...
Am I wrong?
Can someone advice something?

-- 
http://picio.gotdns.com ...Il mio blog su NSLU2


More information about the Tutor mailing list