修正bug
boolw opened this issue · 2 comments
boolw commented
nwidart\db-exporter\src\Nwidart\DbExporter\DbExporter.php
文件:37行
'information_schema.columns' 修正为 DB::raw('information_schema.columns')
原因:DB::table('information_schema.columns') 会自动加上前缀,导致报错
例:SQLSTATE[42S02]: Base table or view not found: 1146 Table 'bool_bool_inform
ation_schema.columns' doesn't exist (SQL: select column_name
as Field
,
column_type
as Type
, is_nullable
as Null
, column_key
as Key
, c olumn_default
as Default
, extra
as Extra
, data_type
as Data_Type
from bool_bool_information_schema
.columns
where table_schema
= bool_
cms and table_name
= bool_admins)
boolw commented
还有类似的:
50行:DB::table($table) 修正为 DB::table(DB::raw($table))