Hi Adrian Good that you are making progress, even though it doesn't look like the SQL would be equivalent to me. However, just in case you didn't already know this tip, I have so often found it useful to see what SQL statement is being generated by prefixing '_' in front of select, eg db(query)._select()
This prints the SQL to the console. However, you can of course also easily put this into a variable and display the string in any view too. Regards, D