private void validateOrderItem ( SqlSelect select , SqlNode orderItem ) { switch ( orderItem . getKind ( ) ) { case DESCENDING : validateFeature ( RESOURCE . sQLConformance_OrderByDesc ( ) , orderItem . getParserPosition ( ) ) ; validateOrderItem ( select , ( ( SqlCall ) orderItem ) . operand ( 0 ) ) ; return ; } final SqlValidatorScope orderScope = getOrderScope ( select ) ; validateExpr ( orderItem , orderScope ) ; }
Validates an item in the ORDER BY clause of a SELECT statement .