# CrateDB

**URL:** https://community.cratedb.com/c/cratedb/18.md?page=4

[Latest](https://community.cratedb.com/latest.md) · [Categories](https://community.cratedb.com/categories.md) · [Tags](https://community.cratedb.com/tags.md)

**Page:** 5

---

## [Query partition size from table](https://community.cratedb.com/t/query-partition-size-from-table/1785)

<div class="topic-metadata">

**Author:** [@SchabiDesigns](https://community.cratedb.com/u/SchabiDesigns)\
**Replies:** 2\
**Last updated:** [June 13, 2024, 3:31pm UTC](https://community.cratedb.com/t/query-partition-size-from-table/1785 "2024-06-13T15:31:40Z")

</div>

Hi Community Is there a way to get the size of a partition within a table? I would like to start a new partition when the size exceed a certain amount of space. Regards

---

## [Advice for table/partitioning/sharding strategies](https://community.cratedb.com/t/advice-for-table-partitioning-sharding-strategies/1780)

<div class="topic-metadata">

**Author:** [@homer](https://community.cratedb.com/u/homer)\
**Replies:** 4\
**Last updated:** [June 3, 2024, 4:21pm UTC](https://community.cratedb.com/t/advice-for-table-partitioning-sharding-strategies/1780 "2024-06-03T16:21:47Z")

</div>

I’m tasked with storing data for a number of IoT devices (more than 50k devices), which is ingested in batches. Multiple time series at different resolutions are associated to each device, although some devices might no…

---

## [Springboot Flyway CrateDB](https://community.cratedb.com/t/springboot-flyway-cratedb/1779)

<div class="topic-metadata">

**Author:** [@ChristopheKod](https://community.cratedb.com/u/ChristopheKod)\
**Replies:** 0\
**Last updated:** [May 31, 2024, 8:39am UTC](https://community.cratedb.com/t/springboot-flyway-cratedb/1779 "2024-05-31T08:39:15Z")

</div>

Hi, We use crateDB in a springboot (jpa) project to monitoring application with driver postgresQL. And we want integrate flyway for database migration but there’s an error when we start the application (and if we repla…

---

## [Couldn't complete updating a table with more than 200 million records](https://community.cratedb.com/t/couldnt-complete-updating-a-table-with-more-than-200-million-records/1771)

<div class="topic-metadata">

**Author:** [@Jun\_Zhou](https://community.cratedb.com/u/Jun_Zhou)\
**Replies:** 3\
**Last updated:** [May 28, 2024, 3:06pm UTC](https://community.cratedb.com/t/couldnt-complete-updating-a-table-with-more-than-200-million-records/1771 "2024-05-28T15:06:27Z")

</div>

We are using crateDB 5.5.2, and there is a table pgdb\_scm.pms\_pms\_short\_of\_material\_log\_l with more than 200 million records, below sql has been running for over a day without completing. update pgdb\_scm.pms\_pms\_short\_…

---

## [Syntax error on if statement with exists](https://community.cratedb.com/t/syntax-error-on-if-statement-with-exists/1775)

<div class="topic-metadata">

**Author:** [@tcochunk](https://community.cratedb.com/u/tcochunk)\
**Replies:** 5\
**Last updated:** [May 28, 2024, 7:35am UTC](https://community.cratedb.com/t/syntax-error-on-if-statement-with-exists/1775 "2024-05-28T07:35:04Z")

</div>

I am new to CrateDB, new to postgresql, and so so with sql in general. I am trying to execute the following sql statements but keep getting an error and cannot figure out what is going on: IF EXISTS(SELECT 1 FROM crate…

---

## [Insert an nest json objects with Error ERROR: Can't map PGType with oid=-272646673 to Crate type](https://community.cratedb.com/t/insert-an-nest-json-objects-with-error-error-cant-map-pgtype-with-oid-272646673-to-crate-type/1772)

<div class="topic-metadata">

**Author:** [@Jun\_Zhou](https://community.cratedb.com/u/Jun_Zhou)\
**Replies:** 3\
**Last updated:** [May 22, 2024, 7:08am UTC](https://community.cratedb.com/t/insert-an-nest-json-objects-with-error-error-cant-map-pgtype-with-oid-272646673-to-crate-type/1772 "2024-05-22T07:08:23Z")

</div>

I’m using CrateDB 5.5.2, and I create a dynamic objects table nifi.nifi\_provenance to store json objects. But I encounter error Can't map PGType with oid=-272646673 to Crate type when inserting some records. cr\> show cr…

---

## [Crate Node issue](https://community.cratedb.com/t/crate-node-issue/1769)

<div class="topic-metadata">

**Author:** [@Vinayak\_Katkar](https://community.cratedb.com/u/Vinayak_Katkar)\
**Replies:** 1\
**Last updated:** [May 21, 2024, 12:24pm UTC](https://community.cratedb.com/t/crate-node-issue/1769 "2024-05-21T12:24:03Z")

</div>

Hi Team, \[2024-05-16T01:18:02,119\]\[INFO \]\[o.e.m.j.JvmGcMonitorService\] \[Node1\] \[gc\]\[2296923\] overhead, spent \[399ms\] collecting in the last \[1s\] \[2024-05-16T04:14:46,652\]\[ERROR\]\[i.c.p.p.PostgresWireProtocol\] \[Node1\] Unc…

---

## [Failed to connect CrateDB 5.5 from NiFi 1.23.2](https://community.cratedb.com/t/failed-to-connect-cratedb-5-5-from-nifi-1-23-2/1662)

<div class="topic-metadata">

**Author:** [@Jun\_Zhou](https://community.cratedb.com/u/Jun_Zhou)\
**Replies:** 5\
**Last updated:** [May 20, 2024, 6:24am UTC](https://community.cratedb.com/t/failed-to-connect-cratedb-5-5-from-nifi-1-23-2/1662 "2024-05-20T06:24:10Z")

</div>

Hi Team, I failed to create cratedb connection in nifi as the configuration connecting postgres, and I also checked the document connecting-to-cratedb-from-apache-nifi, but I don’t find useful information for the issue …

---

## [Do table field limits include sub objects?](https://community.cratedb.com/t/do-table-field-limits-include-sub-objects/1762)

<div class="topic-metadata">

**Author:** [@djbestenergy](https://community.cratedb.com/u/djbestenergy)\
**Replies:** 3\
**Last updated:** [April 30, 2024, 12:36pm UTC](https://community.cratedb.com/t/do-table-field-limits-include-sub-objects/1762 "2024-04-30T12:36:04Z")

</div>

Hello All, Does the field limit of 1000 include fields within objects and sub-objects ? I’m investigating the possibility of a dynamic object field, that contains N sub object fields with fields within that (there ar…

---

## [Allocating shards fails when setting routing.allocation.require.\_name](https://community.cratedb.com/t/allocating-shards-fails-when-setting-routing-allocation-require-name/1760)

<div class="topic-metadata">

**Author:** [@jphjsoares](https://community.cratedb.com/u/jphjsoares)\
**Replies:** 3\
**Last updated:** [April 19, 2024, 7:41am UTC](https://community.cratedb.com/t/allocating-shards-fails-when-setting-routing-allocation-require-name/1760 "2024-04-19T07:41:50Z")

</div>

While building a script to shrink the number of shards of all partitions of a table, on a multi-node cluster, when changing the allocation of shards to a specific node by running: ALTER TABLE \<table\_name\> PARTITION (eda…

---

## [HA was not achieved](https://community.cratedb.com/t/ha-was-not-achieved/1749)

<div class="topic-metadata">

**Author:** [@Vinayak\_Katkar](https://community.cratedb.com/u/Vinayak_Katkar)\
**Replies:** 8\
**Last updated:** [April 4, 2024, 9:01am UTC](https://community.cratedb.com/t/ha-was-not-achieved/1749 "2024-04-04T09:01:40Z")

</div>

Hi Team, We have 4 node clusters, and the table has 0-1 replica. But when one node goes down, we get below error and HA was not achieved; The value of the cluster setting ‘gateway.expected\_data\_nodes’ (or the deprecat…

---

## [Alter table and add new column if already exists](https://community.cratedb.com/t/alter-table-and-add-new-column-if-already-exists/1748)

<div class="topic-metadata">

**Author:** [@Alin\_Mihut](https://community.cratedb.com/u/Alin_Mihut)\
**Replies:** 1\
**Last updated:** [April 3, 2024, 8:04am UTC](https://community.cratedb.com/t/alter-table-and-add-new-column-if-already-exists/1748 "2024-04-03T08:04:29Z")

</div>

Hello, It seems that the IF NOT EXISTS condition is not supported in the ALTER TABLE statement Is there an alternative to execute such statement as below? ALTER TABLE table\_name ADD COLUMN IF NOT EXISTS month AS date\_…

---

## [Restart entire cluster](https://community.cratedb.com/t/restart-entire-cluster/1746)

<div class="topic-metadata">

**Author:** [@role](https://community.cratedb.com/u/role)\
**Replies:** 1\
**Last updated:** [April 2, 2024, 3:47pm UTC](https://community.cratedb.com/t/restart-entire-cluster/1746 "2024-04-02T15:47:57Z")

</div>

hi I didn’t know English so I used a translator, but thank you for your reference. ㅠㅠ It is currently being used with 4 master nodes and 20 data nodes. When usage on an unspecified data node is over 90% It can be see…

---

## [Exploring issues for Software Engineering course assignment](https://community.cratedb.com/t/exploring-issues-for-software-engineering-course-assignment/1742)

<div class="topic-metadata">

**Author:** [@mariakont](https://community.cratedb.com/u/mariakont)\
**Replies:** 1\
**Last updated:** [March 31, 2024, 8:33am UTC](https://community.cratedb.com/t/exploring-issues-for-software-engineering-course-assignment/1742 "2024-03-31T08:33:01Z")

</div>

Hello everyone! I am Maria, a third year undergraduate student at AUEB. As part of a Software Engineering course assignment, my colleague Katerina and I have to contribute to a GitHub Open Sourse Project via a pull-req…

---

## [HTTP connection - caching, or flush data? Inconsistencies](https://community.cratedb.com/t/http-connection-caching-or-flush-data-inconsistencies/1743)

<div class="topic-metadata">

**Author:** [@HughMacd](https://community.cratedb.com/u/HughMacd)\
**Replies:** 1\
**Last updated:** [March 30, 2024, 8:18pm UTC](https://community.cratedb.com/t/http-connection-caching-or-flush-data-inconsistencies/1743 "2024-03-30T20:18:04Z")

</div>

Hi, I have a table with a timestamp as the primary key. I’ve discovered that if I do an INSERT immediately followed immediately by a SELECT, the newly inserted one isn’t listed. I’m doing all of this using the python c…

---

## [Unable to connect to CrateDB from another host](https://community.cratedb.com/t/unable-to-connect-to-cratedb-from-another-host/1735)

<div class="topic-metadata">

**Author:** [@HughMacd](https://community.cratedb.com/u/HughMacd)\
**Replies:** 7\
**Last updated:** [March 26, 2024, 1:28pm UTC](https://community.cratedb.com/t/unable-to-connect-to-cratedb-from-another-host/1735 "2024-03-26T13:28:37Z")

</div>

Hi, I’m using Crate in a pretty simple setup - a single host, on a Raspberry Pi, nothing more. I can successfully connect to it from localhost using http. I’m trying to figure out the configuration to allow me to conne…

---

## [Min/max a value with a fixed number using SQL](https://community.cratedb.com/t/min-max-a-value-with-a-fixed-number-using-sql/1733)

<div class="topic-metadata">

**Author:** [@HughMacd](https://community.cratedb.com/u/HughMacd)\
**Replies:** 3\
**Last updated:** [March 15, 2024, 3:59pm UTC](https://community.cratedb.com/t/min-max-a-value-with-a-fixed-number-using-sql/1733 "2024-03-15T15:59:57Z")

</div>

Hi, I’m trying to figure out how to get the minimul of 2 values (or max, or clamp between two values) when doing an SQL query in CrateDB. I’d like to be able to do a query that is something like this: SELECT time, …

---

## [How to load data from a sensor into CrateDB?](https://community.cratedb.com/t/how-to-load-data-from-a-sensor-into-cratedb/87)

<div class="topic-metadata">

**Author:** [@yash](https://community.cratedb.com/u/yash)\
**Replies:** 4\
**Last updated:** [March 7, 2024, 3:06pm UTC](https://community.cratedb.com/t/how-to-load-data-from-a-sensor-into-cratedb/87 "2024-03-07T15:06:59Z")

</div>

We have a sensor that publishes data to a TCP socket. How could we create an ingest rule in CrateDB to read from that specific socket? Do we need to use MQTT to read data from the Socket and then publish it as topics s…

---

## [Looking for advice on how to implement time-weighted averaging](https://community.cratedb.com/t/looking-for-advice-on-how-to-implement-time-weighted-averaging/1725)

<div class="topic-metadata">

**Author:** [@HiFiJ](https://community.cratedb.com/u/HiFiJ)\
**Replies:** 2\
**Last updated:** [March 2, 2024, 1:03pm UTC](https://community.cratedb.com/t/looking-for-advice-on-how-to-implement-time-weighted-averaging/1725 "2024-03-02T13:03:49Z")

</div>

Hi everyone, sorry for another greenhorn question. I am collecting data from energy meters which are oftentimes missing the total used or produced energy (in kWh), so I have to do the aggregation / averaging myself. H…

---

## [Does CrateDB support modify type of column?](https://community.cratedb.com/t/does-cratedb-support-modify-type-of-column/1727)

<div class="topic-metadata">

**Author:** [@Jun\_Zhou](https://community.cratedb.com/u/Jun_Zhou)\
**Replies:** 1\
**Last updated:** [February 28, 2024, 8:28am UTC](https://community.cratedb.com/t/does-cratedb-support-modify-type-of-column/1727 "2024-02-28T08:28:54Z")

</div>

We want to modify some columns of text type to integer, while couldn’t find related command.

---

## [LTTB downsampling to work around Grafana SQL limits](https://community.cratedb.com/t/lttb-downsampling-to-work-around-grafana-sql-limits/1596)

<div class="topic-metadata">

**Author:** [@CArsten](https://community.cratedb.com/u/CArsten)\
**Replies:** 10\
**Last updated:** [February 27, 2024, 11:06am UTC](https://community.cratedb.com/t/lttb-downsampling-to-work-around-grafana-sql-limits/1596 "2024-02-27T11:06:42Z")

</div>

Hi, still trying to get me feet wet with CrateDB as a Prometheus long term storage back-end. As I was running into timeout problems when querying via Prometheus I switched to “Grafana SQL” to interact directly with Crat…

---

## [It takes longer to count tables where data is being inserted](https://community.cratedb.com/t/it-takes-longer-to-count-tables-where-data-is-being-inserted/1720)

<div class="topic-metadata">

**Author:** [@Jun\_Zhou](https://community.cratedb.com/u/Jun_Zhou)\
**Replies:** 3\
**Last updated:** [February 23, 2024, 3:28am UTC](https://community.cratedb.com/t/it-takes-longer-to-count-tables-where-data-is-being-inserted/1720 "2024-02-23T03:28:12Z")

</div>

I’m using kafka connect sink data to table in cratedb, while it takes longer to count it. Is this normal ？ cr\> select count(\*) from ebs.rwmv\_xxmtl\_transactions; +----------+ | count(\*) | +----------+ | 3259573 | +----…

---

## [RESTORE SNAPSHOT into new table name](https://community.cratedb.com/t/restore-snapshot-into-new-table-name/167)

<div class="topic-metadata">

**Author:** [@web64](https://community.cratedb.com/u/web64)\
**Replies:** 4\
**Last updated:** [February 19, 2024, 9:36am UTC](https://community.cratedb.com/t/restore-snapshot-into-new-table-name/167 "2024-02-19T09:36:04Z")

</div>

I’m moving a table from an old cluster to a new one. In the new cluster, I have already created a new version of the table with updated fields indexes etc. I would like to restore a backed up version of the table into …

---

## [COPY TO fails ~ possibly file size limit reached?](https://community.cratedb.com/t/copy-to-fails-possibly-file-size-limit-reached/1599)

<div class="topic-metadata">

**Author:** [@sblechmann](https://community.cratedb.com/u/sblechmann)\
**Replies:** 4\
**Last updated:** [February 6, 2024, 4:53pm UTC](https://community.cratedb.com/t/copy-to-fails-possibly-file-size-limit-reached/1599 "2024-02-06T16:53:01Z")

</div>

Hey there, I could not find an issue with the similar fault behaviour. So I am using a crate cluster with 2 data nodes and 1 arbiter node, all running in docker containers. I want to copy data from some tables using th…

---

## [CrateDB hourly diagnostics report](https://community.cratedb.com/t/cratedb-hourly-diagnostics-report/1714)

<div class="topic-metadata">

**Author:** [@Vinayak\_Katkar](https://community.cratedb.com/u/Vinayak_Katkar)\
**Replies:** 1\
**Last updated:** [February 2, 2024, 10:20am UTC](https://community.cratedb.com/t/cratedb-hourly-diagnostics-report/1714 "2024-02-02T10:20:57Z")

</div>

Hi Team, Hope everyone is doing great. I want to know that what’s happened in last hour in CrateDB. OR I want some help regrading hourly performance report. Like Oracle Database have AWR report which give information…

---

## [CrateDB partitioned table vs. TimescaleDB Hypertable](https://community.cratedb.com/t/cratedb-partitioned-table-vs-timescaledb-hypertable/1713)

<div class="topic-metadata">

**Author:** [@Tass](https://community.cratedb.com/u/Tass)\
**Replies:** 4\
**Last updated:** [February 1, 2024, 5:59pm UTC](https://community.cratedb.com/t/cratedb-partitioned-table-vs-timescaledb-hypertable/1713 "2024-02-01T17:59:31Z")

</div>

Hello everyone, I’m starting to discover Crate DB and considering using it in a project where I initially planned to use timescaleDB. This is a very timeserie intensive project, so I went with TimescaleDB which I’m fam…

---

## [Mmap error followed by node crash in crate cluster](https://community.cratedb.com/t/mmap-error-followed-by-node-crash-in-crate-cluster/1176)

<div class="topic-metadata">

**Author:** [@vinayak.shukre](https://community.cratedb.com/u/vinayak.shukre)\
**Replies:** 8\
**Last updated:** [January 25, 2024, 8:32am UTC](https://community.cratedb.com/t/mmap-error-followed-by-node-crash-in-crate-cluster/1176 "2024-01-25T08:32:26Z")

</div>

Hi all, I am seeing below errors randomly and crate service crashes with these. Any help would be appreciated. Caused by: java.io.IOException: Map failed: MMapIndexInput(path=“/data/crate/nodes/0/indices/96h08KOgQ26VJ…

---

## [Ubuntu installation: network.host failure](https://community.cratedb.com/t/ubuntu-installation-network-host-failure/1703)

<div class="topic-metadata">

**Author:** [@fhasanabadi](https://community.cratedb.com/u/fhasanabadi)\
**Replies:** 1\
**Last updated:** [January 24, 2024, 4:54pm UTC](https://community.cratedb.com/t/ubuntu-installation-network-host-failure/1703 "2024-01-24T16:54:41Z")

</div>

Hi, I’m heading to run CrateDB on a Ubuntu machine, aiming at make it accessible via a virtual network. When I add the network interface name in the crate.yaml file, crate fails with the following logs: How should I a…

---

## [Snapshot repository certificate error with Oracle Cloud S3](https://community.cratedb.com/t/snapshot-repository-certificate-error-with-oracle-cloud-s3/1461)

<div class="topic-metadata">

**Author:** [@iames](https://community.cratedb.com/u/iames)\
**Replies:** 13\
**Last updated:** [January 23, 2024, 5:17pm UTC](https://community.cratedb.com/t/snapshot-repository-certificate-error-with-oracle-cloud-s3/1461 "2024-01-23T17:17:27Z")

</div>

Hi all, I am currently trying to use OCI Object storage for repository in Crate 5.2.3 and I am facing a certificane common name error. When adding the repository with CREATE REPOSITORY sentence I get the following erro…

---

## [To\_char(): Not able to get timezone offset displayed](https://community.cratedb.com/t/to-char-not-able-to-get-timezone-offset-displayed/1698)

<div class="topic-metadata">

**Author:** [@homer](https://community.cratedb.com/u/homer)\
**Replies:** 7\
**Last updated:** [January 22, 2024, 2:35pm UTC](https://community.cratedb.com/t/to-char-not-able-to-get-timezone-offset-displayed/1698 "2024-01-22T14:35:46Z")

</div>

According to the docs for to\_char, a timestamp can be formatted using the following specifiers (among others): TZ and OF. However, I’m not able to get any of them printed: cr\> select to\_char('2023-01-01T00:00:00+01:00':…

[Previous page](https://community.cratedb.com/c/cratedb/18.md?page=3)

[Next page](https://community.cratedb.com/c/cratedb/18.md?page=5)
