<span class="resolved" aria-label="Resolved" title="Topic is resolved."></span>Latest update broke “groupby”

[ad_1]

Replies: 1

I start receiving this error message today:

Pods Embed Error: GROUP BY contains SQL that is not allowed.

This is the shortcode used:

[pods name=”content” limit=”-1″ where=”‘ . $where_param . ‘” template=”content_display” orderby=”CAST(first_line.meta_value AS DECIMAL), CAST(last_line.meta_value AS DECIMAL)” groupby=”CAST(first_line.meta_value AS DECIMAL), CAST(last_line.meta_value AS DECIMAL)” ]

The groudby argument is used to prevent showing entries that have the same specific contents that I want to show from different PODS entries. (To simply put, to show only unique contents.)

I have reduced the groupby parameter to just:

groupby=first_line.meta_value

and it still wouldn’t work. Only by removing the whole groupby argument will the error message go away and the code starts working again. Also for reference, orderby is working with the exact same parameters.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer