!10 fix bug: 通达信导入数据后stock.db中的stock的startdate 使用了带时分的datetime数字,导致py中 from hikyuu.interactive import *导入数据时候Loading KData卡很久

Merge pull request !10 from Jet/fix-strategy
This commit is contained in:
fasiondog 2024-03-04 19:28:10 +00:00 committed by Gitee
commit 92b6b1ac04
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F

View File

@ -196,7 +196,7 @@ def tdx_import_day_data_from_file(connect, filename, h5file, market, stock_recor
cur = connect.cursor()
cur.execute(
"update stock set valid=1, startdate=%i, enddate=%i where stockid=%i" %
(table[0]['datetime'], 99999999, stockid)
(table[0]['datetime']//10000, 99999999, stockid)
)
connect.commit()
cur.close()