14 videos 📅 2024-12-10 08:00:00 Asia/Brunei
12:04
2024-12-10 13:02:57
6:53
2024-12-10 13:18:23
3:49:58
2024-12-10 13:29:28
9:46
2024-12-11 07:45:15
5:40:21
2024-12-11 09:08:49
5:22
2024-12-11 17:54:14
1:42
2024-12-11 18:04:44
2:05:58
2024-12-12 09:00:08
1:01:06
2024-12-12 12:26:38
3:59
2024-12-12 15:09:36
51:24
2024-12-12 15:24:00
8:06
2024-12-12 16:34:52
2:35
2024-12-12 17:17:14
3:05
2024-12-12 17:26:54

Visit the ORACLE PL/SQL Fundamentals course recordings page

                WEBVTT

00:00:08.000 --> 00:00:16.700
yung sa iyo sir joseph ano pang error mo ah yeah remove the space yeah okay

00:00:24.040 --> 00:00:34.180
sir jerry okay na sir jerry you can clear that na tapos you can paste yung declare begin and ganun yan save that

00:00:34.380 --> 00:00:49.380
can you clear your ano your screen using the pencil the eraser yeah the lugs i mean on the script output line six

00:00:49.920 --> 00:01:02.380
one two three four five six first name salary ah yung space mo po dun sa employees that space first name sorry i put first name yeah

00:01:02.720 --> 00:01:06.380
dun sa line two mo po yung employees that

00:01:10.400 --> 00:01:13.940
talaga hey Miguel sir Miguel okay

00:01:15.660 --> 00:01:17.560
I'm looking at sir Miguel

00:01:19.880 --> 00:01:20.600
okay

00:01:22.060 --> 00:01:23.700
okay lang sir

00:01:23.700 --> 00:01:28.700
dun sa ad mo sir Miguel

00:01:29.360 --> 00:01:38.620
lagay ka ng new line dun sa first line mo yung second ad mo

00:01:38.620 --> 00:01:39.020
yeah

00:01:40.360 --> 00:01:42.540
the second ad

00:01:42.540 --> 00:01:44.160
pero pwede rin naman pala

00:01:44.160 --> 00:01:46.020
second ad enter

00:01:46.020 --> 00:01:48.840
tapos barihin mo yung kama

00:01:48.840 --> 00:01:50.340
tapos i-run mo siyang

00:01:50.340 --> 00:01:52.460
run mo yung script na yan

00:01:52.460 --> 00:01:55.020
okay so na-alter na yung ano

00:01:55.020 --> 00:01:57.260
na-alter na so you can remove it na

00:01:57.260 --> 00:01:58.900
as you can see dun sa script output

00:01:58.900 --> 00:02:00.380
na-alter na siya

00:02:00.380 --> 00:02:02.440
so we can remove

00:02:02.440 --> 00:02:05.060
hanggang dun sa ad salary

00:02:05.060 --> 00:02:07.560
pero you can you can verify kung

00:02:07.560 --> 00:02:09.060
ito type mo describe employees

00:02:10.080 --> 00:02:12.000
para ma verify mo na

00:02:15.200 --> 00:02:15.760
okay

00:02:15.760 --> 00:02:17.400
yan employees

00:02:17.400 --> 00:02:19.500
can you run that script

00:02:19.500 --> 00:02:21.360
select that run

00:02:21.360 --> 00:02:23.120
so may first name yung salary

00:02:23.120 --> 00:02:24.860
hindi nasama no

00:02:24.860 --> 00:02:27.880
so add natin yung salary so remove na yung ad first name

00:02:27.880 --> 00:02:30.020
palita mo na siya ng ad salary

00:02:30.020 --> 00:02:31.220
kasi kailangan natin siya

00:02:31.220 --> 00:02:32.880
later on sa

00:02:32.880 --> 00:02:34.880
second function natin

00:02:35.440 --> 00:02:37.020
si ma'am Christine okay ka na

00:02:37.020 --> 00:02:39.140
ma'am Christine okay

00:02:39.140 --> 00:02:40.780
okay so may first salary na

00:02:40.780 --> 00:02:42.740
so yung may first name and salary na

00:02:42.740 --> 00:02:44.880
you can try the code na

00:02:46.040 --> 00:02:47.220
first name salary

00:02:47.220 --> 00:02:49.540
okay looks good sir Jerry

00:02:50.980 --> 00:02:53.000
is this your first time

00:02:53.000 --> 00:02:55.040
to use Oracle SQL developer

00:02:56.940 --> 00:02:58.620
okay now I'm just wondering

00:03:01.020 --> 00:03:01.960
okay

00:03:01.960 --> 00:03:03.440
lumabas na yung output sa

00:03:03.440 --> 00:03:04.000
you sir

00:03:04.620 --> 00:03:06.500
sir Jerry

00:03:06.500 --> 00:03:07.680
may error ka pa din

00:03:07.680 --> 00:03:09.640
line 6

00:03:10.600 --> 00:03:12.280
oh okay okay

00:03:12.280 --> 00:03:14.280
so yeah let's correct that

00:03:14.280 --> 00:03:16.120
good eye

00:03:19.220 --> 00:03:20.780
EMP ID

00:03:20.780 --> 00:03:21.960
yeah

00:03:30.520 --> 00:03:31.220
tapos yung

00:03:31.220 --> 00:03:32.460
ano yung sa line 6 yung

00:03:32.460 --> 00:03:34.800
or mo po yung dalawang

00:03:34.800 --> 00:03:35.920
bar

00:03:36.620 --> 00:03:38.700
pagdikitin mo po yan yan yan

00:03:38.700 --> 00:03:40.400
yung dalawang bar yan sa gitna

00:03:40.400 --> 00:03:42.720
yan yan try to run it

00:03:42.720 --> 00:03:44.620
no data pound so EMP ID

00:03:45.320 --> 00:03:46.580
okay verify natin

00:03:46.580 --> 00:03:48.220
may 101 ba ang alam ko

00:03:48.220 --> 00:03:50.620
one and two lang ane so put one

00:03:53.740 --> 00:03:54.480
dun sa

00:03:54.480 --> 00:03:56.320
101 change the 101 to

00:03:56.320 --> 00:03:57.600
101

00:03:59.200 --> 00:04:02.320
try to run that

00:04:10.320 --> 00:04:12.000
sir Jerry naran mo na po ayun na

00:04:12.000 --> 00:04:14.180
completed na ngayon

00:04:14.180 --> 00:04:16.240
di ba hindi lumalabas

00:04:16.240 --> 00:04:18.580
kasi kalangan natin iset

00:04:18.580 --> 00:04:19.980
server output

00:04:19.980 --> 00:04:20.960
on

00:04:22.320 --> 00:04:23.800
eto po yung command

00:04:24.960 --> 00:04:27.980
ipipase ko doon

00:04:27.980 --> 00:04:29.500
set server

00:04:29.500 --> 00:04:32.020
output on

00:04:32.020 --> 00:04:34.140
sa taas po ng declare mo

00:04:34.140 --> 00:04:35.080
sir Jerry

00:04:35.800 --> 00:04:38.180
type mo po set server output on

00:04:38.180 --> 00:04:39.820
para makita natin na lalabas yung

00:04:39.820 --> 00:04:41.920
employee name tsaka employee salary sa taas po

00:04:41.920 --> 00:04:44.160
sa taas po ng declare

00:04:44.160 --> 00:04:45.180
yan

00:04:46.100 --> 00:04:46.780
set

00:04:48.180 --> 00:04:48.860
space

00:04:50.100 --> 00:04:51.460
server output

00:04:51.460 --> 00:04:53.840
space on

00:04:53.840 --> 00:04:55.040
tapos

00:04:55.040 --> 00:04:57.280
i-exercise po natin na

00:04:57.280 --> 00:04:58.560
uppercase

00:04:59.460 --> 00:05:01.180
yan perfect

00:05:01.180 --> 00:05:02.680
then on

00:05:02.680 --> 00:05:04.180
lagyan niyo po ng

00:05:05.460 --> 00:05:06.540
semicolon

00:05:06.540 --> 00:05:08.160
after na on

00:05:08.160 --> 00:05:10.700
to end na single

00:05:11.460 --> 00:05:13.600
na isang

00:05:13.600 --> 00:05:15.860
execution siya

00:05:15.860 --> 00:05:17.320
mabagal po ba yung server

00:05:23.260 --> 00:05:23.460
ahem

00:05:25.240 --> 00:05:25.460
yun

00:05:26.160 --> 00:05:27.700
nakita mo na may employee

00:05:27.700 --> 00:05:29.420
name and employee salary na

00:05:29.420 --> 00:05:31.520
pero walang laman no

00:05:33.120 --> 00:05:35.620
you know why

00:05:37.160 --> 00:05:37.460
kasi

00:05:38.080 --> 00:05:39.480
kasi yung

00:05:39.480 --> 00:05:40.220
yeah

00:05:41.460 --> 00:05:42.680
kasi din declare natin

00:05:42.680 --> 00:05:45.460
nakita mo yung declare capital V

00:05:46.260 --> 00:05:46.900
pero

00:05:46.900 --> 00:05:49.760
nung sinun natin small v

00:05:49.760 --> 00:05:51.900
addis sa tuto tayo mag

00:05:51.900 --> 00:05:52.540
debug

00:05:53.720 --> 00:05:55.760
difference we declare sa taas

00:05:55.760 --> 00:05:57.740
V capital

00:05:57.740 --> 00:05:59.500
tapos nag select tayo

00:05:59.500 --> 00:06:01.760
but nung sinun show na natin small v

00:06:09.460 --> 00:06:10.720
wala pa rin so

00:06:10.720 --> 00:06:13.840
B EMP name

00:06:15.780 --> 00:06:16.900
one moment

00:06:19.760 --> 00:06:20.880
one moment

00:06:20.880 --> 00:06:23.300
one moment

00:06:23.300 --> 00:06:25.300
one moment

00:06:47.240 --> 00:06:49.600
select first name

00:06:49.600 --> 00:06:51.300
salary B EMP

00:06:51.600 --> 00:06:52.640
B EMP name

00:06:53.660 --> 00:06:54.460
ah

00:06:55.900 --> 00:06:57.420
alisin na natin ay

00:06:57.420 --> 00:06:59.640
wait lang so from employees

00:06:59.640 --> 00:07:01.520
first name salary

00:07:01.520 --> 00:07:03.240
B EMP name

00:07:03.240 --> 00:07:05.600
employee name first name

00:07:08.140 --> 00:07:09.840
yun lumabas na yung name mo

00:07:09.840 --> 00:07:11.380
salary na lang

00:07:11.380 --> 00:07:12.560
one moment

00:07:32.280 --> 00:07:33.280
for

00:07:33.280 --> 00:07:33.620
that

00:07:33.620 --> 00:07:35.220
and back

00:07:35.220 --> 00:07:37.160
nice

00:07:38.520 --> 00:07:39.520
I

00:07:39.520 --> 00:07:39.760
see

00:07:39.760 --> 00:07:40.100
sir

00:07:40.100 --> 00:07:40.920
Jeremy

00:07:40.920 --> 00:07:42.180
figure that

00:07:42.180 --> 00:07:42.920
out

00:07:42.920 --> 00:07:44.680
I'm looking at

00:07:44.680 --> 00:07:45.600
your screen right now

00:07:47.120 --> 00:07:47.600
okay

00:07:48.980 --> 00:07:51.700
Sir Miguel, can you run the script?

00:07:55.620 --> 00:07:56.680
How about you, Mam Tin?

00:08:11.320 --> 00:08:14.440
Okay, I think you grasped the idea.

00:08:15.800 --> 00:08:19.560
So let's continue kasi marami pa tayong slides.

00:08:20.220 --> 00:08:24.760
Okay, so let's go back to our screen.

00:08:28.500 --> 00:08:34.600
So siguro yung try naman natin pa na pag no data found.

00:08:36.040 --> 00:08:40.260
So we will use no data found or too many rows.

00:08:43.400 --> 00:08:52.840
Okay, so now let's talk about handle scenarios where a query might return either no data or too much data.

00:08:53.280 --> 00:09:00.440
This is crucial when working with PLSQL because we often reply on queries that expect a specific result.

00:09:01.400 --> 00:09:05.040
And handling exceptions ensure our code remains robust and reliable.

00:09:05.040 --> 00:09:11.880
So in this example, we declare a variable BMP name to store the first name of an employee.

00:09:11.960 --> 00:09:19.500
Then we attempt to retrieve the first name from the employee's table for a specific employee ID, in this case 999.

00:09:20.320 --> 00:09:27.580
However, what happens if the employee's ID with 999 does not exist or if due to an error, multiple rows are returned.

00:09:28.140 --> 00:09:30.440
This is where exception handling comes into play.

00:09:30.440 --> 00:09:35.720
So yung tatandahan natin dito yung no data found saka too many rows.

00:09:36.880 --> 00:09:38.440
So can you try this data?

00:09:40.580 --> 00:09:49.420
Gamitin natin when no data found then DBMS output line no employee found with a given ID.

00:10:15.480 --> 00:10:20.440
One moment, let me paste that.

00:10:23.180 --> 00:10:27.380
So declare, we select.

00:11:19.560 --> 00:11:19.980
So now let's see what happens if the employee's ID with 999 does not exist or if due to an error, multiple rows are returned.

00:11:19.980 --> 00:11:20.140
So now let's see what happens if the employee's ID with 999 does not exist or if due to an error, multiple rows are returned.

00:11:44.360 --> 00:11:46.560
Are you looking at my screen right now?

00:11:53.300 --> 00:12:11.140
So I put it in our Google Sheet.

00:12:20.140 --> 00:12:21.600
So let's continue.

00:12:22.720 --> 00:12:26.460
So na get siyo na po yung no data found tapos too many rows.

00:12:27.280 --> 00:12:28.660
Yes, ma'am Christine?

00:12:28.780 --> 00:12:29.960
Sir, wait na po.

00:12:30.840 --> 00:12:32.000
Sige po yung one.

00:12:32.520 --> 00:12:33.220
Okay po.

00:12:40.740 --> 00:12:42.900
Mas maganda pag tinatry, no?

00:12:42.900 --> 00:12:44.160
okay

00:12:46.160 --> 00:12:46.880
nice

00:12:49.980 --> 00:12:50.900
sir joseph

00:12:51.420 --> 00:12:52.700
or everyone

00:12:52.700 --> 00:12:54.720
para matari natin yung too many rows

00:12:54.720 --> 00:12:55.660
output

00:12:55.660 --> 00:12:58.780
pwede tayo mag add

00:12:58.780 --> 00:13:00.700
pwede tayo mag add ng more records

00:13:00.700 --> 00:13:02.100
din sa employee

00:13:02.860 --> 00:13:04.380
para matari natin

00:13:04.380 --> 00:13:06.740
pero ganoon na may logic kung

00:13:06.740 --> 00:13:09.380
more than one yung

00:13:09.380 --> 00:13:10.420
na query nya

00:13:10.420 --> 00:13:11.780
din siya sa too many rows

00:13:11.780 --> 00:13:13.220
so let's move

00:13:14.580 --> 00:13:16.420
self explanatory naman

00:13:17.760 --> 00:13:18.400
so let's

00:13:18.400 --> 00:13:19.320
try this cursor

00:13:19.320 --> 00:13:21.140
this is more interesting

00:13:22.240 --> 00:13:23.080
oops

00:13:23.080 --> 00:13:24.860
i'll paste the code

00:13:24.860 --> 00:13:27.360
so try to copy it

00:13:28.440 --> 00:13:29.280
declare

00:13:30.420 --> 00:13:30.900
cursor

00:13:30.900 --> 00:13:32.260
select

00:13:34.420 --> 00:13:35.220
then begin

00:13:35.220 --> 00:13:37.100
then we open the cursor

00:13:37.100 --> 00:13:40.140
now we will try to do loop

00:13:40.140 --> 00:13:41.180
then

00:13:41.180 --> 00:13:42.700
we will fetch the

00:13:42.700 --> 00:13:44.600
cursor into B EMP

