Questions tagged [cube.js]

For questions specific to the open source modular framework for building analytical web applications called "Cube.js". Where possible also include a tag for the framework specific "Cube.js" wrapper that you may be utilizing. E.g. [reactjs], [vue.js], etc.

Links:

132 questions
4
votes
2 answers

How to format dates on frontend

I am using the React (recharts) integration of cube and was wondering how to format dates or "weeks" instead of having the full ISOdate. For example Week 39 instead of 2021-09-27T00:00:00.000 on the charts and views. I tried looking at the docs but…
4
votes
2 answers

How to aggregate data from another cube in cubejs?

I have the following cubes (I'm only showing the data necessary to reproduce the problem): SentMessages: cube(`SentMessages`, { sql: `Select * from messages_sent`, dimensions: { campaignId: { sql: `campaign_id`, …
DannyMoshe
  • 6,023
  • 4
  • 31
  • 53
4
votes
1 answer

How to deal with jsonb objects in postgres databases in cube.js?

I have postgres database with a jsonb column which contains custom attribute keys and values. Is there any approach to get these to show up in the dimensions?
3
votes
1 answer

cube.js playground not plotting data correctly

I am using cube.js to compare the change in data over the time by plotting it as a line graph . Step 1 : After generating cube.js schema successfully , data looks like this: Step 2 : Now, while I am trying to check the line graph, it's showing the…
Asraful
  • 1,241
  • 18
  • 31
3
votes
0 answers

Cubejs : Error: 19488:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:c:\ws\deps\openssl\openssl\ssl\record\ssl3_record.c:332:

I am trying to connect Cubejs to MongoDB through MongoDB BI Connect. My mongosqld command is as follows ./mongosqld --config mongosqld.conf -u useradmin -p xxxx --auth --sslMode requireSSL --sslPEMKeyFile mongo.pem I have created mongo.pem file by…
user3863585
  • 53
  • 1
  • 1
  • 4
3
votes
2 answers

How to use cube.js to connect to specific redis

If I want to connect cube.js to my own built redis, what should I do. I use CUBEJS_REDIS_URL which is claimed by official document. So, for example, if my own redis port is 31.71.195.218. Should I use write…
Ezra Tsai
  • 43
  • 2
3
votes
1 answer

Undefined Security Context in extended cube using AbstractCube.sql(). CubeJS

I have an Extended Cube that the sql attribute is based on the BaseCube/AbstractCube. The Base Cube uses the SECURITY_CONTEXT in its sql attribute. When I query the extended cube I get TypeError: Cannot read property 'tenantId' of undefined The…
3
votes
1 answer

How to pass dynamic values in sql in cube.js schema?

Somewhere I want status=2 or status<3. Instead of writing separate schemas, how to reuse by passing dynamic values to the status field in SQL? cube(`OrderFacts`, { sql: `SELECT * FROM orders WHERE status>3`, // <--- I want to pass dynamic values…
3
votes
1 answer

CubeJs Preaggregation index fail to compile

I want to put an index on my rollup pre-aggregation cube js table : preAggregations: { projectDate: { type: `rollup`, measureReferences: [count, amount], dimensionReferences: [state, Projects.slug], …
William Pollet
  • 191
  • 1
  • 10
3
votes
1 answer

Error Continue wait issue on Cube.js backend

I'm having some trouble connecting to the cube.js backend on AWS serverless and executing the /cubejs-api/v1/load request in the frontend dashboard. I keep getting {"error":"Continue wait"} instead of a result returned. I am following the…
George
  • 301
  • 3
  • 18
3
votes
1 answer

Cube.js time range best practice

I have table with item price for date ranges. what is the best way to model this in cube.js to allow time dimension queries like price over time, or average price for item? Thanks! the table looks like: CREATE pricing test_timestamp ( id INT…
amirw
  • 67
  • 1
  • 5
3
votes
1 answer

Cube Js | How to join two tables created from MongoDB arrays?

I am new to cube.js and I am facing a problem, maybe someone will be able to help me. I did not find anything very helpful on the internet... Here is an example of o document in my collection: { "_id" : ObjectId("5a835e0000f73b69c100f15c"), …
Elise L.
  • 31
  • 3
3
votes
1 answer

How to dynamically generate schema for cube.js?

I have been working on a project to generate configurable dashboards. so i have to generate schema dynamically based on an api request. is there any way to do that? it will be very helpful if there is any working example!
Mohamed Rashiq
  • 322
  • 1
  • 3
  • 12
3
votes
2 answers

How to add OR condition in Cube.js filter query

I'm want to add OR condition in the JSON query of Cube.js. But once I added one more condition in the filter it always adds AND condition in SQL query. Below is the JSON query that I'm trying. { "dimensions": [ "Employee.name", …
Harshal Nathe
  • 95
  • 1
  • 8
3
votes
1 answer

How to remove CubeJS default Group By clause from query

CubeJS default applies the Group By clause when we run any query in it. For example below is my JSON query for employee Cube: { "dimensions": [ "Employee.date", "Employee.state", "Employee.id" ], "timeDimensions": [], "filters":…
Harshal Nathe
  • 95
  • 1
  • 8
1
2 3
8 9