b0e744e1e3 2024-02-12 1: local 字集库 = require("u8_to_a")
b0e744e1e3 2024-02-12 2: local 档库 = require("lsqlite3")
b0e744e1e3 2024-02-12 3: local 文库 = require(字集库.u8_to_a("算机_程语_月_基类_文"))
b0e744e1e3 2024-02-12 4: local 对库 = require(字集库.u8_to_a("算机_程语_月_基类_表_对"))
5b9fb5e09f 2024-02-13 5: local s = {}
276e038dec 2024-02-12 6: local 卡档
276e038dec 2024-02-12 7: --~ 卡编
a4c0b3bd26 2024-02-13 8: function s.取卡对(u1)
caceb3cbb9 2024-02-13 9: local h1_0, h2_0
276e038dec 2024-02-12 10: --~ 卡文对
0a84ce44ba 2024-02-13 11: h1_0 = s.取卡文(u1)
276e038dec 2024-02-12 12: --~ 卡数据对
caceb3cbb9 2024-02-13 13: h2_0 = s.取卡数据(u1)
caceb3cbb9 2024-02-13 14: return 对库.连两对(h1_0, h2_0)
276e038dec 2024-02-12 15: end
276e038dec 2024-02-12 16: --~ 卡编
a4c0b3bd26 2024-02-13 17: function s._取卡对(u1, u2)
a4c0b3bd26 2024-02-13 18: for o1_4 in 卡档:nrows(文库.连(u2, u1)) do
276e038dec 2024-02-12 19: return o1_4
276e038dec 2024-02-12 20: end
276e038dec 2024-02-12 21: end
276e038dec 2024-02-12 22: do
89f423ff38 2024-02-13 23: local h1
276e038dec 2024-02-12 24: --~ 模
89f423ff38 2024-02-13 25: h1 = "select * from texts where id = "
276e038dec 2024-02-12 26: --~ 卡编
a4c0b3bd26 2024-02-13 27: function s.取卡文(u1)
89f423ff38 2024-02-13 28: return s._取卡对(u1, h1)
276e038dec 2024-02-12 29: end
276e038dec 2024-02-12 30: end
276e038dec 2024-02-12 31: do
89f423ff38 2024-02-13 32: local h1
276e038dec 2024-02-12 33: --~ 模
89f423ff38 2024-02-13 34: h1 = "select * from datas where id = "
276e038dec 2024-02-12 35: --~ 卡编
a4c0b3bd26 2024-02-13 36: function s.取卡数据(u1)
89f423ff38 2024-02-13 37: return s._取卡对(u1, h1)
276e038dec 2024-02-12 38: end
276e038dec 2024-02-12 39: end
276e038dec 2024-02-12 40: --~ 卡档路
a4c0b3bd26 2024-02-13 41: function s.启卡档(u1)
a4c0b3bd26 2024-02-13 42: 卡档 = 档库.open(u1)
276e038dec 2024-02-12 43: end
5b9fb5e09f 2024-02-13 44: return s