SELECT [产品信息].[系列ID], [产品信息].[产品编号], [产品信息].[产品名称], [产品信息].[单位], nz([入库总数查询].[入库总数],0) AS 入库总数, nz([发货总量查询].[发出总数],0) AS 发出总数, nz([产品信息].[期初库存],0) AS 期初库存, nz([入库总数查询].[入库总数]+[产品信息].[期初库存]-[发货总量查询].[发出总数],0) AS 库存结余
FROM (产品信息 LEFT JOIN 发货总量查询 ON [产品信息].[产品ID]=[发货总量查询].[产品ID]) LEFT JOIN 入库总数查询 ON [产品信息].[产品ID]=[入库总数查询].[产品ID];