Home  >  Q&A  >  body text

数据库 - MySQL中如何把多张表格中的相同种类的数据合在同一列显示出来?

题目中给出了四张表:

图中S代表供货商,P代表商品,J代表商业项目,SP代表三者的联系(和这道小题暂时无关),现在需要在同一列显示出供货商、商品、商业项目所在的所有城市(city项)且不重复显示,请问有什么方法可以实现。。。。。

巴扎黑巴扎黑2743 days ago824

reply all(1)I'll reply

  • PHPz

    PHPz2017-04-17 13:29:01

    The connection between your three people must be related to this question. Otherwise, you cannot combine the three unrelated tables. But your three-way connection table is a bit messy. Is there no rule?

    reply
    0
  • Cancelreply