I have a grid view setup to show 3 entries from the system where two particular fields are set. One is the county and the other is where a particular field has a value greater than or equal to 1. There's something like 260 entries that match these criteria. I set the sort to Random. But EVERY time the page loads, it's ALWAYS the same 3 entries. I changed sort to ascending on another field just to make sure it changes, which it does. But then I set it back to Random and I get the same exact 3 entries I had before. Why does it constantly return the same 3 entries. Is there some sort of db caching going on?
There's not enough information to help with a diagnosis. How have you confirmed there are 260 matching entries? Troubleshooting a SQL query often requires testing in PHPMyAdmin and comparing your query with the query Formidable generates. You can see Formidable's query by setting a break point in the frm_view_order filter.
Strategy 11 released Visual Views 5.6 with this changelog note: "Views sorted by random are now randomized with PHP instead of with SQL. This fixes a conflict with WP Engine hosting where ordering by random using SQL is disabled."
Apparently WP Engine and perhaps other hosts have disabled the MySQL RAND() function presumably as a performance improvement. Are you being hosted on WPEngine?
Please login or Register to submit your answer