Skip to content
This repository was archived by the owner on Jan 28, 2021. It is now read-only.

Commit c61381d

Browse files
Fix typos and make style consistent
- Change all functions descriptions in README.md to stick to the lower-case present-tense style, so each row is read as "Function X returns/changes/adds Y". - Fix typos in supported_clients.md. Signed-off-by: Alejandro García Montoro <[email protected]>
1 parent 2e9abc7 commit c61381d

File tree

2 files changed

+69
-69
lines changed

2 files changed

+69
-69
lines changed

README.md

Lines changed: 65 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -59,71 +59,71 @@ We support and actively test against certain third-party clients to ensure compa
5959
<!-- BEGIN FUNCTIONS -->
6060
| Name | Description |
6161
|:-------------|:-------------------------------------------------------------------------------------------------------------------------------|
62-
|`ARRAY_LENGTH(json)`|If the json representation is an array, this function returns its size.|
63-
|`AVG(expr)`|Returns the average value of expr in all rows.|
64-
|`CEIL(number)`|Return the smallest integer value that is greater than or equal to `number`.|
65-
|`CEILING(number)`|Return the smallest integer value that is greater than or equal to `number`.|
66-
|`CHAR_LENGTH(str)`|Return the length of the string in characters.|
67-
|`COALESCE(...)`|The function returns the first non-null value in a list.|
68-
|`CONCAT(...)`|Concatenate any group of fields into a single string.|
69-
|`CONCAT_WS(sep, ...)`|Concatenate any group of fields into a single string. The first argument is the separator for the rest of the arguments. The separator is added between the strings to be concatenated. The separator can be a string, as can the rest of the arguments. If the separator is NULL, the result is NULL.|
70-
|`CONNECTION_ID()`|Return the current connection ID.|
71-
|`COUNT(expr)`| Returns a count of the number of non-NULL values of expr in the rows retrieved by a SELECT statement.|
72-
|`DATE_ADD(date, interval)`|Adds the interval to the given date.|
73-
|`DATE_SUB(date, interval)`|Subtracts the interval from the given date.|
74-
|`DAY(date)`|Synonym for DAYOFMONTH().|
75-
|`DATE(date)`|Returns the date part of the given date.|
76-
|`DAYOFMONTH(date)`|Return the day of the month (0-31).|
77-
|`DAYOFWEEK(date)`|Returns the day of the week of the given date.|
78-
|`DAYOFYEAR(date)`|Returns the day of the year of the given date.|
79-
|`FIRST(expr)`|Returns the first value in a sequence of elements of an aggregation.|
80-
|`FLOOR(number)`|Returns the largest integer value that is less than or equal to `number`.|
81-
|`FROM_BASE64(str)`|Decodes the base64-encoded string str.|
82-
|`GREATEST(...)`|Returns the greatest numeric or string value.|
83-
|`HOUR(date)`|Returns the hours of the given date.|
84-
|`IFNULL(expr1, expr2)`|If expr1 is not NULL, IFNULL() returns expr1; otherwise it returns expr2.|
85-
|`IS_BINARY(blob)`|Returns whether a BLOB is a binary file or not.|
86-
|`JSON_EXTRACT(json_doc, path, ...)`|Extracts data from a json document using json paths. Extracting a string will result in that string being quoted. To avoid this, use `JSON_UNQUOTE(JSON_EXTRACT(json_doc, path, ...))`.|
87-
|`JSON_UNQUOTE(json)`|Unquotes JSON value and returns the result as a utf8mb4 string.|
88-
|`LAST(expr)`|Returns the last value in a sequence of elements of an aggregation.|
89-
|`LEAST(...)`|Returns the smaller numeric or string value.|
90-
|`LENGTH(str)`|Return the length of the string in bytes.|
91-
|`LN(X)`|Return the natural logarithm of X.|
92-
|`LOG(X), LOG(B, X)`|If called with one parameter, this function returns the natural logarithm of X. If called with two parameters, this function returns the logarithm of X to the base B. If X is less than or equal to 0, or if B is less than or equal to 1, then NULL is returned.|
93-
|`LOG10(X)`|Returns the base-10 logarithm of X.|
94-
|`LOG2(X)`|Returns the base-2 logarithm of X.|
95-
|`LOWER(str)`|Returns the string str with all characters in lower case.|
96-
|`LPAD(str, len, padstr)`|Return the string argument, left-padded with the specified string.|
97-
|`LTRIM(str)`|Returns the string str with leading space characters removed.|
98-
|`MAX(expr)`|Returns the maximum value of expr in all rows.|
99-
|`MID(str, pos, [len])`|Return a substring from the provided string starting at `pos` with a length of `len` characters. If no `len` is provided, all characters from `pos` until the end will be taken.|
100-
|`MIN(expr)`|Returns the minimum value of expr in all rows.|
101-
|`MINUTE(date)`|Returns the minutes of the given date.|
102-
|`MONTH(date)`|Returns the month of the given date.|
103-
|`NOW()`|Returns the current timestamp.|
104-
|`NULLIF(expr1, expr2)`|Returns NULL if expr1 = expr2 is true, otherwise returns expr1.|
105-
|`POW(X, Y)`|Returns the value of X raised to the power of Y.|
106-
|`REGEXP_MATCHES(text, pattern, [flags])`|Returns an array with the matches of the pattern in the given text. Flags can be given to control certain behaviours of the regular expression. Currently, only the `i` flag is supported, to make the comparison case insensitive.|
107-
|`REPEAT(str, count)`|Returns a string consisting of the string str repeated count times.|
108-
|`REPLACE(str,from_str,to_str)`|Returns the string str with all occurrences of the string from_str replaced by the string to_str.|
109-
|`REVERSE(str)`|Returns the string str with the order of the characters reversed.|
110-
|`ROUND(number, decimals)`|Round the `number` to `decimals` decimal places.|
111-
|`RPAD(str, len, padstr)`|Returns the string str, right-padded with the string padstr to a length of len characters.|
112-
|`RTRIM(str)`|Returns the string str with trailing space characters removed.|
113-
|`SECOND(date)`|Returns the seconds of the given date.|
114-
|`SLEEP(seconds)`|Wait for the specified number of seconds (can be fractional).|
115-
|`SOUNDEX(str)`|Returns the soundex of a string.|
116-
|`SPLIT(str,sep)`|Receives a string and a separator and returns the parts of the string split by the separator as a JSON array of strings.|
117-
|`SQRT(X)`|Returns the square root of a nonnegative number X.|
118-
|`SUBSTR(str, pos, [len])`|Return a substring from the provided string starting at `pos` with a length of `len` characters. If no `len` is provided, all characters from `pos` until the end will be taken.|
119-
|`SUBSTRING(str, pos, [len])`|Return a substring from the provided string starting at `pos` with a length of `len` characters. If no `len` is provided, all characters from `pos` until the end will be taken.|
120-
|`SUM(expr)`|Returns the sum of expr in all rows.|
121-
|`TO_BASE64(str)`|Encodes the string str in base64 format.|
122-
|`TRIM(str)`|Returns the string str with all spaces removed.|
123-
|`UPPER(str)`|Returns the string str with all characters in upper case.|
124-
|`WEEKDAY(date)`|Returns the weekday of the given date.|
125-
|`YEAR(date)`|Returns the year of the given date.|
126-
|`YEARWEEK(date, mode)`|Returns year and week for a date. The year in the result may be different from the year in the date argument for the first and the last week of the year.|
62+
|`ARRAY_LENGTH(json)`|if the json representation is an array, this function returns its size.|
63+
|`AVG(expr)`| returns the average value of expr in all rows.|
64+
|`CEIL(number)`| returns the smallest integer value that is greater than or equal to `number`.|
65+
|`CEILING(number)`| returns the smallest integer value that is greater than or equal to `number`.|
66+
|`CHAR_LENGTH(str)`| returns the length of the string in characters.|
67+
|`COALESCE(...)`| returns the first non-null value in a list.|
68+
|`CONCAT(...)`| concatenates any group of fields into a single string.|
69+
|`CONCAT_WS(sep, ...)`| concatenates any group of fields into a single string. The first argument is the separator for the rest of the arguments. The separator is added between the strings to be concatenated. The separator can be a string, as can the rest of the arguments. If the separator is NULL, the result is NULL.|
70+
|`CONNECTION_ID()`| returns the current connection ID.|
71+
|`COUNT(expr)`| returns a count of the number of non-NULL values of expr in the rows retrieved by a SELECT statement.|
72+
|`DATE_ADD(date, interval)`| adds the interval to the given `date`.|
73+
|`DATE_SUB(date, interval)`| subtracts the interval from the given `date`.|
74+
|`DAY(date)`| is a synonym for DAYOFMONTH().|
75+
|`DATE(date)`| returns the date part of the given `date`.|
76+
|`DAYOFMONTH(date)`| returns the day of the month (0-31).|
77+
|`DAYOFWEEK(date)`| returns the day of the week of the given `date`.|
78+
|`DAYOFYEAR(date)`| returns the day of the year of the given `date`.|
79+
|`FIRST(expr)`| returns the first value in a sequence of elements of an aggregation.|
80+
|`FLOOR(number)`| returns the largest integer value that is less than or equal to `number`.|
81+
|`FROM_BASE64(str)`| decodes the base64-encoded string `str`.|
82+
|`GREATEST(...)`| returns the greatest numeric or string value.|
83+
|`HOUR(date)`| returns the hours of the given `date`.|
84+
|`IFNULL(expr1, expr2)`| if `expr1` is not NULL, it returns `expr1`; otherwise it returns `expr2`.|
85+
|`IS_BINARY(blob)`| returns whether a `blob` is a binary file or not.|
86+
|`JSON_EXTRACT(json_doc, path, ...)`| extracts data from a json document using json paths. Extracting a string will result in that string being quoted. To avoid this, use `JSON_UNQUOTE(JSON_EXTRACT(json_doc, path, ...))`.|
87+
|`JSON_UNQUOTE(json)`| unquotes JSON value and returns the result as a utf8mb4 string.|
88+
|`LAST(expr)`| returns the last value in a sequence of elements of an aggregation.|
89+
|`LEAST(...)`| returns the smaller numeric or string value.|
90+
|`LENGTH(str)`| returns the length of the string in bytes.|
91+
|`LN(X)`| returns the natural logarithm of `X`.|
92+
|`LOG(X), LOG(B, X)`| if called with one parameter, this function returns the natural logarithm of `X`. If called with two parameters, this function returns the logarithm of `X` to the base `B`. If `X` is less than or equal to 0, or if `B` is less than or equal to 1, then NULL is returned.|
93+
|`LOG10(X)`| returns the base-10 logarithm of `X`.|
94+
|`LOG2(X)`| returns the base-2 logarithm of `X`.|
95+
|`LOWER(str)`| returns the string `str` with all characters in lower case.|
96+
|`LPAD(str, len, padstr)`| returns the string `str`, left-padded with the string `padstr` to a length of `len` characters.|
97+
|`LTRIM(str)`| returns the string `str` with leading space characters removed.|
98+
|`MAX(expr)`| returns the maximum value of `expr` in all rows.|
99+
|`MID(str, pos, [len])`| returns a substring from the provided string starting at `pos` with a length of `len` characters. If no `len` is provided, all characters from `pos` until the end will be taken.|
100+
|`MIN(expr)`| returns the minimum value of `expr` in all rows.|
101+
|`MINUTE(date)`| returns the minutes of the given `date`.|
102+
|`MONTH(date)`| returns the month of the given `date`.|
103+
|`NOW()`| returns the current timestamp.|
104+
|`NULLIF(expr1, expr2)`| returns NULL if `expr1 = expr2` is true, otherwise returns `expr1`.|
105+
|`POW(X, Y)`| returns the value of `X` raised to the power of `Y`.|
106+
|`REGEXP_MATCHES(text, pattern, [flags])`| returns an array with the matches of the `pattern` in the given `text`. Flags can be given to control certain behaviours of the regular expression. Currently, only the `i` flag is supported, to make the comparison case insensitive.|
107+
|`REPEAT(str, count)`| returns a string consisting of the string `str` repeated `count` times.|
108+
|`REPLACE(str,from_str,to_str)`| returns the string `str` with all occurrences of the string `from_str` replaced by the string `to_str`.|
109+
|`REVERSE(str)`| returns the string `str` with the order of the characters reversed.|
110+
|`ROUND(number, decimals)`| rounds the `number` to `decimals` decimal places.|
111+
|`RPAD(str, len, padstr)`| returns the string `str`, right-padded with the string `padstr` to a length of `len` characters.|
112+
|`RTRIM(str)`| returns the string `str` with trailing space characters removed.|
113+
|`SECOND(date)`| returns the seconds of the given `date`.|
114+
|`SLEEP(seconds)`| waits for the specified number of seconds (can be fractional).|
115+
|`SOUNDEX(str)`| returns the soundex of a string.|
116+
|`SPLIT(str,sep)`| returns the parts of the string `str` split by the separator `sep` as a JSON array of strings.|
117+
|`SQRT(X)`| returns the square root of a nonnegative number `X`.|
118+
|`SUBSTR(str, pos, [len])`| returns a substring from the string `str` starting at `pos` with a length of `len` characters. If no `len` is provided, all characters from `pos` until the end will be taken.|
119+
|`SUBSTRING(str, pos, [len])`| returns a substring from the string `str` starting at `pos` with a length of `len` characters. If no `len` is provided, all characters from `pos` until the end will be taken.|
120+
|`SUM(expr)`| returns the sum of `expr` in all rows.|
121+
|`TO_BASE64(str)`| encodes the string `str` in base64 format.|
122+
|`TRIM(str)`| returns the string `str` with all spaces removed.|
123+
|`UPPER(str)`| returns the string `str` with all characters in upper case.|
124+
|`WEEKDAY(date)`| returns the weekday of the given `date`.|
125+
|`YEAR(date)`| returns the year of the given `date`.|
126+
|`YEARWEEK(date, mode)`| returns year and week for a date. The year in the result may be different from the year in the date argument for the first and the last week of the year.|
127127
<!-- END FUNCTIONS -->
128128

129129
## Configuration

SUPPORTED_CLIENTS.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Supported clients
22

3-
These are the clients we actively test against to check are compatible with go-mysql-server. Other clients may also work, but we don't check on every build if we remain compatible with them.
3+
These are the clients we actively test against to check that they are compatible with go-mysql-server. Other clients may also work, but we don't check on every build if we remain compatible with them.
44

55
- Python
66
- [pymysql](#pymysql)
@@ -16,7 +16,7 @@ These are the clients we actively test against to check are compatible with go-m
1616
- Java/JVM
1717
- [mariadb-java-client](#mariadb-java-client)
1818
- Go
19-
- [go-mysql-driver/mysql](#go-mysql-driver-mysql)
19+
- [go-mysql-driver/mysql](#go-sql-drivermysql)
2020
- C
2121
- [mysql-connector-c](#mysql-connector-c)
2222
- Grafana
@@ -218,7 +218,7 @@ func main() {
218218
}
219219
```
220220

221-
### #mysql-connector-c
221+
### mysql-connector-c
222222

223223
```c
224224
#include <my_global.h>
@@ -271,4 +271,4 @@ int main(int argc, char **argv)
271271

272272
return 0;
273273
}
274-
```
274+
```

0 commit comments

Comments
 (0)