00:13:44.600 --> 00:13:47.720
salary then we exit the loop

00:13:47.720 --> 00:13:49.380
when EMP

00:13:49.380 --> 00:13:50.220
cursor

00:13:51.340 --> 00:13:53.580
is not found

00:13:57.100 --> 00:13:58.600
then we output it

00:13:58.600 --> 00:14:00.140
dbms output

00:14:01.100 --> 00:14:03.000
then we end the loop

00:14:03.000 --> 00:14:05.200
then we

00:14:05.200 --> 00:14:06.660
close the EMP cursor

00:14:08.540 --> 00:14:10.100
then end

00:14:10.100 --> 00:14:11.260
so can you try

00:14:11.260 --> 00:14:13.200
this on your end?

00:14:15.840 --> 00:14:17.200
cursor, EMP cursor

00:14:17.200 --> 00:14:18.740
select employee id

00:14:18.740 --> 00:14:21.520
since EMP id

00:14:21.520 --> 00:14:23.320
ang gamit natin

00:14:23.320 --> 00:14:25.020
first name salary from

00:14:25.020 --> 00:14:26.400
employees per

00:14:26.400 --> 00:14:28.500
kasi wala tayo department id no

00:14:28.500 --> 00:14:30.900
so mag add na lang tayo ng department id

00:14:30.900 --> 00:14:33.240
let me create

00:14:33.240 --> 00:14:35.240
department id

00:14:43.240 --> 00:14:44.680
so let's try to create

00:14:45.240 --> 00:14:46.800
department

00:14:46.800 --> 00:14:49.400
let's try to create a department

00:14:49.400 --> 00:14:50.040
table

00:14:51.240 --> 00:14:52.180
then

00:14:53.240 --> 00:14:55.380
let's insert

00:14:55.380 --> 00:14:56.560
data

00:14:57.240 --> 00:14:59.080
so create

00:14:59.080 --> 00:15:00.240
department

00:15:00.240 --> 00:15:02.220
table

00:15:02.220 --> 00:15:04.240
so i am

00:15:04.240 --> 00:15:05.660
pasting the script

00:15:06.900 --> 00:15:08.400
to the

00:15:08.400 --> 00:15:09.820
google sheet

00:15:09.820 --> 00:15:12.220
so we create a department table

00:15:12.220 --> 00:15:14.000
with

00:15:14.000 --> 00:15:15.940
department id

00:15:17.040 --> 00:15:18.600
and department

00:15:18.600 --> 00:15:19.060
name

00:15:19.060 --> 00:15:21.580
then we insert data

00:15:22.240 --> 00:15:24.400
on the department

00:15:24.400 --> 00:15:26.100
department id and department name

00:15:26.100 --> 00:15:28.340
then i think let's insert

00:15:28.340 --> 00:15:30.680
more data to

00:15:30.680 --> 00:15:31.920
employee id

00:15:34.340 --> 00:15:36.820
that we can use later on

00:15:36.820 --> 00:15:38.340
1,2,3

00:15:38.340 --> 00:15:39.980
let's say 4

00:15:39.980 --> 00:15:42.340
5,6

00:15:50.340 --> 00:15:52.340
first name salary department id

00:15:53.640 --> 00:15:54.720
values

00:15:56.260 --> 00:15:57.440
so we have

00:15:57.440 --> 00:15:58.720
to alter the table

00:16:02.140 --> 00:16:03.000
so that

00:16:03.000 --> 00:16:04.720
it will add the department

00:16:04.720 --> 00:16:05.520
id

00:16:09.860 --> 00:16:11.100
let me create

00:16:11.100 --> 00:16:12.260
jones script

00:16:13.200 --> 00:16:14.720
i am pasting it now

00:16:15.640 --> 00:16:16.720
in google sheet

00:16:18.720 --> 00:16:20.880
so after creating a table

00:16:20.880 --> 00:16:23.020
we have to alter

00:16:23.020 --> 00:16:24.740
since we already have employees table

00:16:24.740 --> 00:16:25.880
we have to alter

00:16:25.880 --> 00:16:28.860
the employees to add department id

00:16:42.600 --> 00:16:43.260
so

00:16:44.960 --> 00:16:46.780
practice natin yung pag add

00:16:46.780 --> 00:16:47.780
constraint

00:16:47.780 --> 00:16:50.900
so pwede tayo mag i-alter natin

00:16:50.900 --> 00:16:51.660
yung table

00:16:51.660 --> 00:16:54.240
na magadd yung constraint

00:16:54.900 --> 00:16:57.280
na yung foreign key ng department

00:16:57.280 --> 00:16:59.500
which is department id

00:16:59.500 --> 00:17:00.900
reference din sa department

00:17:01.860 --> 00:17:02.680
pwede yung f

00:17:02.680 --> 00:17:05.280
siguro para sa department id

00:17:05.280 --> 00:17:07.080
nalang din

00:17:07.080 --> 00:17:08.840
one moment

00:17:09.840 --> 00:17:10.760
or

00:17:27.600 --> 00:17:29.000
m

00:17:29.000 --> 00:17:29.420
m

00:17:29.420 --> 00:17:30.440
m

00:17:30.440 --> 00:17:32.800
m

00:17:32.800 --> 00:17:35.440
m

00:17:44.180 --> 00:17:45.580
m

00:17:49.480 --> 00:17:50.880
m

00:18:35.760 --> 00:18:37.160
Okay.

00:19:22.780 --> 00:19:24.560
How are you ma'am Christine?

00:19:26.840 --> 00:19:26.880
Sir?

00:19:27.720 --> 00:19:28.360
Yeah?

00:19:29.200 --> 00:19:29.720
Ano po dito?

00:19:29.940 --> 00:19:32.640
Ano po dito?

00:19:32.640 --> 00:19:34.700
Hindi makapag-copy paste from

00:19:34.700 --> 00:19:36.820
local to the desktop

00:19:36.820 --> 00:19:37.640
gawa no?

00:19:38.420 --> 00:19:39.820
Masin na Firefox po yung gawin.

00:19:42.000 --> 00:19:43.340
Try ko mag-anaw.

00:19:46.280 --> 00:19:46.960
Hmmmm

00:19:50.060 --> 00:19:53.300
Set server output on

00:19:53.300 --> 00:19:53.740
Set server output on

00:19:53.740 --> 00:19:54.320
Set server output on

00:19:54.320 --> 00:19:54.960
Declare

00:19:55.640 --> 00:19:56.820
Declare

00:19:56.820 --> 00:19:58.960
Sir Ray?

00:20:00.040 --> 00:20:00.800
Sir?

00:20:00.800 --> 00:20:02.440
Ok ka na no?

00:20:02.680 --> 00:20:04.040
I mean nakamove on ka na yun sa

00:20:04.040 --> 00:20:05.000
I mean nakamove on ka na yun sa NoDataFound

00:20:05.000 --> 00:20:06.100
NoDataFound

00:20:09.440 --> 00:20:10.520
Ok

00:20:10.520 --> 00:20:10.620
Ok

00:20:10.620 --> 00:20:11.900
Ok

00:20:14.720 --> 00:20:16.620
Kailangan mo na yung first step

00:20:16.620 --> 00:20:18.120
Kailangan mo na yung first step

00:20:18.120 --> 00:20:20.980
Tin, kailangan mo na mag-alter ng table

00:20:20.980 --> 00:20:22.620
Bago ka mag-constraint

00:20:23.340 --> 00:20:24.280
Bago ka mag-constraint

00:20:24.280 --> 00:20:26.160
Bago ka mag-altern ng department

00:20:26.980 --> 00:20:27.900
Bago ka mag-altern ng department

00:20:27.900 --> 00:20:30.460
Na sa yung code na sa

00:20:30.460 --> 00:20:32.120
Google sheet din

00:20:32.120 --> 00:20:34.360
So, alter table employees, add constraint

00:20:34.360 --> 00:20:35.860
FK department

00:20:37.760 --> 00:20:38.620
Foreign key

00:20:38.930 --> 00:20:41.310
Tin, space, foreign key

00:20:41.310 --> 00:20:42.110
Tin, space, foreign key

00:20:43.870 --> 00:20:45.250
Para makita mo din

00:20:45.250 --> 00:20:46.930
Dun sa refresh, dun sa connections

00:20:47.530 --> 00:20:48.210
Dun sa refresh, dun sa connections

00:20:50.150 --> 00:20:52.270
Pwede natin siya makita

00:20:54.330 --> 00:20:54.890
Pwede natin siya makita

00:20:54.890 --> 00:20:56.430
Yun, good

00:20:56.430 --> 00:20:58.290
So may table na tayo

00:20:58.930 --> 00:20:59.690
Matatrain na natin yung

00:20:59.690 --> 00:21:01.490
Yung sa cursor

00:21:13.510 --> 00:21:16.350
Let me fix the cursor

00:21:16.350 --> 00:21:16.470
Let me fix the cursor

00:21:36.870 --> 00:21:38.750
Let me fix the cursor

00:22:38.930 --> 00:22:39.430
Let me fix the cursor

00:22:39.430 --> 00:22:43.070
Let me fix the cursor

00:22:43.070 --> 00:22:52.810
Let me fix the cursor

00:23:22.810 --> 00:23:25.390
Let me fix the cursor

00:23:25.390 --> 00:23:28.210
Let me fix the cursor

00:23:28.210 --> 00:23:28.230
Everything in that

00:23:28.230 --> 00:23:32.910
Everything in that

00:23:48.670 --> 00:23:52.790
义 筒 筒

00:23:50.610 --> 00:23:52.470
Math

00:23:52.790 --> 00:23:54.430
Ayun, okay na pa siya yung monitor.

00:23:54.710 --> 00:23:55.270
Okay pa.

00:25:51.370 --> 00:25:52.770
Ayun.

00:25:54.470 --> 00:25:57.890
Okay na, sir Jerry, nung nakita ko may output ka na po.

00:25:59.130 --> 00:25:59.830
Sir Joseph.

00:26:08.950 --> 00:26:11.550
Sir Miguel, okay ka na po? Nakakapagpuri na?

00:26:12.550 --> 00:26:15.070
Okay na po. Siya pa, sir na po nago'y.

00:26:15.430 --> 00:26:15.910
Okay.

00:26:21.130 --> 00:26:23.310
Okay na din po si Sir Joseph.

00:26:24.070 --> 00:26:24.630
Oo nga po.

00:26:25.490 --> 00:26:26.830
Mam teen, okay ka na mam teen?

00:26:27.430 --> 00:26:30.370
Pwede mo numberin mam teen kasi may department table ka na po.

00:26:30.910 --> 00:26:31.590
Meron na po ba?

00:26:33.070 --> 00:26:33.490
Employ.

00:26:35.190 --> 00:26:40.250
Pwede niyong irine yung insert niyo po ngayon, tignan natin.

00:26:41.670 --> 00:26:45.870
I-select mo lang po yung, i-highlight niyo po yung code na irine niyo po.

00:26:47.790 --> 00:26:49.750
Already exists na po, so okay na.

00:26:49.990 --> 00:26:52.650
So sa insert na lang, buruhin niyo po lahat ng code niyo.

00:26:52.950 --> 00:26:54.830
Tapos iwan natin yung insert.

00:27:01.050 --> 00:27:05.010
So insert, violated parent key not found.

00:27:05.350 --> 00:27:09.130
Kasi kailangan nating mag, try muna nating mag-add ng department.

00:27:09.230 --> 00:27:10.590
May department dito na po ba?

00:27:10.630 --> 00:27:12.270
Table ka na po for departments.

00:27:13.550 --> 00:27:15.270
Ayun, so na-insert na.

00:27:16.230 --> 00:27:17.930
Try mga po insert po yan.

00:27:18.670 --> 00:27:19.550
Ayun, okay na po.

00:27:20.690 --> 00:27:21.210
Nice.

00:27:21.930 --> 00:27:23.570
May data ka na po.

00:27:30.510 --> 00:27:31.270
Okay lang yan.

00:27:31.810 --> 00:27:32.270
Next.

00:27:33.390 --> 00:27:37.530
Gusto po makita sa left side mo yung department table,

00:27:37.650 --> 00:27:39.550
Mam teen, sa left.

00:27:39.550 --> 00:27:41.830
Ang nakita ko ngayon employees e, no?

00:27:45.270 --> 00:27:46.670
Try nyo nga po muna i-refresh.

00:27:46.750 --> 00:27:48.650
Click mo po yung refresh button.

00:27:48.990 --> 00:27:50.390
Yan dyan po.

00:27:51.310 --> 00:27:52.970
Pag wala po, try nating mag-disconnect.

00:27:53.350 --> 00:27:55.890
I-right click natin yung sa taas ng tables.

00:27:58.570 --> 00:27:59.270
Right click.

00:27:59.330 --> 00:28:00.290
Okay na din sa local.

00:28:00.370 --> 00:28:01.550
Right click.

00:28:03.650 --> 00:28:04.090
Disconnect.

00:28:10.810 --> 00:28:11.770
Connecting local.

00:28:11.770 --> 00:28:12.350
Okay lang.

00:28:14.890 --> 00:28:15.890
Tapos connect ka ulit.

00:28:16.070 --> 00:28:17.230
Right click connect.

00:28:17.990 --> 00:28:19.650
Mag-assign ng password.

00:28:20.830 --> 00:28:21.770
Ash blue.

00:28:24.630 --> 00:28:24.930
Okay.

00:28:26.170 --> 00:28:27.050
Then tables.

00:28:28.970 --> 00:28:29.510
Yo, there you go.

00:28:29.550 --> 00:28:30.110
Nakita mo na po.

00:28:30.190 --> 00:28:31.230
May departments ka na.

00:28:33.470 --> 00:28:33.950
Perfect.

00:28:35.390 --> 00:28:36.850
Yan, taos try mo na po yung cursor.

00:28:36.850 --> 00:28:39.650
Yung declare cursor, EMP cursor.

00:28:39.950 --> 00:28:42.050
Na sa Google Docs po.

00:28:45.210 --> 00:28:45.930
Okay ka na, sorry.

00:28:47.710 --> 00:28:48.310
Parang...

00:28:48.850 --> 00:28:51.530
Gamitin natin, sir, EMP underscore ID.

00:28:51.670 --> 00:28:52.930
Instead na employee ID.

00:28:53.330 --> 00:28:55.290
Kasi dun sa employees natin,

00:28:55.830 --> 00:28:58.250
Hindi employee underscore ID yung ginagin natin.

00:28:58.530 --> 00:29:00.530
EMP underscore ID yung ginamit natin.

00:29:02.830 --> 00:29:04.230
As primary key.

00:29:07.110 --> 00:29:09.150
Okay, so yeah.

00:29:09.690 --> 00:29:12.430
Last 5 minutes to fix all the bugs

00:29:12.430 --> 00:29:14.030
and run the SQL.

00:29:19.130 --> 00:29:19.970
There you go.

00:29:20.890 --> 00:29:22.110
Okay, try to run that.

00:29:22.390 --> 00:29:24.870
Pwede na natin clear yung script output

00:29:24.870 --> 00:29:25.750
survey.

00:29:26.610 --> 00:29:27.810
Para pag nagirang tayo,

00:29:28.050 --> 00:29:29.230
hindi medyo confusing.

00:29:39.130 --> 00:29:40.350
Sir, okay na po.

00:29:40.970 --> 00:29:41.510
Okay.

00:29:42.470 --> 00:29:43.010
Yeah.

00:29:43.290 --> 00:29:44.410
Sir Ray okay na din, no?

00:29:44.510 --> 00:29:44.930
Okay.

00:29:45.010 --> 00:29:47.130
So let's move on.

00:29:52.970 --> 00:29:55.250
So I'll continue my presentation.

00:29:55.710 --> 00:29:57.850
So good thing at least nakapag hands-on tayo.

00:29:58.770 --> 00:29:59.770
Nakapag debug tayo,

00:29:59.810 --> 00:30:01.110
nakapag create tayo ng table.

00:30:02.090 --> 00:30:03.830
Nagamit natin yung declare,

