Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
gargantext
Project
Project
Details
Activity
Releases
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
humanities
gargantext
Commits
ef08aad6
Commit
ef08aad6
authored
Mar 29, 2018
by
sim
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Migration: remove legacy table nodes_hyperdata
parent
e6a6f379
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
37 additions
and
0 deletions
+37
-0
e78fd042f13c_drop_legacy_table_nodes_hyperdata.py
...ersions/e78fd042f13c_drop_legacy_table_nodes_hyperdata.py
+37
-0
No files found.
alembic/versions/e78fd042f13c_drop_legacy_table_nodes_hyperdata.py
0 → 100644
View file @
ef08aad6
"""Drop legacy table nodes_hyperdata
Revision ID: e78fd042f13c
Revises: 8fced8397139
Create Date: 2018-03-29 15:22:55.643556
"""
from
alembic
import
op
import
sqlalchemy
as
sa
import
gargantext
from
sqlalchemy.dialects
import
postgresql
# revision identifiers, used by Alembic.
revision
=
'e78fd042f13c'
down_revision
=
'8fced8397139'
branch_labels
=
None
depends_on
=
None
def
upgrade
():
op
.
drop_table
(
'nodes_hyperdata'
)
def
downgrade
():
op
.
create_table
(
'nodes_hyperdata'
,
sa
.
Column
(
'id'
,
sa
.
Integer
(),
nullable
=
False
),
sa
.
Column
(
'node_id'
,
sa
.
Integer
(),
nullable
=
True
),
sa
.
Column
(
'key'
,
gargantext
.
models
.
hyperdata
.
HyperdataKey
(),
nullable
=
True
),
sa
.
Column
(
'value_int'
,
sa
.
Integer
(),
nullable
=
True
),
sa
.
Column
(
'value_flt'
,
postgresql
.
DOUBLE_PRECISION
(),
nullable
=
True
),
sa
.
Column
(
'value_utc'
,
sa
.
DateTime
(
timezone
=
True
),
nullable
=
True
),
sa
.
Column
(
'value_str'
,
sa
.
String
(
length
=
255
),
nullable
=
True
),
sa
.
Column
(
'value_txt'
,
sa
.
Text
(),
nullable
=
True
),
sa
.
ForeignKeyConstraint
([
'node_id'
],
[
'nodes.id'
],
ondelete
=
'CASCADE'
),
sa
.
PrimaryKeyConstraint
(
'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