activecube 0.1.33 → 0.1.37
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/Gemfile.lock +1 -1
- data/lib/activecube/processor/index.rb +1 -1
- data/lib/activecube/query/cube_query.rb +15 -2
- data/lib/activecube/version.rb +1 -1
- metadata +5 -6
- data/.idea/workspace.xml +0 -145
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 259cc692bdf919f12e969df5bb9527627e5a6d8776d2a0e9e87dfcd6be31eb3a
|
4
|
+
data.tar.gz: 441797734d3dd76ace51754bbeedf2bb12a28faa69047a53c798603c6af203bc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5db00ce826c957c7dcc79e1a642b98519d5691520221c91bbb736ef741895fc97fb9608173482daf4845545ced42a1012030f16d6055323af47be7d4ffab70e7
|
7
|
+
data.tar.gz: 139443eca675eea3125b3e357a6dd707698d45f026f14b801442f52ee4c98628f6b9f4bf74b889209c5e3c6d31c1a1e5753a6052d8d1bf8604b1dec21fd5aaa2
|
data/.gitignore
CHANGED
data/Gemfile.lock
CHANGED
@@ -16,6 +16,8 @@ module Activecube::Query
|
|
16
16
|
include ChainAppender
|
17
17
|
|
18
18
|
attr_reader :cube, :slices, :measures, :selectors, :options, :tables, :sql
|
19
|
+
attr_accessor :stats
|
20
|
+
|
19
21
|
def initialize cube, slices = [], measures = [], selectors = [], options = [], model_tables = nil
|
20
22
|
@cube = cube
|
21
23
|
@slices = slices
|
@@ -91,8 +93,15 @@ module Activecube::Query
|
|
91
93
|
|
92
94
|
|
93
95
|
def query
|
94
|
-
|
95
|
-
@composed.connection
|
96
|
+
composed_query = to_query
|
97
|
+
connection = @composed.connection
|
98
|
+
if connection.respond_to?(:with_statistics)
|
99
|
+
connection.with_statistics(stats) do
|
100
|
+
connection.exec_query(composed_query.to_sql)
|
101
|
+
end
|
102
|
+
else
|
103
|
+
connection.exec_query(composed_query.to_sql)
|
104
|
+
end
|
96
105
|
end
|
97
106
|
|
98
107
|
def to_query
|
@@ -107,6 +116,10 @@ module Activecube::Query
|
|
107
116
|
(measures + slices + selectors).map(&:required_column_names).flatten.uniq
|
108
117
|
end
|
109
118
|
|
119
|
+
def column_names_required measures = self.measures
|
120
|
+
(measures + slices + selectors.select{|s| !s.kind_of?(Selector::CombineSelector)}).map(&:required_column_names).flatten.uniq
|
121
|
+
end
|
122
|
+
|
110
123
|
def selector_column_names measures = self.measures
|
111
124
|
(measures.map(&:selectors) + slices.map(&:selectors) + selectors).flatten.map(&:required_column_names).flatten.uniq
|
112
125
|
end
|
data/lib/activecube/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: activecube
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.37
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Aleksey Studnev
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-02-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -76,7 +76,6 @@ extensions: []
|
|
76
76
|
extra_rdoc_files: []
|
77
77
|
files:
|
78
78
|
- ".gitignore"
|
79
|
-
- ".idea/workspace.xml"
|
80
79
|
- ".rspec"
|
81
80
|
- ".travis.yml"
|
82
81
|
- CODE_OF_CONDUCT.md
|
@@ -126,7 +125,7 @@ homepage: https://github.com/bitquery/activecube
|
|
126
125
|
licenses:
|
127
126
|
- MIT
|
128
127
|
metadata: {}
|
129
|
-
post_install_message:
|
128
|
+
post_install_message:
|
130
129
|
rdoc_options: []
|
131
130
|
require_paths:
|
132
131
|
- lib
|
@@ -142,7 +141,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
142
141
|
version: '0'
|
143
142
|
requirements: []
|
144
143
|
rubygems_version: 3.0.4
|
145
|
-
signing_key:
|
144
|
+
signing_key:
|
146
145
|
specification_version: 4
|
147
146
|
summary: Multi-Dimensional Queries with Rails
|
148
147
|
test_files: []
|
data/.idea/workspace.xml
DELETED
@@ -1,145 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
-
<project version="4">
|
3
|
-
<component name="BranchesTreeState">
|
4
|
-
<expand>
|
5
|
-
<path>
|
6
|
-
<item name="ROOT" type="e8cecc67:BranchNodeDescriptor" />
|
7
|
-
<item name="LOCAL_ROOT" type="e8cecc67:BranchNodeDescriptor" />
|
8
|
-
</path>
|
9
|
-
</expand>
|
10
|
-
<select />
|
11
|
-
</component>
|
12
|
-
<component name="ChangeListManager">
|
13
|
-
<list default="true" id="77368870-4045-496a-9737-2c7f83086a16" name="Default Changelist" comment="initial implementation" />
|
14
|
-
<option name="SHOW_DIALOG" value="false" />
|
15
|
-
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
16
|
-
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
17
|
-
<option name="LAST_RESOLUTION" value="IGNORE" />
|
18
|
-
</component>
|
19
|
-
<component name="Git.Settings">
|
20
|
-
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
21
|
-
</component>
|
22
|
-
<component name="ProjectId" id="1Xu9Qappwp8FcqKJZrxzkXK80UI" />
|
23
|
-
<component name="ProjectLevelVcsManager" settingsEditedManually="true" />
|
24
|
-
<component name="ProjectViewState">
|
25
|
-
<option name="hideEmptyMiddlePackages" value="true" />
|
26
|
-
<option name="showLibraryContents" value="true" />
|
27
|
-
</component>
|
28
|
-
<component name="PropertiesComponent">
|
29
|
-
<property name="WebServerToolWindowFactoryState" value="false" />
|
30
|
-
<property name="last_opened_file_path" value="$PROJECT_DIR$/lib/activecube" />
|
31
|
-
<property name="node.js.detected.package.eslint" value="true" />
|
32
|
-
<property name="node.js.detected.package.tslint" value="true" />
|
33
|
-
<property name="node.js.path.for.package.eslint" value="project" />
|
34
|
-
<property name="node.js.path.for.package.tslint" value="project" />
|
35
|
-
<property name="node.js.selected.package.eslint" value="(autodetect)" />
|
36
|
-
<property name="node.js.selected.package.tslint" value="(autodetect)" />
|
37
|
-
<property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" />
|
38
|
-
<property name="nodejs_npm_path_reset_for_default_project" value="true" />
|
39
|
-
<property name="settings.editor.selected.configurable" value="preferences.lookFeel" />
|
40
|
-
</component>
|
41
|
-
<component name="RecentsManager">
|
42
|
-
<key name="MoveFile.RECENT_KEYS">
|
43
|
-
<recent name="$PROJECT_DIR$/lib/activecube" />
|
44
|
-
</key>
|
45
|
-
<key name="CopyFile.RECENT_KEYS">
|
46
|
-
<recent name="$PROJECT_DIR$/lib/activecube" />
|
47
|
-
</key>
|
48
|
-
</component>
|
49
|
-
<component name="SpringUtil" SPRING_PRE_LOADER_OPTION="true" RAKE_SPRING_PRE_LOADER_OPTION="true" RAILS_SPRING_PRE_LOADER_OPTION="true" />
|
50
|
-
<component name="SvnConfiguration">
|
51
|
-
<configuration />
|
52
|
-
</component>
|
53
|
-
<component name="TaskManager">
|
54
|
-
<task active="true" id="Default" summary="Default task">
|
55
|
-
<changelist id="77368870-4045-496a-9737-2c7f83086a16" name="Default Changelist" comment="" />
|
56
|
-
<created>1581885096407</created>
|
57
|
-
<option name="number" value="Default" />
|
58
|
-
<option name="presentableId" value="Default" />
|
59
|
-
<updated>1581885096407</updated>
|
60
|
-
<workItem from="1581885099890" duration="3547000" />
|
61
|
-
</task>
|
62
|
-
<task id="LOCAL-00001" summary="initial commit">
|
63
|
-
<created>1581885128091</created>
|
64
|
-
<option name="number" value="00001" />
|
65
|
-
<option name="presentableId" value="LOCAL-00001" />
|
66
|
-
<option name="project" value="LOCAL" />
|
67
|
-
<updated>1581885128091</updated>
|
68
|
-
</task>
|
69
|
-
<task id="LOCAL-00002" summary="initial implementation">
|
70
|
-
<created>1581885329956</created>
|
71
|
-
<option name="number" value="00002" />
|
72
|
-
<option name="presentableId" value="LOCAL-00002" />
|
73
|
-
<option name="project" value="LOCAL" />
|
74
|
-
<updated>1581885329956</updated>
|
75
|
-
</task>
|
76
|
-
<task id="LOCAL-00003" summary="initial implementation">
|
77
|
-
<created>1581886068687</created>
|
78
|
-
<option name="number" value="00003" />
|
79
|
-
<option name="presentableId" value="LOCAL-00003" />
|
80
|
-
<option name="project" value="LOCAL" />
|
81
|
-
<updated>1581886068687</updated>
|
82
|
-
</task>
|
83
|
-
<task id="LOCAL-00004" summary="initial implementation">
|
84
|
-
<created>1581888304903</created>
|
85
|
-
<option name="number" value="00004" />
|
86
|
-
<option name="presentableId" value="LOCAL-00004" />
|
87
|
-
<option name="project" value="LOCAL" />
|
88
|
-
<updated>1581888304904</updated>
|
89
|
-
</task>
|
90
|
-
<task id="LOCAL-00005" summary="initial implementation">
|
91
|
-
<created>1581888510999</created>
|
92
|
-
<option name="number" value="00005" />
|
93
|
-
<option name="presentableId" value="LOCAL-00005" />
|
94
|
-
<option name="project" value="LOCAL" />
|
95
|
-
<updated>1581888510999</updated>
|
96
|
-
</task>
|
97
|
-
<option name="localTasksCounter" value="6" />
|
98
|
-
<servers />
|
99
|
-
</component>
|
100
|
-
<component name="TypeScriptGeneratedFilesManager">
|
101
|
-
<option name="version" value="2" />
|
102
|
-
</component>
|
103
|
-
<component name="Vcs.Log.Tabs.Properties">
|
104
|
-
<option name="TAB_STATES">
|
105
|
-
<map>
|
106
|
-
<entry key="MAIN">
|
107
|
-
<value>
|
108
|
-
<State />
|
109
|
-
</value>
|
110
|
-
</entry>
|
111
|
-
</map>
|
112
|
-
</option>
|
113
|
-
</component>
|
114
|
-
<component name="VcsManagerConfiguration">
|
115
|
-
<MESSAGE value="initial commit" />
|
116
|
-
<MESSAGE value="initial implementation" />
|
117
|
-
<option name="LAST_COMMIT_MESSAGE" value="initial implementation" />
|
118
|
-
</component>
|
119
|
-
<component name="WindowStateProjectService">
|
120
|
-
<state width="1207" height="48" key="GridCell.Tab.0.bottom" timestamp="1581888894138">
|
121
|
-
<screen x="0" y="23" width="1440" height="786" />
|
122
|
-
</state>
|
123
|
-
<state width="1207" height="48" key="GridCell.Tab.0.bottom/0.23.1440.786@0.23.1440.786" timestamp="1581888894138" />
|
124
|
-
<state width="1207" height="48" key="GridCell.Tab.0.center" timestamp="1581888894135">
|
125
|
-
<screen x="0" y="23" width="1440" height="786" />
|
126
|
-
</state>
|
127
|
-
<state width="1207" height="48" key="GridCell.Tab.0.center/0.23.1440.786@0.23.1440.786" timestamp="1581888894135" />
|
128
|
-
<state width="1207" height="48" key="GridCell.Tab.0.left" timestamp="1581888894133">
|
129
|
-
<screen x="0" y="23" width="1440" height="786" />
|
130
|
-
</state>
|
131
|
-
<state width="1207" height="48" key="GridCell.Tab.0.left/0.23.1440.786@0.23.1440.786" timestamp="1581888894133" />
|
132
|
-
<state width="1207" height="48" key="GridCell.Tab.0.right" timestamp="1581888894136">
|
133
|
-
<screen x="0" y="23" width="1440" height="786" />
|
134
|
-
</state>
|
135
|
-
<state width="1207" height="48" key="GridCell.Tab.0.right/0.23.1440.786@0.23.1440.786" timestamp="1581888894136" />
|
136
|
-
<state x="537" y="156" key="Vcs.Push.Dialog.v2" timestamp="1581888518182">
|
137
|
-
<screen x="0" y="23" width="1440" height="786" />
|
138
|
-
</state>
|
139
|
-
<state x="537" y="156" key="Vcs.Push.Dialog.v2/0.23.1440.786@0.23.1440.786" timestamp="1581888518182" />
|
140
|
-
<state x="352" y="201" width="819" height="558" key="find.popup" timestamp="1581885294826">
|
141
|
-
<screen x="0" y="23" width="1440" height="786" />
|
142
|
-
</state>
|
143
|
-
<state x="352" y="201" width="819" height="558" key="find.popup/0.23.1440.786@0.23.1440.786" timestamp="1581885294826" />
|
144
|
-
</component>
|
145
|
-
</project>
|