一个表有product reference,size,color,quantity字段,另一个表有product reference,size,color,quantity,corner reference想用这两个表形成一个新的临时表,有product reference,cornere reference,size,color,quantity,并加brand字段1)一个表没有corner reference的,在这个字段中填空
2)brand是根据product reference到第三个表中查到的
3)而且前面两个表有冗余的话(即相同数据)也要全部列出来
怎么用存储过程做容易