WordPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '`ordering` AS (SELECT ROW_NUMBER() OVER (ORDER BY `post_modified_gmt`) AS n, pos' at line 1]
WITH `ordering` AS (SELECT ROW_NUMBER() OVER (ORDER BY `post_modified_gmt`) AS n, post_modified_gmt
FROM `wp_posts` USE INDEX ( `type_status_date` )
WHERE `post_status` IN ('publish')
AND `post_type` = 'product'
ORDER BY `post_modified_gmt`)
SELECT `post_modified_gmt`
FROM `ordering`
WHERE MOD(n, 1000) = 0;