zoukankan      html  css  js  c++  java
  • mysql语句使用记录

    mysql>-- 笛卡尔积查询,无连接条件查询
    mysql>select a.*,b.* from customers a , orders b ;

    mysql>-- 内连接,查询符合条件的记录.
    mysql>select a.*,b.* from customers a , orders b where a.id = b.cid ;

    mysql>-- 左外连接,查询符合条件的记录.
    mysql>select a.*,b.* from customers a left outer join orders b on a.id = b.cid ;

    mysql>-- 右外连接,查询符合条件的记录.
    mysql>select a.*,b.* from customers a right outer join orders b on a.id = b.cid ;

    mysql>-- 全外连接,查询符合条件的记录(mysql不支持全外链接)
    mysql>select a.*,b.* from customers a full outer join orders b on a.id = b.cid ;

  • 相关阅读:
    Tarjan-割点&桥&双连通
    树状数组
    loli的搜索测试-5
    思维题
    生成树
    贪心
    loli的搜索测试-4
    树链剖分
    基于AHK的上课自动签到
    用列表实现栈
  • 原文地址:https://www.cnblogs.com/zyanrong/p/15632585.html
Copyright © 2011-2022 走看看