TestingDocs.com
    Software Testing website
    • Automation
      • Selenium
      • JBehave Framework
    • Tutorials
      • MySQL Tutorials
      • Testlink
      • Maven
      • Git
    • IDEs
      • IntelliJ IDEA
      • Eclipse
    • Flowcharts
      • Flowgorithm
      • Raptor
    • About

    MySQL

    MySQL world Database Tables

    Overview

    In this tutorial, we will know about the MySQL world Database Tables. The world sample database has three tables:

    • Country
    • City
    • Countrylanguage

    We can use the following

    mysql> SHOW TABLES;
    +—————–+
    | Tables_in_world |
    +—————–+
    | city |
    | country |
    | countrylanguage |
    +—————–+
    3 rows in set (0.00 sec)

     

    Tables in world Database

    Country

    Country: Database table has information about countries of the world. To know the table structure and the columns we can use the following command.

    mysql> DESC Country;
    +—————-+—————————————————————————————+——+—–+———+——-+
    | Field | Type | Null | Key | Default | Extra |
    +—————-+—————————————————————————————+——+—–+———+——-+
    | Code | char(3) | NO | PRI | | |
    | Name | char(52) | NO | | | |
    | Continent | enum(‘Asia’,’Europe’,’North America’,’Africa’,’Oceania’,’Antarctica’,’South America’) | NO | | Asia | |
    | Region | char(26) | NO | | | |
    | SurfaceArea | decimal(10,2) | NO | | 0.00 | |
    | IndepYear | smallint | YES | | NULL | |
    | Population | int | NO | | 0 | |
    | LifeExpectancy | decimal(3,1) | YES | | NULL | |
    | GNP | decimal(10,2) | YES | | NULL | |
    | GNPOld | decimal(10,2) | YES | | NULL | |
    | LocalName | char(45) | NO | | | |
    | GovernmentForm | char(45) | NO | | | |
    | HeadOfState | char(60) | YES | | NULL | |
    | Capital | int | YES | | NULL | |
    | Code2 | char(2) | NO | | | |
    +—————-+—————————————————————————————+——+—–+———+——-+
    15 rows in set (0.00 sec)

    City

    City: Table has information about some cities in those countries.

    mysql> DESC City;
    +————-+———-+——+—–+———+—————-+
    | Field | Type | Null | Key | Default | Extra |
    +————-+———-+——+—–+———+—————-+
    | ID | int | NO | PRI | NULL | auto_increment |
    | Name | char(35) | NO | | | |
    | CountryCode | char(3) | NO | MUL | | |
    | District | char(20) | NO | | | |
    | Population | int | NO | | 0 | |
    +————-+———-+——+—–+———+—————-+
    5 rows in set (0.02 sec)

     

    City table in world MySQL database

    Countrylanguage

    Countrylanguage: Database table with languages spoken in each country.

    mysql> DESC CountryLanguage;
    +————-+—————+——+—–+———+——-+
    | Field | Type | Null | Key | Default | Extra |
    +————-+—————+——+—–+———+——-+
    | CountryCode | char(3) | NO | PRI | | |
    | Language | char(30) | NO | PRI | | |
    | IsOfficial | enum(‘T’,’F’) | NO | | F | |
    | Percentage | decimal(4,1) | NO | | 0.0 | |
    +————-+—————+——+—–+———+——-+
    4 rows in set (0.00 sec)

     

    CountryLanguage table in world MySQL

     

    —

    MySQL Tutorials

    MySQL Tutorials on this website:

    https://www.testingdocs.com/mysql-tutorials-for-beginners/

    For more information on MySQL Database:

    https://www.mysql.com/

    Related Posts

    Stellar Converter for Database Tool

    MySQL /

    Stellar Converter for Database

    Stellar MySQL Log Analyzer

    MySQL /

    Stellar Log Analyzer for MySQL

    Stellar Repair for MySQL

    MySQL /

    Stellar Repair for MySQL

    MySQL /

    How to secure your SQL Database: Tips and Tricks

    Stellar Converter for Database

    MySQL /

    Database Converter Tools

    ‹ Setup MySQL world Database› MySQL ENUM Datatype

    Recent Posts

    • ChatGPT Plans Free and PlusChatGPT Subscription Plans
    • Stellar Converter for Database ToolStellar Converter for Database
    • Stellar MySQL Log AnalyzerStellar Log Analyzer for MySQL
    • Stellar Repair for MySQLStellar Repair for MySQL
    • ChatGPT IntroductionChatGPT Capabilities
    • How to secure your SQL Database: Tips and Tricks
    • ChatGPT4 Conversational AI FeaturesChatGPT4 Conversational AI Features
    • Trends in Software EngineeringShaping the Future of Development: Exploring Key Trends in Software Engineering
    • Java PerformanceImproving Java Performance with Multithreading
    • QDrant Vector DatabaseOpen-source Vector Databases
    • Difference between PHP and JavaScript?
    • Bing AI Browser Web ContentBing Conversation Styles
    • ChatGPT PreviewChatGPT Introduction
    • Open Source AI Frameworks TensorFlowOpen Source AI Frameworks
    • Artificial Intelligence Tools

    Back to Top

    Links

    • Contact
    • Privacy Policy
    • Cookie Policy

    www.TestingDocs.com