Docs fixes/improvements (#10090)

This commit is contained in:
Ivan Blinkov 2020-04-07 18:35:55 +03:00 committed by GitHub
parent 385e8839dc
commit 292579cad0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 80 additions and 50 deletions

View File

@ -1,4 +1,5 @@
---
toc_title: Commercial
toc_folder_title: Commercial
toc_priority: 70
---

View File

@ -839,32 +839,31 @@ If this query doesnt return anything, it means that everything is fine.
## system.settings {#system-tables-system-settings}
Contains information about session settings for current user.
Contains information about session settings for current user.
Columns:
- `name` ([String](../data_types/string.md)) — Setting name.
- `value` ([String](../data_types/string.md)) — Setting value.
- `changed` ([UInt8](../data_types/int_uint.md#uint-ranges)) — Shows whether a setting is changed from its default value.
- `description` ([String](../data_types/string.md)) — Short setting description.
- `min` ([Nullable](../data_types/nullable.md)([String](../data_types/string.md))) — Minimum value of the setting, if any is set via [constraints](settings/constraints_on_settings.md#constraints-on-settings). If the setting has no minimum value, contains [NULL](../query_language/syntax.md#null-literal).
- `max` ([Nullable](../data_types/nullable.md)([String](../data_types/string.md))) — Maximum value of the setting, if any is set via [constraints](settings/constraints_on_settings.md#constraints-on-settings). If the setting has no maximum value, contains [NULL](../query_language/syntax.md#null-literal).
- `readonly` ([UInt8](../data_types/int_uint.md#uint-ranges)) — Shows whether the current user can change the setting:
- `0` — Current user can change the setting.
- `1` — Current user can't change the setting.
- `name` ([String](../sql_reference/data_types/string.md)) — Setting name.
- `value` ([String](../sql_reference/data_types/string.md)) — Setting value.
- `changed` ([UInt8](../sql_reference/data_types/int_uint.md#uint-ranges)) — Shows whether a setting is changed from its default value.
- `description` ([String](../sql_reference/data_types/string.md)) — Short setting description.
- `min` ([Nullable](../sql_reference/data_types/nullable.md)([String](../sql_reference/data_types/string.md))) — Minimum value of the setting, if any is set via [constraints](settings/constraints_on_settings.md#constraints-on-settings). If the setting has no minimum value, contains [NULL](../sql_reference/syntax.md#null-literal).
- `max` ([Nullable](../sql_reference/data_types/nullable.md)([String](../sql_reference/data_types/string.md))) — Maximum value of the setting, if any is set via [constraints](settings/constraints_on_settings.md#constraints-on-settings). If the setting has no maximum value, contains [NULL](../sql_reference/syntax.md#null-literal).
- `readonly` ([UInt8](../sql_reference/data_types/int_uint.md#uint-ranges)) — Shows whether the current user can change the setting:
- `0` — Current user can change the setting.
- `1` — Current user cant change the setting.
**Example**
The following example shows how to get information about settings which name contains `min_i`.
```sql
``` sql
SELECT *
FROM system.settings
WHERE name LIKE '%min_i%'
```
```text
``` text
┌─name────────────────────────────────────────┬─value─────┬─changed─┬─description───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┬─min──┬─max──┬─readonly─┐
│ min_insert_block_size_rows │ 1048576 │ 0 │ Squash blocks passed to INSERT query to specified size in rows, if blocks are not big enough. │ ᴺᵁᴸᴸ │ ᴺᵁᴸᴸ │ 0 │
│ min_insert_block_size_bytes │ 268435456 │ 0 │ Squash blocks passed to INSERT query to specified size in bytes, if blocks are not big enough. │ ᴺᵁᴸᴸ │ ᴺᵁᴸᴸ │ 0 │
@ -874,20 +873,23 @@ WHERE name LIKE '%min_i%'
Using of `WHERE changed` can be useful, for example, when you want to check:
- Whether settings in configuration files are loaded correctly and are in use.
- Settings that changed in the current session.
- Whether settings in configuration files are loaded correctly and are in use.
- Settings that changed in the current session.
```sql
<!-- -->
``` sql
SELECT * FROM system.settings WHERE changed AND name='load_balancing'
```
**See also**
- [Settings](settings/index.md#settings)
- [Permissions for Queries](settings/permissions_for_queries.md#settings_readonly)
- [Constraints on Settings](settings/constraints_on_settings.md)
- [Settings](settings/index.md#settings)
- [Permissions for Queries](settings/permissions_for_queries.md#settings_readonly)
- [Constraints on Settings](settings/constraints_on_settings.md)
## system.table\_engines {#system.table_engines}
## system.table_engines
``` text
┌─name───────────────────┬─value───────┐
│ max_threads │ 8 │

View File

@ -1,5 +0,0 @@
---
en_copy: true
---
../../../CHANGELOG.md

1
docs/ru/changelog/index.md Symbolic link
View File

@ -0,0 +1 @@
../../../CHANGELOG.md

View File

@ -125,9 +125,9 @@ def sync_translation():
lang_meta, lang_content = util.read_md_file(lang_src)
en_meta.update(lang_meta)
for src, dst in redirects.items():
lang_content = lang_content.replace('(' + src, '(' + dst)
lang_content = lang_content.replace('../' + src, '../' + dst)
for src_link, dst_link in redirects.items():
lang_content = lang_content.replace('(' + src_link, '(' + dst)
lang_content = lang_content.replace('../' + src_link, '../' + dst)
util.write_md_file(lang_dst, en_meta, lang_content)
subprocess.check_call(f'git add {lang_dst}', shell=True)

View File

@ -1,5 +0,0 @@
---
en_copy: true
---
../../../CHANGELOG.md

1
docs/zh/changelog/index.md Symbolic link
View File

@ -0,0 +1 @@
../../../CHANGELOG.md

View File

@ -38,6 +38,16 @@
window.history.replaceState('', document.title, dst);
}
});
var top_nav = $('#top-nav.sticky-top');
if (window.location.hash.length > 1 && top_nav.length) {
var offset = $(window.location.hash).offset().top - top_nav.height() * 1.5;
$('html, body').animate({
scrollTop: offset
}, 70);
}
(function (d, w, c) {
(w[c] = w[c] || []).push(function() {
try {

View File

@ -1,8 +1,9 @@
function onResize() {
var window_height = $(window).height();
$('#sidebar, #toc.toc-right').css({
'height': (window_height - $('#top-nav').height()) + 'px'
});
var window_width = $(window).width();
var is_wide = window_width >= 768;
var docs_top_nav = $('#top-nav.bg-dark-alt');
$('body').attr('data-offset', window_height.toString());
var sidebar = $('#sidebar');
var languages = $('#languages-dropdown')
@ -12,17 +13,33 @@ function onResize() {
} else {
single_page_switch.removeClass('float-right');
}
if ($(window).width() >= 768) {
if (is_wide) {
sidebar.removeClass('collapse');
languages.detach().appendTo($('#languages-wrapper'));
} else {
sidebar.addClass('collapse');
languages.detach().insertBefore(single_page_switch);
languages.addClass('float-right');
single_page_switch.removeClass('float-right');
}
if (window_height < 800 && is_wide) {
docs_top_nav.removeClass('sticky-top');
$('#sidebar, #toc.toc-right').css({
'height': window_height,
'position': 'sticky',
'top': 0
});
} else {
var top_nav_height = docs_top_nav.height();
docs_top_nav.addClass('sticky-top');
$('#sidebar, #toc.toc-right').css({
'height': (window_height - top_nav_height) + 'px',
'position': 'fixed',
'top': top_nav_height + 16
});
}
}
$(document).ready(function () {
onResize();
$('#sidebar .nav-link.active').parents('.collapse').each(function() {
@ -49,6 +66,15 @@ $(document).ready(function () {
}
});
});
$('#sidebar').on('shown.bs.collapse', function () {
onResize();
$('body').on('touchmove', function (e) {
e.preventDefault();
});
});
$('#sidebar').on('hidden.bs.collapse', function () {
$('body').on('touchmove', function () {});
});
var headers = $('#content h1, #content h2, #content h3, #content h4, #content h5, #content h6');
headers.mouseenter(function() {

View File

@ -1,18 +1,15 @@
User-agent: *
Disallow: /docs/en/single/
Disallow: /docs/ru/single/
Disallow: /docs/zh/single/
Disallow: /docs/es/single/
Disallow: /docs/fr/single/
Disallow: /docs/ru/single/
Disallow: /docs/ja/single/
Disallow: /docs/fa/single/
Disallow: /docs/v1*
Disallow: /docs/v2*
Disallow: /docs/v3*
Disallow: /docs/en/search.html
Disallow: /docs/ru/search.html
Disallow: /docs/ja/search.html
Disallow: /docs/zh/search.html
Disallow: /docs/fa/search.html
Disallow: /cdn-cgi/
Allow: /
Host: https://clickhouse.tech
Sitemap: https://clickhouse.tech/docs/sitemap.xml
Sitemap: https://clickhouse.tech/sitemap.xml

View File

@ -3,14 +3,17 @@
<sitemap>
<loc>https://clickhouse.tech/docs/en/sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://clickhouse.tech/docs/zh/sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://clickhouse.tech/docs/es/sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://clickhouse.tech/docs/ru/sitemap.xml</loc>
<loc>https://clickhouse.tech/docs/fr/sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://clickhouse.tech/docs/zh/sitemap.xml</loc>
<loc>https://clickhouse.tech/docs/ru/sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://clickhouse.tech/docs/ja/sitemap.xml</loc>
@ -19,6 +22,6 @@
<loc>https://clickhouse.tech/docs/fa/sitemap.xml</loc>
</sitemap>
<sitemap>
<loc>https://clickhouse.tech/docs/sitemap_static.xml</loc>
<loc>https://clickhouse.tech/sitemap_static.xml</loc>
</sitemap>
</sitemapindex>

View File

@ -6,10 +6,10 @@
</url>
<url>
<loc>https://clickhouse.tech/benchmark.html</loc>
<changefreq>daily</changefreq>
<changefreq>weekly</changefreq>
</url>
<url>
<loc>https://clickhouse.tech/benchmark_hardware.html</loc>
<changefreq>daily</changefreq>
<changefreq>weekly</changefreq>
</url>
</urlset>

View File

@ -1,6 +1,5 @@
<script async type="text/javascript" src="/js/base.js?js_digest"></script>
<noscript>
<div><img src="https://mc.yandex.ru/watch/18343495" alt=""/></div>
<div><img src="https://mc.yandex.ru/watch/18343495" alt="Yandex"/></div>
</noscript>