Insert statement in SQL

4 minutes
Share the link to this page
Copied
  Completed
You need to have access to the item to view this lesson.
One-time Fee
$49.99
List Price:  $69.99
You save:  $20
€48.10
List Price:  €67.35
You save:  €19.24
£39.88
List Price:  £55.83
You save:  £15.95
CA$71.97
List Price:  CA$100.76
You save:  CA$28.79
A$80.16
List Price:  A$112.23
You save:  A$32.07
S$67.96
List Price:  S$95.14
You save:  S$27.18
HK$388.27
List Price:  HK$543.62
You save:  HK$155.34
CHF 45.02
List Price:  CHF 63.04
You save:  CHF 18.01
NOK kr569.59
List Price:  NOK kr797.48
You save:  NOK kr227.88
DKK kr358.90
List Price:  DKK kr502.49
You save:  DKK kr143.58
NZ$88.63
List Price:  NZ$124.10
You save:  NZ$35.46
د.إ183.61
List Price:  د.إ257.07
You save:  د.إ73.45
৳5,972.19
List Price:  ৳8,361.55
You save:  ৳2,389.35
₹4,258.89
List Price:  ₹5,962.79
You save:  ₹1,703.89
RM224.30
List Price:  RM314.04
You save:  RM89.74
₦77,378.02
List Price:  ₦108,335.42
You save:  ₦30,957.40
₨13,924.71
List Price:  ₨19,495.71
You save:  ₨5,570.99
฿1,707.62
List Price:  ฿2,390.81
You save:  ฿683.18
₺1,762.36
List Price:  ₺2,467.44
You save:  ₺705.08
B$310.08
List Price:  B$434.14
You save:  B$124.06
R926.14
List Price:  R1,296.68
You save:  R370.53
Лв94.05
List Price:  Лв131.68
You save:  Лв37.62
₩72,995.06
List Price:  ₩102,198.93
You save:  ₩29,203.86
₪183.24
List Price:  ₪256.56
You save:  ₪73.31
₱2,921.84
List Price:  ₱4,090.81
You save:  ₱1,168.96
¥7,853.11
List Price:  ¥10,994.99
You save:  ¥3,141.87
MX$1,006.35
List Price:  MX$1,408.98
You save:  MX$402.62
QR182.19
List Price:  QR255.09
You save:  QR72.89
P691.26
List Price:  P967.82
You save:  P276.56
KSh6,461.20
List Price:  KSh9,046.20
You save:  KSh2,585
E£2,544.49
List Price:  E£3,562.49
You save:  E£1,018
ብር6,361.91
List Price:  ብር8,907.19
You save:  ብር2,545.27
Kz45,590.88
List Price:  Kz63,830.88
You save:  Kz18,240
CLP$49,514.09
List Price:  CLP$69,323.69
You save:  CLP$19,809.60
CN¥364.84
List Price:  CN¥510.80
You save:  CN¥145.96
RD$3,032.23
List Price:  RD$4,245.36
You save:  RD$1,213.13
DA6,760.37
List Price:  DA9,465.07
You save:  DA2,704.69
FJ$115.98
List Price:  FJ$162.39
You save:  FJ$46.40
Q385.05
List Price:  Q539.11
You save:  Q154.05
GY$10,455.66
List Price:  GY$14,638.77
You save:  GY$4,183.10
ISK kr6,980.10
List Price:  ISK kr9,772.70
You save:  ISK kr2,792.60
DH502.81
List Price:  DH703.98
You save:  DH201.16
L922.32
List Price:  L1,291.33
You save:  L369
ден2,959.81
List Price:  ден4,143.97
You save:  ден1,184.16
MOP$399.96
List Price:  MOP$559.97
You save:  MOP$160.01
N$920.98
List Price:  N$1,289.45
You save:  N$368.46
C$1,839.04
List Price:  C$2,574.80
You save:  C$735.76
रु6,810.12
List Price:  रु9,534.71
You save:  रु2,724.59
S/186.41
List Price:  S/260.99
You save:  S/74.57
K202.74
List Price:  K283.85
You save:  K81.11
SAR187.78
List Price:  SAR262.91
You save:  SAR75.12
ZK1,383.10
List Price:  ZK1,936.45
You save:  ZK553.35
L239.36
List Price:  L335.12
You save:  L95.76
Kč1,209.95
List Price:  Kč1,694.03
You save:  Kč484.08
Ft19,835.61
List Price:  Ft27,771.44
You save:  Ft7,935.83
SEK kr553.09
List Price:  SEK kr774.38
You save:  SEK kr221.28
ARS$51,277.48
List Price:  ARS$71,792.58
You save:  ARS$20,515.09
Bs346.08
List Price:  Bs484.55
You save:  Bs138.46
COP$219,391.32
List Price:  COP$307,165.41
You save:  COP$87,774.08
₡25,377.51
List Price:  ₡35,530.54
You save:  ₡10,153.03
L1,269.45
List Price:  L1,777.33
You save:  L507.88
₲390,156.27
List Price:  ₲546,250
You save:  ₲156,093.73
$U2,225.52
List Price:  $U3,115.91
You save:  $U890.38
zł205.57
List Price:  zł287.82
You save:  zł82.24
Already have an account? Log In

Transcript

We are going to discuss about then sir. statement. So you know very well how can we insert the record? Now we are describing that how can you insert the record, we have two ways to insert the record. The first way, you can specify both the column names and the values to be inserted. How am saying insert into that means I'm saying please, I'm going to insert something.

And though then you have to specify the table name I'm saying, students. Now I'm saying the columns are two braces and now define your columns. I'm saying that this is the auto increment key so you don't need to define this word. I'm saying that s name So you know, this is the S name. And I'm saying this cop, comma separate, second column, comma, third follow. If you have more than four column, you can also specify the fourth column here with comma separated.

And the fifth column here, make sure fourth column. And here, fifth column. Okay, so now I'm saying the values these are the values. Now, you know very well that this is a string, this is a string string, so that's why I'm using the single This is if possible, if you have an integer value of floating value, you can also insert the integer and auto floating and why in history depend upon but for now, it's fine. Okay, now I'm seeing that the name is the john and the city is London. And now I'm saying the addresses are suppose x y Zed London.

Okay, now we have two ways you will way to execute the query right click Execute query or press the control button and hit the enter button. Control Enter. So now we have successfully inserted now I'm saying so in our results let static from students semicolon to terminate the statement control interface security. So now you know that you have successfully inserted the record. So this is the first way The second method is reserved The records, you can correctly specify the values how I'm saying insert into which table I'm seeing students values are your first variable here second variable there and third variable here. So it said it's probably demand upon you that how you creating the how you performing the Curie make sure you can this is a single table, then you know very well that you have only two columns for suppose if you have hundreds or thousands of columns, then you know about the columns, then what you need Yes, you must specify the columns and like this insert into students and the columns name like these columns name and the values like this, you must specify this so surely demand upon you.

So I think this is Now for the next section we are going to cover some other topics. So thank you for watching

Sign Up

Share

Share with friends, get 20% off
Invite your friends to LearnDesk learning marketplace. For each purchase they make, you get 20% off (upto $10) on your next purchase.