postgresql - 无法让 Postgres 表分区工作
问题描述
我在 Windows 上运行 postgres 9.5.7。
我正在尝试使用...创建分区表
CREATE TABLE processlog2
(
processlogid integer NOT NULL DEFAULT
nextval('processlog_processlogid_seq'::regclass),
starttime timestamp without time zone,
endtime timestamp without time zone,
durationsecs integer,
processname character(100),
itemcount integer,
comment character(255),
params character varying(20)
)
PARTITION BY RANGE (starttime );
我得到了错误......
ERROR: syntax error at or near "PARTITION"
LINE 12: PARTITION BY RANGE (starttime );
我认为 Postgres 多年来一直支持分区,但我找不到任何关于此错误的提及,并且不确定我做错了什么。
有任何想法吗?
谢谢
解决方案
推荐阅读
- python - Python Pandas - 如何将两个数据帧(相同维度)的不相交内容合并到一个数据帧中
- java - Is there a way to stop an invokeLater or to create a JFrame at a certain time?
- flutter - 如何将小部件填充到完整的可用行高
- python - how to set the pytest.param id automatically?
- bash - The meaning of ${BASH_SOURCE-$0}?
- netlogo - How to set value of an agent variable same as the value of another variable of same agent in Netlogo
- java - How to set all non nullable properties of swagger responses as required?
- git - git 是在推送期间传输整个修改后的文件还是只是传输差异?
- ios - How to enable or disable landscape mode for specific ViewControllers?
- sql - 如何在 SQL Developer 中显示查询的完整结果?