Merge pull request #65683 from Blargian/doc_displayName

[Docs] add `displayName` to docs
This commit is contained in:
Raúl Marín 2024-06-25 18:28:38 +00:00 committed by GitHub
commit 7d88fd7669
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 41 additions and 0 deletions

View File

@ -3820,3 +3820,43 @@ Result:
10. │ df │ │
└────┴───────────────────────┘
```
## displayName
Returns the value of `display_name` from [config](../../operations/configuration-files.md/#configuration-files) or server Fully Qualified Domain Name (FQDN) if not set.
**Syntax**
```sql
displayName()
```
**Returned value**
- Value of `display_name` from config or server FQDN if not set. [String](../data-types/string.md).
**Example**
The `display_name` can be set in `config.xml`. Taking for example a server with `display_name` configured to 'production':
```xml
<!-- It is the name that will be shown in the clickhouse-client.
By default, anything with "production" will be highlighted in red in query prompt.
-->
<display_name>production</display_name>
```
Query:
```sql
SELECT displayName();
```
Result:
```response
┌─displayName()─┐
│ production │
└───────────────┘
```

View File

@ -1530,6 +1530,7 @@ disableProtocols
disjunction
disjunctions
displaySecretsInShowAndSelect
displayName
distro
divideDecimal
dmesg