@finos/legend-query-builder 0.2.2 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/components/QueryBuilder.d.ts +0 -1
- package/lib/components/QueryBuilder.d.ts.map +1 -1
- package/lib/components/QueryBuilder.js +42 -9
- package/lib/components/QueryBuilder.js.map +1 -1
- package/lib/components/QueryBuilderComponentTestUtils.d.ts.map +1 -1
- package/lib/components/QueryBuilderComponentTestUtils.js +2 -5
- package/lib/components/QueryBuilderComponentTestUtils.js.map +1 -1
- package/lib/components/QueryBuilderDiffPanel.d.ts +0 -1
- package/lib/components/QueryBuilderDiffPanel.d.ts.map +1 -1
- package/lib/components/QueryBuilderDiffPanel.js +2 -2
- package/lib/components/QueryBuilderDiffPanel.js.map +1 -1
- package/lib/components/QueryBuilderParametersPanel.d.ts +0 -1
- package/lib/components/QueryBuilderParametersPanel.d.ts.map +1 -1
- package/lib/components/QueryBuilderPropertyExpressionEditor.d.ts +0 -1
- package/lib/components/QueryBuilderPropertyExpressionEditor.d.ts.map +1 -1
- package/lib/components/QueryBuilderResultPanel.d.ts +0 -1
- package/lib/components/QueryBuilderResultPanel.d.ts.map +1 -1
- package/lib/components/QueryBuilderResultPanel.js +3 -3
- package/lib/components/QueryBuilderSideBar.d.ts +0 -1
- package/lib/components/QueryBuilderSideBar.d.ts.map +1 -1
- package/lib/components/QueryBuilderSideBar.js +2 -1
- package/lib/components/QueryBuilderSideBar.js.map +1 -1
- package/lib/components/QueryBuilderTextEditor.d.ts +0 -1
- package/lib/components/QueryBuilderTextEditor.d.ts.map +1 -1
- package/lib/components/QueryBuilderUnsupportedQueryEditor.d.ts +0 -1
- package/lib/components/QueryBuilderUnsupportedQueryEditor.d.ts.map +1 -1
- package/lib/components/QueryBuilder_TestID.d.ts +1 -0
- package/lib/components/QueryBuilder_TestID.d.ts.map +1 -1
- package/lib/components/QueryBuilder_TestID.js +1 -0
- package/lib/components/QueryBuilder_TestID.js.map +1 -1
- package/lib/components/explorer/QueryBuilderFunctionsExplorerPanel.d.ts +0 -1
- package/lib/components/explorer/QueryBuilderFunctionsExplorerPanel.d.ts.map +1 -1
- package/lib/components/explorer/QueryBuilderFunctionsExplorerPanel.js +5 -5
- package/lib/components/explorer/QueryBuilderFunctionsExplorerPanel.js.map +1 -1
- package/lib/components/explorer/QueryBuilderMilestoningEditor.d.ts +0 -1
- package/lib/components/explorer/QueryBuilderMilestoningEditor.d.ts.map +1 -1
- package/lib/components/explorer/QueryBuilderMilestoningEditor.js +2 -2
- package/lib/components/explorer/QueryBuilderMilestoningEditor.js.map +1 -1
- package/lib/components/explorer/QueryBuilderPropertySearchPanel.d.ts +0 -1
- package/lib/components/explorer/QueryBuilderPropertySearchPanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderFetchStructurePanel.d.ts +0 -1
- package/lib/components/fetch-structure/QueryBuilderFetchStructurePanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderGraphFetchTreePanel.d.ts +0 -1
- package/lib/components/fetch-structure/QueryBuilderGraphFetchTreePanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderOlapGroupByPanel.d.ts +22 -0
- package/lib/components/fetch-structure/QueryBuilderOlapGroupByPanel.d.ts.map +1 -0
- package/lib/components/fetch-structure/QueryBuilderOlapGroupByPanel.js +363 -0
- package/lib/components/fetch-structure/QueryBuilderOlapGroupByPanel.js.map +1 -0
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.d.ts +0 -1
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.js +21 -53
- package/lib/components/fetch-structure/QueryBuilderPostFilterPanel.js.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderPostTDSPanel.d.ts +22 -0
- package/lib/components/fetch-structure/QueryBuilderPostTDSPanel.d.ts.map +1 -0
- package/lib/components/fetch-structure/QueryBuilderPostTDSPanel.js +32 -0
- package/lib/components/fetch-structure/QueryBuilderPostTDSPanel.js.map +1 -0
- package/lib/components/fetch-structure/QueryBuilderResultModifierPanel.d.ts +0 -1
- package/lib/components/fetch-structure/QueryBuilderResultModifierPanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderResultModifierPanel.js +2 -1
- package/lib/components/fetch-structure/QueryBuilderResultModifierPanel.js.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderTDSComponentHelper.d.ts +27 -0
- package/lib/components/fetch-structure/QueryBuilderTDSComponentHelper.d.ts.map +1 -0
- package/lib/components/fetch-structure/QueryBuilderTDSComponentHelper.js +61 -0
- package/lib/components/fetch-structure/QueryBuilderTDSComponentHelper.js.map +1 -0
- package/lib/components/fetch-structure/QueryBuilderTDSPanel.d.ts +0 -1
- package/lib/components/fetch-structure/QueryBuilderTDSPanel.d.ts.map +1 -1
- package/lib/components/fetch-structure/QueryBuilderTDSPanel.js +4 -13
- package/lib/components/fetch-structure/QueryBuilderTDSPanel.js.map +1 -1
- package/lib/components/filter/QueryBuilderFilterPanel.d.ts +0 -1
- package/lib/components/filter/QueryBuilderFilterPanel.d.ts.map +1 -1
- package/lib/components/shared/LambdaEditor.d.ts +0 -1
- package/lib/components/shared/LambdaEditor.d.ts.map +1 -1
- package/lib/components/shared/LambdaEditor.js +23 -7
- package/lib/components/shared/LambdaEditor.js.map +1 -1
- package/lib/components/shared/LambdaParameterValuesEditor.d.ts +0 -1
- package/lib/components/shared/LambdaParameterValuesEditor.d.ts.map +1 -1
- package/lib/components/workflows/ServiceQueryBuilder.d.ts.map +1 -1
- package/lib/components/workflows/ServiceQueryBuilder.js +5 -1
- package/lib/components/workflows/ServiceQueryBuilder.js.map +1 -1
- package/lib/graphManager/QueryBuilderHashUtils.d.ts +14 -0
- package/lib/graphManager/QueryBuilderHashUtils.d.ts.map +1 -1
- package/lib/graphManager/QueryBuilderHashUtils.js +15 -0
- package/lib/graphManager/QueryBuilderHashUtils.js.map +1 -1
- package/lib/graphManager/QueryBuilderSupportedFunctions.d.ts +7 -1
- package/lib/graphManager/QueryBuilderSupportedFunctions.d.ts.map +1 -1
- package/lib/graphManager/QueryBuilderSupportedFunctions.js +7 -0
- package/lib/graphManager/QueryBuilderSupportedFunctions.js.map +1 -1
- package/lib/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.d.ts.map +1 -1
- package/lib/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.js +4 -1
- package/lib/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.js.map +1 -1
- package/lib/graphManager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.d.ts +1 -0
- package/lib/graphManager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.d.ts.map +1 -1
- package/lib/graphManager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.js +50 -0
- package/lib/graphManager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.js.map +1 -1
- package/lib/index.css +2 -2
- package/lib/index.css.map +1 -1
- package/lib/package.json +6 -6
- package/lib/stores/QueryBuilderStateBuilder.d.ts.map +1 -1
- package/lib/stores/QueryBuilderStateBuilder.js +7 -1
- package/lib/stores/QueryBuilderStateBuilder.js.map +1 -1
- package/lib/stores/QueryBuilderStateTestUtils.d.ts.map +1 -1
- package/lib/stores/QueryBuilderStateTestUtils.js +2 -4
- package/lib/stores/QueryBuilderStateTestUtils.js.map +1 -1
- package/lib/stores/QueryBuilderTypeaheadHelper.js +2 -2
- package/lib/stores/explorer/QueryBuilderExplorerState.js +3 -3
- package/lib/stores/fetch-structure/QueryBuilderFetchStructureImplementationState.d.ts +1 -0
- package/lib/stores/fetch-structure/QueryBuilderFetchStructureImplementationState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/QueryBuilderFetchStructureImplementationState.js +3 -0
- package/lib/stores/fetch-structure/QueryBuilderFetchStructureImplementationState.js.map +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeState.js +2 -1
- package/lib/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeState.js.map +1 -1
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSColumnState_.d.ts +24 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSColumnState_.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSColumnState_.js +20 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSColumnState_.js.map +1 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSHelper.d.ts +23 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSHelper.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSHelper.js +41 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSHelper.js.map +1 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.d.ts +11 -0
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.js +44 -1
- package/lib/stores/fetch-structure/tds/QueryBuilderTDSState.js.map +1 -1
- package/lib/stores/fetch-structure/tds/QueryResultSetModifierState.d.ts +2 -2
- package/lib/stores/fetch-structure/tds/QueryResultSetModifierState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/QueryResultSetModifierState.js +2 -2
- package/lib/stores/fetch-structure/tds/QueryResultSetModifierState.js.map +1 -1
- package/lib/stores/fetch-structure/tds/aggregation/QueryBuilderAggregateOperator.js +1 -1
- package/lib/stores/fetch-structure/tds/aggregation/QueryBuilderAggregationState.d.ts +4 -4
- package/lib/stores/fetch-structure/tds/aggregation/QueryBuilderAggregationState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/aggregation/QueryBuilderAggregationState.js +8 -7
- package/lib/stores/fetch-structure/tds/aggregation/QueryBuilderAggregationState.js.map +1 -1
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByOperatorLoader.d.ts +18 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByOperatorLoader.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByOperatorLoader.js +36 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByOperatorLoader.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByState.d.ts +91 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByState.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByState.js +272 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByState.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByStateBuilder.d.ts +19 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByStateBuilder.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByStateBuilder.js +100 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByStateBuilder.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByValueSpecificationBuilder.d.ts +19 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByValueSpecificationBuilder.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByValueSpecificationBuilder.js +83 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByValueSpecificationBuilder.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_.d.ts +29 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_.js +30 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Average.d.ts +25 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Average.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Average.js +50 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Average.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Count.d.ts +25 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Count.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Count.js +51 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Count.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Max.d.ts +25 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Max.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Max.js +50 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Max.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Min.d.ts +25 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Min.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Min.js +50 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Min.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Sum.d.ts +25 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Sum.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Sum.js +51 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Sum.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_AverageRank_.d.ts +24 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_AverageRank_.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_AverageRank_.js +48 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_AverageRank_.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_DenseRank_.d.ts +24 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_DenseRank_.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_DenseRank_.js +48 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_DenseRank_.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_Rank_.d.ts +24 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_Rank_.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_Rank_.js +48 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_Rank_.js.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_RowNumber_.d.ts +24 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_RowNumber_.d.ts.map +1 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_RowNumber_.js +48 -0
- package/lib/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_RowNumber_.js.map +1 -0
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterOperator.d.ts +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterOperator.js +2 -2
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterState.d.ts +6 -4
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterState.js +14 -3
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterState.js.map +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterStateBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterStateBuilder.js +8 -11
- package/lib/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterStateBuilder.js.map +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorHelper.d.ts +2 -2
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorHelper.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorHelper.js +5 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorHelper.js.map +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorValueSpecificationBuilder.js +4 -4
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_Contain.js +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_EndWith.js +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_Equal.js +3 -3
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThan.js +3 -3
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThanEqual.js +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_In.js +2 -2
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_IsEmpty.d.ts +2 -2
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_IsEmpty.js +3 -3
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_LessThan.js +3 -3
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_LessThanEqual.js +1 -1
- package/lib/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_StartWith.js +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionColumnState.d.ts +4 -6
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionColumnState.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionColumnState.js +6 -5
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionColumnState.js.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.js +1 -0
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.js.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.d.ts.map +1 -1
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.js +6 -3
- package/lib/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.js.map +1 -1
- package/lib/stores/filter/QueryBuilderFilterState.d.ts +2 -0
- package/lib/stores/filter/QueryBuilderFilterState.d.ts.map +1 -1
- package/lib/stores/filter/QueryBuilderFilterState.js +6 -0
- package/lib/stores/filter/QueryBuilderFilterState.js.map +1 -1
- package/package.json +13 -13
- package/src/components/QueryBuilder.tsx +110 -35
- package/src/components/QueryBuilderComponentTestUtils.tsx +9 -11
- package/src/components/QueryBuilderDiffPanel.tsx +2 -2
- package/src/components/QueryBuilderResultPanel.tsx +4 -4
- package/src/components/QueryBuilderSideBar.tsx +4 -1
- package/src/components/QueryBuilder_TestID.ts +1 -0
- package/src/components/explorer/QueryBuilderFunctionsExplorerPanel.tsx +6 -6
- package/src/components/explorer/QueryBuilderMilestoningEditor.tsx +2 -3
- package/src/components/fetch-structure/QueryBuilderOlapGroupByPanel.tsx +1140 -0
- package/src/components/fetch-structure/QueryBuilderPostFilterPanel.tsx +31 -106
- package/src/components/fetch-structure/QueryBuilderPostTDSPanel.tsx +69 -0
- package/src/components/fetch-structure/QueryBuilderResultModifierPanel.tsx +4 -1
- package/src/components/fetch-structure/QueryBuilderTDSComponentHelper.tsx +118 -0
- package/src/components/fetch-structure/QueryBuilderTDSPanel.tsx +4 -23
- package/src/components/shared/LambdaEditor.tsx +25 -22
- package/src/components/workflows/ServiceQueryBuilder.tsx +10 -2
- package/src/graphManager/QueryBuilderHashUtils.ts +16 -0
- package/src/graphManager/QueryBuilderSupportedFunctions.ts +7 -0
- package/src/graphManager/protocol/pure/QueryBuilder_PureProtocolProcessorPlugin.ts +14 -0
- package/src/graphManager/protocol/pure/v1/V1_QueryValueSpecificationBuilderHelper.ts +129 -0
- package/src/stores/QueryBuilderStateBuilder.ts +14 -1
- package/src/stores/QueryBuilderStateTestUtils.ts +9 -13
- package/src/stores/QueryBuilderTypeaheadHelper.ts +2 -2
- package/src/stores/explorer/QueryBuilderExplorerState.ts +3 -3
- package/src/stores/fetch-structure/QueryBuilderFetchStructureImplementationState.ts +4 -0
- package/src/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeState.ts +2 -1
- package/src/stores/fetch-structure/tds/QueryBuilderTDSColumnState_.ts +28 -0
- package/src/stores/fetch-structure/tds/QueryBuilderTDSHelper.ts +79 -0
- package/src/stores/fetch-structure/tds/QueryBuilderTDSState.ts +68 -1
- package/src/stores/fetch-structure/tds/QueryResultSetModifierState.ts +2 -2
- package/src/stores/fetch-structure/tds/aggregation/QueryBuilderAggregateOperator.ts +1 -1
- package/src/stores/fetch-structure/tds/aggregation/QueryBuilderAggregationState.ts +11 -9
- package/src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByOperatorLoader.ts +39 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByState.ts +377 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByStateBuilder.ts +237 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByValueSpecificationBuilder.ts +148 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_.ts +43 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Average.ts +56 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Count.ts +57 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Max.ts +56 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Min.ts +56 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Sum.ts +57 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_AverageRank_.ts +54 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_DenseRank_.ts +54 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_Rank_.ts +54 -0
- package/src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_RowNumber_.ts +54 -0
- package/src/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterOperator.ts +2 -2
- package/src/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterState.ts +22 -10
- package/src/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterStateBuilder.ts +11 -19
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorHelper.ts +8 -7
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorValueSpecificationBuilder.ts +4 -4
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_Contain.ts +1 -1
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_EndWith.ts +1 -1
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_Equal.ts +3 -3
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThan.ts +3 -3
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_GreaterThanEqual.ts +1 -1
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_In.ts +2 -2
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_IsEmpty.ts +3 -3
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_LessThan.ts +3 -3
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_LessThanEqual.ts +1 -1
- package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_StartWith.ts +1 -1
- package/src/stores/fetch-structure/tds/projection/QueryBuilderProjectionColumnState.ts +9 -11
- package/src/stores/fetch-structure/tds/projection/QueryBuilderProjectionStateBuilder.ts +1 -0
- package/src/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.ts +8 -4
- package/src/stores/filter/QueryBuilderFilterState.ts +7 -0
- package/tsconfig.json +19 -0
@@ -0,0 +1,54 @@
|
|
1
|
+
/**
|
2
|
+
* Copyright (c) 2020-present, Goldman Sachs
|
3
|
+
*
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
+
* you may not use this file except in compliance with the License.
|
6
|
+
* You may obtain a copy of the License at
|
7
|
+
*
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
9
|
+
*
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
+
* See the License for the specific language governing permissions and
|
14
|
+
* limitations under the License.
|
15
|
+
*/
|
16
|
+
|
17
|
+
import { PRIMITIVE_TYPE, type Type } from '@finos/legend-graph';
|
18
|
+
import { hashArray } from '@finos/legend-shared';
|
19
|
+
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../../graphManager/QueryBuilderHashUtils.js';
|
20
|
+
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
21
|
+
import { QueryBuilderTDSOlapOperator } from './QueryBuilderTDSOlapOperator_.js';
|
22
|
+
|
23
|
+
export class QueryBuilderTDSOlapRankOperator_RowNumber extends QueryBuilderTDSOlapOperator {
|
24
|
+
getLabel(): string {
|
25
|
+
return 'row number';
|
26
|
+
}
|
27
|
+
|
28
|
+
get pureFunc(): string {
|
29
|
+
return QUERY_BUILDER_SUPPORTED_FUNCTIONS.OLAP_ROW_NUMBER;
|
30
|
+
}
|
31
|
+
|
32
|
+
get hashCode(): string {
|
33
|
+
return hashArray([QUERY_BUILDER_HASH_STRUCTURE.OLAP_OPERATOR_ROW_NUMBER]);
|
34
|
+
}
|
35
|
+
|
36
|
+
isCompatibleWithType(type: Type | undefined): boolean {
|
37
|
+
if (type) {
|
38
|
+
return (
|
39
|
+
[
|
40
|
+
PRIMITIVE_TYPE.STRING,
|
41
|
+
PRIMITIVE_TYPE.BOOLEAN,
|
42
|
+
PRIMITIVE_TYPE.NUMBER,
|
43
|
+
PRIMITIVE_TYPE.INTEGER,
|
44
|
+
PRIMITIVE_TYPE.DECIMAL,
|
45
|
+
PRIMITIVE_TYPE.FLOAT,
|
46
|
+
PRIMITIVE_TYPE.DATE,
|
47
|
+
PRIMITIVE_TYPE.STRICTDATE,
|
48
|
+
PRIMITIVE_TYPE.DATETIME,
|
49
|
+
] as string[]
|
50
|
+
).includes(type.path);
|
51
|
+
}
|
52
|
+
return true;
|
53
|
+
}
|
54
|
+
}
|
@@ -31,7 +31,7 @@ export abstract class QueryBuilderPostFilterOperator implements Hashable {
|
|
31
31
|
|
32
32
|
abstract getLabel(): string;
|
33
33
|
|
34
|
-
|
34
|
+
getTDSColumnGetter(): TDS_COLUMN_GETTER | undefined {
|
35
35
|
return undefined;
|
36
36
|
}
|
37
37
|
|
@@ -48,7 +48,7 @@ export abstract class QueryBuilderPostFilterOperator implements Hashable {
|
|
48
48
|
isCompatibleWithPostFilterColumn(
|
49
49
|
postFilterState: PostFilterConditionState,
|
50
50
|
): boolean {
|
51
|
-
const columnType = postFilterState.columnState.
|
51
|
+
const columnType = postFilterState.columnState.getColumnType();
|
52
52
|
if (columnType) {
|
53
53
|
return this.isCompatibleWithType(columnType);
|
54
54
|
}
|
@@ -38,8 +38,9 @@ import {
|
|
38
38
|
uuid,
|
39
39
|
filterByType,
|
40
40
|
ActionState,
|
41
|
-
type Hashable,
|
42
41
|
hashArray,
|
42
|
+
uniq,
|
43
|
+
type Hashable,
|
43
44
|
} from '@finos/legend-shared';
|
44
45
|
import {
|
45
46
|
action,
|
@@ -50,10 +51,10 @@ import {
|
|
50
51
|
observable,
|
51
52
|
} from 'mobx';
|
52
53
|
import { DEFAULT_POST_FILTER_LAMBDA_VARIABLE_NAME } from '../../../QueryBuilderConfig.js';
|
53
|
-
import
|
54
|
+
import { QueryBuilderAggregateColumnState } from '../aggregation/QueryBuilderAggregationState.js';
|
54
55
|
import type { QueryBuilderPostFilterOperator } from './QueryBuilderPostFilterOperator.js';
|
55
56
|
import {
|
56
|
-
|
57
|
+
QueryBuilderProjectionColumnState,
|
57
58
|
type QueryBuilderProjectionColumnDragSource,
|
58
59
|
QueryBuilderDerivationProjectionColumnState,
|
59
60
|
} from '../projection/QueryBuilderProjectionColumnState.js';
|
@@ -65,6 +66,7 @@ import {
|
|
65
66
|
import { QUERY_BUILDER_GROUP_OPERATION } from '../../../QueryBuilderGroupOperationHelper.js';
|
66
67
|
import type { QueryBuilderTDSState } from '../QueryBuilderTDSState.js';
|
67
68
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../graphManager/QueryBuilderHashUtils.js';
|
69
|
+
import type { QueryBuilderTDSColumnState } from '../QueryBuilderTDSColumnState_.js';
|
68
70
|
|
69
71
|
export enum QUERY_BUILDER_POST_FILTER_DND_TYPE {
|
70
72
|
GROUP_CONDITION = 'GROUP_CONDITION',
|
@@ -303,9 +305,7 @@ export class QueryBuilderPostFilterTreeBlankConditionNodeData
|
|
303
305
|
|
304
306
|
export class PostFilterConditionState implements Hashable {
|
305
307
|
readonly postFilterState: QueryBuilderPostFilterState;
|
306
|
-
columnState:
|
307
|
-
| QueryBuilderProjectionColumnState
|
308
|
-
| QueryBuilderAggregateColumnState;
|
308
|
+
columnState: QueryBuilderTDSColumnState;
|
309
309
|
value?: ValueSpecification | undefined;
|
310
310
|
operator: QueryBuilderPostFilterOperator;
|
311
311
|
typeaheadSearchResults: string[] | undefined;
|
@@ -313,9 +313,7 @@ export class PostFilterConditionState implements Hashable {
|
|
313
313
|
|
314
314
|
constructor(
|
315
315
|
postFilterState: QueryBuilderPostFilterState,
|
316
|
-
colState:
|
317
|
-
| QueryBuilderProjectionColumnState
|
318
|
-
| QueryBuilderAggregateColumnState,
|
316
|
+
colState: QueryBuilderTDSColumnState,
|
319
317
|
value: ValueSpecification | undefined,
|
320
318
|
operator: QueryBuilderPostFilterOperator | undefined,
|
321
319
|
) {
|
@@ -363,12 +361,18 @@ export class PostFilterConditionState implements Hashable {
|
|
363
361
|
try {
|
364
362
|
this.typeaheadSearchState.inProgress();
|
365
363
|
this.typeaheadSearchResults = undefined;
|
364
|
+
const _columnState =
|
365
|
+
this.columnState instanceof QueryBuilderProjectionColumnState ||
|
366
|
+
this.columnState instanceof QueryBuilderAggregateColumnState
|
367
|
+
? this.columnState
|
368
|
+
: undefined;
|
369
|
+
const columnState = guaranteeNonNullable(_columnState);
|
366
370
|
if (performTypeahead(this.value)) {
|
367
371
|
const result =
|
368
372
|
(yield this.postFilterState.tdsState.queryBuilderState.graphManagerState.graphManager.executeMapping(
|
369
373
|
buildProjectionColumnTypeaheadQuery(
|
370
374
|
this.postFilterState.tdsState.queryBuilderState,
|
371
|
-
|
375
|
+
columnState,
|
372
376
|
this.value,
|
373
377
|
),
|
374
378
|
guaranteeNonNullable(
|
@@ -536,6 +540,14 @@ export class QueryBuilderPostFilterState
|
|
536
540
|
: undefined;
|
537
541
|
}
|
538
542
|
|
543
|
+
get referencedTDSColumns(): QueryBuilderTDSColumnState[] {
|
544
|
+
return uniq(
|
545
|
+
Array.from(this.nodes.values())
|
546
|
+
.filter(filterByType(QueryBuilderPostFilterTreeConditionNodeData))
|
547
|
+
.map((n) => n.condition.columnState),
|
548
|
+
);
|
549
|
+
}
|
550
|
+
|
539
551
|
getRootNode(): QueryBuilderPostFilterTreeNodeData | undefined {
|
540
552
|
assertTrue(
|
541
553
|
this.rootIds.length < 2,
|
@@ -32,7 +32,9 @@ import {
|
|
32
32
|
guaranteeType,
|
33
33
|
UnsupportedOperationError,
|
34
34
|
} from '@finos/legend-shared';
|
35
|
-
import
|
35
|
+
import { QueryBuilderDerivationProjectionColumnState } from '../projection/QueryBuilderProjectionColumnState.js';
|
36
|
+
import type { QueryBuilderTDSColumnState } from '../QueryBuilderTDSColumnState_.js';
|
37
|
+
import { getTDSColumnState } from '../QueryBuilderTDSHelper.js';
|
36
38
|
import type { QueryBuilderPostFilterOperator } from './QueryBuilderPostFilterOperator.js';
|
37
39
|
import {
|
38
40
|
type QueryBuilderPostFilterState,
|
@@ -43,20 +45,16 @@ import {
|
|
43
45
|
TDS_COLUMN_GETTER,
|
44
46
|
getTypeFromDerivedProperty,
|
45
47
|
} from './QueryBuilderPostFilterState.js';
|
46
|
-
import {
|
47
|
-
type QueryBuilderProjectionColumnState,
|
48
|
-
QueryBuilderDerivationProjectionColumnState,
|
49
|
-
} from '../projection/QueryBuilderProjectionColumnState.js';
|
50
|
-
import { toGroupOperation } from '../../../QueryBuilderGroupOperationHelper.js';
|
51
|
-
import { QueryBuilderTDSState } from '../QueryBuilderTDSState.js';
|
52
|
-
import type { QueryBuilderState } from '../../../QueryBuilderState.js';
|
53
48
|
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
49
|
+
import type { QueryBuilderState } from '../../../QueryBuilderState.js';
|
50
|
+
import { QueryBuilderTDSState } from '../QueryBuilderTDSState.js';
|
51
|
+
import { toGroupOperation } from '../../../QueryBuilderGroupOperationHelper.js';
|
54
52
|
|
55
53
|
const findProjectionColumnState = (
|
56
54
|
propertyExpression: AbstractPropertyExpression,
|
57
55
|
postFilterState: QueryBuilderPostFilterState,
|
58
|
-
):
|
59
|
-
const
|
56
|
+
): QueryBuilderTDSColumnState => {
|
57
|
+
const projectionState = postFilterState.tdsState;
|
60
58
|
const properyExpressionName = propertyExpression.func.value.name;
|
61
59
|
assertTrue(
|
62
60
|
Object.values(TDS_COLUMN_GETTER).includes(
|
@@ -76,13 +74,7 @@ const findProjectionColumnState = (
|
|
76
74
|
).values[0],
|
77
75
|
'Can`t process TDS column expression: Column should be a string primitive instance value',
|
78
76
|
);
|
79
|
-
const
|
80
|
-
...tdsState.aggregationState.columns,
|
81
|
-
...tdsState.projectionColumns,
|
82
|
-
];
|
83
|
-
const columnState = guaranteeNonNullable(
|
84
|
-
columnStates.find((c) => c.columnName === columnName),
|
85
|
-
);
|
77
|
+
const columnState = getTDSColumnState(projectionState, columnName);
|
86
78
|
if (
|
87
79
|
tdsColumnGetter !== TDS_COLUMN_GETTER.IS_NULL &&
|
88
80
|
tdsColumnGetter !== TDS_COLUMN_GETTER.IS_NOT_NULL
|
@@ -97,7 +89,7 @@ const findProjectionColumnState = (
|
|
97
89
|
}
|
98
90
|
return columnState;
|
99
91
|
}
|
100
|
-
const columnType = guaranteeNonNullable(columnState.
|
92
|
+
const columnType = guaranteeNonNullable(columnState.getColumnType());
|
101
93
|
assertTrue(
|
102
94
|
(getTDSColumnDerivedProperyFromType(columnType) as string) ===
|
103
95
|
tdsColumnGetter,
|
@@ -116,7 +108,7 @@ export const buildPostFilterConditionState = (
|
|
116
108
|
operator: QueryBuilderPostFilterOperator,
|
117
109
|
): PostFilterConditionState | undefined => {
|
118
110
|
let postConditionState: PostFilterConditionState | undefined;
|
119
|
-
const tdsColumnGetter = operator.
|
111
|
+
const tdsColumnGetter = operator.getTDSColumnGetter();
|
120
112
|
if (
|
121
113
|
tdsColumnGetter &&
|
122
114
|
expression instanceof AbstractPropertyExpression &&
|
package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperatorHelper.ts
CHANGED
@@ -20,20 +20,21 @@ import {
|
|
20
20
|
} from '@finos/legend-graph';
|
21
21
|
import { UnsupportedOperationError } from '@finos/legend-shared';
|
22
22
|
import { QueryBuilderAggregateColumnState } from '../../aggregation/QueryBuilderAggregationState.js';
|
23
|
-
import {
|
24
|
-
|
25
|
-
|
26
|
-
} from '../../projection/QueryBuilderProjectionColumnState.js';
|
23
|
+
import { QueryBuilderOlapGroupByColumnState } from '../../olapGroupBy/QueryBuilderOlapGroupByState.js';
|
24
|
+
import { QueryBuilderSimpleProjectionColumnState } from '../../projection/QueryBuilderProjectionColumnState.js';
|
25
|
+
import type { QueryBuilderTDSColumnState } from '../../QueryBuilderTDSColumnState_.js';
|
27
26
|
|
28
27
|
export const getColumnMultiplicity = (
|
29
|
-
columnState:
|
30
|
-
| QueryBuilderProjectionColumnState
|
31
|
-
| QueryBuilderAggregateColumnState,
|
28
|
+
columnState: QueryBuilderTDSColumnState | QueryBuilderAggregateColumnState,
|
32
29
|
): Multiplicity => {
|
33
30
|
if (columnState instanceof QueryBuilderAggregateColumnState) {
|
34
31
|
return columnState.aggregationState.tdsState.queryBuilderState.graphManagerState.graph.getTypicalMultiplicity(
|
35
32
|
TYPICAL_MULTIPLICITY_TYPE.ONE,
|
36
33
|
);
|
34
|
+
} else if (columnState instanceof QueryBuilderOlapGroupByColumnState) {
|
35
|
+
return columnState.olapState.tdsState.queryBuilderState.graphManagerState.graph.getTypicalMultiplicity(
|
36
|
+
TYPICAL_MULTIPLICITY_TYPE.ONE,
|
37
|
+
);
|
37
38
|
} else if (columnState instanceof QueryBuilderSimpleProjectionColumnState) {
|
38
39
|
return columnState.propertyExpressionState.propertyExpression.func.value
|
39
40
|
.multiplicity;
|
@@ -63,11 +63,11 @@ export const buildPostFilterConditionExpression = (
|
|
63
63
|
multiplicityOne,
|
64
64
|
);
|
65
65
|
let tdsDerivedPropertyName: TDS_COLUMN_GETTER;
|
66
|
-
const
|
67
|
-
if (
|
68
|
-
tdsDerivedPropertyName =
|
66
|
+
const correspondingTDSDerivedProperty = operator.getTDSColumnGetter();
|
67
|
+
if (correspondingTDSDerivedProperty) {
|
68
|
+
tdsDerivedPropertyName = correspondingTDSDerivedProperty;
|
69
69
|
} else {
|
70
|
-
const type = guaranteeNonNullable(colState.
|
70
|
+
const type = guaranteeNonNullable(colState.getColumnType());
|
71
71
|
tdsDerivedPropertyName = getTDSColumnDerivedProperyFromType(type);
|
72
72
|
}
|
73
73
|
tdsPropertyExpression.func = PropertyExplicitReference.create(
|
@@ -72,7 +72,7 @@ export class QueryBuilderPostFilterOperator_Contain
|
|
72
72
|
postFilterConditionState: PostFilterConditionState,
|
73
73
|
): ValueSpecification {
|
74
74
|
const propertyType = guaranteeNonNullable(
|
75
|
-
postFilterConditionState.columnState.
|
75
|
+
postFilterConditionState.columnState.getColumnType(),
|
76
76
|
);
|
77
77
|
switch (propertyType.path) {
|
78
78
|
case PRIMITIVE_TYPE.STRING: {
|
@@ -69,7 +69,7 @@ export class QueryBuilderPostFilterOperator_EndWith
|
|
69
69
|
getDefaultFilterConditionValue(
|
70
70
|
postFilterConditionState: PostFilterConditionState,
|
71
71
|
): ValueSpecification {
|
72
|
-
const propertyType = postFilterConditionState.columnState.
|
72
|
+
const propertyType = postFilterConditionState.columnState.getColumnType();
|
73
73
|
switch (propertyType?.path) {
|
74
74
|
case PRIMITIVE_TYPE.STRING: {
|
75
75
|
return buildPrimitiveInstanceValue(
|
package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_Equal.ts
CHANGED
@@ -91,7 +91,7 @@ export class QueryBuilderPostFilterOperator_Equal
|
|
91
91
|
return isTypeCompatibleForAssignment(
|
92
92
|
getNonCollectionValueSpecificationType(valueSpecification),
|
93
93
|
guaranteeNonNullable(
|
94
|
-
postFilterConditionState.columnState.
|
94
|
+
postFilterConditionState.columnState.getColumnType(),
|
95
95
|
),
|
96
96
|
);
|
97
97
|
}
|
@@ -102,7 +102,7 @@ export class QueryBuilderPostFilterOperator_Equal
|
|
102
102
|
postFilterConditionState: PostFilterConditionState,
|
103
103
|
): ValueSpecification {
|
104
104
|
const propertyType = guaranteeNonNullable(
|
105
|
-
postFilterConditionState.columnState.
|
105
|
+
postFilterConditionState.columnState.getColumnType(),
|
106
106
|
);
|
107
107
|
switch (propertyType.path) {
|
108
108
|
case PRIMITIVE_TYPE.STRING:
|
@@ -166,7 +166,7 @@ export class QueryBuilderPostFilterOperator_Equal
|
|
166
166
|
return buildPostFilterConditionExpression(
|
167
167
|
postFilterConditionState,
|
168
168
|
this,
|
169
|
-
postFilterConditionState.columnState.
|
169
|
+
postFilterConditionState.columnState.getColumnType()?.path ===
|
170
170
|
PRIMITIVE_TYPE.DATETIME &&
|
171
171
|
postFilterConditionState.value?.genericType?.value.rawType.path !==
|
172
172
|
PRIMITIVE_TYPE.DATETIME
|
@@ -74,7 +74,7 @@ export class QueryBuilderPostFilterOperator_GreaterThan
|
|
74
74
|
? getNonCollectionValueSpecificationType(postFilterConditionState.value)
|
75
75
|
: undefined,
|
76
76
|
guaranteeNonNullable(
|
77
|
-
postFilterConditionState.columnState.
|
77
|
+
postFilterConditionState.columnState.getColumnType(),
|
78
78
|
),
|
79
79
|
);
|
80
80
|
}
|
@@ -82,7 +82,7 @@ export class QueryBuilderPostFilterOperator_GreaterThan
|
|
82
82
|
getDefaultFilterConditionValue(
|
83
83
|
postFilterConditionState: PostFilterConditionState,
|
84
84
|
): ValueSpecification {
|
85
|
-
const propertyType = postFilterConditionState.columnState.
|
85
|
+
const propertyType = postFilterConditionState.columnState.getColumnType();
|
86
86
|
switch (propertyType?.path) {
|
87
87
|
case PRIMITIVE_TYPE.NUMBER:
|
88
88
|
case PRIMITIVE_TYPE.DECIMAL:
|
@@ -120,7 +120,7 @@ export class QueryBuilderPostFilterOperator_GreaterThan
|
|
120
120
|
return buildPostFilterConditionExpression(
|
121
121
|
postFilterConditionState,
|
122
122
|
this,
|
123
|
-
postFilterConditionState.columnState.
|
123
|
+
postFilterConditionState.columnState.getColumnType()?.path ===
|
124
124
|
PRIMITIVE_TYPE.DATETIME &&
|
125
125
|
postFilterConditionState.value?.genericType?.value.rawType.path !==
|
126
126
|
PRIMITIVE_TYPE.DATETIME
|
@@ -43,7 +43,7 @@ export class QueryBuilderPostFilterOperator_GreaterThanEqual extends QueryBuilde
|
|
43
43
|
return buildPostFilterConditionExpression(
|
44
44
|
postFilterConditionState,
|
45
45
|
this,
|
46
|
-
postFilterConditionState.columnState.
|
46
|
+
postFilterConditionState.columnState.getColumnType()?.path ===
|
47
47
|
PRIMITIVE_TYPE.DATETIME &&
|
48
48
|
postFilterConditionState.value?.genericType?.value.rawType.path !==
|
49
49
|
PRIMITIVE_TYPE.DATETIME
|
package/src/stores/fetch-structure/tds/post-filter/operators/QueryBuilderPostFilterOperator_In.ts
CHANGED
@@ -75,7 +75,7 @@ export class QueryBuilderPostFilterOperator_In
|
|
75
75
|
postFilterConditionState: PostFilterConditionState,
|
76
76
|
): boolean {
|
77
77
|
const propertyType = guaranteeNonNullable(
|
78
|
-
postFilterConditionState.columnState.
|
78
|
+
postFilterConditionState.columnState.getColumnType(),
|
79
79
|
);
|
80
80
|
const valueSpec = postFilterConditionState.value;
|
81
81
|
if (valueSpec instanceof CollectionInstanceValue) {
|
@@ -128,7 +128,7 @@ export class QueryBuilderPostFilterOperator_In
|
|
128
128
|
TYPICAL_MULTIPLICITY_TYPE.ONE,
|
129
129
|
);
|
130
130
|
const propertyType = guaranteeNonNullable(
|
131
|
-
postFilterConditionState.columnState.
|
131
|
+
postFilterConditionState.columnState.getColumnType(),
|
132
132
|
);
|
133
133
|
return new CollectionInstanceValue(
|
134
134
|
multiplicityOne,
|
@@ -42,7 +42,7 @@ export class QueryBuilderPostFilterOperator_IsEmpty
|
|
42
42
|
return 'is empty';
|
43
43
|
}
|
44
44
|
|
45
|
-
override
|
45
|
+
override getTDSColumnGetter(): TDS_COLUMN_GETTER | undefined {
|
46
46
|
return TDS_COLUMN_GETTER.IS_NULL;
|
47
47
|
}
|
48
48
|
|
@@ -62,7 +62,7 @@ export class QueryBuilderPostFilterOperator_IsEmpty
|
|
62
62
|
override isCompatibleWithPostFilterColumn(
|
63
63
|
postFilterState: PostFilterConditionState,
|
64
64
|
): boolean {
|
65
|
-
const columnType = postFilterState.columnState.
|
65
|
+
const columnType = postFilterState.columnState.getColumnType();
|
66
66
|
if (columnType && this.isCompatibleWithType(columnType)) {
|
67
67
|
if (
|
68
68
|
postFilterState.columnState instanceof
|
@@ -118,7 +118,7 @@ export class QueryBuilderPostFilterOperator_IsNotEmpty extends QueryBuilderPostF
|
|
118
118
|
return `is not empty`;
|
119
119
|
}
|
120
120
|
|
121
|
-
override
|
121
|
+
override getTDSColumnGetter(): TDS_COLUMN_GETTER | undefined {
|
122
122
|
return TDS_COLUMN_GETTER.IS_NOT_NULL;
|
123
123
|
}
|
124
124
|
|
@@ -74,7 +74,7 @@ export class QueryBuilderPostFilterOperator_LessThan
|
|
74
74
|
? getNonCollectionValueSpecificationType(postFilterConditionState.value)
|
75
75
|
: undefined,
|
76
76
|
guaranteeNonNullable(
|
77
|
-
postFilterConditionState.columnState.
|
77
|
+
postFilterConditionState.columnState.getColumnType(),
|
78
78
|
),
|
79
79
|
);
|
80
80
|
}
|
@@ -82,7 +82,7 @@ export class QueryBuilderPostFilterOperator_LessThan
|
|
82
82
|
getDefaultFilterConditionValue(
|
83
83
|
postFilterConditionState: PostFilterConditionState,
|
84
84
|
): ValueSpecification {
|
85
|
-
const propertyType = postFilterConditionState.columnState.
|
85
|
+
const propertyType = postFilterConditionState.columnState.getColumnType();
|
86
86
|
switch (propertyType?.path) {
|
87
87
|
case PRIMITIVE_TYPE.NUMBER:
|
88
88
|
case PRIMITIVE_TYPE.DECIMAL:
|
@@ -120,7 +120,7 @@ export class QueryBuilderPostFilterOperator_LessThan
|
|
120
120
|
return buildPostFilterConditionExpression(
|
121
121
|
postFilterConditionState,
|
122
122
|
this,
|
123
|
-
postFilterConditionState.columnState.
|
123
|
+
postFilterConditionState.columnState.getColumnType()?.path ===
|
124
124
|
PRIMITIVE_TYPE.DATETIME &&
|
125
125
|
postFilterConditionState.value?.genericType?.value.rawType.path !==
|
126
126
|
PRIMITIVE_TYPE.DATETIME
|
@@ -46,7 +46,7 @@ export class QueryBuilderPostFilterOperator_LessThanEqual
|
|
46
46
|
return buildPostFilterConditionExpression(
|
47
47
|
postFilterConditionState,
|
48
48
|
this,
|
49
|
-
postFilterConditionState.columnState.
|
49
|
+
postFilterConditionState.columnState.getColumnType()?.path ===
|
50
50
|
PRIMITIVE_TYPE.DATETIME &&
|
51
51
|
postFilterConditionState.value?.genericType?.value.rawType.path !==
|
52
52
|
PRIMITIVE_TYPE.DATETIME
|
@@ -70,7 +70,7 @@ export class QueryBuilderPostFilterOperator_StartWith
|
|
70
70
|
getDefaultFilterConditionValue(
|
71
71
|
postFilterConditionState: PostFilterConditionState,
|
72
72
|
): ValueSpecification {
|
73
|
-
const propertyType = postFilterConditionState.columnState.
|
73
|
+
const propertyType = postFilterConditionState.columnState.getColumnType();
|
74
74
|
switch (propertyType?.path) {
|
75
75
|
case PRIMITIVE_TYPE.STRING: {
|
76
76
|
return buildPrimitiveInstanceValue(
|
@@ -19,7 +19,6 @@ import {
|
|
19
19
|
type GeneratorFn,
|
20
20
|
LogEvent,
|
21
21
|
assertErrorThrown,
|
22
|
-
uuid,
|
23
22
|
guaranteeNonNullable,
|
24
23
|
assertTrue,
|
25
24
|
assertNonEmptyString,
|
@@ -50,11 +49,12 @@ import {
|
|
50
49
|
RawLambda,
|
51
50
|
stub_RawLambda,
|
52
51
|
} from '@finos/legend-graph';
|
52
|
+
import { QueryBuilderTDSColumnState } from '../QueryBuilderTDSColumnState_.js';
|
53
|
+
import type { QueryBuilderTDSState } from '../QueryBuilderTDSState.js';
|
53
54
|
import {
|
54
55
|
DEFAULT_LAMBDA_VARIABLE_NAME,
|
55
56
|
QUERY_BUILDER_SOURCE_ID_LABEL,
|
56
57
|
} from '../../../QueryBuilderConfig.js';
|
57
|
-
import type { QueryBuilderTDSState } from '../QueryBuilderTDSState.js';
|
58
58
|
import { QUERY_BUILDER_HASH_STRUCTURE } from '../../../../graphManager/QueryBuilderHashUtils.js';
|
59
59
|
import { LambdaEditorState } from '../../../shared/LambdaEditorState.js';
|
60
60
|
|
@@ -64,12 +64,15 @@ export interface QueryBuilderProjectionColumnDragSource {
|
|
64
64
|
columnState: QueryBuilderProjectionColumnState;
|
65
65
|
}
|
66
66
|
|
67
|
-
export abstract class QueryBuilderProjectionColumnState
|
68
|
-
|
67
|
+
export abstract class QueryBuilderProjectionColumnState
|
68
|
+
extends QueryBuilderTDSColumnState
|
69
|
+
implements Hashable
|
70
|
+
{
|
69
71
|
tdsState: QueryBuilderTDSState;
|
70
72
|
columnName: string;
|
71
73
|
|
72
74
|
constructor(tdsState: QueryBuilderTDSState, columnName: string) {
|
75
|
+
super();
|
73
76
|
makeObservable(this, {
|
74
77
|
uuid: false,
|
75
78
|
tdsState: false,
|
@@ -77,7 +80,6 @@ export abstract class QueryBuilderProjectionColumnState implements Hashable {
|
|
77
80
|
setColumnName: action,
|
78
81
|
hashCode: computed,
|
79
82
|
});
|
80
|
-
|
81
83
|
this.tdsState = tdsState;
|
82
84
|
this.columnName = columnName;
|
83
85
|
}
|
@@ -85,10 +87,6 @@ export abstract class QueryBuilderProjectionColumnState implements Hashable {
|
|
85
87
|
setColumnName(val: string): void {
|
86
88
|
this.columnName = val;
|
87
89
|
}
|
88
|
-
|
89
|
-
abstract getReturnType(): Type | undefined;
|
90
|
-
|
91
|
-
abstract get hashCode(): string;
|
92
90
|
}
|
93
91
|
|
94
92
|
export class QueryBuilderSimpleProjectionColumnState
|
@@ -143,7 +141,7 @@ export class QueryBuilderSimpleProjectionColumnState
|
|
143
141
|
);
|
144
142
|
}
|
145
143
|
|
146
|
-
override
|
144
|
+
override getColumnType(): Type | undefined {
|
147
145
|
return this.propertyExpressionState.propertyExpression.func.value
|
148
146
|
.genericType.value.rawType;
|
149
147
|
}
|
@@ -333,7 +331,7 @@ export class QueryBuilderDerivationProjectionColumnState
|
|
333
331
|
this.setReturnType(resolvedType);
|
334
332
|
}
|
335
333
|
|
336
|
-
override
|
334
|
+
override getColumnType(): Type | undefined {
|
337
335
|
return this.returnType;
|
338
336
|
}
|
339
337
|
|
@@ -346,6 +346,7 @@ export const processTDSSortExpression = (
|
|
346
346
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.TDS_PROJECT,
|
347
347
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.TDS_GROUP_BY,
|
348
348
|
QUERY_BUILDER_SUPPORTED_FUNCTIONS.TDS_FILTER,
|
349
|
+
QUERY_BUILDER_SUPPORTED_FUNCTIONS.OLAP_GROUPBY,
|
349
350
|
]),
|
350
351
|
`Can't process sort() expression: only support sort() in TDS expression`,
|
351
352
|
);
|
package/src/stores/fetch-structure/tds/projection/QueryBuilderProjectionValueSpecificationBuilder.ts
CHANGED
@@ -35,10 +35,6 @@ import {
|
|
35
35
|
guaranteeNonNullable,
|
36
36
|
UnsupportedOperationError,
|
37
37
|
} from '@finos/legend-shared';
|
38
|
-
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
39
|
-
import { buildPropertyExpressionChain } from '../../../QueryBuilderValueSpecificationBuilderHelper.js';
|
40
|
-
import { buildGenericLambdaFunctionInstanceValue } from '../../../QueryBuilderValueSpecificationHelper.js';
|
41
|
-
import { appendPostFilter } from '../post-filter/QueryBuilderPostFilterValueSpecificationBuilder.js';
|
42
38
|
import {
|
43
39
|
QueryBuilderDerivationProjectionColumnState,
|
44
40
|
QueryBuilderSimpleProjectionColumnState,
|
@@ -49,6 +45,11 @@ import {
|
|
49
45
|
type QueryResultSetModifierState,
|
50
46
|
type SortColumnState,
|
51
47
|
} from '../QueryResultSetModifierState.js';
|
48
|
+
import { QUERY_BUILDER_SUPPORTED_FUNCTIONS } from '../../../../graphManager/QueryBuilderSupportedFunctions.js';
|
49
|
+
import { buildGenericLambdaFunctionInstanceValue } from '../../../QueryBuilderValueSpecificationHelper.js';
|
50
|
+
import { buildPropertyExpressionChain } from '../../../QueryBuilderValueSpecificationBuilderHelper.js';
|
51
|
+
import { appendOlapGroupByState } from '../olapGroupBy/QueryBuilderOlapGroupByValueSpecificationBuilder.js';
|
52
|
+
import { appendPostFilter } from '../post-filter/QueryBuilderPostFilterValueSpecificationBuilder.js';
|
52
53
|
|
53
54
|
const buildSortExpression = (
|
54
55
|
sortColumnState: SortColumnState,
|
@@ -396,6 +397,9 @@ export const appendProjection = (
|
|
396
397
|
lambdaFunction.expressionSequence[0] = projectFunction;
|
397
398
|
}
|
398
399
|
|
400
|
+
// build olapGroupBy
|
401
|
+
appendOlapGroupByState(tdsState.olapGroupByState, lambdaFunction);
|
402
|
+
|
399
403
|
// build post-filter
|
400
404
|
appendPostFilter(tdsState.postFilterState, lambdaFunction);
|
401
405
|
|
@@ -374,6 +374,7 @@ export class QueryBuilderFilterState
|
|
374
374
|
isRearrangingConditions = false;
|
375
375
|
operators: QueryBuilderFilterOperator[] = [];
|
376
376
|
private _suppressClickawayEventListener = false;
|
377
|
+
showPanel = true;
|
377
378
|
|
378
379
|
constructor(
|
379
380
|
queryBuilderState: QueryBuilderState,
|
@@ -385,6 +386,7 @@ export class QueryBuilderFilterState
|
|
385
386
|
selectedNode: observable,
|
386
387
|
isRearrangingConditions: observable,
|
387
388
|
lambdaParameterName: observable,
|
389
|
+
showPanel: observable,
|
388
390
|
setLambdaParameterName: action,
|
389
391
|
setRearrangingConditions: action,
|
390
392
|
suppressClickawayEventListener: action,
|
@@ -398,6 +400,7 @@ export class QueryBuilderFilterState
|
|
398
400
|
pruneTree: action,
|
399
401
|
simplifyTree: action,
|
400
402
|
collapseTree: action,
|
403
|
+
setShowPanel: action,
|
401
404
|
expandTree: action,
|
402
405
|
hashCode: computed,
|
403
406
|
});
|
@@ -414,6 +417,10 @@ export class QueryBuilderFilterState
|
|
414
417
|
this.lambdaParameterName = val;
|
415
418
|
}
|
416
419
|
|
420
|
+
setShowPanel(val: boolean): void {
|
421
|
+
this.showPanel = val;
|
422
|
+
}
|
423
|
+
|
417
424
|
setRearrangingConditions(val: boolean): void {
|
418
425
|
this.isRearrangingConditions = val;
|
419
426
|
}
|
package/tsconfig.json
CHANGED
@@ -77,6 +77,8 @@
|
|
77
77
|
"./src/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeStateBuilder.ts",
|
78
78
|
"./src/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeUtil.ts",
|
79
79
|
"./src/stores/fetch-structure/graph-fetch/QueryBuilderGraphFetchTreeValueSpecificationBuilder.ts",
|
80
|
+
"./src/stores/fetch-structure/tds/QueryBuilderTDSColumnState_.ts",
|
81
|
+
"./src/stores/fetch-structure/tds/QueryBuilderTDSHelper.ts",
|
80
82
|
"./src/stores/fetch-structure/tds/QueryBuilderTDSState.ts",
|
81
83
|
"./src/stores/fetch-structure/tds/QueryResultSetModifierState.ts",
|
82
84
|
"./src/stores/fetch-structure/tds/aggregation/QueryBuilderAggregateOperator.ts",
|
@@ -94,6 +96,20 @@
|
|
94
96
|
"./src/stores/fetch-structure/tds/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Population.ts",
|
95
97
|
"./src/stores/fetch-structure/tds/aggregation/operators/QueryBuilderAggregateOperator_StdDev_Sample.ts",
|
96
98
|
"./src/stores/fetch-structure/tds/aggregation/operators/QueryBuilderAggregateOperator_Sum.ts",
|
99
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByOperatorLoader.ts",
|
100
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByState.ts",
|
101
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByStateBuilder.ts",
|
102
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/QueryBuilderOlapGroupByValueSpecificationBuilder.ts",
|
103
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_.ts",
|
104
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Average.ts",
|
105
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Count.ts",
|
106
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Max.ts",
|
107
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Min.ts",
|
108
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapOperator_Sum.ts",
|
109
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_AverageRank_.ts",
|
110
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_DenseRank_.ts",
|
111
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_Rank_.ts",
|
112
|
+
"./src/stores/fetch-structure/tds/olapGroupBy/operators/QueryBuilderTDSOlapRankOperator_RowNumber_.ts",
|
97
113
|
"./src/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterOperator.ts",
|
98
114
|
"./src/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterOperatorLoader.ts",
|
99
115
|
"./src/stores/fetch-structure/tds/post-filter/QueryBuilderPostFilterState.ts",
|
@@ -154,8 +170,11 @@
|
|
154
170
|
"./src/components/explorer/QueryBuilderPropertySearchPanel.tsx",
|
155
171
|
"./src/components/fetch-structure/QueryBuilderFetchStructurePanel.tsx",
|
156
172
|
"./src/components/fetch-structure/QueryBuilderGraphFetchTreePanel.tsx",
|
173
|
+
"./src/components/fetch-structure/QueryBuilderOlapGroupByPanel.tsx",
|
157
174
|
"./src/components/fetch-structure/QueryBuilderPostFilterPanel.tsx",
|
175
|
+
"./src/components/fetch-structure/QueryBuilderPostTDSPanel.tsx",
|
158
176
|
"./src/components/fetch-structure/QueryBuilderResultModifierPanel.tsx",
|
177
|
+
"./src/components/fetch-structure/QueryBuilderTDSComponentHelper.tsx",
|
159
178
|
"./src/components/fetch-structure/QueryBuilderTDSPanel.tsx",
|
160
179
|
"./src/components/filter/QueryBuilderFilterPanel.tsx",
|
161
180
|
"./src/components/shared/BasicValueSpecificationEditor.tsx",
|