我有以下表格
折扣
id    product_type    product_id    discounted_price
 1       videos           1               20
 2       videos           2               20
视频
id    name
 1     test-1        
 2     test-2
 3     test-3
预期结果
 id    name    discount_product_type    discount_product_id    discount_discounted_price
  1    test-1        videos                 1                           20
  2    test-2        videos                 2                           20
  3    test-3          null                 null                        null
通过以下查询,我只得到前两行。我知道这是因为我有“and discounts.product_type='videos'”,但是......我不知道要添加什么。
select videos.* from 
videos left join discounts on videos.id = discounts.product_id where 
videos.id in(1,2,3) and discounts.product_type='videos'
基本上,我想从视频表中获取第 1、2、3 行以及来自折扣的行,但discounts.product_type必须是“视频”