public function select(...$args)
    {
        $args = WF::flatten_array($args);

        $select = new Query\Select;
        $select->add(new Query\SourceTableClause($this->tablename));
        $cols = $this->getColumns();
        foreach ($cols as $name => $def)
            $select->add(new Query\GetClause($name));
        foreach ($args as $arg)
            $select->add($arg);

        $drv = $this->db->getDriver();
        return $drv->select($select);
    }
public function select(...$args)
    {
        $args = WF::flatten_array($args);

        $select = new Query\Select;
        $select->add(new Query\SourceTableClause($this->tablename));
        $cols = $this->getColumns();
        foreach ($cols as $name => $def)
            $select->add(new Query\GetClause($name));
        foreach ($args as $arg)
            $select->add($arg);

        $drv = $this->db->getDriver();
        return $drv->select($select);
    }
public function select ( ... $ args ) { $ args = WF :: flatten_array ( $ args ) ; $ select = new Query \ Select ; $ select -> add ( new Query \ SourceTableClause ( $ this -> tablename ) ) ; $ cols = $ this -> getColumns ( ) ; foreach ( $ cols as $ name => $ def ) $ select -> add ( new Query \ GetClause ( $ name ) ) ; foreach ( $ args as $ arg ) $ select -> add ( $ arg ) ; $ drv = $ this -> db -> getDriver ( ) ; return $ drv -> select ( $ select ) ; }
Select one or more records from the database.

@param $args The provided arguments should contain query parts passed to the
Select constructor. These can be objects such as:
FieldName, JoinClause, WhereClause, OrderClause, LimitClause,
OffsetClause. A Wedeto\DB\DB object can also be passed in to
use as a Database.
@return PreparedStatement The executed select query

@see Wedeto\DB\Query\Select
Select one or more records from the database .