Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
999cf029
Commit
999cf029
authored
Apr 10, 2017
by
Valery Sizov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Issue multile assignees] Add a migration to fix inconsistent data[ci skip]
parent
2cf082ec
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
db/migrate/20170320173259_migrate_assignees.rb
db/migrate/20170320173259_migrate_assignees.rb
+4
-0
No files found.
db/migrate/20170320173259_migrate_assignees.rb
View file @
999cf029
...
...
@@ -25,6 +25,10 @@ class MigrateAssignees < ActiveRecord::Migration
def
up
execute
<<-
EOF
UPDATE issues
SET assignee_id = NULL
WHERE assignee_id NOT IN(SELECT id FROM users);
INSERT INTO issue_assignees(issue_id, user_id)
SELECT id, assignee_id FROM issues WHERE assignee_id IS NOT NULL
EOF
...
...
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