删除重复行,同时保留最旧的提交
要根据subscriberEmail字段消除重复行,同时保留原始提交,请按照以下步骤操作:
<code class="sql">delete x from myTable x join myTable z on x.subscriberEmail = z.subscriberEmail where x.id > z.id;</code>
解释:
附加说明:
<code class="sql">delete x from myTable x join myTable z on x.subscriberEmail = z.subscriberEmail and x.id > z.id;</code>
以上是如何根据订阅者电子邮件删除重复行,同时保留最旧的提交?的详细内容。更多信息请关注PHP中文网其他相关文章!