00:30:04.510 --> 00:30:06.130
nakapag begin tayo.

00:30:07.850 --> 00:30:10.030
So dynamic SQL

00:30:10.030 --> 00:30:13.230
is a powerful feature in PLSQL

00:30:13.230 --> 00:30:16.590
that allows you to

00:30:16.590 --> 00:30:19.970
construct SQL statement

00:30:19.970 --> 00:30:21.330
dynamically at runtime.

00:30:21.830 --> 00:30:24.270
So let's walk through an example

00:30:24.270 --> 00:30:25.610
to see how it works.

00:30:25.790 --> 00:30:26.710
So in this example,

00:30:27.190 --> 00:30:29.530
we declare a variable v underscore query

00:30:29.530 --> 00:30:32.030
to hold our dynamic SQL statement.

00:30:32.030 --> 00:30:32.730
Okay.

00:30:35.170 --> 00:30:37.850
So the query is designed

00:30:37.850 --> 00:30:40.390
to fetch the first name of an employee

00:30:40.390 --> 00:30:42.190
based on their employee ID.

00:30:43.050 --> 00:30:45.690
Notice the placeholder column 1

00:30:45.690 --> 00:30:47.810
in the query.

00:30:48.590 --> 00:30:50.090
This is where we bind

00:30:50.090 --> 00:30:51.810
a value at runtime.

00:30:52.630 --> 00:30:54.590
So pwede tayo magbind ng data.

00:30:55.210 --> 00:30:58.030
So using the execute immediate

00:30:59.210 --> 00:30:59.950
statement,

00:30:59.950 --> 00:31:01.910
we execute the dynamic query

00:31:01.910 --> 00:31:03.950
into clause specify

00:31:04.750 --> 00:31:07.330
where the result should be stored.

00:31:07.890 --> 00:31:08.510
In this case,

00:31:08.650 --> 00:31:11.510
the variable will be v underscore result.

00:31:12.030 --> 00:31:14.950
The using clause binds the value 101

00:31:16.370 --> 00:31:18.990
to the placeholder column 1

00:31:18.990 --> 00:31:19.850
in the query.

00:31:20.590 --> 00:31:22.550
Finally, we use dbms output

00:31:22.550 --> 00:31:24.610
that put line display the employee's name

00:31:24.610 --> 00:31:26.410
showcasing how dynamic SQL

00:31:26.410 --> 00:31:28.770
provide flexibility to handle

00:31:28.770 --> 00:31:31.550
varying query structure.

00:31:31.770 --> 00:31:34.550
So this technique is especially useful

00:31:34.550 --> 00:31:36.010
for scenario where query structure

00:31:36.010 --> 00:31:38.470
or parameters need to be determined

00:31:38.470 --> 00:31:40.350
programmatically at the runtime.

00:31:41.930 --> 00:31:42.910
Siguro, try natin to.

00:31:44.930 --> 00:31:47.750
Let me paste this code.

00:31:47.750 --> 00:31:49.330
Sige pa.

00:31:56.430 --> 00:31:58.310
Dynamic SQL.

00:31:59.410 --> 00:32:00.390
It will be at the bottom.

00:32:00.490 --> 00:32:03.130
So we declare vQuery,

00:32:03.470 --> 00:32:04.710
workar,

00:32:05.110 --> 00:32:06.530
oops, sorry.

00:32:11.090 --> 00:32:13.110
Then we

00:32:13.110 --> 00:32:16.230
vResult, employees,

00:32:16.230 --> 00:32:19.230
that first name type.

00:32:19.490 --> 00:32:20.370
So natatandaan niya

00:32:20.370 --> 00:32:21.410
ano yung percent type.

00:32:21.530 --> 00:32:23.750
Ibig sabihin gagamitin niya yung

00:32:23.750 --> 00:32:27.050
data type noong column.

00:32:30.590 --> 00:32:32.830
Tapos vQuery colon equal.

00:32:33.110 --> 00:32:35.150
So nag-assign tayo ng dynamic

00:32:38.310 --> 00:32:39.030
SQL.

00:32:39.210 --> 00:32:40.050
So in this case,

00:32:40.350 --> 00:32:41.970
select first name from employees

00:32:41.970 --> 00:32:44.330
where since wala tayo employee ID,

00:32:44.330 --> 00:32:46.290
we replace it with EMP

00:32:46.290 --> 00:32:48.310
underscore ID equals colon

00:32:48.310 --> 00:32:49.030
1.

00:32:49.970 --> 00:32:52.490
Then execute immediate.

00:32:53.550 --> 00:32:54.330
So vQuery

00:32:55.790 --> 00:32:56.730
into

00:32:57.910 --> 00:32:58.330
vResult.

00:32:59.310 --> 00:33:00.830
Using 101.

00:33:01.630 --> 00:33:03.430
Tapos output natin siya.

00:33:03.630 --> 00:33:04.810
DBMS output

00:33:04.810 --> 00:33:06.810
that put line employee name

00:33:06.810 --> 00:33:07.710
tasyong result.

00:33:08.150 --> 00:33:09.870
Let's try it.

00:33:14.330 --> 00:33:16.550
Let's try it.

00:33:51.150 --> 00:33:53.230
Natry nyo po.

00:33:55.290 --> 00:33:56.850
So pag no data found,

00:33:56.990 --> 00:33:57.790
kasi wala,

00:33:58.070 --> 00:33:59.470
try using 2.

00:33:59.590 --> 00:34:02.070
Kasi if you look at the table,

00:34:03.610 --> 00:34:04.530
sir Jeremy,

00:34:06.050 --> 00:34:08.130
pwede mo pong i-click yung,

00:34:08.330 --> 00:34:11.690
tignan natin yung table ng

00:34:13.570 --> 00:34:14.310
employees mo

00:34:16.250 --> 00:34:16.310
maitrika.

00:34:16.950 --> 00:34:18.330
I think it's 2.

00:34:18.670 --> 00:34:19.570
Do you have 4?

00:34:21.970 --> 00:34:22.990
Can I check

00:34:22.990 --> 00:34:24.650
your employees table?

00:34:25.450 --> 00:34:26.130
Employees.

00:34:26.410 --> 00:34:27.470
Then click data.

00:34:28.070 --> 00:34:30.550
We try to replace it

00:34:30.550 --> 00:34:31.670
with

00:34:35.010 --> 00:34:35.690
4.

00:34:35.950 --> 00:34:37.870
Dapat ano ba sa iyo si John?

00:34:40.410 --> 00:34:41.190
Try to run that.

00:34:41.190 --> 00:34:42.950
Narun mo na po, sir Jeremy.

00:34:44.970 --> 00:34:47.190
Nakita mo si John na yung lumabas?

00:34:51.530 --> 00:34:52.330
Ah, 10.

00:34:53.270 --> 00:34:55.070
101. So dapat doon sa employees mo,

00:34:55.090 --> 00:34:56.150
may 101 ka.

00:34:57.890 --> 00:34:58.810
Try natin i-edit yung

00:34:58.810 --> 00:35:00.850
isang name doon ng 101.

00:35:02.110 --> 00:35:03.110
Punta ka po sa employees,

00:35:03.190 --> 00:35:04.110
sir Jeremy.

00:35:07.190 --> 00:35:09.310
Tapos i-edit natin yung

00:35:09.310 --> 00:35:10.070
ke Alice.

00:35:11.310 --> 00:35:13.790
Yung ke Jane, gawin natin 101.

00:35:14.150 --> 00:35:15.250
Yung ID nya,

00:35:15.310 --> 00:35:16.870
palitan natin yung ID nya.

00:35:17.190 --> 00:35:19.370
Tape natin 101.

00:35:22.590 --> 00:35:22.930
Enter.

00:35:23.390 --> 00:35:24.590
Tapos i-commit mo siya,

00:35:24.650 --> 00:35:25.290
yun nyo i-check.

00:35:26.550 --> 00:35:28.850
Try, run.

00:35:30.210 --> 00:35:31.190
Yung 4, palitan natin

00:35:31.190 --> 00:35:31.690
ng 101.

00:35:35.230 --> 00:35:37.330
Yung gagamitin natin,

00:35:37.330 --> 00:35:38.810
which is using for,

00:35:38.890 --> 00:35:41.370
gagamitin yung 101. So expect natin si Jane

00:35:42.950 --> 00:35:43.670
lumabas.

00:35:44.650 --> 00:35:44.970
Yun.

00:35:45.190 --> 00:35:47.330
Nakita niya po si Jane lumabas.

00:35:52.150 --> 00:35:53.410
How about sir Joseph?

00:35:55.950 --> 00:35:57.570
Ok na po.

00:35:58.270 --> 00:35:59.090
Ok na lahat.

00:35:59.370 --> 00:36:00.090
Nice.

00:36:04.130 --> 00:36:04.750
So,

00:36:05.770 --> 00:36:06.470
that is the

00:36:06.470 --> 00:36:07.030
select for

00:36:07.030 --> 00:36:08.170
Dynamic SQL.

00:36:11.690 --> 00:36:12.530
Ok na?

00:36:12.730 --> 00:36:14.090
Naggets nyo po yung logic nya?

00:36:19.230 --> 00:36:19.330
Yes.

00:36:21.350 --> 00:36:22.590
Nice, congrats.

00:36:22.830 --> 00:36:23.910
Ngayon naman, try naman natin

00:36:23.910 --> 00:36:26.070
mag loop.

00:36:26.610 --> 00:36:27.870
Practice natin yung loop.

00:36:27.870 --> 00:36:30.710
So, I'll paste the code

00:36:30.710 --> 00:36:31.870
in the

00:36:32.570 --> 00:36:33.870
Google Sheet.

00:36:43.150 --> 00:36:44.390
Ato naman,

00:36:44.550 --> 00:36:46.130
let's try the

00:36:46.130 --> 00:36:47.390
looping.

00:36:49.650 --> 00:36:50.170
So,

00:36:50.190 --> 00:36:51.850
we declare a variable.

00:36:53.470 --> 00:36:53.870
Type

00:36:54.390 --> 00:36:55.430
nametable

00:36:55.430 --> 00:36:57.710
of employees dot

00:36:57.710 --> 00:36:58.630
first name.

00:36:59.430 --> 00:37:00.730
Then, we declare

00:37:01.430 --> 00:37:02.950
vnames nametable.

00:37:04.010 --> 00:37:05.830
Then, we select first name,

00:37:06.230 --> 00:37:07.330
bulk, collect,

00:37:08.370 --> 00:37:09.430
into vnames

00:37:10.050 --> 00:37:11.430
from employees

00:37:11.430 --> 00:37:13.190
where department

00:37:13.190 --> 00:37:15.310
IDs stand. So, I think we need more data

00:37:15.310 --> 00:37:16.490
para mara natin to.

00:37:18.130 --> 00:37:18.430
So,

00:37:19.650 --> 00:37:20.910
mag loop tayo

00:37:21.430 --> 00:37:22.990
for i in

00:37:22.990 --> 00:37:24.750
one dot

00:37:24.750 --> 00:37:26.830
v underscore names

00:37:26.830 --> 00:37:28.370
dot count loop

00:37:29.670 --> 00:37:30.590
dbms

00:37:30.590 --> 00:37:32.290
put line employees name

00:37:32.990 --> 00:37:34.930
vnames i tapos

00:37:34.930 --> 00:37:36.990
end loop then end.

00:37:37.890 --> 00:37:39.010
I'll try to

00:37:39.010 --> 00:37:41.190
create more department

00:37:41.190 --> 00:37:43.210
more user on the department ID.

00:37:43.430 --> 00:37:44.570
One moment.

00:37:48.830 --> 00:37:49.590
Pero you can

00:37:49.590 --> 00:37:50.450
paste the code na.

00:37:52.990 --> 00:37:54.990
Okay, department ID 10.

00:38:51.110 --> 00:38:52.510
Okay.

00:39:22.190 --> 00:39:22.350
So,

00:39:22.490 --> 00:39:22.510
I'm going to

00:39:22.530 --> 00:39:22.710
create a new

00:39:22.750 --> 00:39:22.830
Okay.

00:39:22.830 --> 00:39:22.950
So,

00:39:33.030 --> 00:39:33.710
Okay.

00:39:35.250 --> 00:39:36.510
So, let's try to

00:39:36.510 --> 00:39:37.550
create more data.

00:39:37.930 --> 00:39:39.110
So, I put an insert.

00:39:39.350 --> 00:39:40.890
It's a 10

00:39:40.890 --> 00:39:41.950
items.

00:39:43.090 --> 00:39:44.330
Can you try to insert

00:39:44.330 --> 00:39:45.690
into your employees?

00:39:51.630 --> 00:39:52.310
Can you try to insert

00:39:52.310 --> 00:39:52.750
Can you try to insert

00:39:52.870 --> 00:39:52.930
Okay.

00:39:59.170 --> 00:40:00.570
Okay.

00:40:20.910 --> 00:40:20.930
So,

00:40:44.110 --> 00:40:50.430
Okay, nakita n'yo po na natrae n'yo po mag loop, gumawa na po.

00:41:01.570 --> 00:41:03.470
Okay, last 5 minutes.

00:41:14.470 --> 00:41:19.470
Okay na si Sir Ray, si Ma'am Christine. Nakapag-insert na.

00:41:19.720 --> 00:41:26.960
And tatrain na lang ni Ma'am Christine yung code. Nakapag-insert na si Sir Miguel.

00:42:01.400 --> 00:42:02.800
Okay.

00:42:19.640 --> 00:42:21.900
Okay, Ma'am Christine looks good.

00:42:24.080 --> 00:42:28.040
Yeah, I think all good. So let's continue.

00:42:29.620 --> 00:42:39.980
So the fundamentals of populating variable in PLSQL is variables that are essential part of PLSQL programs.

00:42:43.720 --> 00:42:50.300
So in PLSQL, nakita natin na variable must be declared before their use.

00:42:50.840 --> 00:42:56.300
Typically, we declare variables at the beginning of the block or within a declare section.

00:42:57.360 --> 00:43:06.500
So in our example, we declare the employee name, employee salary, which employee name bar chart, the data type, and employee salary and number.

00:43:09.400 --> 00:43:15.720
Tapos yun, so we also have a direct assignment using the colon or equal operator.

00:43:16.760 --> 00:43:19.500
So you can directly assign a value to a variable.

00:43:21.740 --> 00:43:27.220
Next is select into. This is one of the most common ways to populate variables.

00:43:27.860 --> 00:43:34.840
When pulling data from a table, the select into statement fetches data from database and store it in a variable.

00:43:34.840 --> 00:43:46.060
For instance, you can use select first name salary into employee name, employee salary from employees where EMP ID equals 101.

00:43:46.740 --> 00:43:50.700
So these methods allow you to dynamically assign values based on the query result.

00:43:52.160 --> 00:44:04.480
Both methods, direct assignment and select into, are essential tool for working with variables in PLSQL, enabling you to manipulate and utilize data effectively within your programs.

00:44:04.480 --> 00:44:10.460
So now let's explore the practical example how to use this method in different scenarios.

00:44:12.700 --> 00:44:28.480
So for example, looking at the code block, we select the query, we query retrieve the first name and salary of an employee from the employee's table with the employee's ID 1001.

00:44:28.480 --> 00:44:39.740
The into clause direct the retrieve values into the variables, employee name for the first name, then employee salary for the salary.

00:44:40.640 --> 00:44:46.560
It is important to note that select into requires the query to return exactly one row.

00:44:47.060 --> 00:44:55.480
If no matching record is found or if multiple rows are returned, PLSQL will raise an exception, kagayon nung ginawa natin kanina.

00:44:56.760 --> 00:45:02.780
This is why exception handling is essential when using select into.

00:45:03.280 --> 00:45:09.140
You need to manage scenarios where no data is found using the no data found exception.

00:45:09.720 --> 00:45:13.640
Multiple rows are returned which raises too many rows exception.

00:45:17.300 --> 00:45:24.900
Let's look how we can initialize and populate variables in PLSQL using default value expression.

