SELECT
    tbgi.id,
    count( tbpi.goods_id ) commoditySpecificationsNum
FROM
    t_b_goods_info tbgi
LEFT JOIN t_b_price_info tbpi ON tbpi.goods_id = tbgi.id
GROUP BY
    tbgi.id