forked from ptinqsey9/for_you
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
449 B
20 lines
449 B
import sqlite3
|
|
|
|
conn = sqlite3.connect('info.db')
|
|
c = conn.cursor()
|
|
print ("数据库打开成功")
|
|
def insert_xyz():
|
|
strs = "INSERT INTO XYZ VALUES ('这',"
|
|
for i in range(21*4):
|
|
strs+=str(i+0.01)+","
|
|
strs=strs[:-1]+");"
|
|
c.execute(strs)
|
|
|
|
def insert_trans():
|
|
strs = "INSERT INTO TRANSLATION VALUES('好','100000000|000000000');"
|
|
print(strs)
|
|
c.execute(strs)
|
|
|
|
conn.commit()
|
|
print ("数据插入成功")
|
|
conn.close() |