grafana/pkg/services/sqlstore/migrations
Oleg Gaidarenko b37ee65bd3
Chore: prepare our SQL for cockroach db (#16471)
This is basically implementation of the https://github.com/grafana/grafana/issues/8900#issuecomment-435437167
points, except for the type conversion bit.

I tried to implement idea mentioned in cockroachdb ticket (see below).
And it is possible, but it complicates things as lot - not only we have to
have 4 SQL statements instead of one, but we would have to copy the column
structure as well - PK, FG, indexes and stuff, plus there will
be additional downtime with this approach.

So idea for this pull is to prepare our SQL as much as possible, so when
cockroachdb will add support for full type conversions, we could easilly add
support for it as well.

* Add `CASCADE` to `DROP INDEX` statement

* Make string conversions explicit

Thanks @Luit

Ref #8900
Ref cockroach/cockroach#9851
2019-04-15 18:49:24 +03:00
..
alert_mig.go Chore: prepare our SQL for cockroach db (#16471) 2019-04-15 18:49:24 +03:00
annotation_mig.go Fix some typos found by codespell 2018-09-21 11:54:52 +02:00
apikey_mig.go utf8mb4 encoding (#7959) 2017-03-28 14:34:53 +02:00
cache_data_mig.go renames key to cache_key 2019-03-11 10:49:55 +01:00
common.go login: uses epochs for login throtting. 2018-02-16 17:25:46 +01:00
dashboard_acl.go move database-specific code into dialects (#11884) 2018-05-10 16:54:21 +02:00
dashboard_mig.go Chore: prepare our SQL for cockroach db (#16471) 2019-04-15 18:49:24 +03:00
dashboard_snapshot_mig.go snapshots: Add external_delete_url column 2018-12-10 16:25:02 -05:00
dashboard_version_mig.go move database-specific code into dialects (#11884) 2018-05-10 16:54:21 +02:00
datasource_mig.go fix: prevent datasource json data stored as nil (#15508) 2019-03-02 21:18:26 +01:00
heartbeat_mig.go feat(query_part): refactoring query part 2016-08-15 17:20:45 +02:00
login_attempt_mig.go login: migration fix. 2018-02-16 17:36:28 +01:00
migrations_test.go Sqlstore refactor (#11908) 2018-05-18 11:10:10 +02:00
migrations.go Move oauth token migrations in user_auth_mig 2019-03-11 09:31:03 -04:00
org_mig.go Sqlstore refactor (#11908) 2018-05-18 11:10:10 +02:00
playlist_mig.go utf8mb4 encoding (#7959) 2017-03-28 14:34:53 +02:00
plugin_setting.go utf8mb4 encoding (#7959) 2017-03-28 14:34:53 +02:00
preferences_mig.go feat: team preferences 2018-11-12 20:01:53 +01:00
quota_mig.go utf8mb4 encoding (#7959) 2017-03-28 14:34:53 +02:00
serverlock_migrations.go moves migrations to /sqlstore/migrations 2018-12-17 16:36:57 +01:00
session_mig.go Issue 3461: Session table is now created automatically 2015-12-23 01:33:46 -06:00
stats_mig.go pkg: fix deadcode issues 2018-04-26 19:24:21 +02:00
tag_mig.go Create annotations (#8197) 2017-10-07 10:31:39 +02:00
team_mig.go teams: refactored db code. 2019-03-19 14:01:18 +01:00
temp_user.go tweak column lengths for utf8mb4 support on older mysql (#8483) 2017-05-29 08:31:36 +02:00
user_auth_mig.go Move oauth token migrations in user_auth_mig 2019-03-11 09:31:03 -04:00
user_auth_token_mig.go begin user auth token implementation 2019-01-15 15:16:20 +01:00
user_mig.go pkg/services/sqlstore: Fix x.Sql is deprecated: use SQL instead. (megacheck) 2018-09-16 12:26:05 +02:00