Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有两个表父子表,子表包含外键约束。
现在我想从连接到父表的子表中获取数据,并且还想从子表中获取父表 id 为空的记录。
select * from child c left join parent p on c.id = c.parent_id;