I'm not really sure how to describe the question I'm asking because I'm not really sure what it is.
I'm a beginner in SQL and just learning in my free time. I've been looking at the w3schools and codeacademy course and I encounter this for the first time. I don't understand why we have used the letter a in either of these cases. I've looked at some other threads for advice but they use similar notation but different letters. Pics of the code below.
Can someone please explain what is the point of using the letter a and also when/what situations would you use this.
Cheers
Edit: So the first pic is an alias and the second is a subquery. I'm interested in the second pic where the subquery is named because don't quite understand it.
Edit 2: I've been reading more and more into aliasing from the provided links and still don't fully understand the syntax. This may just be because it's a self join and I'm confusing myself. In the first picture, there is only table named "Customer" so why is there "FROM Customers A, Customers B"? Database can be viewed here