00:45:25.760 --> 00:45:32.420
So you can assign default values to variables during declaration.

00:45:32.620 --> 00:45:42.900
This ensure the variable have meaningful initial values even if no, wala naman explicit assignment is made later in the program.

00:45:42.900 --> 00:45:55.900
So the example is employee name bar chart 50 so we put it unknown and salary number 0 then after that in the begin the code goes there.

00:45:57.460 --> 00:46:04.020
Variable can also be assigned using expression or calculation or function result.

00:46:04.680 --> 00:46:11.100
For example, employees underscore salary colon equal base salary times 1.1.

00:46:11.100 --> 00:46:16.080
So pwede ka magligay ng mga calculation or function or expression.

00:46:17.040 --> 00:46:26.880
This assign employees salary the result base salary multiplied by 1.1 which could represent a salary adjustment or bonus calculation.

00:46:27.920 --> 00:46:38.900
So by using default values and expression effectively, you can ensure your variables are always properly initialized and dynamically updated based on the program's logic.

00:46:41.340 --> 00:46:43.100
So let's move on the example.

00:46:47.880 --> 00:46:49.440
Let's try to do this.

00:46:50.580 --> 00:46:53.400
Let me paste this in the Google.

00:47:02.780 --> 00:47:04.300
So I paste it in the Google.

00:47:04.300 --> 00:47:20.300
So we declare empid number then current salary then increase rate then the new salary siguri babana natin.

00:47:21.620 --> 00:47:33.040
Tapos begin so we put comment so here we fetch the current salary so we select salary into current salary from employees.

00:47:34.040 --> 00:47:38.240
Where employee id equals employee id.

00:47:41.620 --> 00:47:55.040
Then we calculate the new salary so new salary colon current salary then we update the employee salary so update employees.

00:47:57.200 --> 00:48:05.780
Set natin yung salary equals new salary where employee id equals so this will be empid.

00:48:10.900 --> 00:48:12.620
Can you try this code in your end?

00:48:14.540 --> 00:48:18.820
See if you're able to change the new salary.

00:48:49.000 --> 00:48:51.800
Oh debug here.

00:49:33.980 --> 00:49:41.400
Select salary into current salary from employees.

00:49:42.680 --> 00:49:45.180
I think we don't have current salary column.

00:49:46.440 --> 00:49:47.700
One moment.

00:50:56.820 --> 00:50:59.040
See the error you're getting at?

00:51:00.680 --> 00:51:02.040
Let me paste the correct code.

00:51:11.660 --> 00:51:17.200
As you can see may error kasi yung empid.

00:51:17.200 --> 00:51:17.600
Let's try it.

00:51:24.200 --> 00:51:35.180
So issue ng unang unang code yung empid variable inside the work clause conflicts with the empid with the column from the employees table.

00:51:35.620 --> 00:51:40.380
So to fix that nagdagdag tayo ng v underscore sa empid.

00:51:50.500 --> 00:51:59.200
Verify nyo kung nagbago yung salary ng target natin na user.

00:52:00.020 --> 00:52:06.280
So kung wala yung 101, since sa employee table niya may one, dapat nagbago siya.

00:52:15.380 --> 00:52:20.780
Again pag walang lumalabas, don't forget the set server output on.

00:52:37.120 --> 00:52:44.280
Nakakita nyo po, every time you run the code, it adds by 10%.

00:53:08.720 --> 00:53:12.180
Can you try to run?

00:53:17.660 --> 00:53:21.180
Kasi walang output, new salary din declare mo ba sa taas?

00:53:21.920 --> 00:53:31.180
New underscore salary colon number.

00:53:32.180 --> 00:53:33.880
Ok naman.

00:53:34.800 --> 00:53:44.760
Ba't di lumalabas yung colon or date employees, set salary, cost me salary or empid?

00:54:03.600 --> 00:54:06.380
Yung current salary.

00:54:07.960 --> 00:54:11.040
Yun, sumabas na.

00:54:11.800 --> 00:54:14.600
Ok good.

00:54:17.880 --> 00:54:22.660
Good no? At least natututunan natin magdebag, macheck yung error.

00:54:25.940 --> 00:54:27.180
So row type naman.

00:54:27.180 --> 00:54:28.580
One moment.

00:54:29.680 --> 00:54:32.260
So 3pm, bibig tayo alit.

00:54:36.920 --> 00:54:39.220
250, 250, you want 250?

00:54:42.680 --> 00:54:44.180
250 ok, let's have a break.

00:54:44.820 --> 00:54:46.740
So let's explore the row type.

00:54:46.960 --> 00:54:53.820
So it's an attribute in PLSQL which is a powerful way to work the entire rows of data from a table query.

00:54:54.040 --> 00:54:56.360
So what is a row, percent row type?

00:54:56.360 --> 00:55:04.440
So percent row type attribute allow us to declare a record variable that can store an entire row of data.

00:55:04.500 --> 00:55:06.520
So pwede natin ilagay yung bang row ng data.

00:55:06.880 --> 00:55:14.240
This means that the variable can hold multiple columns with their respective data types matching the structure upon a table or cursor.

00:55:15.240 --> 00:55:22.300
So the syntax will be variable, name, space, table name, percent row type.

00:55:22.300 --> 00:55:27.400
So variable name is the name of variable you are declaring.

00:55:28.280 --> 00:55:34.660
Then table name, percent row type is the table or cursor whose row structure the variable will adapt.

00:55:35.660 --> 00:55:39.660
So ito yung example natin yun ipinsko sa ano.

00:55:58.000 --> 00:56:00.800
One moment.

00:56:04.660 --> 00:56:05.600
So yun.

00:56:05.600 --> 00:56:06.660
So yung row type.

00:56:06.800 --> 00:56:07.660
Mami ilalagay ko example.

00:56:08.540 --> 00:56:09.660
Ito ito natin pagbalik.

00:56:10.580 --> 00:56:11.640
So let's continue.

00:56:12.400 --> 00:56:15.840
So let's for example declaring variable with a row type.

00:56:17.240 --> 00:56:23.480
So let's look at the practical example of declaring a variable with row type to work with an entire row of data from a table.

00:56:24.220 --> 00:56:30.420
So suppose we have employees table with empid, phrase name, last name, department salary.

00:56:30.940 --> 00:56:33.620
So ito yung sample natin ng data for employees table.

00:56:35.780 --> 00:56:42.720
So here's how we can declare use a row type variable access data from this table.

00:56:44.420 --> 00:56:47.400
So let's try this before we do a break.

00:56:47.620 --> 00:56:57.000
I'll paste the code in the application of row type.

00:57:03.620 --> 00:57:05.900
So let me check.

00:57:07.120 --> 00:57:13.480
So we declare emp record employees row type.

00:57:13.500 --> 00:57:15.480
So we declare record variable.

00:57:16.440 --> 00:57:18.160
Tapos we begin.

00:57:20.060 --> 00:57:20.720
One moment.

00:57:21.040 --> 00:57:21.820
So we begin.

00:57:22.560 --> 00:57:23.180
We fetch.

00:57:27.740 --> 00:57:32.180
So we fetch the record into variable.

00:57:34.260 --> 00:57:47.200
So select asterisk into emp record from employees or empid.

00:57:47.800 --> 00:57:49.500
So check na lang kung anong meron kayo.

00:57:49.600 --> 00:57:51.180
Pero pwede 101 or 1.

00:57:51.740 --> 00:57:58.680
Tapos we can access na yung individual fields nila using the dot notation.

00:58:00.480 --> 00:58:02.900
Baban natin para mas madaling makita.

00:58:06.300 --> 00:58:16.740
So ito try natin really quick na gamit yung emp record yung buong data ng employees nilagay natin dito.

00:58:17.080 --> 00:58:29.320
So mas madali natin siyang ma-access na yung department ID nya, yung first name nya, tapos yung salary.

00:58:33.360 --> 00:58:43.480
So emp record nilipat natin dito tapos nilag natin into from employees or empid.

00:58:44.100 --> 00:58:45.740
She goes to 1.

00:58:46.160 --> 00:58:48.580
So dapat makapag-out po tayo.

00:58:48.860 --> 00:58:49.820
Can you try it now?

00:59:11.100 --> 00:59:15.120
Maybe my comment is wrong because of google docs.

00:59:15.120 --> 00:59:24.520
Doon sa fetch arrow or any comment, just put double dash.

00:59:28.920 --> 00:59:32.120
Tapos unline to ayun.

00:59:32.120 --> 00:59:36.680
Pag kinapipaser yung mali lang niya yung mga comment.

00:59:42.420 --> 00:59:43.340
Refresh.

00:59:46.540 --> 00:59:49.500
So do we declare emp record employees?

01:00:06.660 --> 01:00:10.840
Let me correct the code one moment.

01:00:43.400 --> 01:00:45.760
Last name must be declared.

01:00:48.640 --> 01:00:50.060
First name.

01:00:58.220 --> 01:01:00.480
So let me correct that.

01:01:00.640 --> 01:01:02.340
So this should be first name.

01:01:05.440 --> 01:01:10.100
And I put the correct syntax on the google docs.

01:01:10.100 --> 01:01:25.340
So lahat po ba nakapagrana?

01:01:26.300 --> 01:01:26.960
May error pa rin?

01:01:26.960 --> 01:01:30.800
Ayun, okay na yung kay Sir Jerry.

01:01:32.680 --> 01:01:35.540
Okay na po lahat nung Mr. Ray.

01:01:35.820 --> 01:01:37.120
Nakapagrana rin.

01:01:37.840 --> 01:01:38.780
I think we're good.

01:01:39.160 --> 01:01:41.720
So nintindihan niyo na po yung percent throw type, correct?

01:01:42.500 --> 01:01:44.880
Na pwede natin siyang ilipat dun sa isang variable.

01:01:49.160 --> 01:01:49.840
I think that's it.

01:01:49.880 --> 01:01:50.980
We can have a break.

01:01:50.980 --> 01:01:57.020
Balit natin is 3.30.

01:01:57.440 --> 01:01:58.820
Is that okay?

01:02:07.520 --> 01:02:08.060
Okay.

01:02:08.960 --> 01:02:10.000
Your stream's busy, guys.

01:02:10.760 --> 01:02:11.060
Yes.

01:02:11.600 --> 01:02:12.200
Yes po.

01:02:14.420 --> 01:02:16.460
Ngayon po hanggang.

01:02:16.800 --> 01:02:18.380
You want 30 minutes?

01:02:20.200 --> 01:02:21.180
Okay po.

01:02:21.340 --> 01:02:23.500
Let's resume 3.30, okay?

01:02:24.540 --> 01:02:25.800
Thank you po.

01:02:27.820 --> 01:02:28.520
Thank you po.

01:04:16.720 --> 01:04:18.360
Thank you po.

01:05:39.280 --> 01:05:41.260
Ika ko nang lasa ng tubig. Sa mga rin?

01:05:43.080 --> 01:05:44.040
Sa ano?

01:05:44.040 --> 01:05:45.980
Sa plastik.

01:05:46.040 --> 01:05:46.840
Hindi mas nasa.

01:05:47.940 --> 01:05:48.540
Tapos nga.

01:05:48.860 --> 01:05:49.240
Ito?

01:05:52.980 --> 01:05:54.000
Tapos nga tayo.

01:05:56.260 --> 01:05:58.040
Tapos ko lumawan ng...

01:05:58.960 --> 01:05:59.680
Ay, may nga pre?

01:06:00.540 --> 01:06:00.980
Kasi?

01:06:02.580 --> 01:06:03.220
Hindi...

01:06:03.220 --> 01:06:04.500
Hindi na dago kong papibali na chocolate.

01:06:04.760 --> 01:06:05.180
Chocolate.

01:08:49.420 --> 01:08:50.820
Tapos na.

01:08:52.920 --> 01:08:54.320
Tapos na.

01:08:54.320 --> 01:08:55.060
Tapos na.

01:09:42.360 --> 01:09:43.760
Tapos na.

01:14:12.620 --> 01:14:14.020
Tapos na.

01:14:54.700 --> 01:14:56.100
O, pwede.

01:14:57.480 --> 01:14:57.660
Tapos na.

01:28:26.000 --> 01:28:26.440
So,

01:28:27.080 --> 01:28:27.380
hindi nila.

01:28:27.400 --> 01:28:27.640
So,

01:28:33.520 --> 01:28:34.920
so,

01:28:36.420 --> 01:28:37.820
so,

01:28:37.820 --> 01:28:38.660
so,

01:28:45.200 --> 01:28:46.600
so,

01:28:46.600 --> 01:28:46.640
so,

01:28:46.640 --> 01:28:47.560
so,

01:28:51.640 --> 01:28:53.040
so,

01:28:53.040 --> 01:28:55.200
so,

01:28:55.200 --> 01:28:56.700
so,

01:29:03.840 --> 01:29:05.240
so,

01:29:05.240 --> 01:29:05.280
so,

01:29:11.220 --> 01:29:12.620
so,

01:29:12.620 --> 01:29:12.640
so,

01:29:12.640 --> 01:29:12.660
so,

01:29:12.660 --> 01:29:13.340
so,

01:29:21.300 --> 01:29:22.660
so,

01:29:22.660 --> 01:29:23.280
so,

01:29:30.020 --> 01:29:31.380
so,

01:29:47.480 --> 01:29:48.880
so,

01:29:59.960 --> 01:30:01.360
so,

01:30:01.360 --> 01:30:03.200
so,

01:30:05.020 --> 01:30:06.420
so,

01:30:07.300 --> 01:30:07.620
so,

01:30:15.880 --> 01:30:17.280
so,

01:30:26.800 --> 01:30:26.840
so,

01:30:26.860 --> 01:30:26.880
so,

01:30:26.880 --> 01:30:26.900
so,

01:30:26.920 --> 01:30:26.940
so,

01:30:43.500 --> 01:30:43.540
so,

01:30:55.720 --> 01:30:57.120
so,

01:30:57.380 --> 01:30:57.780
so,

01:31:02.360 --> 01:31:05.160
complex operations.

01:31:11.880 --> 01:31:12.840
So,

01:31:15.240 --> 01:31:16.200
so,

01:31:16.200 --> 01:31:17.000
so,

01:31:29.400 --> 01:31:30.360
so,

01:31:35.060 --> 01:31:35.080
so,

01:31:35.100 --> 01:31:35.120
so,

01:31:36.360 --> 01:31:36.440
so,

01:31:36.460 --> 01:31:36.480
so,

01:31:38.240 --> 01:31:38.320
so,

01:31:38.360 --> 01:31:38.380
so,

01:31:38.380 --> 01:31:38.400
so,

01:31:40.140 --> 01:31:40.220
so,

01:31:43.500 --> 01:31:44.220
so,

01:32:00.740 --> 01:32:02.140
so,

01:32:05.400 --> 01:32:06.800
so,

01:32:09.400 --> 01:32:09.440
so,

01:32:09.760 --> 01:32:09.780
so,

01:32:12.440 --> 01:32:13.840
so,

01:32:14.740 --> 01:32:15.040
so,

01:32:17.300 --> 01:32:18.700
so,

01:32:18.700 --> 01:32:18.920
so,

01:32:31.660 --> 01:32:33.060
so,

01:32:49.340 --> 01:32:49.380
so,

01:32:49.400 --> 01:32:49.420
so,

01:32:49.440 --> 01:32:49.460
so,

01:33:01.660 --> 01:33:01.700
so,

01:33:12.140 --> 01:33:13.540
so,

01:33:14.860 --> 01:33:15.660
so,

01:33:15.780 --> 01:33:16.760
so,

01:33:22.840 --> 01:33:23.960
so,

01:33:25.800 --> 01:33:26.680
so,

01:33:32.980 --> 01:33:33.000
so,

01:33:36.640 --> 01:33:37.000
so,

01:33:38.420 --> 01:33:38.440
so,

01:33:42.300 --> 01:33:43.700
so,

01:33:43.700 --> 01:33:44.300
so,

01:33:57.980 --> 01:33:59.380
so,

01:34:02.120 --> 01:34:02.140
so,

01:34:14.780 --> 01:34:15.900
so,

01:34:15.920 --> 01:34:15.940
so,

01:34:17.340 --> 01:34:18.460
so,

01:34:19.820 --> 01:34:20.940
so,

01:34:22.460 --> 01:34:23.580
so,

01:34:24.340 --> 01:34:24.560
so,

01:34:31.560 --> 01:34:31.580
so,

01:34:43.120 --> 01:34:43.600
so,

01:34:43.980 --> 01:34:44.040
so,

01:34:44.180 --> 01:34:44.200
so,

01:34:44.220 --> 01:34:44.240
so,

01:34:54.720 --> 01:34:55.200
so,

01:34:58.460 --> 01:34:58.720
so,

01:35:01.760 --> 01:35:03.160
so,

01:35:04.200 --> 01:35:04.540
so,

01:35:04.540 --> 01:35:05.340
so,

01:35:18.380 --> 01:35:19.780
so,

01:35:20.020 --> 01:35:21.820
so,

01:35:23.040 --> 01:35:24.140
so,

01:35:35.820 --> 01:35:36.900
so,

01:35:47.680 --> 01:35:48.760
so,

01:35:48.760 --> 01:35:48.780
so,

01:35:48.780 --> 01:35:49.260
so,

01:35:51.020 --> 01:35:51.360
so,

01:35:51.900 --> 01:35:52.040
so,

01:35:57.460 --> 01:35:58.860
so,

01:36:02.360 --> 01:36:03.760
so,

01:36:03.880 --> 01:36:05.480
so,

01:36:09.100 --> 01:36:10.500
so,

01:36:17.740 --> 01:36:18.140
so,

01:36:30.900 --> 01:36:30.920
so,

01:36:36.440 --> 01:36:36.840
so,

01:36:36.920 --> 01:36:37.100
so,

01:36:37.180 --> 01:36:37.400
so,

01:36:37.420 --> 01:36:38.060
so,

01:36:45.460 --> 01:36:46.860
so,

01:36:49.620 --> 01:36:50.060
so,

01:36:52.940 --> 01:36:54.340
so,

01:37:02.460 --> 01:37:03.860
so,

01:37:04.280 --> 01:37:04.300
so,

01:37:04.320 --> 01:37:04.340
so,

01:37:06.020 --> 01:37:06.780
so,

01:37:08.980 --> 01:37:09.600
so,

01:37:09.620 --> 01:37:09.640
so,

01:37:09.680 --> 01:37:09.700
so,

01:37:09.720 --> 01:37:09.740
so,

01:37:10.140 --> 01:37:10.560
so,

01:37:11.620 --> 01:37:12.380
so,

01:37:12.380 --> 01:37:13.760
so,

01:37:15.520 --> 01:37:16.920
so,

01:37:37.020 --> 01:37:38.420
so,

01:37:41.860 --> 01:37:42.220
so,

01:37:42.220 --> 01:37:42.860
so,

01:37:49.160 --> 01:37:50.560
so,

01:37:54.400 --> 01:37:55.800
so,

01:37:56.440 --> 01:37:57.640
so,

01:38:07.140 --> 01:38:08.540
so,

01:38:11.660 --> 01:38:12.660
so,

01:38:15.340 --> 01:38:15.500
so,

01:38:15.500 --> 01:38:15.540
so,

01:38:15.540 --> 01:38:16.040
so,

01:38:17.700 --> 01:38:18.700
so,

01:38:18.700 --> 01:38:18.820
so,

01:38:18.820 --> 01:38:19.340
so,

01:38:45.860 --> 01:38:47.260
so,

01:39:05.580 --> 01:39:06.980
so,

01:39:10.380 --> 01:39:10.960
so,

01:39:10.960 --> 01:39:11.740
so,

01:39:13.140 --> 01:39:13.420
so,

01:39:13.420 --> 01:39:15.900
so,

01:39:16.860 --> 01:39:17.320
so,

01:39:37.000 --> 01:39:37.320
so,

01:39:38.820 --> 01:39:38.840
so,

01:39:38.860 --> 01:39:38.880
so,

01:39:38.900 --> 01:39:38.920
so,

01:39:40.160 --> 01:39:40.480
so,

01:39:40.620 --> 01:39:40.980
so,

01:39:45.340 --> 01:39:45.660
so,

01:39:49.780 --> 01:39:51.060
so,

01:40:01.080 --> 01:40:02.360
so,

01:40:09.160 --> 01:40:10.440
so,

01:40:10.440 --> 01:40:10.460
so,

01:40:10.460 --> 01:40:10.600
so,

01:40:16.500 --> 01:40:17.300
so,

01:40:20.040 --> 01:40:20.240
so,

01:40:20.260 --> 01:40:20.660
so,

01:40:35.820 --> 01:40:36.620
so,

01:40:39.460 --> 01:40:39.480
so,

01:40:39.500 --> 01:40:39.520
so,

01:40:51.340 --> 01:40:52.740
so,

01:40:52.740 --> 01:40:52.760
so,

01:41:03.720 --> 01:41:05.120
so,

01:41:22.660 --> 01:41:22.700
so,

01:41:22.700 --> 01:41:22.720
so,

01:41:22.740 --> 01:41:22.760
so,

01:41:22.780 --> 01:41:22.800
so,

01:41:30.740 --> 01:41:30.780
so,

01:41:34.160 --> 01:41:34.200
so,

01:41:43.440 --> 01:41:44.840
so,

01:41:46.940 --> 01:41:47.760
so,

01:41:56.900 --> 01:41:58.300
so,

01:42:02.420 --> 01:42:02.540
so,

01:42:04.160 --> 01:42:06.480
so,

01:42:06.480 --> 01:42:06.500
so,

01:42:14.360 --> 01:42:15.760
so,

01:42:25.440 --> 01:42:26.840
so,

01:42:28.660 --> 01:42:30.060
so,

01:42:33.620 --> 01:42:34.060
so,

01:42:36.160 --> 01:42:36.520
so,

01:42:36.780 --> 01:42:37.700
so,

01:42:37.860 --> 01:42:37.880
so,

01:42:46.760 --> 01:42:48.160
so,

01:42:52.440 --> 01:42:53.040
so,

01:42:53.860 --> 01:42:54.020
so,

01:42:57.400 --> 01:42:58.000
so,

01:43:00.980 --> 01:43:01.580
so,

01:43:16.880 --> 01:43:16.900
so,

01:43:16.920 --> 01:43:16.940
so,

01:43:17.240 --> 01:43:17.260
so,

01:43:20.500 --> 01:43:21.260
so,

01:43:32.760 --> 01:43:34.160
so,

01:43:34.160 --> 01:43:36.700
so,

01:43:38.700 --> 01:43:39.860
so,

01:43:40.340 --> 01:43:40.380
so,

01:43:41.900 --> 01:43:42.460
so,

01:43:59.700 --> 01:44:01.100
so,

01:44:09.660 --> 01:44:11.060
so,

01:44:17.140 --> 01:44:18.540
so,

01:44:19.840 --> 01:44:20.120
so,

01:44:20.120 --> 01:44:21.040
so,

01:44:35.240 --> 01:44:36.640
so,

01:44:36.640 --> 01:44:36.720
so,

01:44:40.840 --> 01:44:41.040
so,

01:44:41.040 --> 01:44:41.520
so,

01:44:41.680 --> 01:44:41.780
so,

01:44:41.780 --> 01:44:42.480
so,

01:44:42.480 --> 01:44:43.140
so,

01:45:05.120 --> 01:45:06.520
so,

01:45:08.660 --> 01:45:10.060
so,

01:45:13.120 --> 01:45:13.500
so,

01:45:22.560 --> 01:45:23.960
so,

01:45:31.300 --> 01:45:32.700
so,

01:45:44.540 --> 01:45:45.940
oops,

01:45:45.960 --> 01:45:46.660
oops,

01:45:55.520 --> 01:45:55.900
oops,

01:45:56.100 --> 01:45:56.280
oops,

01:46:05.840 --> 01:46:05.860
oops,

01:46:12.020 --> 01:46:14.020
else if

01:46:21.940 --> 01:46:24.520
Nagwork po sa inyo

01:46:24.520 --> 01:46:28.200
Try to change value on the declaration

01:46:28.860 --> 01:46:31.200
Very high salary

01:46:34.120 --> 01:46:35.080
Moderate

01:46:36.200 --> 01:46:38.520
Try to increase the number of the salary

01:46:38.520 --> 01:46:41.560
Maybe put 60,000

01:46:41.560 --> 01:46:45.420
So it will say very high salary

01:46:45.420 --> 01:46:48.260
So ganyan maagcondisyon sa PLSQL

01:46:48.260 --> 01:46:50.200
If condition then else if

01:46:51.760 --> 01:46:52.720
Okay

01:46:52.720 --> 01:46:55.360
Ngayon mayroon ding

01:46:55.360 --> 01:46:57.320
Pano naman pag

01:46:58.900 --> 01:46:59.740
Case

01:47:02.340 --> 01:47:07.560
So using case statement adds conditional logic directly into a query

01:47:07.560 --> 01:47:12.840
So it evaluates condition and returns specific value based on the result

01:47:14.900 --> 01:47:16.320
Tapos yung decode

01:47:16.840 --> 01:47:20.080
Using a decode as alternative to case in oracle

01:47:20.080 --> 01:47:26.080
So oracle's decode function provides simple conditional logic within a select statement

01:47:26.080 --> 01:47:32.440
Though less flexible than case, it is useful for straightforward evaluation

01:47:36.200 --> 01:47:41.820
Like I'll paste something in here

01:47:43.080 --> 01:47:46.600
Para magamit natin yung decode

01:47:47.600 --> 01:47:54.900
So in this case MPID

01:47:57.560 --> 01:48:00.820
Sa atin department ID yung gamit natin

01:48:00.820 --> 01:48:03.400
So pag tan daw HR papakita nya

01:48:03.400 --> 01:48:05.340
Pag 20 sales

01:48:05.340 --> 01:48:09.040
Otherwise 20

01:48:09.040 --> 01:48:14.660
Can you try to run the code?

01:48:36.960 --> 01:48:37.400
So

01:48:37.400 --> 01:48:39.060
Nag-run po yung code sa inyo

01:48:39.060 --> 01:48:41.540
Nakita nya may HR, sales

01:48:42.560 --> 01:48:47.140
So do you understand po yung decode?

01:48:48.660 --> 01:48:53.540
So pag yung department ID kapag tan HR lalabas nya pag 20 sales

01:48:54.460 --> 01:48:57.040
Otherwise other yung lalabas

01:48:57.040 --> 01:48:57.760
Okay

01:48:57.760 --> 01:49:01.560
So yun yung purpose ng decode

01:49:03.020 --> 01:49:06.300
So using the case in a select statement

01:49:07.800 --> 01:49:14.640
So it says here when salary is less than 40,000 then low

01:49:14.640 --> 01:49:19.300
When salary between 40,000 and 60,000 then medium

01:49:19.840 --> 01:49:21.740
L size siya

01:49:22.520 --> 01:49:26.100
Tapos pag nag-case ka, laging may end

01:49:26.100 --> 01:49:27.320
So case end

01:49:27.320 --> 01:49:32.260
As aning pangalan? Salary category from employees

01:49:33.620 --> 01:49:40.260
So this is really straight forward and easy to understand how the case work

01:49:45.200 --> 01:49:48.680
So using if with select into

01:49:48.680 --> 01:49:51.580
So we declare a salary

01:49:51.580 --> 01:50:00.460
So select salary into salary from employees who are employee ID or MPID equals to 1 for example

01:50:00.460 --> 01:50:04.460
So if salary is greater than 40,000

01:50:05.420 --> 01:50:10.460
So ganun din yung value na makuha natin dito yun yung pagbabasahan

01:50:12.920 --> 01:50:18.760
So yung select nating salary nilipat dito sa variable ng salary

01:50:18.760 --> 01:50:22.080
Tapos yun yung lalagin natin ng condition

01:50:22.080 --> 01:50:26.500
So pag using decode naman, alternative to case

01:50:26.500 --> 01:50:30.600
So kung yung department niya at sales, lalagin niya sales department

01:50:30.600 --> 01:50:33.400
Kung HR yung nalagin natin human resource

01:50:33.400 --> 01:50:35.700
Otherwise, other yung ilalagin natin

01:50:35.700 --> 01:50:37.320
You can put more

01:50:38.440 --> 01:50:42.660
I think it's only two cases

01:50:44.680 --> 01:50:50.480
So case is add complex conditional logic directly in select statement

01:50:50.480 --> 01:51:01.740
So if we select into useful in PLSQL blocks for decision making based on query result

01:51:02.480 --> 01:51:10.040
Yung decode naman it very simple, straightforward, just alternative for the select

01:51:11.040 --> 01:51:20.160
So the key benefit of that is the decode is straightforward for basic evaluation, readability, and performance

01:51:20.160 --> 01:51:30.360
While decode is less powerful than case, its simplicity makes it a valuable tool for quick basic transformation in Oracle SQL queries

01:51:30.360 --> 01:51:33.040
Now let's try to do a summarize

01:51:33.100 --> 01:51:44.080
So basic syntax, the case statement in SQL is a very powerful tool for incorporating conditional logic directly into your queries

01:51:45.800 --> 01:51:54.220
So search case, it's evaluate multiple Boolean condition in return result based on the first condition that evaluates it through

01:51:54.220 --> 01:52:01.860
Then the key benefits of that is dynamic logic adds if-else behavior directly to SQL queries

01:52:01.860 --> 01:52:04.840
Or PLSQL blocks

01:52:06.160 --> 01:52:13.720
Custom categorization enables you to label or group data dynamically based on specific criteria

01:52:13.720 --> 01:52:21.520
Then versatility, it can handle both simple value matching and complex Boolean condition

01:52:22.900 --> 01:52:26.440
So this is the simple case syntax

01:52:26.440 --> 01:52:28.300
So case, then expression

01:52:28.300 --> 01:52:34.420
So when value 1, then result 1, when value 2, then result 2

01:52:34.420 --> 01:52:38.300
Pwede pa mag-add na marami, so when value 3, then result 3

01:52:38.980 --> 01:52:46.560
Else, pag wala nagfold din sa condition, it will go to else, which is the default result

01:52:50.060 --> 01:52:54.980
So in this case, a simple case, so we select employee ID and department

01:52:54.980 --> 01:53:05.000
So case department, sales, gagal siyang sales team pag HR human resource, pag IT then tech department, else other department

01:53:05.000 --> 01:53:14.900
So yung search case syntax naman is case when condition then result

01:53:17.000 --> 01:53:20.480
When another condition then result 2

01:53:20.480 --> 01:53:25.780
So in this case, when salary is greater than 40,000 then low

01:53:25.780 --> 01:53:32.080
Kapag yung salary between, so another condition, kapag nagtruto then medium

01:53:32.080 --> 01:53:36.420
Otherwise, pumunta siya sa default which is yung high

01:53:36.420 --> 01:53:38.800
Then for, don't forget to end

01:53:39.480 --> 01:53:42.000
Then as, ano yung magiging label niya

01:53:42.000 --> 01:53:55.820
Then yung case statement for salary number colon equal 45,000 and salary category datatype 20

01:53:57.120 --> 01:54:03.120
So we begin with, kumaga pwede nating ilipat yung result nito

01:54:03.120 --> 01:54:10.580
So nag case siya, when salary greater than less than 40,000 then low lalabas niya

01:54:10.580 --> 01:54:16.960
When salary between 40,000 and 60,000 then medium, else high

01:54:16.960 --> 01:54:21.020
Tapos pwede mo nang i-input yung salary category

01:54:23.300 --> 01:54:27.280
So again, dineclear nating dito yung salary category

01:54:27.280 --> 01:54:31.660
So don't forget to declare kapag ginamit mo siya dito

01:54:32.580 --> 01:54:34.980
So let's try this one really quick

01:54:34.980 --> 01:54:42.160
And since we have the data already, we can use that

