LeetCode/Ritコード-Combine Two Table-MySQL

1777 ワード

質問する



に答える

  • Write a SQL query for a report that provides the following information for each person in the Person table, regardless if there is an address for each of those people
  • コード#コード#

    # leetcode, combine two tables, mysql
    SELECT P.FirstName, P.LastName, A.City, A.State
    FROM Person as P
    LEFT OUTER JOIN Address as A ON P.PersonId = A.PersonId

    結果




    ソース&ハーブ


    leetcode
    github