Joining Data in SQL
  • AI Chat
  • Code
  • Report
  • Beta
    Spinner

    Joining Data with SQL

    Here you can access every table used in the course. To access each table, you will need to specify the world schema in your queries (e.g., world.countries for the countries table, and world.languages for the languages table).

    Take Notes

    Add notes about the concepts you've learned and SQL cells with queries you want to keep.

    Add your notes here

    Unknown integration
    DataFrameavailable as
    world_info
    variable
    -- Add your own queries here
    SELECT *
    FROM world.languages 
    LIMIT 5
    This query is taking long to finish...Consider adding a LIMIT clause or switching to Query mode to preview the result.

    Explore Datasets

    Use the tables to explore the data and practice your skills!

    • Combine the states and countries tables into one table.
      • The final result should have a name column, a continent column, and an indep_year column. Use the local_name column from the countries table as the name.
      • The final result should not include duplicate rows.
    • Return the country_code, fertility_rate, and life_expectancy from the populations table.
      • Only return countries which are categorized as 'large' in the countries_plus table.
      • Filter for data from 2015.
    • Return the local_name aliased as country_name, continent, surface_area, the number of official languages, gdp_percapita, and unemployment_rate from the countries, economies, and languages tables.
      • Ensure that all records from the countries table are preserved, regardless whether a match is present in the economies or languages tables.
      • Only include economy data from 2015.
      • Sort your results by gdp_percapita in descending order.
    Unknown integration
    DataFrameavailable as
    df
    variable
    This query is taking long to finish...Consider adding a LIMIT clause or switching to Query mode to preview the result.