project-m36 1.2.3 → 1.2.4
raw patch · 5 files changed
+36/−4 lines, 5 filesPVP: major bump suggested
API removals or changes: PVP suggests a major version bump
API changes (from Hackage documentation)
- ProjectM36.Base: AddInclusionDependencyF :: Text -> InclusionDependency -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: AddInclusionDependencyF :: Text -> InclusionDependency -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: AddNotificationF :: Text -> RelationalExprBase () -> RelationalExprBase () -> RelationalExprBase () -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: AddNotificationF :: Text -> RelationalExprBase () -> RelationalExprBase () -> RelationalExprBase () -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: AddRegisteredQueryF :: Text -> RelationalExprBase () -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: AddRegisteredQueryF :: Text -> RelationalExprBase () -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: AddTypeConstructorF :: TypeConstructorDef -> [DataConstructorDef] -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: AddTypeConstructorF :: TypeConstructorDef -> [DataConstructorDef] -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: AlterACLF :: AlterDBCACLExprBase r_aFch -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: AlterACLF :: AlterDBCACLExprBase r_aFco -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: AssignF :: Text -> RelationalExprBase a_aFcg -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: AssignF :: Text -> RelationalExprBase a_aFcn -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: DefineF :: Text -> [AttributeExprBase a_aFcg] -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: DefineF :: Text -> [AttributeExprBase a_aFcn] -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: DeleteF :: Text -> RestrictionPredicateExprBase a_aFcg -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: DeleteF :: Text -> RestrictionPredicateExprBase a_aFcn -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: DifferenceF :: r_aQNe -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: DifferenceF :: r_aQNl -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: EqualsF :: r_aQNe -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: EqualsF :: r_aQNl -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: ExecuteDatabaseContextFunctionF :: Text -> [AtomExprBase a_aFcg] -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: ExecuteDatabaseContextFunctionF :: Text -> [AtomExprBase a_aFcn] -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: ExistingRelationF :: Relation -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: ExistingRelationF :: Relation -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: ExtendF :: ExtendTupleExprBase a_aFcl -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: ExtendF :: ExtendTupleExprBase a_aFcs -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: GrantAccessExprF :: r_aF8A -> SomePermission -> Bool -> AlterDBCACLExprBaseF (r_aF8A :: Type) r_aS8E
+ ProjectM36.Base: GrantAccessExprF :: r_aF8H -> SomePermission -> Bool -> AlterDBCACLExprBaseF (r_aF8H :: Type) r_aS8L
- ProjectM36.Base: GrantDBCFunctionAccessExprF :: r_aF8A -> Text -> DBCFunctionPermission -> Bool -> AlterDBCACLExprBaseF (r_aF8A :: Type) r_aS8E
+ ProjectM36.Base: GrantDBCFunctionAccessExprF :: r_aF8H -> Text -> DBCFunctionPermission -> Bool -> AlterDBCACLExprBaseF (r_aF8H :: Type) r_aS8L
- ProjectM36.Base: GroupF :: AttributeNamesBase a_aFcl -> Text -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: GroupF :: AttributeNamesBase a_aFcs -> Text -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: InsertF :: Text -> RelationalExprBase a_aFcg -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: InsertF :: Text -> RelationalExprBase a_aFcn -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: JoinF :: r_aQNe -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: JoinF :: r_aQNl -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: MakeRelationFromExprsF :: Maybe [AttributeExprBase a_aFcl] -> TupleExprsBase a_aFcl -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: MakeRelationFromExprsF :: Maybe [AttributeExprBase a_aFcs] -> TupleExprsBase a_aFcs -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: MakeStaticRelationF :: Attributes -> RelationTupleSet -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: MakeStaticRelationF :: Attributes -> RelationTupleSet -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: MultipleExprF :: [r_aRtK] -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: MultipleExprF :: [r_aRtR] -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: NoOperationF :: DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: NoOperationF :: DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: NotEqualsF :: r_aQNe -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: NotEqualsF :: r_aQNl -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: ProjectF :: AttributeNamesBase a_aFcl -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: ProjectF :: AttributeNamesBase a_aFcs -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: RelationValuedAttributeF :: Text -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: RelationValuedAttributeF :: Text -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: RelationVariableF :: Text -> a_aFcl -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: RelationVariableF :: Text -> a_aFcs -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: RemoveAtomFunctionF :: Text -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: RemoveAtomFunctionF :: Text -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: RemoveDatabaseContextFunctionF :: Text -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: RemoveDatabaseContextFunctionF :: Text -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: RemoveInclusionDependencyF :: Text -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: RemoveInclusionDependencyF :: Text -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: RemoveNotificationF :: Text -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: RemoveNotificationF :: Text -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: RemoveRegisteredQueryF :: Text -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: RemoveRegisteredQueryF :: Text -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: RemoveTypeConstructorF :: Text -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: RemoveTypeConstructorF :: Text -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: RenameF :: Set (Text, Text) -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: RenameF :: Set (Text, Text) -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: RestrictF :: RestrictionPredicateExprBase a_aFcl -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: RestrictF :: RestrictionPredicateExprBase a_aFcs -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: RevokeAccessExprF :: r_aF8A -> SomePermission -> AlterDBCACLExprBaseF (r_aF8A :: Type) r_aS8E
+ ProjectM36.Base: RevokeAccessExprF :: r_aF8H -> SomePermission -> AlterDBCACLExprBaseF (r_aF8H :: Type) r_aS8L
- ProjectM36.Base: RevokeDBCFunctionAccessExprF :: r_aF8A -> Text -> DBCFunctionPermission -> AlterDBCACLExprBaseF (r_aF8A :: Type) r_aS8E
+ ProjectM36.Base: RevokeDBCFunctionAccessExprF :: r_aF8H -> Text -> DBCFunctionPermission -> AlterDBCACLExprBaseF (r_aF8H :: Type) r_aS8L
- ProjectM36.Base: UndefineF :: Text -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: UndefineF :: Text -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: UngroupF :: Text -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: UngroupF :: Text -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: UnionF :: r_aQNe -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: UnionF :: r_aQNl -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: UpdateF :: Text -> Map Text (AtomExprBase ()) -> RestrictionPredicateExprBase a_aFcg -> DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: UpdateF :: Text -> Map Text (AtomExprBase ()) -> RestrictionPredicateExprBase a_aFcn -> DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: WithF :: [(WithNameExprBase a_aFcl, r_aQNe)] -> r_aQNe -> RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: WithF :: [(WithNameExprBase a_aFcs, r_aQNl)] -> r_aQNl -> RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.Base: data AlterDBCACLExprBaseF (r_aF8A :: Type) r_aS8E
+ ProjectM36.Base: data AlterDBCACLExprBaseF (r_aF8H :: Type) r_aS8L
- ProjectM36.Base: data DatabaseContextExprBaseF (a_aFcg :: Type) (r_aFch :: Type) r_aRtK
+ ProjectM36.Base: data DatabaseContextExprBaseF (a_aFcn :: Type) (r_aFco :: Type) r_aRtR
- ProjectM36.Base: data RelationalExprBaseF (a_aFcl :: Type) r_aQNe
+ ProjectM36.Base: data RelationalExprBaseF (a_aFcs :: Type) r_aQNl
- ProjectM36.SQL.Select: BetweenOperatorF :: r_a1bCj -> r_a1bCj -> r_a1bCj -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: BetweenOperatorF :: r_a1bDv -> r_a1bDv -> r_a1bDv -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: BinaryOperatorF :: r_a1bCj -> OperatorName -> r_a1bCj -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: BinaryOperatorF :: r_a1bDv -> OperatorName -> r_a1bDv -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: BooleanLiteralF :: Bool -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: BooleanLiteralF :: Bool -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: BooleanOperatorExprF :: r_a1bCj -> BoolOp -> r_a1bCj -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: BooleanOperatorExprF :: r_a1bDv -> BoolOp -> r_a1bDv -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: CaseExprF :: [(r_a1bCj, r_a1bCj)] -> Maybe r_a1bCj -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: CaseExprF :: [(r_a1bDv, r_a1bDv)] -> Maybe r_a1bDv -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: DoubleLiteralF :: Double -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: DoubleLiteralF :: Double -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: ExistsExprF :: Select -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: ExistsExprF :: Select -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: FunctionApplicationF :: FuncName -> [r_a1bCj] -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: FunctionApplicationF :: FuncName -> [r_a1bDv] -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: IdentifierF :: n_a11gj -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: IdentifierF :: n_a11hv -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: InExprF :: InFlag -> r_a1bCj -> InPredicateValue -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: InExprF :: InFlag -> r_a1bDv -> InPredicateValue -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: IntegerLiteralF :: Integer -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: IntegerLiteralF :: Integer -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: NullLiteralF :: ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: NullLiteralF :: ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: PostfixOperatorF :: r_a1bCj -> OperatorName -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: PostfixOperatorF :: r_a1bDv -> OperatorName -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: PrefixOperatorF :: OperatorName -> r_a1bCj -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: PrefixOperatorF :: OperatorName -> r_a1bDv -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: QuantifiedComparisonF :: r_a1bCj -> ComparisonOperator -> QuantifiedComparisonPredicate -> Select -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: QuantifiedComparisonF :: r_a1bDv -> ComparisonOperator -> QuantifiedComparisonPredicate -> Select -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: StringLiteralF :: Text -> ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: StringLiteralF :: Text -> ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
- ProjectM36.SQL.Select: [caseElseF] :: ScalarExprBaseF (n_a11gj :: Type) r_a1bCj -> Maybe r_a1bCj
+ ProjectM36.SQL.Select: [caseElseF] :: ScalarExprBaseF (n_a11hv :: Type) r_a1bDv -> Maybe r_a1bDv
- ProjectM36.SQL.Select: [caseWhensF] :: ScalarExprBaseF (n_a11gj :: Type) r_a1bCj -> [(r_a1bCj, r_a1bCj)]
+ ProjectM36.SQL.Select: [caseWhensF] :: ScalarExprBaseF (n_a11hv :: Type) r_a1bDv -> [(r_a1bDv, r_a1bDv)]
- ProjectM36.SQL.Select: [qcExprF] :: ScalarExprBaseF (n_a11gj :: Type) r_a1bCj -> r_a1bCj
+ ProjectM36.SQL.Select: [qcExprF] :: ScalarExprBaseF (n_a11hv :: Type) r_a1bDv -> r_a1bDv
- ProjectM36.SQL.Select: [qcOperatorF] :: ScalarExprBaseF (n_a11gj :: Type) r_a1bCj -> ComparisonOperator
+ ProjectM36.SQL.Select: [qcOperatorF] :: ScalarExprBaseF (n_a11hv :: Type) r_a1bDv -> ComparisonOperator
- ProjectM36.SQL.Select: [qcPredicateF] :: ScalarExprBaseF (n_a11gj :: Type) r_a1bCj -> QuantifiedComparisonPredicate
+ ProjectM36.SQL.Select: [qcPredicateF] :: ScalarExprBaseF (n_a11hv :: Type) r_a1bDv -> QuantifiedComparisonPredicate
- ProjectM36.SQL.Select: [qcQueryF] :: ScalarExprBaseF (n_a11gj :: Type) r_a1bCj -> Select
+ ProjectM36.SQL.Select: [qcQueryF] :: ScalarExprBaseF (n_a11hv :: Type) r_a1bDv -> Select
- ProjectM36.SQL.Select: data ScalarExprBaseF (n_a11gj :: Type) r_a1bCj
+ ProjectM36.SQL.Select: data ScalarExprBaseF (n_a11hv :: Type) r_a1bDv
Files
- Changelog.markdown +4/−0
- examples/zoo.hs +0/−1
- project-m36.cabal +1/−1
- src/lib/ProjectM36/Streaming/RelationalExpression.hs +1/−1
- test/TutorialD/InterpreterTest.hs +30/−1
Changelog.markdown view
@@ -1,3 +1,7 @@+# 2026-02-16 (v1.2.4)++* fix bug resulting in duplicate rows after group operator application+ # 2026-02-09 (v1.2.3) * add support for importing whole Haskell modules for easier application logic programming
examples/zoo.hs view
@@ -11,7 +11,6 @@ import Data.Time.Calendar import qualified Data.Text.IO as T ---TODO add dbc func ACLs data Ticket = Ticket { ticketId :: Integer , visitorAge :: Integer -- years
project-m36.cabal view
@@ -1,6 +1,6 @@ Cabal-Version: 2.2 Name: project-m36-Version: 1.2.3+Version: 1.2.4 License: MIT --note that this license specification is erroneous and only labeled MIT to appease hackage which does not recognize public domain packages in cabal >2.2- Project:M36 is dedicated to the public domain Build-Type: Simple
src/lib/ProjectM36/Streaming/RelationalExpression.hs view
@@ -484,7 +484,7 @@ case projectionAttributesForNames groupAttrNames attrsIn of Left err -> pure (Left err) Right groupProjectionAttributes -> do- eGroupS <- executePlan (ProjectTupleStreamPlan nonGroupProjectionAttributes expr () orig) ctxTuples gfEnv cacheKeyBlackList cache+ eGroupS <- executePlan (UniqueifyTupleStreamPlan (ProjectTupleStreamPlan nonGroupProjectionAttributes expr () orig) ()) ctxTuples gfEnv cacheKeyBlackList cache case eGroupS of Left err -> pure (Left err) Right (StreamRelation _ nonGroupProjectionTupS) -> do
test/TutorialD/InterpreterTest.hs view
@@ -102,7 +102,8 @@ testComplexTypeVarResolution, testNotifications, testDBCFunctionAccessControl,- testAttributeTypeHintsFromExistingRelVar+ testAttributeTypeHintsFromExistingRelVar,+ testGroup ] simpleRelTests :: Test@@ -959,3 +960,31 @@ let err1 = "RelationTypeMismatchError" expectTutorialDErr session dbconn (T.isPrefixOf err1) "x:=relation{tuple{a 3, b 4}}" +-- ensure that non-group attributes are not duplicates after the projection+testGroup :: Test+testGroup = TestCase $ do+ (session, dbconn) <- dateExamplesConnection emptyNotificationCallback+ executeTutorialD session dbconn "x := s group ({sname,status,s#} as rel)"+ result <- executeRelationalExpr session dbconn (RelationVariable "x" ())+ + let expected = mkRelationFromList attrs+ [[t "Paris",+ mkSubRel [[t "S2", t "Jones", i 10],+ [t "S3", t "Blake", i 30]]],+ [t "London",+ mkSubRel [[t "S4", t "Clark", i 20],+ [t "S1", t "Smith", i 20]]],+ [t "Athens",+ mkSubRel [[t "S5", t "Adams", i 30]]]+ ]+ attrs = A.attributesFromList [Attribute "city" TextAtomType,+ Attribute "rel" (RelationAtomType subAttrs)]+ subAttrs = A.attributesFromList [Attribute "s#" TextAtomType,+ Attribute "sname" TextAtomType,+ Attribute "status" IntegerAtomType]+ t = TextAtom+ i = IntegerAtom+ mkSubRel atoms = case mkRelationFromList subAttrs atoms of+ Left err -> error $ "bad mkSubRel " <> show err+ Right rel -> RelationAtom rel+ assertEqual "group operator" expected result