Skip to main content
Filter by
Sorted by
Tagged with
0 votes
1 answer
16 views

What does rows processed mean in the cockroachDB UI/console?

Here is a screenshot of the DB console for a cockroachDB cluster, what does 7.5 writes mean in this case? This application is a Spring Boot application and is doing batched writes. Is 7.5 the size of ...
alyshan's user avatar
  • 176
-1 votes
1 answer
28 views

Implement of triggers postgresql to cockroachdb

I'm trying to migrate a database written in PostgreSQL to cockroachDB I want to know if there's a way to implement the trigger in SQL in cockroachDB. I know cocroachDB not supported triggers but I ...
Erkan RUA's user avatar
1 vote
4 answers
100 views

How does client handle failures in RAFT-replicated datastores?

Consider a database like cockroachDB that uses RAFT protocol for replicating data to a replica group owning a partition of the data. How does a client handle a request that fails in such DBs? Because, ...
Dumb_Pegasus's user avatar
0 votes
1 answer
55 views

Cockroachdb pg_connect() [duplicate]

Fatal error: Uncaught Error: Call to undefined function pg_connect() I'm using php8 and apache2.4 server, cockroachdb as cloud database. now I have uncommented these already: extension=pdo_pgsql, ...
NOOB14's user avatar
  • 13
0 votes
0 answers
73 views

Getting issue in Cockroach DB cluster

We have setup three node Cockroach-DB cluster(version: 22.2.14) on GKE kubernetes cluster on GCP using Helm. Helm chart version is 6.0.3. Suddenly, we’re getting below error on Cockroach-DB pod’s. ...
Sagar Bud's user avatar
1 vote
1 answer
81 views

Cockroachdb transactions running in readonly mode with typeorm mifgrations

