This repository has been archived by the owner on Mar 15, 2021. It is now read-only.
Add getVersion function to db clients to get version details #104
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This unifies aspects of getting version information across databases as prior to this. In #80, I added the
version
function that returns version details, except that this was inconsistent across providers where some would return just the version number string (e.g.8.0.21
) and then some would return additional details (e.g.PostgreSQL 9.4.26 on x86_64-pc-linux-gnu (Debian 9.4.26-1.pgdg90+1), compiled by gcc (Debian 6.3.0-18+deb9u1) 6.3.0 20170516, 64-bit
).This deprecates the
version()
function in favor ofgetVersion()
which returns an object that has the properties ofname
,version
, andstring
.name
is the minimal string name of the client (e.g.PostgreSQL
orMariaDB
),version
is the numerical identifier (e.g.9.4.26
), and thenstring
is that full string.This, combined with #100 cleans up some of the version comparisons in the test suite, as well as will be used in follow-up work for adding support for minimally redshift.