Postgresql Select Distinct On

At the bottom of the Chapter 7.3.3 "Select Lists" of the PostgreSQL manual


DISTINCT ON

syntax is described. But when I want to use this syntax in


CDbCriteria->distinct

  • only boolean value available. And CDbCommandBuilder at line #123 of the yiiframework v1.1.13 for example, created statement SELECT DISTINCT, and no opportunity to hook this. Will be good to set CDbCriteria->distinct property as string or as array otherwise boolean as now.

SELECT DISTINCT ON (expression [, expression ...]) select_list ...

Thanks!