fix: type and sql for insert version

This commit is contained in:
Wataru Otsubo 2024-09-30 14:38:27 +09:00
parent 64056a89d8
commit 066e0d5e46
2 changed files with 7 additions and 2 deletions

View file

@ -1,3 +1,8 @@
"""
insert_version_info(db::SQLite.DB)
Insert version information of this software as string.
"""
function insert_version_info(db::SQLite.DB) function insert_version_info(db::SQLite.DB)
stmt = DBInterface.prepare( stmt = DBInterface.prepare(
db, db,
@ -5,7 +10,7 @@ function insert_version_info(db::SQLite.DB)
INSERT INTO versions VALUES (:converter) INSERT INTO versions VALUES (:converter)
""", """,
) )
DBInterface.execute(stmt, (; converter = pkgversion(@__MODULE__))) DBInterface.execute(stmt, (; converter = pkgversion(@__MODULE__) |> string))
nothing nothing
end end

View file

@ -1,5 +1,5 @@
CREATE TABLE versions ( CREATE TABLE versions (
converter TEXT, converter TEXT
); );
CREATE TABLE ps_boards ( CREATE TABLE ps_boards (