Skip to content
This repository was archived by the owner on Apr 16, 2022. It is now read-only.
This repository was archived by the owner on Apr 16, 2022. It is now read-only.

Grouping UnionModel with GroupModel is not working. #9

Description

@romaninsh

Trying to avoid #8, using GroupModel to group UnionModel causes error. Code:

$m = new \smbo\GroupModel($m);
$m->groupBy(['contact_id'], [
    'c'=>'count(*)',
    'total_net'=>'sum([])',
});

But this leads to the following error:

error: "SQLSTATE[42S22]: Column not found: 1054 Unknown column 'derivedTable.contact_id' in 'group statement'"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions