SQL: Write Commands
Learn how to write CRUD commands in SQL.
We'll cover the following...
Once we create a table, it’s empty. Let’s fill it with data. In this lesson, we’ll learn how to modify the database contents.
Insert record
To insert a record into a table, we need to specify which fields we provide and in which order. We use an INSERT INTO
command with a tuple of field names followed by tuples with record values. We can insert multiple records in a single command, for example:
Press + to interact
INSERT INTO plays(name, author_name, duration)VALUES("Hamlet", "William Shakespeare", 160),("Long Day's Journey Into Night", "Eugene O'Neill", 170)
We ...