Learn how to create primary key columns to enforce uniqueness of inserted values and prevent duplicate rows.
- Constraints are ways for us to create rules…on which data can be inserted into our table…and which data should be rejected.…Similarly to data types, which restrict the type of data…that can be inserted into specific columns,…constraints can extend these capabilities further.…So let's see some examples of table constraints in action.…For example, if we create a new table,…such as create table demo_table2…and specify the first column with the name of column one,…of type, number, and precision of five,…we can specify that this is a primary key column.…
Primary key means that the database…will enforce uniqueness for values inserted…into this column.…So no duplicate values can exist.…So let's add another column,…column two with the varchar two data type,…giving it a precision of 20.…Let's create our demo table and insert some rows.…We'll start with the first row,…insert into_demo_table2 values, and let's specify one…as the value for column one,…with Hello as the value for column two.…
Let's execute the SQL statement…
Note: This training course is appropriate for beginning database developers with no prior experience with SQL or Oracle.
- Using Oracle SQL*Developer, the free development environment
- Selecting data from tables
- Filtering data
- Using functions to manipulate data
- Joining data from tables
- Creating tables
- Updating values
- Truncating data
- Grouping and ordering result sets
- Working with primary keys
- Checking constraints
Skill Level Beginner
Database Foundations: Core Conceptswith Adam Wilbert2h 14m Beginner
Database Foundations: Administrationwith Adam Wilbert1h 14m Beginner
Oracle 12c Database: Administrationwith David Yahalom3h 58m Beginner
1. Introduction to SQL
2. Preparing the Course Environment
Downloading the course VM2m 16s
3. Using Oracle SQL Developer
4. Basic SELECT Queries
5. String, Number, and Date Functions
6. Joining Table Data
7. Manipulating Data
8. Grouping Data
9. Advanced Topics
Next steps1m 33s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.