驱动改进

This commit is contained in:
thinkphp
2016-05-09 12:01:41 +08:00
parent ae908199eb
commit e7839557c6
5 changed files with 15 additions and 11 deletions

View File

@@ -59,7 +59,7 @@ class Sqlsrv extends Connection
AND t.table_name = c.table_name
WHERE t.table_name = '$tableName'";
$pdo = $this->linkID->query($sql);
$result = $pdo->fetchAll(\PDO::FETCH_ASSOC);
$result = $pdo->fetchAll(PDO::FETCH_ASSOC);
$info = [];
if ($result) {
foreach ($result as $key => $val) {
@@ -90,7 +90,7 @@ class Sqlsrv extends Connection
WHERE TABLE_TYPE = 'BASE TABLE'
";
$pdo = $this->linkID->query($sql);
$result = $pdo->fetchAll(\PDO::FETCH_ASSOC);
$result = $pdo->fetchAll(PDO::FETCH_ASSOC);
$info = [];
foreach ($result as $key => $val) {
$info[$key] = current($val);