使用postgres数据库床建一个项目失败
nekorrrr opened this issue · comments
Describe the bug
A clear and concise description of what the bug is.
To Reproduce
Steps to reproduce the behavior, if applicable:
-
The code is
-
The error is
有可能是数据库字段类型的错误?
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
Environments (please complete the following information):
- OS: windows
- sponge version v1.6.2
More description
Add any other context about the problem here.
如图所示
这是在postgresql创建的表
create table users
(
id bigint not null,
user_id character varying(50) not null,
user_name character varying(100)
);
用这个表可以生成代码,没有出现错误,你导出sql看看是什么样的。
这是在postgresql创建的表
create table users ( id bigint not null, user_id character varying(50) not null, user_name character varying(100) );用这个表可以生成代码,没有出现错误,你导出sql看看是什么样的。
-- Table: public.users
-- DROP TABLE IF EXISTS public.users;
CREATE TABLE IF NOT EXISTS public.users
(
id bigint NOT NULL,
user_id character varying COLLATE pg_catalog."default" NOT NULL,
user_name character varying COLLATE pg_catalog."default",
CONSTRAINT users_pkey PRIMARY KEY (id, user_id)
)
TABLESPACE pg_default;
ALTER TABLE IF EXISTS public.users
OWNER to postgres;
···
这是用pgadmin导出的DDL
这个bug在 v1.6.3
版本已修复,可以执行 sponge upgrade
升级到最新版本。
这个bug在
v1.6.3
版本已修复,可以执行sponge upgrade
升级到最新版本。
经测试问题已经解决,感谢您的回答!