scores 主键改用 UUID v7
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -38,7 +38,7 @@ def init_db(db_url: str = DEFAULT_DB_URL):
|
||||
""")
|
||||
cur.execute("""
|
||||
CREATE TABLE IF NOT EXISTS scores (
|
||||
id INTEGER GENERATED ALWAYS AS IDENTITY PRIMARY KEY,
|
||||
id UUID DEFAULT gen_random_uuid_v7() PRIMARY KEY,
|
||||
ts_code TEXT NOT NULL,
|
||||
trade_date TEXT NOT NULL,
|
||||
close REAL,
|
||||
|
||||
Reference in New Issue
Block a user