This is my dataSource.ts file import { DataSource } from 'typeorm'; import { Step } from './src/recipe/entity/step.entity'; import { Chemical } from './src/recipe/entity/chemical.entity'; import { ...
pekka 123's user avatar
0 votes
1 answer
52 views

operator classes are only allowed for the last column of an inverted index

Since I migrated my Django application from MariaDb to CockraochDB which is basically Postgres Syntax I get the following error, I really do not understand, I also do not find any referenced on the ...
V O's user avatar
  • 113
0 votes
0 answers
38 views

how to add array data in single field in CockroachDB

Here is the payload and need to insert payload.b data individually payload = { a:test1, b: [1,2,3,4] } expecting out in table db test1 1 test1 2 test1 3 test1 4 i tried using unset query shown below ...
Akhilesh Sooji's user avatar
-1 votes
1 answer
70 views

CockroachDB configuration on NUMA enabled processors

Old CockroachDB documentation v2.1 has a cryptic description of CPUs with NUMA (Non-uniform Memory Access): To add more processing power (up to 16 vCPUs), adding more vCPUs is better than adding more ...
Brad Schoening's user avatar
0 votes
0 answers
29 views

How can I build statements using CockroachDB's `AS OF SYSTEM TIME` clause with knex?

I have been able to work around this with some fromRaw and joinRaw shenanigans, but the joinRaw in particular is rather unfortunate (having to specify the full join in raw just to add the clause at ...
pamphlet's user avatar
  • 2,094
0 votes
0 answers
48 views

Trying to communicate between services through traefik dns

I've been trying to build a concrete portfolio project to learn about industry tools and new concepts in programming and I decided I was going to do it in a micro-services architecture. I'm trying to ...
BAXYCoding's user avatar
0 votes
1 answer
25 views

Is it Possible to Read From a CockroachDb in a Region if it has Lost Connection to the Other Regions?

If I have CockroachDb replicas in three Kubernetes Clusters in different regions and one of the clusters loses connection to the others, will a app in that cluster still be able to read from the ...
Math-dude's user avatar
0 votes
1 answer
150 views

Does column order of multi-column primary keys matter in CockroachDB?

CRDB documentation for secondary indexes clearly states column order matters: Columns with a higher cardinality (higher number of distinct values) should be placed in the index before columns with a ...
pamphlet's user avatar
  • 2,094
0 votes
1 answer
377 views

CockroachDB: The best way to turn a UNIQUE CONSTRAINT into a PRIMARY KEY?

We have tables in CockroachDB which have a PK which always have 2 extra columns prefix, e.g. (u1, u2, id), now not needed anymore. For performance, there's also the real primary key set up as a UNIQUE ...
Ondra Žižka's user avatar
1 vote
1 answer
49 views

Is the ANY keyword in SQL considered an atomic operation?

I'm currently working on a project where I need to use the ANY keyword in a SQL query, and I'm curious about its atomicity. Specifically, I'm using it in the context of updating rows in a cockroachdb ...
gilfoyle's user avatar
0 votes
0 answers
132 views

Cannot recover cockroachdb when a node is dead

I deploy cockroachdb helm chart (https://github.com/cockroachdb/helm-charts/tree/master) in my kubernetes cluster. Here is my value file. tls: enabled: false conf: join: - myapp-...
asinkxcoswt's user avatar
  • 2,512
0 votes
1 answer
51 views

Is there a limit on the table or database creation for CockroachDB Serverless

We know that CockroachDB Serverless provides auto-scaling for tenant, but is there a limit on the number of tables or databases that each tenant is allowed to create? Seems that the doc didn't ...
JaneXing1998's user avatar
0 votes
0 answers
133 views

Using r2dbc-postgresql for CockroachDB result in authentication failure: "Password must not be null"

I'm trying to connect to a CockroachDB cluster using r2dbc-postgresql, (I've tried both org.postgresql as well as io.r2dbc) as well as spring-data-r2dbc from my reactive Kotlin app - which is running ...
Dongjun Lim's user avatar
0 votes
1 answer
53 views

Is it possible to perform evelope encryption in CockroachDB?

With Tink and AEAD I can perform envelope encryption in BigQuery. ref: https://docs.aws.amazon.com/kms/latest/developerguide/concepts.html#enveloping https://fuchsia.googlesource.com/third_party/tink/...
Dan Clift's user avatar
0 votes
1 answer
95 views

How to split table ranges to other nodes in a cluster

I have a write heavy table that will get write errors if all the table data is assigned to one range, so when I create the table, I want to split the table into multiple ranges assigned to different ...
Jim Meyer's user avatar
  • 9,465
0 votes
1 answer
48 views

How to handle CA cert of Cockroach DB when deploying a Streamlit app to production?

I am trying to deploy a streamlit app to production that uses CockroachDB as the backend. To authenticate to CockroachDB, CA certs are needed in addition to the connection string credentials. How ...
Kahhow's user avatar
  • 1
0 votes
1 answer
174 views

Error: P1001: Can't reach database server at `crdb`:`26257`

Framework:Nest js ORM: Prisma Database: Cockroach DB (like postgres) OS: Debian 12 I want to run a container using Docker Compose and am getting this error. Prisma schema loaded from prisma/schema....
sonytruelove's user avatar
0 votes
1 answer
198 views

How does HLC hybrid logical clock solve Linearizability and Serializability in distributed transaction?

My understanding why distributed transaction need synchronized clock is the following true time = 100ms node A local time = 100ms node B local time = 0ms the following transaction will run into ...
olaf's user avatar
  • 337
2 votes
2 answers
120 views

Why is the slice not passed to the pg array?

I'm trying to pass a slice to a query that has a cte, but I get an error Goland code: insertQuery = ` WITH cte AS (SELECT $1 AS id, UNNEST(ARRAY($2)) AS address) ...
vovanchello's user avatar
0 votes
1 answer
195 views

Symfony database connection to CockroachDB

after several attempts I still don't understand what's happening, I'm trying to connect my database to a CockroachDB database, so I have this in my .env: DATABASE_URL=postgresql://user:password@...
Lucifer Mew's user avatar
0 votes
1 answer
109 views

Using cockroachdb / postgresql in an iOS swift app

I'm trying to connect to a cockroachdb instance from within an iOS app being developed on Xcode. I am using the PostgresClientKit. I get an error saying: localizedSeverity: Fatal code: 0C800 message: ...
la44578's user avatar
0 votes
1 answer
79 views

How to change my region on CockroachDB Cloud?

I'm currently in AWS us-west-2 and I'm trying to find a solution to change region to California — possibly Google Cloud — as I'm using CockroackDB Cloud I've been searching for a while. I have a small ...
Laurent's user avatar
  • 2,168
1 vote
0 answers
146 views

How to ignore getaddrinfo ENOTFOUND in NestJS (using TypeORM)

We have a NestJS application which is using TypeORM for the database layer. We are doing a lot of requests to the database, sometimes the DB refuses the connection and even after some retries it ...
Matthew Husák's user avatar
0 votes
1 answer
149 views

2 phase commit in CockroachDb

I don't want to write a long and complicated question. Is it possible to do 2 phase commits in CockroachDb natively similar to how it is done in Postgres? How do we do it in Postgres? PREPARE ...
Arnold Zahrneinder's user avatar
0 votes
1 answer
309 views

How can I update the statistics of a table in cockroachdb

In cockroachdb when I explain my query i see this root@:26257/management_console_production> explain select * from clusters; info --------------------------------...
alyshan's user avatar
  • 176
1 vote
0 answers
79 views

The database session is not closed

When calling the SetPersonStatusByName function, a non-closing session occurs. Question: Did I miss anything to close the session after calling this function? func (m *DBManager) SetPersonStatusByName(...
vovanchello's user avatar
0 votes
1 answer
1k views

How to connect to CockroachDB with docker-compose?

I have a docker-compose file in which I locally deploy the database and the application on go services: node_1: container_name: node_1 image: cockroachdb/cockroach:latest ...
vovanchello's user avatar
0 votes
0 answers
95 views

Networking issue between GCP instances - can't init Cockroach cluster

I deployed CockroachDB on Google Cloud Platform's Compute Engine using Terraform. I mainly followed the tutorial - Deploy CockroachDB on Google Cloud Platform GCE (Insecure). My issue is related to ...
Fala Baguete's user avatar
1 vote
1 answer
242 views

Multi cluster CockroachDB with Cilium Cluster Mesh

I am trying to enable a multi cluster CockroachDB spawning 3 k8s clusters connected with Cilium Cluster Mesh. The idea of having a multi cluster CockroachDB is described on cockroachlabs.com - 1, 2. ...
Krystian Marek's user avatar
0 votes
1 answer
654 views

"A PostgreSQL type with the name 'json' was not found in the database" - Npgsql & cochroach db

Using this code, A PostgreSQL type with the name 'json' was not found in the database Connection string var connString = "Host=REMOVE;Port=26257;Username=daniel;Password=REMOVED;Database=REMOVED&...
Daniel Dorman's user avatar
3 votes
0 answers
1k views

CockroachDB performance is much worse than mongoDB and Aurora?

I am doing some basic load testing against cockroachDB, mongoDB and Aurora. I just have a project which can keep read/write into one of those three DBs. In that project, we can configure groutine ...
xiaoyaoworm's user avatar
  • 1,092
0 votes
2 answers
363 views

CockroachDB equivalent of RowVersion in SQL

I'm trying to migrate my SQL db to CockroachDB. SQL Server has the RowVersion datatype which my database uses, which will automatically be generated every time a record is created, and then ...
Aiyuni's user avatar
  • 810
1 vote
1 answer
575 views

How to periodically delete data in CockroachDB

I am using CockroachDB for my newsletter project, and I want to delete rows every day when the data is unverified and the TTL stamp expired. It means it has to check both the "verified" ...
Chloe's user avatar
  • 13
2 votes
1 answer
221 views

Does CockroachDB support read only mode?

Can you connect to CRDB in a read only mode? So that a connection cannot make any writes?
alyshan's user avatar
  • 176
1 vote
1 answer
73 views

Kubernetes CockroachDB unable to access cluster externally

I installed cockroachdb via operator therefore used a kind: crdbcluster to spin up the cluster. Also using a metallb as loadbalancer. I'm trying to access a cockroachdb externally by exposing an ...
simone.benati's user avatar
0 votes
2 answers
381 views

Kubernetes: Haproxy ingress isn't taking on any addresses

I'm running Kubernetes v1.25.9+rke2r1. I have a Metallb correctly setup with an external ip address and haproxy ingress controller. I need to expose a cockroachdb instance via ingress and I set up ...
simone.benati's user avatar
0 votes
1 answer
1k views

In Jetbrains Rider Datagrip, exporting database with pg_dump throws a search_path error

I have a CockroachDB cluster that i have connected to through JetBrains Rider. I want to make sure I can export all the data (as a backup, for example) using pg_dump. However, when running the export ...
Davrozz's user avatar
  • 47
0 votes
1 answer
79 views

How to create trigram index on json attribute in cockroachdb?

Is there a way to create trigram index on a json attribute in cockroach DB just like normal columns like CREATE INDEX ON t USING GIN (a, w gin_trgm_ops)?
RCX's user avatar
  • 81
0 votes
1 answer
109 views

DISTINCT on Two Individual Columns instead of Group of Two Columns

Table: Campaign_mapping campaign_id emailid_id 1 1 1 2 1 3 2 2 4 4 5 4 6 5 7 7 8 6 Table: Leads id campaign_id emailid_id data_a data_b data_c 2 1 a b c 3 2 2 a1 b2 c3 4 3 a2 b3 c4 5 ...
Abhishek Anand's user avatar
0 votes
1 answer
76 views

How to connect Heroku Discord Bot to CockroachDB?

I currently have a discord bot built with Nextcord.py with a working database on CockroachDB. I managed to host and deploy the bot on Heroku and commands work, but I can't seem to get the database to ...
Natan Niemetz's user avatar
0 votes
2 answers
710 views

Why is method annotated with @PrePersist not called on @Entity class with @IdClass?

Why is method annotated with @PrePersist not called when persisting class annotated with @Entity and @IdClass? Folder (entity) @Data @Entity @NoArgsConstructor @AllArgsConstructor @Builder(toBuilder = ...
joshuatvernon's user avatar
0 votes
1 answer
113 views

How can I run the YCSB workload on CockroachDB?

I want to run the "Yahoo! Cloud Serving Benchmark" on CockroachDB for evaluation. Is there a dedicated testing manual or documentation for using YCSB to test CockroachDB? I tried using the ...
Jayant's user avatar
  • 66
2 votes
1 answer
1k views

JOOQ: Database version is older than what dialect COCKROACHDB supports: 13.0.0

We use CockroachDB 22.2 and JOOQ 3.18.2. In our logs, this message appears: Database version is older than what dialect COCKROACHDB supports: 13.0.0. Consider https://www.jooq.org/download/support-...
Ondra Žižka's user avatar
-2 votes
1 answer
416 views

How can I bulk insert test data into a table in postgresql or cockroachdb?

In procedural SQL, I could write a loop that used an incrementing variable to build data rows and insert them into a table one by one. Is there a way to get the same effect using the regular SQL ...
histocrat's user avatar
  • 2,371
0 votes
1 answer
1k views

Can't get celery results in django-db backend but my settings seem to be correct (Django, Postgres, Redis)

I cannot get celery results to store in my django-db backend- I have tried many solutions without any luck. I'm kind of stuck at this point.. however, I suspect this has something to do with cockroach-...
chrisr's user avatar
  • 1

1
2 3 4 5
10