modifié : INITBASE/loader.py

This commit is contained in:
sidya82 2015-03-20 23:13:10 +01:00
parent e73999cd56
commit 605252c76e
1 changed files with 5 additions and 0 deletions

View File

@ -44,6 +44,7 @@ try :
cur.execute("TRUNCATE table domaines")
cur.execute("TRUNCATE table datations")
cur.execute("TRUNCATE table oeuvres")
cur.execute("TRUNCATE table referents")
# On parcourt le fichier xml
tree = ET.parse('inventaire.xml')
@ -199,6 +200,10 @@ try :
idoeuvre = insert(cur,"oeuvres",datas)
i+=1
#On Cree utilisateur decouvrir le muse
datas = { "id" : "1", "nom": "Découverte" }
insert(cur,"referents",datas)
con.commit()
except mdb.Error, e: