Lectue Script

Summary

Action Items & Next Steps

Overview of Query Processing

Query Processing Pipeline

Query Compiler Components

Parse Tree Construction

Relational Algebra Fundamentals

Selection Operation

Projection Operation

Join Operations

Set Operations

Additional Operations

Converting SQL to Logical Query Plans

Query Tree Construction

Notes

Transcript

So, how does or how do database systems process queries and how do they go on to to optimize their performance. Basically, you want to see how fast. The query is execute and which one is going to cost you computationally your cost. Okay, so if you understand the query processing concepts very well, it's going to be easy for you to do the optimization or the estimation.

We want to look at exactly what happens when a SQL is issued into the system. And if you recall, SQL is declarative language. Declarative meaning that just tell me what you want to get. Don't tell me how to get it. Don't tell me how to bring it out. I will give it to you.

So SQL basically does the donkey work. Or does any work behind it. So we, as advanced students, we want to understand what really happens behind the hood. So, of course, under processing, the query is going to be translated into some internal structure that the database system understands, and then it's through the structures that make decisions to take on...

The component that is responsible for this is the QueryOptProcessor. The QueryOptProcessor does the processing of the execution and also is responsible for...

So there are very many ways a particular query can be processed. You are looking at parsing. So, first thing, basically, which is going to be translating the query, the SQL query into class tree, which is basically... that is still in a high level but we want to put it, we want to reduce it to a more internal structure that a system would understand. So that process of converting,

structure. It's going to be very easy for you to do a direct translation of every single relation algebra operator into a relation algebra algorithm. And that is why we can define a logical credit plan as a null. Okay. So, overall, an overview of the query plan is you issue a legal SQL statement and then the operators in the queries are arranged in a tree format. The Russian algebra that you've been looking at is basically the one that was in a linear format.

So you've We arrange it in a tree format for easy visualization. So data in that tree comes from the bottom to the root. So the leads at the bottom, and then the root is basically gonna be at the top. The output comes from the roots. So anything that is final from the root becomes the result of the query.

And of course, that query can be executed in many ways, in multiple ways. And those ways are actually the ways that they're going to generate so many plots. Okay. So many, many times our queries implement indexes. Therefore, we're going to be... you would want to use an index scan. Every time an index is applied, it's very beneficial for you to use an index plan.

The description you see here basically indicates query optimization. And you can see that hey, the query has so many plans and these plans are associated costs. But we're not going to go with all the costs. You want to go with the cost that is the least cost.

The least cost is the most optimal. And how do you know it's a least cause? You see it's a least cause by looking at two metrics. We're going to look at two metrics. Number of tuples in that intermediate and the number of times the disk is accessed. to be read or input. Okay. So, yeah. So processing, step-by-step of step to process SQL. So these are the steps if you want to process an SQL. You can see a legal SQL select first name, last name from two tables, employee and department, where the D number is equal to D number, department number is equal to department number, and also department name is research.

So you can see, if that legal query is sent in, the first component that is going to be interacted with is what we call the Query Compiler Angular Printer. That compiler now starts to take that query, to break it down into a smaller...

We're going to be able to come up with this physical query plan. So this physical query plan is the plan that indicates This plan indicates algorithm. So every single item that you see here is an algorithm. Okay, so we're going to do a projection. You're going to pull an index join algorithm, index scan, and the table scan. These are all algorithms that you have to pull out. And of course, whatever plan that you, physical plan that you choose based on the cost is the one going to be executed and the output will come there.

If you further look into the compiler, you're going to find the three major components. The parser, query-rewrite, and the compiler. and also a physical query plan generational constructor. So again, our query is very evident, is very basic. You can understand that very easily. And.

so in the past we say the past is going to give us this output okay and this output effect you know so this output It's basically worked on in many... So we do a query transformation. You keep on transforming that query in... This is the logical query plan, which I'm going to call LQP. This LQP, you can see, is none other than sequential relation algebra operators.

So, our index scan is going to be on R. And the index can is reducing this table to 1. And then another index can on C is going to reduce the second table by 3. So I'm only dealing with 1 times 3. I'm dealing with an intermediate. Algorithm which can be a hash join, it could be an index join, it could be a match sort join, all this join is only going to be dealing with an intermediate of 3 tuples, as opposed to this one and this one, 25 tuples. So you can see that having these two is very beneficial.

What do I mean? Having the filters go down or be pushed down to their respective relation before they are subjected to a heavy operators like a hash join or all other joins, it is very beneficial. In that way. And we will see that when we look at the number of tuples. So number of tuples here is 25, number of tuples here is 3. This one is so much optimized because I am going to go through the 3 tuples faster than you who has 25 tuples.

If I'm projecting, it's going to be basically 7F. All right, so what have you just seen? You've basically seen how queries can be operated. I'll show you three ways. Especially for when you want to pick data from two tables. Now, going forward, this is basically the overview that we are looking at. A legal SQL is going to be issued, then there is going to be a first component that is going to handle it. It will handle it and have an output as a parse tree.

The internal database system is going to be like. The internal database system wants you to simplify it further into its language. And we use relational algebra. So, we want to kind of move this, which we are going to do it by query rewriting. So, query rewriting is continuing rewriting that into a fashion that is going to be fully...

with a join, or a natural join, or a different join. For this one, this is a theta join, because the join attribute there does not have the same name. So you can see that... This query now has been simplified to this. It's shorter. Some of the operations have been removed. So the less operations, the better. Meaning that, hey, you're skipping some line of code in the algorithm, okay? So that is one way of optimizing. The other way of optimizing, I told you we are going to scientifically calculate the result size based on the statistics that can be provided.

So we're not going to go through everything. We're only scanning through, get them, and expose them to the next operator which is going to do it. So this accounts for basically introduction to query processing and optimization. Okay, so if I look at our second slide, we want to dig deeper into these components. And this is an image that we've just gone through. We want to go straight to the parser and understand this parser. So the parser gets SQL and then it starts constructing.

So you cannot start optimizing at the physical level. No, we optimize at a logical level, such that anything that is physical means implementation. It is ready to go into the computer to be physically implemented. This is how the tool really translates it. So inside the parser, we see the parser has two core parts. The language parser and also the preprocessor. So in the language parser, it's basically going to be looking at the SQL. Converting SQL into...

A slightly internal format, which is the tree. And after that, we are going to check the preprocessor. You hear the word preprocessor. What are the things that are going to happen before we actually start processing? We want to check for correct syntax.

It's the one going to tell us, hey, you have a wrong SQL query, or you have an incorrect. Then we also replace virtual tables by the corresponding SQL used to obtain virtual tables. So you basically want to... Make sure that wherever there is a virtual table, you want to expand it, because virtual tables are not underlining tables or schemas in a tree. They are temporary holders. And for you to do a live query, you're going to basically need to run this underlining query schema.

This is something that, our first step that happens in the parser. So statements in SQL are clear. Clear SQL statements without any mistakes. We map it to a tree using a SELECT FROM WHERE construct. And then we say every component on that tree is either an atom or is a category.

So, this combination of atoms and syntactic categories can be used. to understand this arrangement of this tree, of the past tree. So look at atoms as elements that cannot further be broken down into smaller elements. Atoms cannot be divided. If you're looking at compiling costs, look at it as a terminal, that's the end.

So keywords here, like select, all of these ones, employee, all these. Constants can be that. Operators can be that. All these can be considered as atoms because we don't have, we can't choose the key words. to break into maybe some key words. Now, if it's not an atom, it's a category like you see right there, and this is the opposite. Lexical constructs or elements in programming language that can further be built upon. You basically can break them into different...

So this is basically taking us to the rules. If you want to translate an SQL to a PASS3, you need to follow some rules. So what are the properties of coming up with a pass-through? We say that any node there is either an atom of a category, meaning that, hey, if it's an atom then that atom does not have children. It cannot further be pointing to a child.

So the grammar, just like any other programming languages, The same thing, we have some standards that we use when we are translating the SQL to a tree. Look at it as a set of writing rules. As you write something, there are some things you need to follow.

If you are writing a tree, if you are going to be translating SQL into a parse tree, you need to follow some of those rules. Let's look at this translation from SQL to the logical query plan. So, in the simple terms, we say that hey, it is a legal SQL query, which is basically going to appear this way.

and the correct usage of the data. An example we know very well that we cannot You cannot do a computation where you're adding a string. and an integer. And then the other check that you need to check when you're preprocessing an SQL is to make sure that you resolve all the vital tables,So we replace the views with the corresponding Estuel Quebe. So this could be a An example.

So the thing is We don't want to work with the Vacho tables We want to make sure that we replace vegetables with the underlying steamer and that's why our power mount here is being replaced by the entire tree of this and you're going to have This holeThis whole, Tree, okay. Um... To represent basically this, to represent this R1, this virtual table with another sub query here.

So Um, Much of the optimization, the query optimization, we say it relies on the underlying concept.

We are looking at an internal representation. And why do we want an internal representation? The database system understands relational algebra or a sequence of relational algebra much more than a high level structured query language or even a high level power stream. So we are going to need it for analysis We are going to need internal representation for optimization. And of course, we need to heavily understand relational algebra.

You may have a complex relation but you can go on breaking it down into r1 then make sure r1 is an input in your r2 and then make sure your r2 is input to your r3 until you get your final That is what relation algebra is about. As we talk about relational algebra, We want to understand these two concepts. So... With the reduction algebra or the set of The algebra of sets. can be seen in two versions or two semantic versions, yes.

So when somebody say "exceptivagel" A set version, you're basically looking at elements. that do not Do not accept or do not contain duplicates, Elements. And then if you're looking at the back version, you're looking at a collection of elements. That's it. allow or contain duplicates. So relational algebra Can give you the two worlds I believe I can show you the multi-set. The multi-set is basically also the bag.

That are actually efficient when we're working with multiple sets And the others are efficient when you are working in self-advocacy. So by default, SQL is a bug semantic. Vagina. That's why in SQL we have things like this thing. We want to tell as to that, hey, can you Only return unique values.

or have minimal impact like we're gonna see So let's start with looking at the selection. Almost every relation algebra every SQL query that you're going to run many times is going to have It's going to require to run this operator, which is a selection. And this selection follows the predicate Everybody knows what the selection does. It's going to get a subset of rows that qualify basing on the predicate or condition So, what are you going to do?

If you want to represent this, this is the right syntax that is the right syntax for writing the selection Where C is going to be the condition which we also call the predicate. and R is the input the input is always going to be the relation So let's look at how these two vary when it's a set and when it's a bag. So one thing we have to do that we have to know is when we apply a selection, we're going to return all two poles that match the condition.

If you do not match the condition, you are going to be left out. Sometimes I like calling it a filter. It filters. You know... So for the set If T If T is a tuple and T is a member in R, For T to be selected as a set, it must fulfill or qualifyUh, in our condition. The same thing if I have so many teas, two pots that are repeated I have to make sure that each of those two poles still satisfy the condition.

So here we can say The set version The set version has equally the same same impact as the back version. the selection so here yes So for this T1, T2, T3, where these Ts are all the same, Each of the two poles is being treated independently. It's evaluated independently. As we go through one by one sequentially, we check whether it is going to satisfy the condition C. so that is basically sedation and this is an illustration This is an illustration and if I ask you is it a set version or a back version?

So what did we say about a set? Okay, it said house unique So 1, 2, 3 all the tuples are unique unless I'm gonna have 614 if I have this 2.3 and 2.4 are bugs because they are duplicates. And if I'm looking for My results on this bag version, so this is a bag If I'm looking out for this bad version of this I will also add another one here and this is also going to be a bag. Okay? All right. So if you're not doing a selection, you're basically doing projection And we all know what the projection does.

It's going to only return data or values of a specified attribute. If I say project A, the values I'm going to look at are only A's. Now, The beauty with projects You can be order I can say project ABC or project B CA project so it can you can basically You know... Choose which one counts for what we call the rearrangement. And also you can manipulate values. You can say a plus b plus c. You can say this.

The answer is count. Libos. count levels or number of levels. that the projection can allow you to do that. Now, how is the projection? in Russian algebra. That is how it is represented. Within That symbol we call it pi. So if you look at that R is being the input Pi is the operator that the system wants to understand And A can be an attribute or a list of attributes. Okay. So... A list of attributes like this one, ABC.

So two for one and two for three is the same. So when I'm projecting In the set version, it's going to be just one tool. because I don't want to have one again. But if I'm projecting It's a vision. So projecting makes a lot of sense. Makes a lot of sense. to have it in a To have it in a In the Bab Vajra Okay, because you can see the difference. Okay, so here the set version is basically not, does not give the same impact as the bad version.

You can actually see the illustration here. So... This is a set version And if I say 1614, that stands to be That goes to be a bad margin. project let's project a this is gonna be project a uh this is gonna be project b sorry Project Project B in the back This is a bug, this is a set. So a bag B is going to be 13, 12, 14, 14 if we are We don't have 14 here because it's a set. A set only has unique.

Okay, now that we know the projection and selection, most complex queries or complete queries are actually going to have to deal with both Like, you know Most of our queries are going to first define that Then later we're going to have a condition and later tell me if you are projecting A and C And then our final maybe we will call our one So this is going to be mostly our common attributes. And we'll say a composition of selection and project is going to stand out in most of the queries.

Now, what comes to your mind if you are seeing these two combination It means that we are reducing And... Let's start with the condition. Condition filters Selection filters on what? You can tell me what selection filters are. When you do a selection, what do we filter on? Anyone wants to try? OK, projection. What do we filter on? These are both filter operations If I have the condition I am filtering on rows Meaning I am reduced filter is reducing reduce on the number of rows Not all rows are going to make it in my condition.

So I'm going to reduce filter reduce If I have 21 columns I'm only going to be asking maybe one or two columns. So if I have 21 and if I have 100, so 21 times 100, that is the initial. If I apply my filter, it's going to be how many rows make it for the condition? Maybe three. Three times two. So I'm dealing with two roles as opposed to someone who's dealing with 2100 roles. Who is optimized? These are two operations that are going to help us optimize.

our queries. And we're gonna be talking about optimization. So these two operations are very powerful when we are going to start looking at that. Now The other The other attributes Uh... All operations that we can easily The word that is used in virtual algebra is renaming. And this is helping us when we want to unify some schemas. And we want to make some Self joins To be, to appear, clear which is a disambiguation of some self-join.

So we use the syntax is that symbol which you can also call row. You can see if we are taking this as a syntax, r will be the input which is our relation where the data is If you subject the data in relation With their role And A is going to be a list of attributes I'm renaming. So, whatever you see where an arrow is, is the new rename. attribute so we want to change every attribute to appear as B in R.

Now, we call it cross product. or you can call it Cartesian And this is your combining two tables. or two lessons. So... What is the cross product or what is a Cartesian? You are going to Mix. All possible combinations of those two. If I say each one of us is going to have possible combinations, I am going to have a link to everyone and everyone there is going to have a link with everyone. Is that gonna make sense?

That's why we say this Cartesian creates meaningless results. Meaningless result. Imagine you have instructor and courses at IIT. They are going to map me with every single course that is taught at the IIT. And what kind of logic are you going to get? Why am I going to be linked with bioscience? Science, why am I gonna be linked with architecture? You know? So that is why we say, hey, if you are going to If you want to mean this Cartesian, you are basically going to write it this way and this means that you want to look at all possible combinations.

So R and S are inputs, of course those are relations, all relations in our operations are inputs. And here the semantics, we are saying that the whole total combination of two poles R and S is what we are going to be looking at. And by definition, mathematically, we say that the Cartesian is a cross product.

Most of the joints are going to first run the Cartesian. Okay And we are saying that, hey, cross-joint is also called a Cartesian, and we have seen how it cross-multiplies. How about if it is not Cartesian but we want to Emphasize another joint. And let's look above the inner joint. This inner joint can be an equidjoint, it can be a theta joint, it can be a natural joint, depending on the condition.

All right. So yes, this thing It's a join what makes it a theta join and what makes it a an inner joy. So a theta joint It's going to be based on the condition. So we're going to combine related tuples. from two tables. We're going to match two poles using some random joint condition which we're going to call theta. So arbitrary joint condition random, a random can be That's the condition. Okay? so we're gonna join that feature now we're saying if this is this and this If we use equalityPlease, um,And is Joining RNS is actually going to be An equi-joint, if it's an equality.

So this one's an equality, this is an inequality. Inequality will be a theta-joint. How do you represent this theta joint?

So A natural joint will generate a relation that contains All two poles that have There are-combination of two So R and S with common values. For one or more articles. So here we're going to enforce equality. And we can say a natural joint is so close to an equijoint equality. So a force equality on all attributes with same name So the same naming standard which we also call the naming convention is where nitro-joins is applicable.

Now, does Nacho John have a short hand? Yes. We could also write a shorthand and if this is The attribute "this is equal to" also this Thank you. And how? How is this possible? In that illustration, I'm going to show that illustration. So a list of attributes in R-UnionB. So union B is basically plus the other secondary attributes in S. Now, why is the projection so important? The projection is important because strictly a natural joint is going to project In natural zone there is the projection.

Meaning that it's going to project and leave out a common attribute and only give a unique set of the common attributes.

So outer joint you want to retain information for also the R and S that do not match. So we don't want to lose that information. Instead we replace it with the null in the other table where we don't get a match. So in the left outer joint, how do you write it? You can see In left outer joint we emphasize the left elbow meaning the left elbow should appear the way it is. All of it. So we keep data from the left hand relation.

So what do we do? contain all tuples of S of R then join join join Join us. So this is all, first of all, that's what it's gonna do. We want to look at two poles in S, In R, An S? So a left joint is going to look at first of all The common attributes. There's going to be an inner joy. Okay, what's common in R and what's common in S? And then it's going to go on to say we also want to I include to pose in R that is not also include every 2.r that is not joined with a 2.s so that is the That is the other two poles that don't match.

The right joint is basically the opposite Okay.

And if you're looking at an illustration R, not enjoying S, S is going to be emphasized and you can see the entire S is there. Now you want to look at two points in S that have matched if only one, which is this two point here. The match is there. Then do you want to represent also the other two poles that do not have match? Yes. These two poles do not have match so finish them up with a null. And these two poles do not have match, finish them with a null.

Now a full joint A full joint is basically an intersection of a left joint and an R joint. And this is how you write it. R full join S is equal to R Left joint S intersection A union? Union I love John S. So how do you know this? So this is how we represent this. We're keeping data in both tables, but also we're going to include the data that matches that does not match in either tables. Okay, so that's the full joint.

The semantic here is going to be, if you look at this, this is the matching data, which is going to be like the intersection. This is the data here. If you're looking at a full joint, then this, we want all data in S. All the data in S and the data that does not match in R. So all the data in S, if this is R, this is S. So basically it's going to be this as well. Then union union union all the data in T that has no matching with S.

This is basically going to be R full join S, whereby it has data that matches and data in one table but does not match in another table. in either table, so you can have nausea and amnesia. Okay. So we know very well that another Another OBJECTION Our operator that we're going to look at is aggregation. And aggregation work hand in hand with Groupby. Stop here.

I'm going to add all 1 plus 3 is 4 Then 1+3 is 4 again. This is 8. So this is gonna come here and have eight. Upper two, my second group. My second group is 2, 1, 2. I did one. so six Plus three, nine. 9 plus 6. Which is? 9+6 is 15, so this is gonna come here 15 So this will be the result Of this function if R has been considered as a bar Okay. And how would you write this as a tree? We would write this function as a tree This way, so our R is an input comes down Then followed by Um...

So you need a duplicate removal and you can see the syntax the syntax here for duplicate removal is something like this Okay, now do not confuse this duplicate mobile for Their selection Selection is just like that and duplicate removal exists. So this is probably a sigma.

In a set because it's already in removal, it's not required here. It's required on duplicate, so it's required on duplicate and it makes Many copies, one copy. Now one thing you need to know is it's very expensive Why expensive?

Because a duplicate removal for it to be able to remove duplicates. If I have something like this it's going to first Order a sort, so that you're going to have a three.

Now, if you consider R and S as your schema, You need to ensure that the schema is compatible. Union Compatibility Meaning that hey, these two relations have similar Schema. In terms of the data type, And the domain. Union Compatibility Meaning that hey, these two relations have similar Schema. In terms of the data type, And the domain. Now for example let me say scope School. Score ranging from 0 to 100.

So this could be, score is an integer. and the range it is. So, this can be compared with any other attribute let me say xxx with same domain and it's an integer, that is allowed. So what we want to avoid here when we say union compatibility, I don't want you to union cut Union Dogs This is not possible. You cannot intersect Cats and dogs. Oh, you cannot. Say cats take away dogs. You're not gonna get it.

For a set, how about for a bag? What does the union do for the bag? You know, when you have, so, We know that if you say R union S, you generate a relation that contains all All two poses that appear in AIDA Oh, only one. Oh, boss. So you're going to get Basically Let's first get to both. That is Ara Union S. It first gets for both and either and either So basically you better get everything Okay.

Okay, that is a union, but we are union, but is there an impact? Definitely there is an impact. Now let's look at intersection. Intersection is basically the total opposite. We are only looking at what is in the box. So, R intersection S what is it both? okay but also we're saying that hey that's that operation is only possible if We are Union We are observing what we call union compatibility. Okay, so this is basically is this the set version that is going to be easy just tell me These two codes are going to be T and it's going to be S.

And one of his tears is going to be that. I must say difference Set difference Is a set operation also that first of all is going to Make sure it's possible if that is correct But by definition it means that hey get me all two positives in R but not in S Okay, so that is what you get.

With this, in actual You sometimes use a keyword except Or you sometimes use minus or you sometimes use not in.

In SQL, it will be select Select A alias B. This is how it is showing So we can do all that Okay, and now select if it has an aggregation function. If you ever have select the sum, T. If you ever have aggregation function, it's definitely going to be projected. And we've already seen that. Okay? Now, don't forget that we can also add distinct. And we have seen this thing is a duplicate removal. So you have like country, you have country A, country A, country B, country C.

And I say, can you count how many countries we have there? If you are going to just say count Asterix is going to give you 1, 2, 3, 4, 5, 4 countries. But they need to be distinct. You need to count distinct and you say country When you say distinct country, it's going to give us, this is going to be counted one. We have only three countries. I was opposed to having four countries. I've read about group buy You group by very good into aggregation.

It's very reasonable to use it. Then we don't really have a counterpart for other The other bike can can can go As a matter of fact, every relation is considered without any order.

So what do you see this is a tree a tree From So before we would write this in a linear format.

We are interested in arranging the relation algebra in the tree format. If you're interested in arranging it in the tree format, you're gonna find that This understanding of relation algebra is going to help us evaluate the queries. We're going to understand how each query costs. Then we know that data comes from the bottom. to the root, from the leaves to the root. So the root is where we get the results.

Our final result comes out from here and this is the route. Now... Along the way, we're going to find internal nodes.

So you can see I'm going to build my My tree from the leaves Through the internal nodes, what are the internal nodes? First of all these are inputs This is And, erasure algebra.

We don't need to separate them. Now, a very... Easy example of how this tree easily you know of course we already know the formulas which come from the form from from the from list that comes from our from clause form list they are advised they are advising us or recommending to Look at the query and look for or from. So this is going to be the first two. And then if we look at the where, the where advises us on the condition.

So this way It's gonna be birthday like this and this is the whole where is that selection And then they select Advises that, hey, the select list must have attributes. And you can see the attributes. So you can see translation here is very, very easy. But how about if you have a query like this one?

Um. Again, use the same rules of transformation. of conversion and see that hey now here i have two and this comma is basicallyI'm going to be the Cartesian. So that comma is the Cartesian.

Now from there you have Do I have a condition? How do you pick conditions? You pick conditions from the where clause. And you can see I have predicate 1 and this is the junction. Predicate two. Conjunction here can be written like that and you can see my predicate 1 and the predicate 2 here.

operator or operation. As you continue pushing the result here is gonna be pushed here and the last one is basically Our select. This select advises us to have a select list category and that category should only accept attributes. And that's how you know this and this It's an easy translation I can say, Okunfajo. Example 2. Now let's look at example 3.

So Um... This time we don't have a way, so we're not going to have a selection. We only have a from. So from is gonna be my first and you can see right there from is right there From is the art. Now I go straight to group by. And my group by is this. This is the group by attribute.

Oh, I can add something. You know that this is a group dataset so I can say having Having a total, let me say this is This is us.

If that is what I'm... Now I need to... It's gonna be right here immediately before As soon as I group back, I need to bring in halving is a filter we say that halving is the same as wear So what's my condition? A total. But A total is not yet renamed. So I have to first rename it. I'm gonna come here Then I'm going to first rename sum A is equal to Hey Toto Then after that I'm going to do a selection with an A total is greater than five.

We're going to use the heuristic rules, the textbook rules, and we're going to use also a scientific model. So that is gonna be Our next and then We will talk about the physical query plan. What really actually happens when these operators are running? We talk about the hash join, we talk about the In this joint and other type of journeys. So next week is a holiday But I would like you guys to concentrate on your assignment 3 And um...

The final exam. He's out So you need to budget yourself. I think the first week of May is when we are all writing. And your final results, your current final grades have been boosted. so you need to check if you have any query in your final The grades in Canva right now are in Okay, so we'll open it up.


Query Processing: Overview


Query Processing의 목표

SQL Query
   ↓
Parsing
   ↓
Query Rewrite
   ↓
Query Optimization
   ↓
Execution Plan
   ↓
Execution Engine

Query Processing 단계

1. Parsing

SELECT name
FROM Emp
WHERE dept = 'Toy'