Swoole\Model::createTable PHP 메소드

createTable() 공개 메소드

建立表,必须在Model类中,指定create_sql
public createTable ( ) : boolean
리턴 boolean
    function createTable()
    {
        if ($this->create_sql) {
            return $this->db->query($this->create_sql);
        } else {
            return false;
        }
    }

Usage Example

예제 #1
0
 function createTable()
 {
     $this->model->createTable();
 }