-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
ORM&Mysql : or { panic(err) } #24184
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
Bug
This tag is applied to issues which reports bugs.
Comments
Connected to Huly®: V_0.6-22570 |
This is normal in SQLite |
For sqlite, your example works, except if you change
to:
the definition you use for your mysql case.
|
This is OK! |
I think this should still be enabled, and it should return an error instead of a panic. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
Refer to under code
Reproduction Steps
Expected Behavior
[temp.v:80] json.encode(result): []
Current Behavior
V panic: db.mysql.SQLError: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-01-01T00:00:00 +00:00 NOT NULL, PRIMARY KEY(
id
), UNIQUE(id
), UNIQUE(name
)' at line 1 (1) (CREATE TABLE IF NOT EXISTSsys_users
(id
VARCHAR(255) NOT NULL,name
VARCHAR(255),created_at
TIMESTAMP,updated_at
TIMESTAMP DEFAULT 0001-01-01T00:00:00 +00:00 NOT NULL, PRIMARY KEY(id
), UNIQUE(id
), UNIQUE(name
));)v hash: d54a823
/tmp/v_1000/orm_m.01JRHFA3Y4FXTHY7G7GXW61374.tmp.c:6642: at _v_panic: Backtrace
/tmp/v_1000/orm_m.01JRHFA3Y4FXTHY7G7GXW61374.tmp.c:12537: by main__main
/tmp/v_1000/orm_m.01JRHFA3Y4FXTHY7G7GXW61374.tmp.c:12746: by main
Possible Solution
No response
Additional Information/Context
No response
V version
V 0.4.10 d54a823
Environment details (OS name and version, etc.)
Note
You can use the 👍 reaction to increase the issue's priority for developers.
Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.
The text was updated successfully, but these errors were encountered: