小编Mun*_*kar的帖子

无法解析 [Maatwebsite\Excel\Transactions\TransactionManager] 的 NULL 驱动程序

我正在尝试将数据从数据库下载到 excel 文件。我也从作曲家导入了 Maatwebsite\Excel。我的控制器中的代码是:

function excel()
    {
$month = date('m');
DB::statement("CREATE OR REPLACE VIEW monthly_cost AS
select  user_name,  id, phone, sum(cost) as cost from (
        select users.name as user_name, users.roll as id,users.phone as phone, BC.individual_cost as cost
        from breakfast_orders BO, breakfast_costs BC,users
        WHERE (BO.date=BC.date) and (BO.user_id=users.id)and MONTH(BO.date)='$month'
        UNION ALL
        select users.name as user_name, users.roll as id,users.phone as phone, LC.individual_cost as cost
        from lunch_orders LO, lunch_costs LC,users
        WHERE (LO.date=LC.date) and (LO.user_id=users.id) and MONTH(LO.date)='$month'
        UNION ALL
        select users.name as user_name, users.roll as …
Run Code Online (Sandbox Code Playgroud)

laravel

7
推荐指数
1
解决办法
7659
查看次数

标签 统计

laravel ×1