Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
D
docker-iot-v3
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
deploy
docker-iot-v3
Commits
8312eb42
Commit
8312eb42
authored
Aug 07, 2023
by
吴文龙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add new file
parent
0071c397
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
0 deletions
+37
-0
hsiotdb_pgsql_03.sql
db/hsiotdb_pgsql_03.sql
+37
-0
No files found.
db/hsiotdb_pgsql_03.sql
0 → 100644
View file @
8312eb42
CREATE
TABLE
"public"
.
"hs_order_statistical"
(
"id"
uuid
NOT
NULL
,
"order_no"
varchar
(
255
)
COLLATE
"pg_catalog"
.
"default"
NOT
NULL
,
"order_status"
varchar
(
255
)
COLLATE
"pg_catalog"
.
"default"
DEFAULT
'underway'
::
character
varying
,
"code"
varchar
(
255
)
COLLATE
"pg_catalog"
.
"default"
NOT
NULL
,
"statistic_val"
numeric
(
10
,
4
)
NOT
NULL
DEFAULT
0
,
"start_time"
timestamp
(
6
),
"end_time"
timestamp
(
6
),
"created_time"
int8
,
"updated_time"
int8
NOT
NULL
,
"tenant_id"
uuid
NOT
NULL
,
"order_array"
varchar
(
1000
)
COLLATE
"pg_catalog"
.
"default"
,
CONSTRAINT
"hs_order_statistical_pkey"
PRIMARY
KEY
(
"id"
),
CONSTRAINT
"hs_order_statistical_order_no_code_key"
UNIQUE
(
"order_no"
,
"code"
)
)
;
ALTER
TABLE
"public"
.
"hs_order_statistical"
OWNER
TO
"postgres"
;
COMMENT
ON
COLUMN
"public"
.
"hs_order_statistical"
.
"order_status"
IS
'订单状态(underway-进行中;close-结束)'
;
COMMENT
ON
COLUMN
"public"
.
"hs_order_statistical"
.
"code"
IS
'water-水;electric-电;vapor-蒸汽;output-产量'
;
COMMENT
ON
COLUMN
"public"
.
"hs_order_statistical"
.
"statistic_val"
IS
'统计值'
;
COMMENT
ON
COLUMN
"public"
.
"hs_order_statistical"
.
"tenant_id"
IS
'租户标识'
;
COMMENT
ON
COLUMN
"public"
.
"hs_order_statistical"
.
"order_array"
IS
'订单明细'
;
COMMENT
ON
TABLE
"public"
.
"hs_order_statistical"
IS
'统计订单的能耗产量(kafka)'
;
ALTER
TABLE
hs_customer_extension
ADD
COLUMN
"sort"
int4
DEFAULT
1000
;
ALTER
TABLE
tcode_group
ADD
COLUMN
"id"
uuid
NOT
NULL
;
ALTER
TABLE
tcode_group
ADD
CONSTRAINT
"tcode_group_pkey"
PRIMARY
KEY
(
"id"
);
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment