检查、新建表

<?php
        $table_check = $db->prepare("SHOW TABLES LIKE '%".$tb_name."%'");
        $table_check->execute();
        $table_check_result = $table_check->fetchAll();
        if(count($table_check_result)==0){
            Tools_DbSharding::create_table($db, $tb_name, self::$CRTSQL);
        }
原文地址:https://www.cnblogs.com/zl0372/p/3410512.html