01:54:43.320 --> 01:54:45.980
Or yeah, I think it's almost the same

01:54:48.300 --> 01:54:51.460
I'll just put it na lang, then you can try it later

01:54:52.380 --> 01:54:59.040
I'll just put it in the Google sheet

01:55:00.680 --> 01:55:01.880
Case statement

01:55:04.980 --> 01:55:16.640
So we declare the salary number, salary category, salary case, else high

01:55:16.640 --> 01:55:18.980
And then we input

01:55:23.280 --> 01:55:27.700
Na-paste ko na po, just in case you want to copy this code

01:55:27.700 --> 01:55:30.980
But you already have copy in the PDF

01:55:32.540 --> 01:55:36.540
So key point, simple case

01:55:36.540 --> 01:55:39.180
So best for matching specific values directly

01:55:40.180 --> 01:55:44.240
So yung nga, yung example nating dun is when 40,000 then low

01:55:44.240 --> 01:55:46.800
When 60,000 then medium, else high

01:55:46.800 --> 01:55:52.780
Search case naman is flexible in a therefore evaluating complex condition

01:55:53.820 --> 01:55:59.260
Yung example nating yung case, when salary is greater less than 40,000 then low

01:55:59.260 --> 01:56:07.840
Tapos yung other condition natin when salary between 40,000 and 60,000 then medium, else high

01:56:08.620 --> 01:56:12.040
So default result is yung else

01:56:12.040 --> 01:56:17.320
Now let's ensure that the result is returned even if no condition match

01:56:17.320 --> 01:56:20.000
It provides fallback logic

01:56:20.000 --> 01:56:22.120
So mahalaga din yung else

01:56:22.120 --> 01:56:31.100
Para baka may mga anticipated values na walang magfall na tru dun sa condition dun sa mga when under cases

01:56:31.100 --> 01:56:34.120
Then usage of SQL and PLSQL

01:56:34.660 --> 01:56:39.240
So versatile across queries for dynamic data categorization

01:56:39.240 --> 01:56:44.620
So effective in PLSQL blocks for procedural language and conditional assignment

01:56:45.580 --> 01:56:50.600
So I think the takeaway is the case statement adds valuable conditional board

01:56:50.600 --> 01:56:54.600
Logic to both SQL queries and PLSQL codes

01:56:54.600 --> 01:56:58.320
It allows for dynamic decision making

01:56:58.320 --> 01:57:02.740
Making your programs more adaptable and data processing more streamlined

01:57:04.880 --> 01:57:07.440
So now let's trap the errors

01:57:07.440 --> 01:57:09.340
How we can trap the errors

01:57:10.620 --> 01:57:14.480
When an error exception occurs in PLSQL block

01:57:14.480 --> 01:57:17.320
The block stop executing at the point of the error

01:57:17.320 --> 01:57:22.140
Control is transferred to the exception handling section of the block

01:57:22.140 --> 01:57:27.320
So you can define how to manage the error ensuring the program respond appropriately

01:57:27.320 --> 01:57:36.240
By using exception in PLSQL you can write a robust program that handle the errors gracefully

01:57:36.240 --> 01:57:40.340
Ensuring smooth execution even in unexpected situation

01:57:41.340 --> 01:57:47.180
Okay let's look at a specific sample of handling different types of exception in the next section

01:57:49.680 --> 01:57:51.420
So yun yung exception

01:57:51.420 --> 01:57:57.180
So it's an error of unexpected condition that disrupt the normal flow of the program

01:57:57.180 --> 01:58:03.280
Example including the missing data or division by zero or invalid operation

01:58:03.280 --> 01:58:06.840
Yung exception handling section naman is

01:58:06.840 --> 01:58:11.840
It's a dedicated part of PLSQL that begins with the keyword exception

01:58:12.560 --> 01:58:17.840
It specify how to handle different type of exception when they occur

01:58:18.660 --> 01:58:22.840
Pero si PLSQL may predefined exception siya

01:58:22.840 --> 01:58:28.420
Sample of that is no underscore data underscore pound and two underscore many underscore rows

01:58:28.420 --> 01:58:32.840
It trigger when a query returns multiple rows for a single row fetch

01:58:32.840 --> 01:58:35.180
Yung user defined exception

01:58:35.180 --> 01:58:39.880
It's a custom exception we define for a specific scenario in your program

01:58:39.880 --> 01:58:46.660
It's very useful for handling application specific errors that are not covered by predefined exception

01:58:46.660 --> 01:58:51.840
So with exception handling you can ensure that your PLSQL programs are resilient

01:58:52.860 --> 01:58:56.340
Responding effectively to errors without abrupt failures

01:58:56.340 --> 01:59:03.520
Now let's look example how to handle both predefined and user exception

01:59:06.320 --> 01:59:09.200
So please analyze this code

01:59:11.060 --> 01:59:15.340
So we declare the employee ID or EMP ID number

01:59:15.860 --> 01:59:18.120
Salary then we begin

01:59:18.120 --> 01:59:21.120
Select salary into salary from employees

01:59:21.120 --> 01:59:24.060
Or employee ID equals employee ID

01:59:24.060 --> 01:59:26.540
Then we output the line

01:59:26.540 --> 01:59:29.080
So we put here the word exception

01:59:30.000 --> 01:59:33.760
So we put exception when data no pound

01:59:34.740 --> 01:59:36.760
Sabi niya hindi niya nakita yung ID na yun

01:59:36.760 --> 01:59:38.400
So ito it's a predefined

01:59:38.400 --> 01:59:44.740
When too many rows then sabi niya more than employee pound with ID

01:59:44.740 --> 01:59:53.040
Or you can say when others then DBMS catches any other unexpected error

01:59:54.060 --> 01:59:59.060
So the structure is we declare begin

01:59:59.820 --> 02:00:02.460
So we know the declare begin and end

02:00:02.460 --> 02:00:07.840
Now we add another blocks with this exception

02:00:07.840 --> 02:00:12.480
So we say when exception name then the result

02:00:12.480 --> 02:00:15.640
Ano yung message natin or ano yung gagawin niya

02:00:15.640 --> 02:00:20.400
Will it revert the transaction or will it do something

02:00:20.400 --> 02:00:22.820
Same with this and this

02:00:22.820 --> 02:00:27.840
So the other one that is predefined is the zero underscore divide

02:00:27.840 --> 02:00:31.500
It raised when there's attempt to divide by zero

02:00:31.500 --> 02:00:35.660
Or invalid number when there's a data conversion issue

02:00:35.660 --> 02:00:40.820
At least malaman natin yung mga predefined then na pwede natin magami

02:00:47.620 --> 02:00:49.760
So example of that

02:00:49.760 --> 02:00:54.140
So we declare salary number low salary exception

02:00:54.760 --> 02:00:59.820
So begin if salary is 30,000 then raise low salary

02:00:59.820 --> 02:01:06.540
And if DBMS put line salary is acceptable

02:01:06.540 --> 02:01:12.940
Exception when low salary then DBMS put line error salary is too low

02:01:13.760 --> 02:01:17.440
So I think let's try it to try the exception sample

02:01:19.760 --> 02:01:23.760
I'll put the code in the Google sheet

02:01:27.740 --> 02:01:29.600
Trapping errors

02:01:31.780 --> 02:01:35.220
Let's really quickly try that

02:01:35.760 --> 02:01:41.640
So we declare the salary number we assign 20,000 value

02:01:41.640 --> 02:01:45.400
We declare low underscore salary exception

02:01:46.400 --> 02:01:53.400
So sabi na if salary is less than 30,000

02:01:54.280 --> 02:01:56.400
Gagawin niya raise low salary

02:01:59.560 --> 02:02:03.400
And if tapos po talagang sa exception

02:02:03.940 --> 02:02:06.540
When low salary

02:02:09.580 --> 02:02:11.800
When low salary

02:02:14.680 --> 02:02:18.500
Then output niya salary is too low error

02:02:18.500 --> 02:02:21.520
Okay so let's try that

02:02:34.680 --> 02:02:37.480
Then try to change the number

02:02:40.800 --> 02:02:46.620
So if you change the number it should say salary is acceptable

02:02:49.480 --> 02:02:54.620
Nakita niya pag hindi natin binago it's 30,000

02:02:55.260 --> 02:02:58.620
It says salary is too low

02:03:02.480 --> 02:03:04.640
Try to play with the numbers

02:03:18.220 --> 02:03:24.180
Yung raise yan yung word na statement is used explicitly to raise an exception

02:03:24.180 --> 02:03:32.800
So exception and PLSQL are used to handle errors or unusual condition during the execution program

02:03:32.800 --> 02:03:39.800
So to trigger the pre-defined exception we can use raise no data found for example

02:03:39.800 --> 02:03:42.840
Or raise my exception

02:03:42.840 --> 02:03:46.380
Then when my exception

02:03:46.380 --> 02:03:51.240
So parang niraise na to since when it's true the low salary

02:03:51.240 --> 02:03:52.940
Kaya niya ipapakita to

02:03:52.940 --> 02:03:55.840
Otherwise hindi niya mariraise yung exception

02:03:56.580 --> 02:03:59.520
Ito yung ipapakita niya salary is acceptable

02:03:59.520 --> 02:04:01.800
Okay po

02:04:11.120 --> 02:04:14.460
So raise application error

02:04:14.460 --> 02:04:16.700
So we declare salary number

02:04:16.700 --> 02:04:19.520
So if salary is less than 30,000

02:04:20.360 --> 02:04:22.520
So we can raise application error

02:04:23.040 --> 02:04:26.880
So it's built in as well

02:04:26.880 --> 02:04:29.420
Explicit in the PLSQL

02:04:29.420 --> 02:04:32.880
And we can have an error code

02:04:33.560 --> 02:04:37.620
Then a message salary below minimum required level

02:04:37.620 --> 02:04:41.280
And if then we in exception

02:04:41.280 --> 02:04:50.000
So if it is when others we can raise this built in error code

02:04:50.000 --> 02:04:54.820
Which I will explain in a bit

02:04:57.960 --> 02:05:05.440
So yung SQL ERM is a function to retrieve the error message for the exception that occur

02:05:05.440 --> 02:05:13.040
So it's a built in function that returns the error message associated with the most recently raised exception

02:05:13.040 --> 02:05:17.700
It is typically used in exception handling to provide meaningful feedback

02:05:17.700 --> 02:05:20.800
Or lagging about the error that occur

02:05:20.800 --> 02:05:27.780
So when others block catches the raised error and display the custom error message

02:05:27.780 --> 02:05:34.700
So the custom error messaging provide specific and meaningful error message tailored to your application requirements

02:05:35.640 --> 02:05:42.060
The error numbers allows you to categorize user defined errors using a unique error number range

02:05:42.060 --> 02:05:50.340
Then the debugging support the SQL ERRM makes it easy to log or display error message for troubleshooting

02:05:50.340 --> 02:05:59.760
So using raise application error ensure that your PLSQL program enforce business rules clearly and communicate errors effectively

02:05:59.760 --> 02:06:03.180
So let's try to move on the internal errors

02:06:03.180 --> 02:06:15.240
So internal errors in PLSQL are the unexpected condition or system level issues that occur during the execution of program

02:06:15.240 --> 02:06:23.740
You know this error often stem from database malfunction, maybe resource constraint or underlying system problems

02:06:23.740 --> 02:06:27.780
So let's explore common types of internal errors

02:06:28.560 --> 02:06:36.200
It's good that now we know and we identify, oh this is more on server or this is more on my error

02:06:36.200 --> 02:06:42.780
So we know, so first is the ORA00600, it's an internal error

02:06:43.940 --> 02:06:46.920
Indicates that a serious issue with the Oracle kernel

02:06:46.920 --> 02:06:51.140
So if you're the one who is managing the server, it's really critical

02:06:53.340 --> 02:06:59.720
It's a low level system error that typically request Oracle to support and diagnose and resolve

02:06:59.720 --> 02:07:05.140
Then the 4031, it's meaning insufficient shared memory

02:07:05.680 --> 02:07:11.700
So when Oracle cannot allocate memory from the shared pool especially if you're using the cloud

02:07:11.700 --> 02:07:20.020
Then common cause include insufficient memory in the shared pool or higher memory demands from SQL statement or PLSQL blocks

02:07:20.020 --> 02:07:26.360
Then the 1555, meaning snapshot is too old

02:07:26.360 --> 02:07:34.680
You know triggered during long running, read consistent cursor, Oracle cannot retrieve a consistent snapshot of the data

02:07:34.680 --> 02:07:43.120
Then the 01000, it's a maximum open cursor exceeded because it's such limit

02:07:43.120 --> 02:07:49.260
It's occur when a program exceed the database configured limit per open cursor

02:07:49.260 --> 02:07:53.000
Commonly caused by not closing the cursor properly in the code

02:07:53.000 --> 02:08:00.260
So kapag hindi natin kasi clean ocean cursor, nakabukas lang siya, nasa memory lang siya

02:08:00.980 --> 02:08:08.780
So pwede natin ma-receive yan kung maraming nakabukas or yung iba hindi nagsasara or hindi nagsara sa code

02:08:08.780 --> 02:08:11.760
So ma-mari-receive natin yan

02:08:12.760 --> 02:08:27.480
So sa system level nature, so the internal errors usually indicate system level problems or misconfiguration that require investigation beyond the application logic

02:08:27.480 --> 02:08:39.740
Preventive measure na pwede natin gawin, addressing this error often involves optimizing system resource, improving query performance or tuning the database parameter

02:08:39.740 --> 02:08:47.360
So pag yung ano naman, 600 is typically require Oracle support for resolution

02:08:48.780 --> 02:08:57.780
So understanding these internal errors help us identifying the root cause of critical issues implementing preventive measures

02:08:59.060 --> 02:09:04.160
Next let's discuss or mitigate and troubleshoot this type of errors effectively

02:09:06.440 --> 02:09:14.780
So in this example, we use sql errm, it returns the error message associated with that exception

02:09:18.200 --> 02:09:29.700
So as I said, it's a built-in function and also we use when others, it capture all the exception that are not explicitly handled by specific exception clauses

02:09:29.700 --> 02:09:37.500
It's useful for addressing unforeseen error including internal ones like 600 or 4031

02:09:39.740 --> 02:09:47.200
So the effective error handling includes not only catching error but also lagging them

02:09:47.200 --> 02:09:52.160
So pag nakatch natin sya, maganda ma-lag natin sya for diagnosis and resolution

02:09:52.160 --> 02:09:57.860
So by capturing error details, you can review and address issues systematically

02:09:57.860 --> 02:10:02.560
So let's explore an example of plugging internal errors

02:10:02.560 --> 02:10:11.980
So we can insert in the database, for example into error lag, the error code, error message, error time

02:10:11.980 --> 02:10:18.980
So the values is sql code, then the message sql errm and error time the system date

02:10:18.980 --> 02:10:22.900
Then we output antenna error correct has been logged

02:10:22.900 --> 02:10:28.340
So this is the suggestion how we can log the error

02:10:32.840 --> 02:10:39.880
So lagging errors to database table ensure that internal issues are recorded for analysis and resolution

02:10:39.880 --> 02:10:44.920
Making your PLS code programs more maintainable and reliable

02:10:46.100 --> 02:10:50.760
Next we'll discuss the best practices for designing and managing error lag table

02:10:51.820 --> 02:10:55.680
So when to seek the oracle support

02:10:57.640 --> 02:11:08.660
While internal error handling PLS code is robust, certain critical errors require expertise of oracle support for resolution

02:11:08.660 --> 02:11:20.400
So for critical errors like for example OR8-00600, it's recommended to consult oracle support

02:11:20.400 --> 02:11:26.440
These errors often involve deep technical troubleshooting

02:11:26.440 --> 02:11:34.700
It might be issue with the oracle kernel or underlying configuration, maybe misconfigured database parameter settings

02:11:34.700 --> 02:11:40.700
Or maybe you have patches or updates, problems that require software patches or upgrades

02:11:40.700 --> 02:11:49.280
And lastly is hardware limitation, maybe the resource already exhaust or constrained that may impact database performance

