Skip to content

Searching for not empty grid field in {exp:channel:entries} tag is not possible #2670

Closed
@shbchk

Description

@shbchk

EE 7.2.5
PHP 7.4.21

I have two entries:
Entry id 2: Entry without content in a grid field
Entry id 1: Entry with content in a grid field

What I need
Show only entries that have rows in a grid field.

What I tried to do

Try 1

{exp:channel:entries channel="test" search:grid_field="not IS_EMPTY" limit="1"}
{if no_results}
<h1>Nothing</h1>
{/if}

<h1>{title}</h1>
{/exp:channel:entries}

Output:

Nothing

Try 2

{exp:channel:entries channel="test" search:grid_field:total_rows=">=1" limit="1"}
{if no_results}
<h1>Nothing</h1>
{/if}

<h1>{title}</h1>
{/exp:channel:entries}

Output:

Entry without content in a grid field

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug: InvalidIssue is either not a bug, or external in nature.under reviewAn EE team member is reviewing this issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions