SQL: Instead of describing every step necessary to produce a wanted end result, you instead describe what you want the end result to look like, and the database will figure out the steps necessary to produce that end result for you. This aspect of SQL and query engines have always fascinated me.
@@user-bj4lp3fr1o And now I can tell chat GPT about a database and ask it in plain english what Data I want and it can write a valid query 99% of the time
Some pro tips after years of experience: use singular type (table) names, use a fully descriptive name for the primary key (player_id, team_id, ...) and reuse those names for foreign keys, make sure to properly apply constraints (foreign key constraints and for example a column can only contain a value between 0 and 10), try to avoid NULLs as much as possible, don't bother with datetime types (just use bigint unix timestamp and always ALWAYS store in UTC), learn as much about your database server as you can because it can do a lot more than you think, use the force!
I am just now learning SQL Server and your video is God-sent. I mean, the concise explanation, the language used, the graphical representations, etc. It's just perfectly done!
They took half a year to explain this in Uni and you did in 100 seconds, nicely done! I might be wrong, but at 2:01 the "primary" and "foreign" labels seem to be swapped.
Gi, i wish I had seeing this video before I started to learn on a bootcamp. I desisted because even though they said you dont need to know anything and there did not understood what clause was, what function was and sintax. They assumed it was default but for me was not. Going back now much stronger. You took the mistery away. Now is just exercises and projects. Thank You for the generosity
I retired in 2000. I was the data base administrator, and was generating a report for a merchandise manager. Two days before I retired, I coded the report in SQL. I entered two command sequences in the console and picked up the report a couple of minutes later. As I was leaving the console, it hit me: it would have taken a week of Cobol (15 years writing Cobol) coding and testing to generate the same report.
? You retired 24 years ago? Did you retire early or are you like 90 years old? What did you do for the past 24 years? Not trying to be rude, just curious.
For someone who loves basketball and just started learning SQL. I really liked how you combined those two words into this video. Made it much easier to comprehend 👍🏾
0:27 SQLite is the world’s most popular DBMS. Consider that it ships with every smartphone being sold today, so likely you have a copy about your very person right now.
00:03 SQL is the standard language for relational database systems. 00:23 IBM introduced System R database with standardized syntax in 1986 00:43 Establish relationships between data points 01:02 Structuring data in smallest normal form to eliminate duplication 01:19 SQL syntax contains key parts 01:37 Filter results using the WHERE keyword 01:52 SQL uses join keyword to connect data from different tables 02:09 SQL is a structured query language supported by many databases. .
Sorry for the downer but in MS SQL Server the statement at the end of the video wouldn't work. The WHERE clause has to come after the JOIN statement. I haven't used much of MySQL and haven't touched any of the others so not sure if the syntax varies and it lets you do it that way.
LOL this logic in the video wouldn't work anywhere. They all need the source before they can limit the source's data. So joins come before the where clause. i've worked on ms sql, mysql, redshift, snowflake, oracle, sqlite, access...all kinds of tech. good catch. very astute.
Thanks to this I understand what primary key and foreign key is. I would like to see an extended tutorial on all JOINs and some random Clauses like Trigger.
Each part of the query is executed sequentially and the order is a bit different to how you read the statement. The execution order is as follows: [1] FROM and JOINs [2] WHERE [3] GROUP BY [4] HAVING [5] SELECT [6] DISTINCT [7] ORDER BY [8] OFFSET
@@EinKesselBuntes You separate DISTINCT and ORDER BY but I was somewhat certain that DISTINCT relied on a SORT operation to complete to guarantee the uniqueness of the returned set (it's a small nitpick that doesn't really matter). The thing that does matter, and why I appreciate you grouping FROM and JOINs on the same item, is that just because an item is listed first (like FROM before a JOIN) doesn't guarantee that query processor will start there. It's one of those intermediate lessons you learn after working with it forever that you have little control over the order of operations, and generally the best you can do is nudge it in your intended direction, lol
@@ProfShibe In Civ V and VI games, the game mechanics values are stored in SQLite database format. So if you want to mod the game you must learn some SQL stuff.
I primarily use MySQL 8 for everything. Tried lots of time to shift to other db but nothing beats the power of SQL. I might perhaps switch something else in future but in generally, all my production apps are running smoothly on MySQL. With JSON type supported, it becomes even more useful
I love watching your explanations before I really dive into something, and then later after I've done some more in-depth learning. Still waiting on the rewatch for when I actually "know" something though
Why are there so many variations of SQL? Why not just one for all databases (like the HTML for the web)? What are the differences between them? What are the advantages and disadvantages of each one?
While I generally like those short videos, this one is mostly wrong or lacks important concepts, for a change. Databases are not "based on SQL" they're based on what is called an "engine", and the SQL language is just the API that is used to access it. Tables don't need a key. Keys can span over multiple columns. Accessing data needs to be done through indexes for performance, and indexes can also span to multiple columns. Databases also deal with events and can cascade behaviour to enforces certain integrity contrains. SQL also has capacities for mutation over the scheme of the data, and most of the databases engines can perform those mutations while the database is running other requests in parallel, and those requests will succeed.
I feel like you got the Primary and Foreign key switched around. `id` is the primary key on `Teams`, referenced by the foreign key named `team_id` in the `Players` table
On small test projects I even use csv as database and then keep calling string.trim().split(' ').map(row => row.trim().split(';').map(cell => cell.trim()));
this is good for beginners. The hard part is learning how to think in logical terms to get what you want. the last sql statement in the video is wrong. as someone pointed out the where clause is mistakenly placed before the join.
I have zero experience and I still have no clue what SQL does or how to use it. Most teachers spew jargon and acronyms without defining their terms or they assume too much about what a student knows and thus they suck as teachers. Good teachers who speak with clarity and simplicity while defining and illustrating each step as they go along are extremely rare.
Thanks for the video, I'm a business student and I'm primarely interested in marketing. Do you guys think that learning SQL to making analysis on using a data for marketing purposes helps me out?
Fun video! It would have been nice if you added in that SQL is a descriptive language, so the text you write isn't actually executed. It's translated to an optimized script, which then gets executed.
Its executive code as it technicly same as commands and have procedural features and you can execute in sequance. Lot of classical php cms install by not having information how database is constucted which would be descriptive, but sequance of sql queues which builds the database. What you dezcribe could be said about C or C++ or C#. Also programing languages can addapt sql like features like Linq in C#
A where statement before a join. We gonna have problems there. Probably was worth mentioning partitions and indexes as they are quite important part of SQL.
I'm kind of "new" to SQL (mssql) and right now I have few tables with relations, no problem. But how do I design a table for USER SETTINGS? I mean for example site background (and few others). Where and what values would the table have for logged in users?
i think the best thing about SQL is that is basically English language, you can read and write statements fast, and you know what some statement does in the first glance... also most of the stuff are becoming obsolete as new and better ideas come to life, except SQL... it's like Russian Lada, if it's not broken dont fix it :D
SQL is Declarative / Functional. for example: X^2 (x squared) is defined as: X x X (x times x). SQL is like that. things are defined like maths. A procedural Language (C++) is not like that. You tell the Computer HOW and Not WHAT. You can Program ANYTHING with Procedural Languages, However they're Not as Safe as Declarative / Functional languages. you can only do a limited number of things with Declarative / functional languages. however, they are safer.
Why am I watching this when I have 10 years of SQL experience? Can't get enough of these videos!
@John Doe Sounds like SQL was too difficult for you
@@shishkebab64 🤣🤣🤣
I probably used MongoDB about 9 years ago for the first time 😄 The two aren't mutually exclusive
@@shishkebab64 LoL 😂😂😂
Passive agressive much @everyone
SQL: Instead of describing every step necessary to produce a wanted end result, you instead describe what you want the end result to look like, and the database will figure out the steps necessary to produce that end result for you. This aspect of SQL and query engines have always fascinated me.
P
@@luisbeneyto6154 riveting statement
Well, it was just ahead of it's time with all this: the computer knows better
spoiler: it doesn't
@@user-bj4lp3fr1o And now I can tell chat GPT about a database and ask it in plain english what Data I want and it can write a valid query 99% of the time
lol why did they make sql when they can just use a filter on an excel sheet? dumb nerds!
sequel for short, now that's how you settle both sides of a debate
If you want to shorten it, say "squeal". Save another syllable.
im sure that he spent a little bit of time figuring out how to make everyone satisfied haha
And pronounce "vi" "six"
The guy who coined it pronounced it as “sequel”
@@stolensentience that line of reasoning has not settled the gif pronunciation debate either.
Maybe we can change the title to: "Your College Semester in 100 seconds"?
Lmao 🤣
🤣🤣🤣
Yess
This would cover the first 3 weeks of my 1st DB module in college
still more comprehensive than my college DB modules
An SQL Query walks into a bar and goes up to two tables and asks "Can i join you?"
An*
Some pro tips after years of experience: use singular type (table) names, use a fully descriptive name for the primary key (player_id, team_id, ...) and reuse those names for foreign keys, make sure to properly apply constraints (foreign key constraints and for example a column can only contain a value between 0 and 10), try to avoid NULLs as much as possible, don't bother with datetime types (just use bigint unix timestamp and always ALWAYS store in UTC), learn as much about your database server as you can because it can do a lot more than you think, use the force!
I've always wanted to use a bigint Unix timestamp but wherever I've worked they always use a date time. Had to fix so many bugs related to timezones.
DrawSQL looks like such a neat tool.
thanks for the tool name :) was actually curious about it. Too bad there isn't a free variant on this
@@frankhuurman3955 There is, for public tables
@@frankhuurman3955mysql workbench, it ain't that beautiful to look at but its good, else you can pirate dbforge
@@SumanRoy.official Thanks! I'll check it out :)
I am just now learning SQL Server and your video is God-sent. I mean, the concise explanation, the language used, the graphical representations, etc. It's just perfectly done!
The only channel where I'd watch something i already know about regarding computer science, your videos are captivating man, keep it up
cuz it's short and sweet with soothing and relaxing voice
@@kushal6065 lmao true
They took half a year to explain this in Uni and you did in 100 seconds, nicely done! I might be wrong, but at 2:01 the "primary" and "foreign" labels seem to be swapped.
You are right about the last point. You seem very focused haha.
it's more like it takes half a year to fully understeand what is he saying in those 100s
I bet they took half a year to explain this and *much* more to give you a proper understanding. If they didn’t, you got ripped off.
Thanks for this cuz I was confused a bit
in 100 minutes/days/years... We'll never know
Edit: The title originally didn't contain "Seconds"
lol, its funny that i said that first but you got more likes :D
@@samarmohan9891 it's funny that you are tracking his numbers of likes
@@samarmohan9891 How the turntables.
That's what happens when you publish from your phone 🤦♀️
@@Fireship gotta make an AI for that
Why did I learn more from this 100 second free UA-cam video than the thousand dollar university course I took
when reccomendations are quicker then notifications
Yep
Lmao same
I was searching for this!
Thank you for the video!
Keep the hard work going! 🔥🔥🔥🔥
I'm a huge basketball fan and know nothing about sql but the fact that you used basketball as your example really helped me alot
Early enough for the title to be "SQL Explained in 100' without the 'seconds'
title written in less than 100 lmao
yes
Holy crap... now I know how effective being early is when making your comment.
Gi, i wish I had seeing this video before I started to learn on a bootcamp. I desisted because even though they said you dont need to know anything and there did not understood what clause was, what function was and sintax. They assumed it was default but for me was not. Going back now much stronger.
You took the mistery away. Now is just exercises and projects. Thank You for the generosity
Mark my words
In near future this channel will be on top choices of every Developer in the world.
hello from the future, you were right!
I retired in 2000. I was the data base administrator, and was generating a report for a merchandise manager. Two days before I retired, I coded the report in SQL. I entered two command sequences in the console and picked up the report a couple of minutes later. As I was leaving the console, it hit me: it would have taken a week of Cobol (15 years writing Cobol) coding and testing to generate the same report.
? You retired 24 years ago? Did you retire early or are you like 90 years old? What did you do for the past 24 years? Not trying to be rude, just curious.
For someone who loves basketball and just started learning SQL. I really liked how you combined those two words into this video. Made it much easier to comprehend 👍🏾
0:27 SQLite is the world’s most popular DBMS. Consider that it ships with every smartphone being sold today, so likely you have a copy about your very person right now.
I am an amateur developer and your videos have really helped me gain spherical knowledge on CS
00:03 SQL is the standard language for relational database systems.
00:23 IBM introduced System R database with standardized syntax in 1986
00:43 Establish relationships between data points
01:02 Structuring data in smallest normal form to eliminate duplication
01:19 SQL syntax contains key parts
01:37 Filter results using the WHERE keyword
01:52 SQL uses join keyword to connect data from different tables
02:09 SQL is a structured query language supported by many databases.
.
1:50 shouldnt be the where clause after the join :D?
Ya same question..
I'm required to take a database class for my cs degree, this video just summarized the entire content of that class
Sorry for the downer but in MS SQL Server the statement at the end of the video wouldn't work. The WHERE clause has to come after the JOIN statement. I haven't used much of MySQL and haven't touched any of the others so not sure if the syntax varies and it lets you do it that way.
My college makes us use the oracle standard and I don't think it would work either.
LOL this logic in the video wouldn't work anywhere. They all need the source before they can limit the source's data. So joins come before the where clause. i've worked on ms sql, mysql, redshift, snowflake, oracle, sqlite, access...all kinds of tech. good catch. very astute.
@ 2:02 Primary/Foreign labels should be swapped: `Players.team_id` is the Foreign key and the `Teams.id` is the Primary key
Thanks to this I understand what primary key and foreign key is. I would like to see an extended tutorial on all JOINs and some random Clauses like Trigger.
Me: Has been using SQL for years.
Also me: Watches anyway because Jeff's about to blow my mind.
I think you have to join the table and then set the where condition. The other way would give your an error
Was wondering which flavor of SQL that is. The WHERE goes at the end in mssql, mysql, and I think Oracle. Can't speak to any others though.
Each part of the query is executed sequentially and the order is a bit different to how you read the statement. The execution order is as follows:
[1] FROM and JOINs
[2] WHERE
[3] GROUP BY
[4] HAVING
[5] SELECT
[6] DISTINCT
[7] ORDER BY
[8] OFFSET
@@EinKesselBuntes You separate DISTINCT and ORDER BY but I was somewhat certain that DISTINCT relied on a SORT operation to complete to guarantee the uniqueness of the returned set (it's a small nitpick that doesn't really matter).
The thing that does matter, and why I appreciate you grouping FROM and JOINs on the same item, is that just because an item is listed first (like FROM before a JOIN) doesn't guarantee that query processor will start there. It's one of those intermediate lessons you learn after working with it forever that you have little control over the order of operations, and generally the best you can do is nudge it in your intended direction, lol
>Video about SQL
Everyone else: Talk about database, data manipulation, MySQL, PostgresSQL, SQL Server, etc.
Me: Civilization V & VI modding!
what
@@ProfShibe In Civ V and VI games, the game mechanics values are stored in SQLite database format. So if you want to mod the game you must learn some SQL stuff.
This alone taught me more than my college Databases class
I primarily use MySQL 8 for everything. Tried lots of time to shift to other db but nothing beats the power of SQL. I might perhaps switch something else in future but in generally, all my production apps are running smoothly on MySQL. With JSON type supported, it becomes even more useful
I love watching your explanations before I really dive into something, and then later after I've done some more in-depth learning. Still waiting on the rewatch for when I actually "know" something though
Greg Ostertag... there's a blast from the past.
Another great vid Jeff. Thx! 👍🏾
Mom: no we already have mysql at home
Mysql at home: Excel
I just love your explaination....Simple...Short...Superrr 🥳
This was great, I cant wait for the SQL !
0:09 Can you give me the name of that tools? That looks amazing!
My thought exactly. I'd love to get a link to that resource!
I need it too!
Guys I got that name. It's DrawSQL
I am not programmer but a network guy, I really do enjoy your videos
Wonderfully efficient, thank you. This was a master class in minimalized visual explanation .
I'm trying to learn SQL and this video gives me a bit more understanding! It helps 👍
1:54 does not the WHERE clause come after the JOIN 🤔
I just learned more about it here than in my one semester class
bro explained everything i needed to learn today in 100 seconds 😭
how
Did you ever do the full tutorial? I'm taking Database at my college and your explanation cleared a bunch of things I didn't understand. :)
I like you videos even before played, and you never disappoint me ❣️
SQL Explained in 100
"100 what? apples? bananas?"
great video for truly sql beginners...
i learn in this short video, more any other course or tutorial even books. congrats.
About to do this in school. Thanks for the explanation
Why are there so many variations of SQL? Why not just one for all databases (like the HTML for the web)?
What are the differences between them?
What are the advantages and disadvantages of each one?
Some are faster but have slightly different syntax, some are slow but are easy to setup/install
Bruh, im not kidding i started learning sql yesterday and u made the video
While I generally like those short videos, this one is mostly wrong or lacks important concepts, for a change. Databases are not "based on SQL" they're based on what is called an "engine", and the SQL language is just the API that is used to access it. Tables don't need a key. Keys can span over multiple columns. Accessing data needs to be done through indexes for performance, and indexes can also span to multiple columns. Databases also deal with events and can cascade behaviour to enforces certain integrity contrains. SQL also has capacities for mutation over the scheme of the data, and most of the databases engines can perform those mutations while the database is running other requests in parallel, and those requests will succeed.
I agree, there are some areas for improvement here. Working on a full SQL video and taking your comment into account.
@Fireship
Link to the longer video, please.
I really like your videos! Short, but FULL of content. Thanks for sharing ;)
He should stop asking "... If you wanna see", of course we want to, I mean, it's a fireship video. 🔥
I do sql in my sleep but this video is quite enticing to watch. 😍
Can you do a video of Gemini? The middle ground between Gopher and http
I feel like you got the Primary and Foreign key switched around. `id` is the primary key on `Teams`, referenced by the foreign key named `team_id` in the `Players` table
On 2:00 yes
Absolutely love these series!
I just landed junior analyst position only by watching this video. many thanks
Thanks, I never knew that Greg Ostertag played for the Jazz
My homies use Json as database.
On small test projects I even use csv as database and then keep calling string.trim().split('
').map(row => row.trim().split(';').map(cell => cell.trim()));
For POC tests and fake APIs, try json-server.
For real stuff, a real database is the way.
this is good for beginners. The hard part is learning how to think in logical terms to get what you want. the last sql statement in the video is wrong. as someone pointed out the where clause is mistakenly placed before the join.
Teachers be like: 100 what? Apples? Dollars? Years?
Like without see, it's always a terrific vídeo!
Wow great explanation makes it soooo easy , Thank you !
Awesome as always!
It’s amazing how far the Fireship AI model has come. When did they add the snark and humor modules?
I have zero experience and I still have no clue what SQL does or how to use it. Most teachers spew jargon and acronyms without defining their terms or they assume too much about what a student knows and thus they suck as teachers. Good teachers who speak with clarity and simplicity while defining and illustrating each step as they go along are extremely rare.
Thanks for the video,
I'm a business student and I'm primarely interested in marketing. Do you guys think that learning SQL to making analysis on using a data for marketing purposes helps me out?
All right, I can now put SQL on my Linkedin experience
yeah lets go for the full tutorial..
Nice!... lambda loves squirrel sql mounted on a svelte backend that regulates Hugo along transitional database contracts. Tash hags included! .
Yay!
What’s the program/website to have a representation of your tables?
Asking the same question
@@viniciusgabriel6632 drawsql.app
DrawSQL
1:25 Which DBMS would accept this query?
Fun video! It would have been nice if you added in that SQL is a descriptive language, so the text you write isn't actually executed. It's translated to an optimized script, which then gets executed.
Its executive code as it technicly same as commands and have procedural features and you can execute in sequance. Lot of classical php cms install by not having information how database is constucted which would be descriptive, but sequance of sql queues which builds the database. What you dezcribe could be said about C or C++ or C#. Also programing languages can addapt sql like features like Linq in C#
A where statement before a join. We gonna have problems there. Probably was worth mentioning partitions and indexes as they are quite important part of SQL.
Impressive Greg Ostertag reference.
Easiest video about SQL
I think a good SQL sequel would be "Different types of SQL JOINs explained in 100 seconds"
I'm kind of "new" to SQL (mssql) and right now I have few tables with relations, no problem. But how do I design a table for USER SETTINGS? I mean for example site background (and few others). Where and what values would the table have for logged in users?
You would not believe how much of a lifesave SQL is during linguistic fieldwork
The most important part was missed: ACID compliance. You can actually trust and rely on the data integrity, unlike most document databases...
i was searching for this dumb comment ngl
daaaamn, drawsql is PRETTY
1:06 and this is where NoSQL/Firestore fails
Yes, but that might be irrelevant in trade where does not
excellent presentation, congratulations !
i think the best thing about SQL is that is basically English language, you can read and write statements fast, and you know what some statement does in the first glance... also most of the stuff are becoming obsolete as new and better ideas come to life, except SQL... it's like Russian Lada, if it's not broken dont fix it :D
00:05 whats the software you were using to show table relations.
see left bottom corner
At 2:03 the Players.team_id isn't the foreign key ?? I think it is a mistake
a full tutorial on sql pls 🥺
2:00 this is not at all how joins work in any DB that I have ever interacted with. SELECT FROM JOIN WHERE GROUP BY HAVING ORDER BY
Excellent description, thanks
MIND BLOWN FOREIGN KEY
informative video.. ♥️ from India
SQL is Declarative / Functional. for example: X^2 (x squared) is defined as: X x X (x times x).
SQL is like that. things are defined like maths. A procedural Language (C++) is not like that.
You tell the Computer HOW and Not WHAT.
You can Program ANYTHING with Procedural Languages, However they're Not as Safe as Declarative / Functional languages. you can only do a limited number of things with Declarative / functional languages. however, they are safer.
SQL is most superior form, NoSQL is useful for limited cases, SQL can be used for anything
Basketball examples made it so much easier
Structured Query Language , SQL or Sequel for short *lol , this made me distracted for the first minute and had to rewatch 😆
"It's all tables?"
"Always has been."