Remove remaining SQLite-only schema and docs residue.
This commit is contained in:
@@ -10,17 +10,13 @@ import (
|
||||
_ "github.com/jackc/pgx/v5/stdlib"
|
||||
)
|
||||
|
||||
// applySchema runs semicolon-separated DDL statements, skipping PRAGMA lines.
|
||||
// applySchema runs semicolon-separated DDL statements.
|
||||
func applySchema(db *sql.DB, schema string) error {
|
||||
for _, stmt := range strings.Split(schema, ";") {
|
||||
stmt = strings.TrimSpace(stmt)
|
||||
if stmt == "" {
|
||||
continue
|
||||
}
|
||||
upper := strings.ToUpper(stmt)
|
||||
if strings.HasPrefix(upper, "PRAGMA") {
|
||||
continue
|
||||
}
|
||||
if _, err := db.Exec(stmt); err != nil {
|
||||
return fmt.Errorf("%w: %s", err, stmt)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user