#!/usr/bin/python
import sqlite3
conn = sqlite3.connect('switchgear.db')

conn.execute("INSERT INTO NAME (NAME) VALUES('TC100_A1');")

conn.execute("INSERT INTO NAME (NAME) VALUES('PXM8000_A2');")
conn.execute("INSERT INTO NAME (NAME) VALUES('METER_A4');")
conn.execute("INSERT INTO NAME (NAME) VALUES('MAGNUM_B2');")
conn.execute("INSERT INTO NAME (NAME) VALUES('MAGNUM_B3');")
conn.execute("INSERT INTO NAME (NAME) VALUES('MAGNUM_B4');")

conn.execute("INSERT INTO TC100 (NAME, ALARM,TEMP) VALUES('TC100_A1',0,123);")
conn.execute("INSERT INTO PXM8000 (NAME, LINE1C,LINE1V,LINE2C,LINE2V,LINE3C,LINE3V) VALUES('PXM8000_A2',15,5,21,4,32,5);")
conn.execute("INSERT INTO METER (NAME, LINE1C,LINE1V,LINE2C,LINE2V,LINE3C,LINE3V) VALUES('METER_A4',15,5,21,4,32,5);")
conn.execute("INSERT INTO MAGNUM (NAME,REASON,MAINTENANCE,STATUS,LINE1C,LINE2C,LINE3C) VALUES('MAGNUM_B2','NONE',0,0,15,21,32);")
conn.execute("INSERT INTO MAGNUM (NAME,REASON,MAINTENANCE,STATUS,LINE1C,LINE2C,LINE3C) VALUES('MAGNUM_B3','NONE',0,0,15,21,32);")
conn.execute("INSERT INTO MAGNUM (NAME,REASON,MAINTENANCE,STATUS,LINE1C,LINE2C,LINE3C) VALUES('MAGNUM_B4','NONE',0,0,15,21,32);")
conn.commit()
conn.close()
print "Successful"
