jjmontesl / cubesviewer Goto Github PK
View Code? Open in Web Editor NEWExplore and visualize analytical datasets
Home Page: http://www.cubesviewer.com
License: Other
Explore and visualize analytical datasets
Home Page: http://www.cubesviewer.com
License: Other
string with hyphen sign can't use dimension filter. it's always return 0 on web browser.
When selecting views where a measure is required, use record_count
as default measure.
The new work on CubesViewer is super impressive. I'm wondering if you would at all be interesting in adding support for Babbage: https://github.com/openspending/babbage
Babbage is a port of the Cubes API, with some small changes, and less complexity as it does not support multiple backends (Babbage only runs on an SQL backend).
Babbage was originally written by @pudo to power fiscal data analysis, and since, it is being used in various cases by SpenDB in various locations throughout Germany, Municipal Data in South Africa, and it also forms the core analytical API of OpenSpending, a generic platform for fiscal data. We have a several regular contributors ( @pudo @akariv @longhotsummer @jbothma ) and some more occasional contributors.
We'd be delighted if this would be of interest.
I see the customization part of the documents are not done yet but...
Can we get json output for custom views with js lib of choice
Can We save Analysis View as HTML widget for static blogs?
Hi!
I had to change the model and restart the cube, what should I do to "restart" the CubesViewer to run with the new model? Run the syncdb again?
Thanks in advance :)
I have a year-month-day dimension (cubes-examples/procurement). I add cv-date-field
to every level. I get error:
Wrong configuration of model: datefilter field 'day' is invalid.
When I remove the cv-date-field from the day level I get:
Wrong configuration of model: datefilter field 'null' is invalid.
HTTP API has changed: http://cubes.databrewery.org/doc/server.html
Hi there, i am having some trouble using the cuts
feature on a serializedView
to force a certain filtering.
i have
var serializedView = {
"cubename":"products_ordersproductsoffers", "name":"Cube View",
"mode":"series",
"drilldown":[
"id", "user", "products", "resources"
],
"cuts":[{"id":"184"}],
"yaxis":"unitary_price_sum"
};
i have tried both "cuts":[{"id":"184"}],
and "cuts":["id:184"],
and no luck
What am i doing wrong??
cheers
This might be an enhancement but here it goes:
Basically when i filter a dimension like in the screenshot if i get like 10 or more search results its not very practical to be clicking each one.
Maybe have an extra button so only select the filtered results all at once?? If you guide me to the proper place in the code maybe i can even write this enhancement on my own
It would be great to see side-by-side or in the same graphic two views that one wants to compare
Error Message:
django.core.exceptions.ImproperlyConfigured: The TEMPLATE_DIRS setting must be a tuple. Please fix your settings.
Can you please advise?
Ideally datefilter functionality should be taken out of the cube view and refactored as a plugin.
Add a plugin, similar to datefilter, that allows to filter dimensions based on a range (e.g. find all rows in a column that have values above a given value).
When in "explore" mode I did:
request to the slicer "cut=dim:..." contained the level label attribute instead of level key which resulted in no return value.
default_aggregate = none|count|first|count+first
Coming from #70, this moves to the top of the to-do list, only after map charts which is already in development. This ticket will take a some weeks to be resolved.
I'm currently reviewing your software and I think is a great piece of work. However, I encountered some issues that I cannot solve by myself.
I was trying to connect to Sql Server (Nortwind instance) and create a cube based.
I struggle a lot because the documentation about the proper access to Sql Server is a little bit messy.
Anyway, finally I connected to Sql Server and validate my model and my test my slicer.ini as correct. However, when I'm running the server and connect directly with the cubes viewer and click the facts button the following error appears.
Error on request:
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\werkzeug-0.9.6-py2.7.egg\werkzeug\serving.py", line 177, in run_wsgi
execute(self.server.app)
File "C:\Python27\lib\site-packages\werkzeug-0.9.6-py2.7.egg\werkzeug\serving.py", line 165, in execute
application_iter = app(environ, start_response)
File "C:\Python27\lib\site-packages\cubes-0.10.2-py2.7.egg\cubes\server\slicer.py", line 168, in call
return self.wsgi_app(environ, start_response)
File "C:\Python27\lib\site-packages\cubes-0.10.2-py2.7.egg\cubes\server\slicer.py", line 160, in wsgi_app
response = self.dispatch(ctrl_class, action, request, params)
File "C:\Python27\lib\site-packages\cubes-0.10.2-py2.7.egg\cubes\server\slicer.py", line 179, in dispatch
response = action(**params)
File "C:\Python27\lib\site-packages\cubes-0.10.2-py2.7.egg\cubes\server\controllers.py", line 381, in facts
page_size = self.page_size)
File "C:\Python27\lib\site-packages\cubes-0.10.2-py2.7.egg\cubes\backends\sql\star.py", line 150, in facts
statement = self.context.denormalized_statement()
File "C:\Python27\lib\site-packages\cubes-0.10.2-py2.7.egg\cubes\backends\sql\star.py", line 652, in denormalized_statement
key_column = self.fact_table.c[self.fact_key].label(self.fact_key)
File "C:\Python27\lib\site-packages\sqlalchemy\util_collections.py", line 157, in getitem
return self._data[key]
KeyError: 'id'
Could you please help me solve this issue?
My server configuration is:
CubesServer: cubes-0.10-maintenance egg cubes-0.10.2-py2.7.egg
jinja: Jinja2-2.7.3-py2.7.egg
sqlalchmey: SQLAlchemy-0.9.7-py2.7.egg-info
werkzeug: Werkzeug-0.9.6-py2.7.egg
I have attached the configuration files I used for this example.
By the way, I tried other cubes server in different versions.
https://github.com/Stiivi/cubes/releases
outer_joins_stable
v1.0alpha3
v0.11.2
latest version development master on
https://github.com/Stiivi/cubes
Unfortunately, any of them runs properly in windows 2008 R2.
Apparently, the slicer is presenting issues. Previosuly, I only change the slicer to slicer.py and fix the issue. But in this new version, you also include an sclicer.exe that calls a slicer-scripts.py. And those never run properly.
Thank you for your hard work and I hope you could help to solve this issue.
Regards
Juan
I have attached some images. However, I dont know how to add the files here.
So i have about 200 records in my db and i am trying to display charts for them but it looks like the frontend doesnt allow me to go down below were the graphs actually are:
Am i doing something wrong or is this a bug?
PS: WIth less records, i have to click down but i can eventually see the charts. but with a lot of them i am not able to..
Using latest Chrome
The "savedId" attribute is being stored in the view.params dictionary. This causes the attribute to be serialized and considered as an actual "change" to a view.
This should be a view attribute, managed by the "store" plugin, and not stored with view params.
First of all - thank you for this wonderful piece of software!
I have gotten it up and running - everything works great.
I was wondering if there is an easy way to allowing a logged on user access only a part of the cube. Is this customization done on the cubes side, or the django side?
Any help/advice would be appreciated.
Hi,
The current analytical workspace code seems to have some import error.
I tried this ..
from cubes import Workspace
workspace = Workspace(config="slicer.ini")
workspace.import_model("model.json")
workspace.list_cubes()
And I get this error:
/home/anand/.virtualenvs/cubes/local/lib/python2.7/site-packages/cubes/workspace.pyc in list_cubes(self, identity) 535 """ 536 --> 537 all_cubes = self.namespace.list_cubes(recursive=True) 538 539 if self.authorizer:/home/anand/.virtualenvs/cubes/local/lib/python2.7/site-packages/cubes/namespace.pyc in list_cubes(self, recursive)
112 name = cube["name"]
113 if name in cube_names:
--> 114 raise ModelError("Duplicate cube '%s'" % name)
115 cube_names.add(name)
116NameError: global name 'ModelError' is not defined
Can you please share the model.json file you have used for demo apps?
There are very few examples out there for sql store and yours would be a great reference.
Thanks a bunch.
Edit: spelling.
The "Measure dimension" label in menu should read "Measure"
cubesviewer-server takes almost a minute to save and get the views.
Optimization needed.
The "loading" icon is required as an option and included as an image. As this is part of the presentation, it should be defined in the CSS, avoiding the need for the configuration option too.
I use the following date dimension:
{
'label': 'date de soumission',
'name': 'receipt_time',
'role': 'time',
'levels': [
{
'name': 'year',
'label': 'année',
'role': 'year',
'order_attribute': 'year',
'order': 'asc',
},
{
'name': 'quarter',
'order_attribute': 'quarter',
'label': 'trimestre',
'role': 'quarter',
},
{
'name': 'month',
'label': 'mois',
'role': 'month',
'attributes': ['month', 'month_name'],
'order_attribute': 'month',
'label_attribute': 'month_name',
'order': 'asc',
},
{
'name': 'week',
'label': 'semaine',
'role': 'week',
},
{
'name': 'day',
'label': 'jour',
'role': 'day',
'order': 'asc',
},
{
'name': 'dow',
'label': 'jour de la semaine',
'attributes': ['dow', 'dow_name'],
'order_attribute': 'dow',
'label_attribute': 'dow_name',
'order': 'asc',
},
],
'hierarchies': [
{
'name': 'default',
'label': 'par défaut',
'levels': ['year', 'month', 'day']
},
{
'name': 'quarterly',
'label': 'par trimestre',
'levels': ['year', 'quarter']
},
{
'name': 'weekly',
'label': 'par semaine',
'levels': ['year', 'week']
},
{
'name': 'dowly',
'label': 'par jour de la semaine',
'levels': ['dow']
},
]
},
associated to the following mapping
'mappings': {
'receipt_time.year': {
'table': 'dates',
'column': 'date',
'schema': 'public',
'extract': 'year',
},
'receipt_time.month': {
'table': 'dates',
'column': 'date',
'schema': 'public',
'extract': 'month'
},
'receipt_time.month_name': {
'table': 'dates',
'schema': 'public',
'column': 'month'
},
'receipt_time.week': {
'table': 'dates',
'column': 'date',
'schema': 'public',
'extract': 'week'
},
'receipt_time.day': {
'table': 'dates',
'column': 'date',
'schema': 'public',
'extract': 'day'
},
'receipt_time.dow': {
'table': 'dates',
'column': 'date',
'schema': 'public',
'extract': 'dow'
},
'receipt_time.dow_name': {
'table': 'dates',
'schema': 'public',
'column': 'day',
},
'receipt_time.quarter': {
'table': 'dates',
'column': 'date',
'schema': 'public',
'extract': 'quarter'
},
When drilling on the default hierarchy of the receipt_time dimension to the month level, year are correctly ordered but not months, is it a known bug ?
The dimensions could be of a geo type (point, line, polygon...).
It would be great to be able to filter by range (geographic dimentions).
migrations, etc
Hi, Sir,
I tried your cubesviewer to OLAP our Mac Store data. This is quite friendly and powerful. Here I met one problem.
a) I define the date dim like below
{
"name": "DATE",
"comment": "This is used as a template for other date dimensions.",
"label": "Update Date",
"role": "time",
"levels": [
{
"name": "year",
"label": "Year"
},
{
"name": "quarter",
"label": "Quarter"
},
{
"name": "month",
"label": "Month"
},
{
"name": "week",
"label": "Week"
},
{
"name": "day",
"label": "Day"
}
],
"hierarchies": [
{
"name": "weekly",
"label": "Weekly",
"levels": ["year", "week"]
} ,
{
"name": "monthly",
"label":"Monthly",
"levels":["year", "quarter", "month"]
} ,
{
"name": "daily",
"label":"Daily",
"levels":["year", "month", "day" ]
}
]
},
When I choose daily->day to shown the daily result and show the picture report, the data will be sorted. I know I can export data to generate report by self. Just wonder if there is one way to avoid this.
2015/3/1
2015/3/11
2015/3/12
2015/3/13
....
2015/3/19
2015/3/2
2015/3/21
....
cubesviewer-server 2.0.1
cubes 1.1
django 1.9
backend database: postgresql 9.5
I have seen the bug from two separate machines. When using "Export table" functions, dimension drilldowns which are used show only as "[object Object" in the CSV export:
(opened in Excel for the screenshot, but same display when using Notepad++).
This happens for all dimension I habe in my model. Measure fields are not affected. I have tested this with different data types in the database and see the same behaviour whether the field is varchar, text or int.
The "Export facts" function does not produce this output.
Hello,
I'm curious about your viewer but the demo isn't working. Is there a chance that it could be fired up again?
Best wishes, Max
proxy.py lines 30:
import requests
"no module name requests"
We are working toward embedding the cubesviewer in our web based php application. We've just run into a few minor issues with functionality and am wondering if someone can help on the Javascript side. Works fine outside of our environment.
Hi,
I'm running cubesviewer master with minor modification (see #47). Cubesviewer seems to work fine, the model data is delivered to the webpage, but I can not get measures to have selected.
As a result when I would like to open a chart or series table view I get the following image.
How can I select measures?
Suggestion: In cubes 1.0 there is a new dimension and level metadata called "role". Date/time dimensions have role == "time"
and levels have respective calendar unit names, such as year
, month
, ... It would be nice if the cubes viewer uses this information.
The roles for date/time dimension levels are guaranteed to be provided from the server, even if it is not explicitly specified in the model, if the level names match the calendar unit names.
It would be nice to have somewhere locale switcher if model has attribute locales
. Slicer HTTP query parameter is locale
.
Localization is completely transparent. The attribute references (names) stay the same, so no need to change the report specification.
If the model is cached in the JS application, on locale change it has to be reloaded. The slicer returns model with labels of requested locale.
(low priority request, just nice to have for multi-lingual cubes)
CSS styles are half embedded in the application code. They should all be normalized and moved to the appropriate CSS sheet.
Also, some class names used to tag buttos and other UI components are not normalized. They should all adapt to the new notation "cv-module-component".
Readme links to https://github.com/jjmontesl/cubesviewer/blob/master/cubesviewer/blob/master/doc/guide/index.md for documentation, which 404s.
It should link here instead: https://github.com/jjmontesl/cubesviewer/blob/master/doc/guide/index.md
I have moved all static dependencies of CubesViewer all of them are loaded. I have configured the Cubes Server as follows:
[server]
host: localhost
port: 5000
prettyprint: true
reload: true
allow_cors_origin: *
flask_app.py
CUBESVIEWER_CUBES_URL = "http://localhost:5000"
CUBESVIEWER_BACKEND_URL = "http://localhost:8000/cubesviewer"
I am rendering my template cubesviewer.html
like this:
@app.route("/cubesviewer")
def cubesviewer():
return render_template('cubesviewer.html',
cubesviewer_backend_url=CUBESVIEWER_BACKEND_URL,
cubesviewer_cubes_url= CUBESVIEWER_CUBES_URL)
Flask application is running on http://localhost:8000/. However when I try to access the http://localhost:8000/cubesviewer I always encounter this error:
CubesViewer: An error occurred while accessing the data server. Please try again or contact the application administrator if the problem persists.
Browser says:
XMLHttpRequest cannot load http://localhost:5000/cubes/info. Origin http://localhost:8000 is not allowed by Access-Control-Allow-Origin.
Requirement for django-piston package is missing in the README.
I think that in a chat the y-axis should be labeled using the measure label. I can work on it if I'm given some direction.
I'm using django 1.7
Cubes 1.0 and latest Cubesviewer
Hello, i have a question cube definition is read from config file ?
Temptation got the better of me (lunch had to wait!): Using cubes 1.0alpha3 and cubesviewer 0.10-alpha
slicer.ini looks like:
[workspace]
log_level: info
[server]
host: localhost
port: 5000
reload: yes
prettyprint: yes
allow_cors_origin: http://localhost:8000
[store]
type: sql
url: sqlite:///data.sqlite
[models]
main: model.json
Restarted slicer and restarted cubesviewer django app.
Output from Javascript console on cubesviewer is:
XMLHttpRequest cannot load http://localhost:8000/cubesviewer/cubes/info. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://127.0.0.1:8000' is therefore not allowed access. (index):1
XMLHttpRequest cannot load http://localhost:8000/cubesviewer/view/list/. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://127.0.0.1:8000' is therefore not allowed access. (index):1
Command line terminal output for cubesviewer is:
0 errors found
Django version 1.4, using settings 'cvapp.settings'
Development server is running at http://127.0.0.1:8000/
Quit the server with CONTROL-C.
DEBUG (0.001) SELECT "django_session"."session_key", "django_session"."session_data", "django_session"."expire_date" FROM "django_session" WHERE ("django_session"."session_key" = 1174bc130e44d82708272e9a86dd463e AND "django_session"."expire_date" > 2014-08-06 18:30:30.196512 ); args=('1174bc130e44d82708272e9a86dd463e', u'2014-08-06 18:30:30.196512')
DEBUG (0.000) SELECT "auth_user"."id", "auth_user"."username", "auth_user"."first_name", "auth_user"."last_name", "auth_user"."email", "auth_user"."password", "auth_user"."is_staff", "auth_user"."is_active", "auth_user"."is_superuser", "auth_user"."last_login", "auth_user"."date_joined" FROM "auth_user" WHERE "auth_user"."id" = 1 ; args=(1,)
[06/Aug/2014 18:30:30] "GET /cubesviewer/ HTTP/1.1" 200 6784
[06/Aug/2014 18:30:30] "GET /static/js/dateformat/dateformat.js HTTP/1.1" 200 3884
[06/Aug/2014 18:30:30] "GET /static/css/cvapp.css HTTP/1.1" 200 1689
[06/Aug/2014 18:30:30] "GET /static/css/blueprint/screen.css HTTP/1.1" 200 12342
[06/Aug/2014 18:30:30] "GET /static/css/blueprint/print.css HTTP/1.1" 200 1286
[06/Aug/2014 18:30:30] "GET /static/css/jqueryui-cupertino/jquery-ui-1.9.2.custom.css HTTP/1.1" 200 32414
[06/Aug/2014 18:30:30] "GET /static/js/jquery/jquery-1.8.3.js HTTP/1.1" 200 267739
[06/Aug/2014 18:30:30] "GET /static/css/jqgrid/ui.jqgrid.css HTTP/1.1" 200 12198
[06/Aug/2014 18:30:30] "GET /static/js/wiky/wiky.math.css HTTP/1.1" 200 1472
[06/Aug/2014 18:30:30] "GET /static/js/nvd3/nv.d3.min.css HTTP/1.1" 200 8695
[06/Aug/2014 18:30:30] "GET /static/js/jquery/jquery.cookie.js HTTP/1.1" 200 3654
[06/Aug/2014 18:30:30] "GET /static/js/wiky/wiky.js HTTP/1.1" 200 19569
[06/Aug/2014 18:30:30] "GET /static/js/qtip/jquery.qtip.css HTTP/1.1" 200 12200
[06/Aug/2014 18:30:30] "GET /static/css/cubesviewer/cubesviewer.css HTTP/1.1" 200 6253
[06/Aug/2014 18:30:30] "GET /static/js/wiky/wiky.math.js HTTP/1.1" 200 19432
[06/Aug/2014 18:30:30] "GET /static/js/jquery/jquery.blockUI.js HTTP/1.1" 200 18703
[06/Aug/2014 18:30:30] "GET /static/js/cvapp.js HTTP/1.1" 200 33
[06/Aug/2014 18:30:30] "GET /static/js/flotr2/flotr2.min.js HTTP/1.1" 200 96531
[06/Aug/2014 18:30:30] "GET /static/js/jquery/jquery-ui-1.9.2.custom.min.js HTTP/1.1" 200 237802
[06/Aug/2014 18:30:30] "GET /static/js/d3js/d3.v3.js HTTP/1.1" 200 325164
[06/Aug/2014 18:30:30] "GET /static/js/nvd3/nv.d3.js HTTP/1.1" 200 450730
[06/Aug/2014 18:30:30] "GET /static/js/qtip/jquery.qtip.js HTTP/1.1" 200 96039
[06/Aug/2014 18:30:30] "GET /static/js/jqgrid/jquery.jqGrid.min.js HTTP/1.1" 200 259343
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.js HTTP/1.1" 200 5442
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.js HTTP/1.1" 200 7666
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.explore.js HTTP/1.1" 200 23589
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.datefilter.js HTTP/1.1" 200 12624
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.rangefilter.js HTTP/1.1" 200 9418
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.series.js HTTP/1.1" 200 14996
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.chart.js HTTP/1.1" 200 23376
[06/Aug/2014 18:30:30] "GET /static/js/jqgrid/i18n/grid.locale-en.js HTTP/1.1" 200 6531
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.dimensionfilter.js HTTP/1.1" 200 14577
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.columns.js HTTP/1.1" 200 8377
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.export.js HTTP/1.1" 200 4883
[06/Aug/2014 18:30:30] "GET /static/js/cubes/cubes.js HTTP/1.1" 200 26662
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.js HTTP/1.1" 200 8115
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.cache.js HTTP/1.1" 200 3649
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.cube.facts.js HTTP/1.1" 200 8871
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.gui.serializing.js HTTP/1.1" 200 4246
[06/Aug/2014 18:30:30] "GET /static/img/cubesviewer-logo.png HTTP/1.1" 200 11376
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.undo.js HTTP/1.1" 200 5421
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.views.notes.js HTTP/1.1" 200 9410
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.gui.js HTTP/1.1" 200 10450
[06/Aug/2014 18:30:30] "GET /static/js/cubesviewer/cubesviewer.gui.reststore.js HTTP/1.1" 200 12111
[06/Aug/2014 18:30:30] "GET /static/img/cubes-logo.png HTTP/1.1" 200 10032
[06/Aug/2014 18:30:30] "GET /static/css/jqueryui-cupertino/images/ui-bg_highlight-hard_100_f2f5f7_1x100.png HTTP/1.1" 200 103
[06/Aug/2014 18:30:30] "GET /cubesviewer/cubes/info HTTP/1.1" 302 0
[06/Aug/2014 18:30:30] "GET /cubesviewer/view/list/ HTTP/1.1" 302 0
Nothing changes on the slicer terminal output (which I imagine is due to it blocking cubesviewer).
Let me know if you need anything else.
Currently when multiple dimensions/levels are used for drilldown, the table contains only one column with values in form "dim1 / dim2 / dim3 / ...". It would be nicer to have one column per drilled dimension/level which also can be used for sorting in-place.
django-materials provide many built in stuff using which the look and feel of cube views could be greatly enhanced.
version: cubesviewer-server 2.0.1
date model:
"dimensions": [
{
"name": "d_date",
"label": "Date",
"role": "time",
"cv-datefilter": "true",
"levels": [
{
"name": "year",
"label": "Year",
"attributes": [{"name": "year", "label": "Year"}],
"role": "year",
"order_attribute": "year"
},
{
"name": "quarter",
"label": "Quarter",
"attributes": [{"name": "quarter", "label": "Quarter"}],
"role": "quarter",
"order_attribute": "quarter"
},
{ "name": "month",
"label": "Month",
"attributes": [{"name": "month", "label": "Month"}],
"role": "month",
"order_attribute": "month"
},
{
"name": "week",
"label": "Week",
"attributes": [{"name": "week", "label": "Week"}],
"role": "week",
"order_attribute": "week"
},
{
"name": "date",
"label": "Date",
"attributes": [{"name": "date", "label": "Date"}],
"role": "day",
"order_attribute": "date"
}
],
"hierarchies": [
{
"name": "default",
"label": "default",
"levels": ["year", "month", "date"]
},
{
"name": "weekly",
"label": "by week",
"levels": ["year", "week"]
}
]
}
"joins": [
{
"master": "test_cube.dim_date_date_id",
"detail": {
"table": "d_date_test",
"column": "date"
},
"method": "match"
}
"mappings": {
"d_date.year": "d_date_test.year",
"d_date.quarter": "d_date_test.quarter",
"d_date.month": "d_date_test.month",
"d_date.week": "d_date_test.week",
"d_date.date": "d_date_test.day"
}
PostgresSQL Backend -
Database schema (date dimension table):
Table "cubes.d_date_test"
Column | Type | Modifiers
----------+---------+-----------
year | integer |
month | integer |
week | integer |
day | integer |
week_day | integer |
date | date |
quarter | integer |
Excerpt from date dimension table:
year | month | week | day | week_day | date | quarter
------+-------+------+-----+----------+------------+---------
2016 | 1 | 1 | 4 | 1 | 2016-01-04 | 1
2016 | 1 | 1 | 5 | 2 | 2016-01-05 | 1
2016 | 1 | 1 | 6 | 3 | 2016-01-06 | 1
2016 | 1 | 1 | 7 | 4 | 2016-01-07 | 1
2016 | 1 | 1 | 8 | 5 | 2016-01-08 | 1
The "dim_date_date_id" is of type date and contains values such as '2016-01-01'.
With one date hierarchy. date filtering and sorting works entirely as expected (using date hierarchy "default")
When I use two, hierarchies, however, date sorting only works correctly for the hierarchy which is used for filtering first during the session! Example: (now using date hierarchy "by week")
"Ascending" order is used, but weeks are not ordered correctly.
If I drill down to "Week" using the date hierarchy "by week" first, date ordering works correctly for this hierarchy, but not for the other one.
The data could be of a geo type (point, line, polygon...).
It would be great to be able to show it in a map (it could be done using Leafletjs.com)
Application ignores measures that have no "aggregations" specified in the model. This should default to "sum".
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.