![](/img/trans.png)
[英]Oracle SQL: Insert select from one table to another where user has multiple entries with order number
[英]SQL select from table where multiple entries exist
考虑自身的INNER JOIN
或自连接:
SELECT l1.Pokemon, l1.'Move' AS 'Move1', l2.'Move' AS 'Move2'
FROM 'learned-moves' l1
INNER JOIN 'learned-moves' l2
ON l2.Pokemon = l1.Pokemon
AND l2.'Version Group' = l1.'Version Group'
AND l1.'Version Group' = ?
AND l1.'Move' = ?
AND l2.'Move' = ?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.