src/Charcoal/Source/DatabaseSource.php
public function sqlSelect()
    {
        $properties = $this->properties();
        if (empty($properties)) {
            return self::DEFAULT_TABLE_ALIAS.'.*';
        }

        $parts = [];
        foreach ($properties as $key) {
            $parts[] = Expression::quoteIdentifier($key, self::DEFAULT_TABLE_ALIAS);
        }

        if (empty($parts)) {
            throw new UnexpectedValueException(
                'Can not get SQL SELECT clause. No valid properties.'
            );
        }

        $clause = implode(', ', $parts);

        return $clause;
    }
public function sqlSelect()
    {
        $properties = $this->properties();
        if (empty($properties)) {
            return self::DEFAULT_TABLE_ALIAS.'.*';
        }

        $parts = [];
        foreach ($properties as $key) {
            $parts[] = Expression::quoteIdentifier($key, self::DEFAULT_TABLE_ALIAS);
        }

        if (empty($parts)) {
            throw new UnexpectedValueException(
                'Can not get SQL SELECT clause. No valid properties.'
            );
        }

        $clause = implode(', ', $parts);

        return $clause;
    }
public function sqlSelect ( ) { $ properties = $ this -> properties ( ) ; if ( empty ( $ properties ) ) { return self :: DEFAULT_TABLE_ALIAS . '.*' ; } $ parts = [ ] ; foreach ( $ properties as $ key ) { $ parts [ ] = Expression :: quoteIdentifier ( $ key , self :: DEFAULT_TABLE_ALIAS ) ; } if ( empty ( $ parts ) ) { throw new UnexpectedValueException ( 'Can not get SQL SELECT clause. No valid properties.' ) ; } $ clause = implode ( ', ' , $ parts ) ; return $ clause ; }
Compile the SELECT clause.

@throws UnexpectedValueException If the clause has no selectable fields.
@return string
Compile the SELECT clause .