mirror of
https://gitlab.cern.ch/wotsubo/PSBoardDataBase.git
synced 2025-06-11 07:19:23 +09:00
update: docstring for create_database
This commit is contained in:
parent
1dd48e703e
commit
61b6d4a39e
2 changed files with 11 additions and 2 deletions
|
@ -1,7 +1,13 @@
|
|||
"""
|
||||
create_database(dbpath::AbstractString)
|
||||
create_database(db)
|
||||
|
||||
Create new database at `dbpath` and prepare all tables.
|
||||
Tables are empty.
|
||||
"""
|
||||
function create_database end
|
||||
|
||||
"""
|
||||
create_database(dbpath::AbstractString)
|
||||
"""
|
||||
function create_database(dbpath::AbstractString)
|
||||
db::SQLite.DB = DBInterface.connect(SQLite.DB, dbpath)
|
||||
|
@ -9,6 +15,9 @@ function create_database(dbpath::AbstractString)
|
|||
create_database(db)
|
||||
end
|
||||
|
||||
"""
|
||||
create_database(db::SQLite.DB)
|
||||
"""
|
||||
function create_database(db::SQLite.DB)
|
||||
dirpath = @__DIR__
|
||||
sql_creates::String = read("$dirpath/sql/create_table.sql", String) |> chomp
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue