1 00:00:05,670 --> 00:00:06,330 Hey everyone. 2 00:00:06,770 --> 00:00:09,620 So in the last two videos you have seen that things are very large. 3 00:00:09,630 --> 00:00:11,130 The videos are very big. 4 00:00:11,130 --> 00:00:16,530 But now you will notice that how easy do things up because until then we do not have set up the tanks. 5 00:00:16,550 --> 00:00:18,310 Now everything is already setup. 6 00:00:19,090 --> 00:00:24,660 So now let's move with inserting the data now in this video we will learn that how you can insert the 7 00:00:24,660 --> 00:00:26,200 data in tables. 8 00:00:26,250 --> 00:00:34,030 So for that one again inserting data come on will be same just the execution is different. 9 00:00:34,050 --> 00:00:37,860 So at that point you are creating a table set creating a draw. 10 00:00:37,860 --> 00:00:40,890 Now you're going to actually insert that some data in that. 11 00:00:41,610 --> 00:00:46,800 So while working on different databases you need to change the connection while working in the same 12 00:00:46,800 --> 00:00:47,550 database. 13 00:00:47,580 --> 00:00:49,260 You need to change the execution Come on. 14 00:00:50,580 --> 00:00:53,780 So first I'm showing without a function then we will move with function. 15 00:00:54,330 --> 00:00:58,530 So just go to execute and it came out of a scholar. 16 00:00:58,530 --> 00:01:01,160 Very simple just what you want here. 17 00:01:01,230 --> 00:01:02,490 Insert some data. 18 00:01:02,700 --> 00:01:09,030 So insert and then in two in which database you won't see data. 19 00:01:09,090 --> 00:01:13,870 We have data after that when you just need two positive values. 20 00:01:14,630 --> 00:01:23,030 So here we have values fences in that one according to the columns positive value serial number of Sandy 21 00:01:23,060 --> 00:01:27,280 five name buggy. 22 00:01:27,590 --> 00:01:36,770 And that will be in quotes because it's actually a name and double code single after that one marks. 23 00:01:36,800 --> 00:01:41,060 So a hundred that will be a real save this one. 24 00:01:42,110 --> 00:01:46,120 And then we had the terminal right and three. 25 00:01:46,140 --> 00:01:46,410 No. 26 00:01:46,440 --> 00:01:51,850 Sorry not Python 3 Python 3. 27 00:01:51,920 --> 00:01:54,830 And then D.B. No. 28 00:01:54,880 --> 00:02:02,520 B Why had we done David go this one successful so we'll not get any output here or here or anywhere 29 00:02:02,550 --> 00:02:06,520 else as you just get the data and like database. 30 00:02:06,710 --> 00:02:11,940 If I open this one my open read text added default. 31 00:02:12,080 --> 00:02:15,410 We got something non understandable. 32 00:02:15,470 --> 00:02:22,930 We have added bogey that is maybe this one so will not understand what is actually written here. 33 00:02:23,930 --> 00:02:27,750 But we will get this thing that how you can check the data on that it is stored or not. 34 00:02:27,890 --> 00:02:32,030 When we we learn about the view come on in the next video. 35 00:02:32,030 --> 00:02:37,180 Now just add this one to a function so define insert 36 00:02:40,170 --> 00:02:47,810 busted dots do and all this come on there because again you do not need to again and again write these 37 00:02:47,810 --> 00:02:49,800 things after that open. 38 00:02:50,180 --> 00:02:55,850 This is a function so that will be user input commands so of values so pass parameters there for us 39 00:02:55,850 --> 00:02:59,920 to unsaved rule number denoting a number. 40 00:03:00,440 --> 00:03:07,140 Then we have the name and then we have a will Max. 41 00:03:07,380 --> 00:03:16,440 So Mark for Lippman and I'm taking a name full name because these same column named data and these sometimes 42 00:03:16,440 --> 00:03:24,030 they get added Not every time but generally in my case they sometimes made errors. 43 00:03:24,180 --> 00:03:27,530 So I'm using a different name from the column names. 44 00:03:27,640 --> 00:03:35,130 So here insert into data values and then now you do not need to pass these values here or by using the 45 00:03:35,130 --> 00:03:39,150 percentage as in defining these values after this one. 46 00:03:40,140 --> 00:03:42,440 What do you need to do here. 47 00:03:42,590 --> 00:03:46,720 Boss question marks as number of parameters you have. 48 00:03:46,740 --> 00:03:50,250 So again caution marks and not be focused with that one. 49 00:03:50,730 --> 00:03:58,740 So prosecution marks here and after the courts using a comma not here after defenses and before the 50 00:03:58,740 --> 00:04:06,050 court after this command is finished with this court's here possible barometer read labels that is drawl. 51 00:04:06,300 --> 00:04:07,980 Then we have a name. 52 00:04:08,220 --> 00:04:10,830 Then we have Mark just simplistic. 53 00:04:11,600 --> 00:04:25,560 And now insert and positive value serial number for name say this time bug hero and or number so remarks 54 00:04:25,620 --> 00:04:29,510 again under because the bugs are an intelligent safe. 55 00:04:29,520 --> 00:04:36,220 This one tried to run here but we go to the Adam function text at most two arguments for. 56 00:04:36,240 --> 00:04:49,080 Given what we have done here I have buzzed three arguments here I believe Edwin try this one again maybe 57 00:04:49,120 --> 00:04:56,730 that's so again getting error in that one. 58 00:04:56,730 --> 00:04:57,690 Let me check that. 59 00:04:57,690 --> 00:05:02,370 What's the mistake we have done do no name Mark. 60 00:05:02,370 --> 00:05:02,710 Correct. 61 00:05:02,710 --> 00:05:05,950 We did one for no name and mark. 62 00:05:06,300 --> 00:05:11,860 So what's the thing happen here. 63 00:05:14,470 --> 00:05:21,740 I need to pass the fences because the variables are more than one here. 64 00:05:22,130 --> 00:05:23,990 So I require robust pencils there. 65 00:05:24,920 --> 00:05:25,970 So save this one. 66 00:05:26,480 --> 00:05:29,030 And now let me do that again. 67 00:05:29,040 --> 00:05:30,010 David go with that one. 68 00:05:30,230 --> 00:05:31,550 So that is successful No. 69 00:05:32,450 --> 00:05:39,720 So here you also need to pass the bear panties because I do not focus that down are more than one variables 70 00:05:39,720 --> 00:05:40,630 here. 71 00:05:40,650 --> 00:05:45,060 So while we are working on more than one we just generally pass them in form of cool pulse. 72 00:05:45,060 --> 00:05:46,080 If you remember. 73 00:05:46,500 --> 00:05:49,300 So this one needs to be passed into tuples. 74 00:05:49,470 --> 00:05:56,160 Now that is also added in that one and if guy again try to check in this one the language that would 75 00:05:56,170 --> 00:06:02,350 inaudible to understand here we have bigger Hazel but are demoed. 76 00:06:02,370 --> 00:06:07,370 So they are adding a day by themself so that one is buggy. 77 00:06:07,860 --> 00:06:08,290 No. 78 00:06:08,550 --> 00:06:12,330 Then with inserting the data in this one. 79 00:06:12,350 --> 00:06:16,920 Now I'm going to move with that one baby too. 80 00:06:16,980 --> 00:06:20,880 So for that one everything will be again same. 81 00:06:20,880 --> 00:06:29,090 Just copy this one pasted tail and just copy this one from here. 82 00:06:30,720 --> 00:06:33,320 And replace this execute Come on. 83 00:06:34,610 --> 00:06:37,240 Also this one function name 84 00:06:45,990 --> 00:06:51,790 get company copied let me just this one and replace it. 85 00:06:52,190 --> 00:06:53,790 So there we go with that one. 86 00:06:53,930 --> 00:07:05,420 Now the command for inserting something will be again same basic detail changed almost a one and just 87 00:07:05,470 --> 00:07:09,090 bugger marks will be same hundred. 88 00:07:09,720 --> 00:07:16,710 Now one more thing you need to do here this time in case of these kinds of databases that one is just 89 00:07:16,710 --> 00:07:19,860 for local you did not require question marks here. 90 00:07:19,980 --> 00:07:21,870 What do you need to pass these percentages. 91 00:07:22,950 --> 00:07:26,220 So percentages percentages and percentages. 92 00:07:26,220 --> 00:07:29,710 So again full shoot focus on the question marks and decode. 93 00:07:30,120 --> 00:07:38,830 Now if you save this one and done it here a little discipline successful and now when you open your 94 00:07:38,830 --> 00:07:43,870 database and go to the tables they maybe have different columns. 95 00:07:44,170 --> 00:07:49,510 Now to see that data whether the data is added here or not just go to this school. 96 00:07:49,990 --> 00:07:52,830 So not this one these tools where they do. 97 00:07:53,360 --> 00:07:59,910 There you can write the commands that you are writing in your atom also to add or edit the things. 98 00:08:00,020 --> 00:08:09,670 So for selecting the data to view we just do select star Stallman everything from and we are working 99 00:08:09,670 --> 00:08:10,870 with data also data. 100 00:08:11,830 --> 00:08:12,940 So here we have the data. 101 00:08:13,730 --> 00:08:16,250 So select start from data now click on drone. 102 00:08:16,270 --> 00:08:19,930 Here we have this one from and there we go the output. 103 00:08:19,960 --> 00:08:23,880 So here we have two inputs Bulger and Bulger with hundreds and hundreds. 104 00:08:23,890 --> 00:08:28,190 It seemed all number maybe I have executed twice that one. 105 00:08:28,240 --> 00:08:31,140 So this is how you can have data here. 106 00:08:31,270 --> 00:08:43,660 If I add one more data to that one say rule number two and this one say super and Max will be dead save 107 00:08:43,660 --> 00:08:49,310 this one go to terminal run that again and now get two data. 108 00:08:50,020 --> 00:08:51,490 So here we have our data again. 109 00:08:51,970 --> 00:08:55,750 If you run this one again we get this super also. 110 00:08:55,780 --> 00:09:02,230 So here now super is added indictment and this data is also readable instead of deadpan. 111 00:09:02,290 --> 00:09:05,200 So this is about that how we can insert data in our database. 112 00:09:05,200 --> 00:09:13,650 You can even add to any paragraph also informal string just pass any paragraph in between that will 113 00:09:13,650 --> 00:09:15,010 be added there. 114 00:09:15,030 --> 00:09:20,210 So this is about inserting data will continue about realizing that data in the next video. 115 00:09:20,250 --> 00:09:21,150 So thanks for watching. 116 00:09:21,150 --> 00:09:21,740 See you there.