diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-15 18:10:57 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-15 18:10:57 +0300 |
commit | e5c7d631a84940c66e46f1824ba7ce0c7f1d0ea4 (patch) | |
tree | ac1cce129d8c8cdcee6a668e27d8034d2da172e4 /doc/development/verifying_database_capabilities.md | |
parent | 0687020509cafe1e24eb0bfa0e0f5c9f6c4799d2 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/development/verifying_database_capabilities.md')
-rw-r--r-- | doc/development/verifying_database_capabilities.md | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/development/verifying_database_capabilities.md b/doc/development/verifying_database_capabilities.md index c5e854701c2..bda9c68eae5 100644 --- a/doc/development/verifying_database_capabilities.md +++ b/doc/development/verifying_database_capabilities.md @@ -12,13 +12,13 @@ necessary to add database (version) specific behavior. To facilitate this we have the following methods that you can use: -- `Gitlab::Database.main.version`: returns the PostgreSQL version number as a string +- `ApplicationRecord.database.version`: returns the PostgreSQL version number as a string in the format `X.Y.Z`. This allows you to write code such as: ```ruby -if Gitlab::Database.main.version.to_f >= 11.7 +if ApplicationRecord.database.version.to_f >= 11.7 run_really_fast_query else run_fast_query |