CommencerCommencer gratuitement

Using integer types

The Small Business Administration through its local Small Business Development Centers (SBDC) provides advising and technical support for entrepreneurs and small businesses. Given the importance of having an online presence, the SBA is starting an initiative to help small businesses with e-commerce website development. You have been brought in to develop a database to store data on these development efforts. In this exercise, you will have the opportunity to use your knowledge of integer data types in PostgreSQL for defining a table for SBDC clients.

Cet exercice fait partie du cours

Creating PostgreSQL Databases

Afficher le cours

Instructions

  • Complete the definition of the client table using the most appropriate integer type to support the range of possible data values for the column.

Exercice interactif pratique

Essayez cet exercice en complétant cet exemple de code.

-- Create the client table
___ ___ ___ (
	-- Unique identifier column
	id ___ PRIMARY KEY,
    -- Name of the company
    name VARCHAR(50),
	-- Specify a text data type for variable length urls
	site_url VARCHAR(50),
    -- Number of employees (max of 1500 for small business)
    num_employees ___,
    -- Number of customers
    num_customers ___
);
Modifier et exécuter le code