02:11:49.280 --> 02:11:56.100
So in summary we have internal errors, we have common internal errors

02:11:56.100 --> 02:11:59.480
Handling internal errors, use the when others

02:11:59.480 --> 02:12:05.920
To catch all the exception and log details for further investigation

02:12:05.920 --> 02:12:14.820
Then what other you can do is consult oracle support because they are expert in their server's database

02:12:14.820 --> 02:12:19.480
So as they often require advanced solution beyond application level troubleshooting

02:12:23.260 --> 02:12:28.340
So again the SQL code retrieves the numeric code of the error

02:12:28.340 --> 02:12:33.440
Then the SQL ERM retrieved the error message associated with the error code

02:12:33.440 --> 02:12:46.800
So in this case when no data found, we can put the code in the error message to get more information why we have that error

02:12:48.000 --> 02:12:57.340
So these are the example of the built-in in the PLSQL

02:13:00.980 --> 02:13:07.780
Meaning integrity constraint violated, cannot insert null, existing state, the package has been discharged

02:13:07.780 --> 02:13:19.340
Unable to allocate shared memory, so better if you have this on your side to check the error code

02:13:25.520 --> 02:13:30.500
So again how do we log the SQL code in SQL ERM

02:13:30.500 --> 02:13:38.560
So this is the code, so insert into the error code message and system date

02:13:40.480 --> 02:13:45.460
Kapag no data found, so when selecting the statement of no errors from table or view

02:13:45.460 --> 02:13:54.540
So it does not occur with normal select queries but specifically with select into we expect exactly one row of data

02:13:54.540 --> 02:14:01.560
So here we have select salary into salary for employees

02:14:01.560 --> 02:14:11.780
So kapag wala siyang nakita when no data found, it will fire this message

02:14:17.700 --> 02:14:26.560
Pwede rin tayo maglagay na kapag wala siyang nakita, ibabalik niya yung default values ng salary

02:14:26.560 --> 02:14:34.220
So don't forget the end, so begin, if you have begin you always have an end like this

02:14:34.220 --> 02:14:43.560
Begin and end then you can have exception that when data no found itang gagawin niya

02:14:47.960 --> 02:14:52.740
So you can use the no data found to control the flow of your program

02:14:52.740 --> 02:14:56.480
Such as inserting a new row if none exists

02:14:56.480 --> 02:15:01.340
So for example in this case nag select siya but walang na found

02:15:03.540 --> 02:15:08.760
So it will just insert the new data in this case for example

02:15:10.780 --> 02:15:22.700
So then making it output so inserting default record with salary 30,000

02:15:35.340 --> 02:15:42.160
So the purpose of no data found help handle cases where select into retrieve no rows

02:15:42.160 --> 02:15:49.940
Tapos we can catch the data found in the exception block to avoid errors and apply custom logic

02:15:49.940 --> 02:15:52.500
So kapag walang nakita what will you do?

02:15:53.020 --> 02:16:01.900
Then the application it display message assign default values or trigger alternative action when data is no found

02:16:04.140 --> 02:16:09.300
So step 2 user define exception, first we declare the exception

02:16:09.300 --> 02:16:15.400
So declare the exception in the declare section of your PL SQL block

02:16:15.400 --> 02:16:25.380
Then we raise the exception, use the raise statement to trigger the exception when a specific condition is met

02:16:25.380 --> 02:16:35.620
Then we handle the exception so add an exception handling block to manage the error when it's raised

02:16:35.620 --> 02:16:42.340
So you can say when custom exception kapag nag raise siya ng custom exception dito siya papasok

02:16:42.340 --> 02:16:49.580
Don't forget to declare it, so custom exception exception so it's very important to declare

02:16:49.580 --> 02:16:56.400
So baka nakalimutan niya i-declare tapos nag-run ka nito so mag-error yan

02:16:56.400 --> 02:17:00.340
So you have to declare it para magamit mo siya dito at dito

02:17:03.840 --> 02:17:09.780
So example of other user define exception, so salary number

02:17:09.780 --> 02:17:15.560
So again we declare low underscore salary variables as exception

02:17:16.560 --> 02:17:25.520
So if you know your salary is lower so we raise natin yung lower which is ginamit natin dito under the exception block

02:17:25.520 --> 02:17:34.780
So when low salary then just make it error or if you have other logic that you want to put

02:17:36.460 --> 02:17:37.960
Nag-gets po

02:17:41.440 --> 02:17:42.960
Thank you po

02:17:47.700 --> 02:17:52.720
Using user define exception with raise application error

02:17:52.720 --> 02:17:59.760
So raise application error produce allows you to define custom error codes and message for user define exception

02:17:59.760 --> 02:18:08.120
This provides standardized and controlled way to handle unique error scenarios in your PLS-CL program

02:18:08.120 --> 02:18:11.020
So let's explore how it works

02:18:11.020 --> 02:18:15.780
So yung syntax natin is raise underscore application underscore error

02:18:15.780 --> 02:18:19.460
Tapos yung error number comma error message

02:18:19.460 --> 02:18:30.600
So yung error number is a custom error code in the range of negative 20,000 to negative 20,999

02:18:30.600 --> 02:18:34.820
Then the error message display when the exception is raised

02:18:35.540 --> 02:18:39.060
So the advantage of that it has a clarity

02:18:40.280 --> 02:18:41.980
Inya yung pinakita natin

02:18:41.980 --> 02:18:44.100
Let me paste the code here

02:18:44.100 --> 02:18:46.240
You can try it later on

02:18:46.240 --> 02:18:48.240
I'll paste it in the google

02:18:50.120 --> 02:18:52.240
Or I think I already have

02:18:55.840 --> 02:18:58.680
User define exception

02:19:01.240 --> 02:19:07.300
By the way tomorrow we have multiple choice quick exam 30 items

02:19:13.000 --> 02:19:14.920
So let's move on

02:19:14.920 --> 02:19:17.400
So the advantage of that is

02:19:17.400 --> 02:19:18.920
Go ahead

02:19:21.260 --> 02:19:28.680
Okay so the advantage of that is you have the clarity, the control and the standardization

02:19:29.500 --> 02:19:36.300
So I think using raise application error with user define exception ensure that the PLS-CL programs

02:19:36.300 --> 02:19:43.540
Communicate errors effectively making debugging and application handling more intuitive and standardized

02:19:47.000 --> 02:19:50.320
So pa na ba natin kagimitin yung raise application error

02:19:50.320 --> 02:19:53.920
So check if salary is below the threshold

02:19:53.920 --> 02:19:58.880
So we use the raise application error yung error code

02:19:58.880 --> 02:20:04.860
So again from negative 20,000 to 20,999 ang pwede natin gamitin

02:20:04.860 --> 02:20:08.580
Then salary is below the minimum required level

02:20:09.340 --> 02:20:12.840
So pag nag error siya dito siya papasok

02:20:12.840 --> 02:20:18.860
When others then dbms put line error tapos yung error message

02:20:20.940 --> 02:20:30.520
So again yung error number negative integer between negative 20,000 and negative 20,999

02:20:30.520 --> 02:20:33.560
It's a reserve for user define errors

02:20:34.840 --> 02:20:39.600
This range help differentiate custom error from oracle predefined ones

02:20:39.600 --> 02:20:47.260
Then the error message a descriptive string up to 2048 character that explain the error

02:20:47.260 --> 02:20:55.780
So ang key points natin yung raise application error can only be used within the PLS-QL blocks

02:20:55.780 --> 02:21:00.260
It's typically employed in begin or exception section

02:21:00.260 --> 02:21:06.140
Then execution flow nya when invoke it terminates the execution of the PLS-QL block

02:21:06.140 --> 02:21:14.460
The error code message are returned to the calling environment making them accessible for further handling or logging

02:21:19.760 --> 02:21:23.340
So ito yung sample syntax natin

02:21:23.340 --> 02:21:27.260
So here nag raise siya ng error code

02:21:27.260 --> 02:21:32.140
So ang magiging code nito is yung negative 20,001

02:21:34.420 --> 02:21:38.140
Tapos yung error message natin ito yun

02:21:39.020 --> 02:21:44.140
I think let's try this

02:21:44.720 --> 02:21:47.140
Let's try really quick

02:21:47.920 --> 02:21:50.140
Para makita natin siya

02:21:50.760 --> 02:22:01.160
I'll paste it now in the try this raise application error

02:22:01.160 --> 02:22:03.160
Okay I pasted it

02:22:03.780 --> 02:22:06.160
Try to paste or try to check

02:22:07.140 --> 02:22:18.100
So if salary ang gagawin niya yung raise nya and if put line tapos exception when others

02:22:33.420 --> 02:22:37.160
Salary is greater than or less than

02:22:52.780 --> 02:22:55.800
One moment let me fix the code

02:23:15.540 --> 02:23:18.840
Okay I paste the correct code in the Google sheet

02:23:31.660 --> 02:23:34.920
You see the error code it change

02:23:35.780 --> 02:23:42.560
Then try to change the 20,001 to negative 20,002

02:23:43.160 --> 02:23:49.340
You see the error code and error message as well

02:23:50.760 --> 02:23:53.040
Na-check nyo pa

02:24:15.740 --> 02:24:20.500
Try to change the error code to negative 20,003

02:24:25.960 --> 02:24:36.640
So in your company you can have documentation that hey if it is 20,001 this is the equivalent something like that

02:24:36.640 --> 02:24:39.720
Okay so let's move on

02:24:39.720 --> 02:24:43.760
We have 30 minutes more for today

02:24:45.180 --> 02:24:49.300
So example of raise application error in business logic validation

02:24:49.300 --> 02:24:53.560
So here we declare account balance, withdrawal amount

02:24:53.560 --> 02:25:02.140
Then if withdrawal amount is greater than account balance then raise application insufficient for request withdrawal

02:25:02.140 --> 02:25:07.780
Then account balance is account balance minus withdrawal

02:25:08.300 --> 02:25:13.540
So pag successful siya saka niya lang ibabawa siya account balance otherwise mag gradation error

02:25:13.540 --> 02:25:16.340
Which is this one

02:25:19.880 --> 02:25:28.880
But kung pumasa siya if it is false then gagawin siya to

02:25:28.880 --> 02:25:33.180
Babawasan niya account balance then display the output

02:25:35.340 --> 02:25:39.060
Using application raise application error in stored procedure

02:25:39.060 --> 02:25:45.480
Okay so here we create or replace procedure

02:25:45.480 --> 02:25:49.080
Check age as begin

02:25:49.080 --> 02:25:55.280
So if age is greater less than 18 so mag rais application error

02:25:55.280 --> 02:26:00.880
So here we just raise it but we don't have exception

02:26:00.880 --> 02:26:06.980
So we can do that in creating procedure

02:26:06.980 --> 02:26:13.300
So it helps you to create meaningful user friendly error message for unique application condition

02:26:13.300 --> 02:26:15.700
Improving your code

02:26:17.500 --> 02:26:21.240
How about when others to catch non-defined errors

02:26:21.240 --> 02:26:30.120
So here we try to 100 divide by divisor which is 0

02:26:30.120 --> 02:26:34.800
So the when others is placed at the end of exception block

02:26:35.880 --> 02:26:43.120
It will catch any error not handled by other specific when clauses allowing it to log display

02:26:44.500 --> 02:26:47.860
Or handle the error in a standardized way

02:26:47.860 --> 02:26:51.320
So kapag hindi pumasa dun sa ibang mga when

02:26:51.320 --> 02:26:53.400
So dun siya pumunta sa when others

02:26:53.400 --> 02:26:57.120
So it's better a good practice to have when others

02:26:57.120 --> 02:27:02.420
Then parataos pwedeng ilag dito yung error sa database

02:27:05.860 --> 02:27:09.780
Eto naman yung paglalag natin no non-defined errors

02:27:10.740 --> 02:27:19.120
But of course you have to create your table error log for it to record into your table for all the errors

02:27:21.600 --> 02:27:27.680
So again sql code returns a numeric error code associated with exception

02:27:27.680 --> 02:27:31.160
Then the sql erm is the message

02:27:31.160 --> 02:27:39.600
So best practice when others use sparring license when other cache owner using mainly as a last resort of the error handler

02:27:39.600 --> 02:27:45.380
Log and re-raise in complex application log the error and re-raise it using raise

02:27:45.380 --> 02:27:49.220
So the error can propagate up to higher level handlers

02:27:49.220 --> 02:27:54.600
And provide context ensure meaningful error message or log to makes debugging easier

02:27:58.180 --> 02:28:04.040
So eto yung sample natin ng logging and re-raising the error

02:28:04.040 --> 02:28:09.120
So we declare device or numbers colon 0 result number

02:28:09.120 --> 02:28:17.120
So pag nag-error siya pumunta siya dito then ir-raise niya yung error

02:28:20.720 --> 02:28:23.840
Why use pragma exception in it?

02:28:26.420 --> 02:28:35.060
So pragma exception in it is a directive that allow you to associate a user-defined exception with oracle error code

02:28:35.060 --> 02:28:41.120
This enable siya to handle specific oracle errors as name exception in your code

02:28:41.120 --> 02:28:44.620
Making your exception handling more readable and organized

02:28:44.620 --> 02:28:51.900
So without the pragma exception in it you can only handle oracle errors code using the when others

02:28:51.900 --> 02:28:59.180
Catch all or by directly comparing sql code by using pragma exception in it

02:28:59.180 --> 02:29:03.780
You assign a meaningful name to specific oracle error code

02:29:03.780 --> 02:29:08.120
Allowing you to manage it with descriptive user defined exception

02:29:08.120 --> 02:29:15.240
So let's say you want to handle the 1400 error

02:29:15.240 --> 02:29:21.000
Which is raised when a null value is inserted in the column that cannot be null

02:29:21.000 --> 02:29:28.180
So here we declare the exception we associate with oracle error using pragma exception in it

02:29:28.180 --> 02:29:32.520
Handle the exception in the exception block

02:29:34.960 --> 02:29:37.100
So here's the example

02:29:37.100 --> 02:29:41.060
So we declare null value error exception

02:29:41.060 --> 02:29:43.220
This is the step one

02:29:43.220 --> 02:29:50.620
Then the step two is we associate with ora 1400 the null value error

02:29:51.180 --> 02:29:53.720
Minus 1400

02:29:54.500 --> 02:29:58.920
So we attempt to insert a null value into null column

02:30:00.840 --> 02:30:07.140
So for example we declare we say to the table that first name should be not null

02:30:07.140 --> 02:30:09.860
And we're trying to insert a null

02:30:10.600 --> 02:30:14.020
So when we do this it will go to the exception

02:30:15.300 --> 02:30:22.020
Then it will go or fall into this specific error

02:30:26.780 --> 02:30:33.800
So alongside this main column it is important to follow best practices for the film

02:30:33.800 --> 02:30:41.840
Oops sorry where should I have here one moment

02:30:41.840 --> 02:30:46.720
So handling multiple errors with pragma exception in it

02:30:47.750 --> 02:30:54.210
So we declare the null value error exception then unique violation exception

02:30:54.910 --> 02:31:03.910
Then we put the pragma exception in the null value error as negative 4800 error code and unique violation negative one

02:31:04.510 --> 02:31:10.750
So we insert employees employee ID for his name

02:31:10.750 --> 02:31:12.930
So if the error is null

02:31:12.930 --> 02:31:17.310
So here's the message of attempting to insert null into null column value

02:31:17.310 --> 02:31:22.410
Or if the unique violation was triggered

02:31:22.410 --> 02:31:30.650
It will do the when unique validation it will say duplicate value found on the unique constraint

02:31:30.650 --> 02:31:35.930
Kasi yung employee ID is primary key and it should be unique

02:31:39.260 --> 02:31:42.860
So let's begin insert

02:31:42.860 --> 02:31:50.700
In this example we have the commit statement

02:31:50.700 --> 02:31:52.780
Am I correct one moment

02:31:56.320 --> 02:32:06.780
By default the commit statement is used to save changes made during a transaction permanently

