<bdo id='bWXpP'></bdo><ul id='bWXpP'></ul>
      <i id='bWXpP'><tr id='bWXpP'><dt id='bWXpP'><q id='bWXpP'><span id='bWXpP'><b id='bWXpP'><form id='bWXpP'><ins id='bWXpP'></ins><ul id='bWXpP'></ul><sub id='bWXpP'></sub></form><legend id='bWXpP'></legend><bdo id='bWXpP'><pre id='bWXpP'><center id='bWXpP'></center></pre></bdo></b><th id='bWXpP'></th></span></q></dt></tr></i><div id='bWXpP'><tfoot id='bWXpP'></tfoot><dl id='bWXpP'><fieldset id='bWXpP'></fieldset></dl></div>
      <legend id='bWXpP'><style id='bWXpP'><dir id='bWXpP'><q id='bWXpP'></q></dir></style></legend>

      <small id='bWXpP'></small><noframes id='bWXpP'>

    1. <tfoot id='bWXpP'></tfoot>

    2. MySQL如何连接两个字段上的表

      时间:2023-10-08

          <bdo id='aobWj'></bdo><ul id='aobWj'></ul>

          <small id='aobWj'></small><noframes id='aobWj'>

          <i id='aobWj'><tr id='aobWj'><dt id='aobWj'><q id='aobWj'><span id='aobWj'><b id='aobWj'><form id='aobWj'><ins id='aobWj'></ins><ul id='aobWj'></ul><sub id='aobWj'></sub></form><legend id='aobWj'></legend><bdo id='aobWj'><pre id='aobWj'><center id='aobWj'></center></pre></bdo></b><th id='aobWj'></th></span></q></dt></tr></i><div id='aobWj'><tfoot id='aobWj'></tfoot><dl id='aobWj'><fieldset id='aobWj'></fieldset></dl></div>
            <tbody id='aobWj'></tbody>
        • <legend id='aobWj'><style id='aobWj'><dir id='aobWj'><q id='aobWj'></q></dir></style></legend>

            <tfoot id='aobWj'></tfoot>

                本文介绍了MySQL如何连接两个字段上的表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                我有两个带有 dateid 字段的表.我想加入这两个领域.我试过

                I have two tables with date and id fields. I want to join on both fields. I tried

                JOIN t2 ON CONCAT(t1.id, t1.date)=CONCAT(t2.id, t2.date)
                

                可以,但是速度很慢.有没有更好的方法来做到这一点?

                that works, but it is very slow. is there a better way to do this?

                推荐答案

                JOIN t2 ON t1.id=t2.id AND t1.date=t2.date
                

                这篇关于MySQL如何连接两个字段上的表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                上一篇:什么时候使用左外连接? 下一篇:从 SQL 表中删除重复行(基于多列的值)

                相关文章

                <legend id='asmjV'><style id='asmjV'><dir id='asmjV'><q id='asmjV'></q></dir></style></legend>
                <tfoot id='asmjV'></tfoot>
              1. <small id='asmjV'></small><noframes id='asmjV'>

                  • <bdo id='asmjV'></bdo><ul id='asmjV'></ul>
                    <i id='asmjV'><tr id='asmjV'><dt id='asmjV'><q id='asmjV'><span id='asmjV'><b id='asmjV'><form id='asmjV'><ins id='asmjV'></ins><ul id='asmjV'></ul><sub id='asmjV'></sub></form><legend id='asmjV'></legend><bdo id='asmjV'><pre id='asmjV'><center id='asmjV'></center></pre></bdo></b><th id='asmjV'></th></span></q></dt></tr></i><div id='asmjV'><tfoot id='asmjV'></tfoot><dl id='asmjV'><fieldset id='asmjV'></fieldset></dl></div>