ClickHouse® is a real-time analytics DBMS
Go to file
Azat Khuzhin 5277c802f7 Fix table dependencies in case of failed RENAME TABLE
CI found this [1]

    [ 382620 ] {} <Error> Application: Caught exception while loading metadata: Code: 60. DB::Exception: Table test_25.join doesn\'t exist: While processing _CAST(joinGet(test_25.join, \'m\', CAST(\'42\', \'int\')) AS m_tmp_alter1351896088559986425, \'Int32\') AS m: default expression and column type are incomp
    [ 382620 ] {} <Error> Application: Code: 60. DB::Exception: Table test_25.join doesn\'t exist: While processing _CAST(joinGet(test_25.join, \'m\', CAST(\'42\', \'int\')) AS m_tmp_alter1351896088559986425, \'Int32\') AS m: default expression and column type are incompatible.: Cannot attach table `test_25`.`t

  [1]: https://s3.amazonaws.com/clickhouse-test-reports/48670/d7f865037266ed87538cf4df7ec7e8165681871b/stress_test__asan_.html

The problem here is that after failed RENAME dependencies got lost:

    [4e937f39d866] 2023.04.12 00:51:06.833624 [ 13419 ] {61429225-64cb-4fce-b60d-01e0dac6e52c} <Error> executeQuery: Code: 241. DB::Exception: Memory limit (total) exceeded: would use 34.65 GiB (attempt to allocate chunk of 2097419 bytes), maximum: 34.29 GiB. OvercommitTracker decision: Memory overcommit has freed not enough memory. (MEMORY_LIMIT_EXCEEDED) (version 23.4.1.1) (from [::1]:45710) (comment: 01160_table_dependencies.sh) (in query: create database test_25_1), Stack trace (when copying this message, always include the lines below):
    [4e937f39d866] 2023.04.12 00:51:07.351914 [ 5151 ] {66d8bdd4-668e-4239-a8af-6b8f17bb5222} <Error> executeQuery: Code: 81. DB::Exception: Database test_25_1 doesn't exist. (UNKNOWN_DATABASE) (version 23.4.1.1) (from [::1]:45762) (comment: 01160_table_dependencies.sh) (in query: rename table t to test_25_1.t), Stack trace (when copying this message, always include the lines below):

And from the test output:

    OK
    OK
    OK
    OK
    a       []      []      []
    data_02344      []      []      []
    date_table      []      []      []
    dict1   []      ['dict_src']    ['join']
    dict2   []      ['join']        []
    dict_src        []      []      ['dict1']
    dist_02346      []      []      []
    join    []      ['dict1']       ['dict2','s']
                                    ^^^^^^^^^^^^^ no "t"

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-04-12 11:11:05 +02:00
.github fix 2023-04-07 23:50:09 +02:00
base Merge pull request #48569 from awfeequdng/bugfix/wide_integer 2023-04-10 07:25:51 +03:00
benchmark
cmake
contrib Merge pull request #48183 from ClickHouse/contrib_sparse_checkout 2023-04-11 16:18:27 +03:00
docker
docs Merge pull request #48489 from ClickHouse/rs/date_time-alias 2023-04-11 19:53:44 +02:00
packages
programs Slightly optimize Install 2023-04-10 04:15:13 +02:00
rust
src Fix table dependencies in case of failed RENAME TABLE 2023-04-12 11:11:05 +02:00
tests Fix table dependencies in case of failed RENAME TABLE 2023-04-12 11:11:05 +02:00
utils add Observability to spell list 2023-04-11 09:53:40 -04:00
.clang-format
.clang-tidy Cleanup mess in .clang-tidy 2023-04-04 16:07:02 +00:00
.editorconfig
.exrc
.git-blame-ignore-revs
.gitattributes
.gitignore
.gitmodules
.pylintrc
.snyk
.yamllint
AUTHORS
CHANGELOG.md
CMakeLists.txt
CODE_OF_CONDUCT.md
CONTRIBUTING.md
format_sources
LICENSE
PreLoad.cmake
README.md Change ClickHouse logo to dark mode 2023-04-06 14:44:29 -07:00
SECURITY.md

ClickHouse — open source distributed column-oriented DBMS

ClickHouse® is an open-source column-oriented database management system that allows generating analytical data reports in real-time.

How To Install (Linux, macOS, FreeBSD)

curl https://clickhouse.com/ | sh
  • Official website has a quick high-level overview of ClickHouse on the main page.
  • ClickHouse Cloud ClickHouse as a service, built by the creators and maintainers.
  • Tutorial shows how to set up and query a small ClickHouse cluster.
  • Documentation provides more in-depth information.
  • YouTube channel has a lot of content about ClickHouse in video format.
  • Slack and Telegram allow chatting with ClickHouse users in real-time.
  • Blog contains various ClickHouse-related articles, as well as announcements and reports about events.
  • Code Browser (Woboq) with syntax highlight and navigation.
  • Code Browser (github.dev) with syntax highlight, powered by github.dev.
  • Contacts can help to get your questions answered if there are any.

Upcoming Events

  • ClickHouse Meetup in Austin - Mar 30 - The first ClickHouse Meetup in Austin is happening soon! Interested in speaking, let us know!
  • v23.3 Release Webinar - Mar 30 - 23.3 is rapidly approaching. Original creator, co-founder, and CTO of ClickHouse Alexey Milovidov will walk us through the highlights of the release.

Recent Recordings

  • FOSDEM 2023: In the "Fast and Streaming Data" room Alexey gave a talk entitled "Building Analytical Apps With ClickHouse" that looks at the landscape of data tools, an interesting data set, and how you can interact with data quickly. Check out the recording on YouTube.
  • Recording available: v23.2 Release Webinar NTILE Window Function support, Partition Key for GROUP By, io_uring, Apache Iceberg support, Dynamic Disks, integrations updates! Watch it now!
  • All release webinar recordings: YouTube playlist