02:32:08.860 --> 02:32:16.380
So ito yung code natin we insert into employee is the value

02:32:16.380 --> 02:32:21.800
So this commit function ensure that the new employee record is saved permanently

02:32:21.800 --> 02:32:32.080
So yung auto commit kapag naka off hindi siya mas save unless you put this commit

02:32:34.940 --> 02:32:43.820
Then the rollback kasi minsan we have to rollback all the changes especially in financial transaction

02:32:43.820 --> 02:32:49.000
If like error in the middle or if there's any discrepancy

02:32:49.000 --> 02:32:54.400
So the rollback command undoes all changes made in the current transaction

02:32:55.000 --> 02:32:57.700
So reverting the database to its previous state

02:32:57.700 --> 02:33:04.080
So it's very helpful when error occurs or when you want to cancel a series of operation

02:33:05.820 --> 02:33:09.540
So example of that is when we update employee

02:33:09.540 --> 02:33:12.760
Sinat natin yung salary niyo ng 65,000

02:33:12.760 --> 02:33:15.340
Dun sa employee ID na 10005

02:33:15.340 --> 02:33:17.060
Then we rollback

02:33:17.060 --> 02:33:23.540
The rollback command undoes the update operation so the salary remains unchanged

02:33:25.080 --> 02:33:31.480
So let's try to do the commit and rollback

02:33:31.480 --> 02:33:37.100
So let's try to code this one moment

02:33:37.100 --> 02:33:41.720
I'll put that in our coding

02:33:41.720 --> 02:33:45.520
Let's try the commit and rollback

02:33:48.720 --> 02:33:52.820
So we begin at inserting new employees

02:33:53.720 --> 02:33:57.980
So in our case it's employees and EMP ID

02:33:58.720 --> 02:34:00.880
Then first name

02:34:01.720 --> 02:34:04.300
Wala pa tayong last name eh

02:34:04.300 --> 02:34:06.620
We only have department

02:34:09.440 --> 02:34:11.900
ID then salary

02:34:13.840 --> 02:34:17.640
Tapos i-update natin yung employees

02:34:20.620 --> 02:34:24.020
Is set natin yung salary niya

02:34:24.620 --> 02:34:26.620
To 70,000

02:34:27.280 --> 02:34:29.560
Where EMP ID

02:34:35.160 --> 02:34:36.520
Is 1002

02:34:36.520 --> 02:34:39.120
Tapos na try natin i-commit

02:34:40.560 --> 02:34:44.280
Pag may error pwede natin i-rollback

02:34:44.280 --> 02:34:47.440
So try natin gawan siya ng error

02:34:48.140 --> 02:34:50.700
For example we will insert

02:34:51.560 --> 02:34:53.580
Or here in the update

02:34:53.580 --> 02:34:57.380
I-try natin mag-update pero wala yung ID

02:34:57.380 --> 02:35:01.160
So try natin if mag-rollback siya

02:35:01.160 --> 02:35:06.100
If it is throw an error

02:35:20.580 --> 02:35:21.220
Rollback

02:35:22.020 --> 02:35:25.380
I think I'll make it down one moment

02:35:28.200 --> 02:35:30.340
Ya it's on the last page

02:35:30.340 --> 02:35:32.220
Then after the rollback

02:35:32.220 --> 02:35:35.840
It doesn't change the rollback

02:36:04.460 --> 02:36:09.200
Kasta nandito rin natin i-insert is

02:36:11.620 --> 02:36:14.100
ID and department ID ba

02:36:45.320 --> 02:36:48.740
So try natin palitan yung

02:36:48.740 --> 02:36:50.540
Wala tayong last name

02:36:50.540 --> 02:36:55.160
Wala tayong last name

02:36:58.740 --> 02:37:01.780
Tapos yung department ID natin is 10

02:37:02.580 --> 02:37:04.900
So yung nasa ba yung ginagawa ko yung tama

02:37:35.700 --> 02:37:36.840
Okay

02:37:41.620 --> 02:37:43.520
So let's continue

02:37:43.520 --> 02:37:46.840
We have like less than 20 minutes

02:37:46.840 --> 02:37:50.620
So the key difference with

02:37:50.620 --> 02:37:51.340
Oops

02:38:01.020 --> 02:38:03.560
So the key difference is commit

02:38:03.560 --> 02:38:06.360
It saves changes permanently

02:38:06.360 --> 02:38:10.660
It saves all changes made in the transaction permanently to the database

02:38:10.660 --> 02:38:12.640
Once issued

02:38:12.640 --> 02:38:15.020
Changes cannot be undone

02:38:15.020 --> 02:38:17.740
Once na nakomit mo di mo nang babalik

02:38:17.740 --> 02:38:22.660
It's commonly used after successful transaction like insert, updates, or delete

02:38:23.380 --> 02:38:26.620
Rollback and that's all changes made in the transaction

02:38:26.620 --> 02:38:29.840
Restoring the database to its previous state

02:38:29.840 --> 02:38:35.020
Useful for handling errors or canceling transaction that did not meet expectation

02:38:35.020 --> 02:38:38.740
Ensure that no unintentional changes are saved

02:38:39.260 --> 02:38:41.180
May isa pa yung locks

02:38:41.180 --> 02:38:45.580
Yung both commit and rollback release any locks held by transaction

02:38:45.580 --> 02:38:48.320
Bring resources for other operation

02:38:48.320 --> 02:38:50.780
For example nga yung pag-withdraw

02:38:51.580 --> 02:39:00.660
Kalangan na check lahat bago ma-initiate yung commit

02:39:02.580 --> 02:39:04.640
So structure of nested block

02:39:04.640 --> 02:39:06.760
So we have the declare

02:39:06.760 --> 02:39:08.480
Declare number of variables

02:39:08.480 --> 02:39:09.920
Then we begin

02:39:10.580 --> 02:39:13.680
Then we declare the inner block declaration

02:39:13.680 --> 02:39:14.780
Begin

02:39:15.680 --> 02:39:17.820
Then inner block code

02:39:17.820 --> 02:39:19.820
Then we do the exception

02:39:19.820 --> 02:39:22.880
So if may error dun sa inner exception

02:39:22.880 --> 02:39:24.680
Dito siya papasok

02:39:25.360 --> 02:39:29.820
Otherwise kung may error sa loob na to

02:39:29.820 --> 02:39:31.780
Dito yung exception nya

02:39:31.780 --> 02:39:34.060
So outer block exception handling

02:39:35.720 --> 02:39:37.820
So basic nested block

02:39:37.820 --> 02:39:39.300
So outer variable

02:39:39.300 --> 02:39:40.880
We declare number

02:39:40.880 --> 02:39:45.480
Then we say this is the outer block variable

02:39:45.480 --> 02:39:48.760
So we declare inner variable number 50

02:39:49.880 --> 02:39:53.740
Then we output the inner block variable

02:39:54.740 --> 02:39:59.360
Then we output the accessing outer variable from inner block

02:39:59.360 --> 02:40:02.340
Kasi accessible naman to sa loob nya

02:40:02.880 --> 02:40:07.180
So this is how you do nested block

02:40:07.880 --> 02:40:09.900
Kasi you have declare declare

02:40:09.900 --> 02:40:13.660
So pwede ka pa magkaroon nyan dito ng declare

02:40:15.960 --> 02:40:20.140
So nested block with local exception handling

02:40:20.140 --> 02:40:22.900
So nag declare tayo

02:40:23.900 --> 02:40:24.900
Then we begin

02:40:25.900 --> 02:40:28.900
Putline iting starting outer block natin

02:40:29.720 --> 02:40:31.200
Then another nested

02:40:31.200 --> 02:40:33.060
So nag begin tayo ulit

02:40:33.060 --> 02:40:35.800
Din declare natin yung inner divisor resolved

02:40:35.800 --> 02:40:38.060
Then nag begin tayo ulit

02:40:38.060 --> 02:40:41.060
This will cause division 0 by error

02:40:41.640 --> 02:40:44.240
Tapos pag may error dito

02:40:44.240 --> 02:40:45.900
Dito siya papasok

02:40:47.060 --> 02:40:51.060
Tapos after ng begin may exception siya

02:40:52.180 --> 02:40:54.440
Exception then end

02:40:54.440 --> 02:40:58.020
Tapos may end pa rin yung begin dito

02:40:58.020 --> 02:41:00.020
So dito yung exception nya

02:41:00.020 --> 02:41:07.020
Yung sa labas ng o sa loob ng begin nato

02:41:08.200 --> 02:41:10.880
Kaya make it sure kapag nangcode kayo

02:41:10.880 --> 02:41:14.520
It's properly indented like we discussed a while ago

02:41:14.520 --> 02:41:20.080
Tapos all caps yung DBMS yung mga keywords

02:41:20.080 --> 02:41:21.780
Para madali siyang mabasa

02:41:21.780 --> 02:41:23.420
Kasi pag marami ng code

02:41:23.420 --> 02:41:25.380
Medyo mahirap naman mag read

02:41:26.020 --> 02:41:28.440
Tapos make it sure may proper comment

02:41:28.440 --> 02:41:33.680
Especially sa mga functions sa mga conditions

02:41:36.260 --> 02:41:40.000
Using variables across nested blocks

02:41:40.000 --> 02:41:42.420
So we declare the salary number

02:41:42.420 --> 02:41:47.080
So we begin with starting block initial salary

02:41:47.080 --> 02:41:50.800
Tapos nag declare tayo increment

02:41:50.800 --> 02:41:55.740
So ang pinagusapan natin dito yung variables na salary

02:41:55.740 --> 02:41:58.740
Na magigamit natin dito

02:41:58.740 --> 02:42:01.840
That we can use across the block

02:42:01.840 --> 02:42:04.340
So variables scope yan

02:42:04.340 --> 02:42:08.220
So variables in the outer block are accessible within the inner block

02:42:08.220 --> 02:42:12.940
But inner block variables are local to that block

02:42:12.940 --> 02:42:13.820
Okay

02:42:13.820 --> 02:42:15.980
So local exception handling

02:42:15.980 --> 02:42:19.680
You can handle a specific exception within the inner block

02:42:19.680 --> 02:42:23.320
Without impacting the entire outer block

02:42:23.320 --> 02:42:25.320
And also data sharing

02:42:25.320 --> 02:42:32.000
So outer block variables can be modified in nested block to share across scope

02:42:32.000 --> 02:42:35.740
So nested blocks are a powerful feature in PLSQL

02:42:35.740 --> 02:42:39.960
For structuring code, managing error codes, and controlling variable scope

02:42:39.960 --> 02:42:44.660
Helping you to build clear and robust PLSQL program

02:42:46.680 --> 02:42:50.320
So yeah, so iteration and looping

02:42:52.960 --> 02:42:55.240
Siguro, siguro let's try this

02:42:55.240 --> 02:42:59.100
Para tomorrow we can have the new topic

02:42:59.100 --> 02:43:01.320
Which is iteration and looping

02:43:03.640 --> 02:43:05.320
So let's try this

02:43:07.120 --> 02:43:12.940
Let's try to play with using variable in the nested blocks

02:43:14.080 --> 02:43:17.320
Let me put that in the Google sheet

02:43:18.740 --> 02:43:20.740
Step 3

02:43:30.740 --> 02:43:33.680
Okay so we declare number salary

02:43:34.740 --> 02:43:37.140
50,000 begin

02:43:38.740 --> 02:43:40.400
Then we declare

02:43:41.740 --> 02:43:43.780
Then we increment

02:43:45.860 --> 02:43:47.060
Number

02:43:48.780 --> 02:43:50.780
Then we begin again

02:44:00.780 --> 02:44:02.920
Okay let's try this block

02:44:20.200 --> 02:44:21.980
Did you try it guys?

02:44:25.340 --> 02:44:27.860
Let me know if you run any error

02:44:30.340 --> 02:44:34.280
Try to play with the number as well

02:44:35.580 --> 02:44:37.760
Try to change the number

02:44:37.760 --> 02:44:39.200
See if it is increment

02:44:39.200 --> 02:44:43.760
See if the operation does

02:44:43.760 --> 02:44:45.400
It's staying

02:44:48.380 --> 02:44:54.640
So you should see the starting outer block, initial salary, inner block updated

02:44:54.640 --> 02:44:56.760
Then the final salary

02:45:06.160 --> 02:45:07.760
Nag-run po sa inyo

02:45:09.880 --> 02:45:10.480
Nice

02:45:16.180 --> 02:45:17.180
Yes

02:45:20.760 --> 02:45:22.280
Siguro before we end

02:45:22.280 --> 02:45:25.400
Do you have any more question, clarification

02:45:28.760 --> 02:45:31.080
So our topic for

02:45:31.080 --> 02:45:32.000
Go ahead

02:45:39.360 --> 02:45:41.860
Okay one moment

02:45:43.820 --> 02:45:45.760
Thank you po

02:45:50.520 --> 02:45:51.080
Yeah

02:45:51.760 --> 02:45:52.420
Ayun na po

02:45:52.420 --> 02:45:55.600
Nagbabago siya pag na exit ko

02:45:56.960 --> 02:46:00.420
May nagbago po? May nag-add po ba ng question before?

02:46:02.100 --> 02:46:02.920
Parang wala naman o

02:46:02.920 --> 02:46:04.080
Wala naman ako nakita

02:46:04.080 --> 02:46:06.700
But yeah here's the

02:46:06.700 --> 02:46:14.900
When I stop the presentation or accidentally stop

02:46:14.900 --> 02:46:17.400
Yun nagbabago siya ng URL

02:46:18.860 --> 02:46:21.020
Go ahead po

02:46:21.020 --> 02:46:23.580
Add na lang yung question sa laptop namin

02:46:23.580 --> 02:46:25.580
Siguro evolve na lang yung question

02:46:25.580 --> 02:46:27.840
Yes, yes please

02:46:27.840 --> 02:46:29.360
Tapos i-

02:46:29.360 --> 02:46:30.440
Okay

02:46:30.440 --> 02:46:33.400
Then you have your PDF

02:46:33.400 --> 02:46:35.900
For the entire tutorial

02:46:35.900 --> 02:46:37.580
You can do advanced reading

02:46:37.580 --> 02:46:39.900
Then yeah I would love to hear your questions

02:46:47.400 --> 02:46:49.200
Awesome, awesome, awesome

02:46:49.200 --> 02:46:50.880
Yeah thank you

02:46:50.880 --> 02:46:53.320
Yeah so if you have any more question

02:46:53.320 --> 02:46:54.900
I think we can call it a day

02:46:56.800 --> 02:46:59.220
Thank you so much for your time guys

02:46:59.220 --> 02:47:01.360
See you tomorrow at 9am

02:47:02.320 --> 02:47:04.160
Thank you so much

02:47:04.160 --> 02:47:06.160
God bless po, bye bye po

02:47:06.900 --> 02:47:08.140
Thank you everyone

02:47:08.140 --> 02:47:10.060
Tapos dito na lang po yung

02:47:10.060 --> 02:47:12.740
Photo ng G-Drive ang sabi level na si recording

02:47:12.740 --> 02:47:14.400
Thank you, see you tomorrow

02:47:14.400 --> 02:47:16.160
Okay ma'am

02:47:24.380 --> 02:47:25.960
Okay na po, thank you po

02:47:25.960 --> 02:47:26.880
Okay po

02:49:49.980 --> 02:49:51.380
Okay po

02:49:51.380 --> 02:49:51.460
Okay po

02:49:51.460 --> 02:49:53.880
Okay po

02:49:55.760 --> 02:49:57.160
Okay po

02:49:57.160 --> 02:49:57.700
Okay po

02:49:57.700 --> 02:49:58.900
Okay po

02:49:58.900 --> 02:50:00.340
Okay po

02:50:00.340 --> 02:50:02.040
Okay po

02:50:02.040 --> 02:50:03.700
Okay po

02:50:03.700 --> 02:50:03.780
Okay po

02:50:03.780 --> 02:50:03.820
Okay po

03:49:35.480 --> 03:49:38.960
Ayan! Ayan na ba? Ayan na ba?