SQL Database

How the fuck do I learn SQL?

This is literally the only shit preventing me from getting an internship - i couldnt obtain a database design class, so now I need to learn all this stuff over the summer.

I know Python and Java, what are some projects or resources, or anything I can do to learn SQL?

I have the basics down tho desu, just need to implement them in some hands on way.

Attached: 7AB.jpg (1499x939, 540K)

Other urls found in this thread:

sol.gfxile.net/galaxql.html
youtube.com/watch?v=knUitQQnpJo
db.cs.cmu.edu/courses/
youtube.com/channel/UCHnBsf2rH-K7pn09rb3qvkA/videos
twitter.com/SFWRedditVideos

if you already know python and java why not look at an orm?

Learn Database normalization up to 3NF.

PL/SQL is also useful because stored procedures are faster than back end solutions.

liek what?

Are these really commonly used?

So when I see a job asking for "SQL" either of these things will suffice for that job?

trying to go straight for orm without knowing anything about sql is a recipe for disaster and also how the fuck would anyone be able to make a mapping file with many-to-many relations but not be able to shit out three tables in straight sql?

if you know anything about computers you can pick up the very basics in a week and be decent in a month. there's literally thousands of free tutorials out there.

Just learn the basics. There's not much to SQL, so if you know SELECT, JOIN, WHERE, then you're fine. You won't be writing direct queries anyways.

You bet, at least anywhere decent

make a CRUD webapp that allows the users to search/maintain some kind of database. The queries shouldn't be crazy for simple database and it's a pretty nice resume project.

>You won't be writing direct queries anyways
You should learn what the eldritch horrors you write translate into in order to understand the results and optimize the requests

sol.gfxile.net/galaxql.html

>3NF.
Yes, is like the fizzbuzz of databases.

>PL/SQL
It depends on the database, PL/SQL is oracle oriented and it has more features on oracle DB than mysql, while Microsoft language is totally different.

Most ORMs are absolutely cancerous. The only tolerable ones are just object mappers with helpers for writing parametrized queries. Once you get into magic shit that writes the SQL behind the scenes for you you're going to run into weird edge cases and performance issues.

>So when I see a job asking for "SQL" either of these things will suffice for that job?
Depends, if SQL is tacked on a list of various requirements: it's usually not a focus and you can get away with just knowing the basic stuff: ddl, doing joins, basics of transactions etc.

All three if those database engines support almost all of the ANSI SQL standard. They each have bonus features that can come in handy, but for basic crud operations SQL code is generally portable.

That's why i said PL/SQL code, Microsoft uses T-SQL

>but for basic crud operations SQL code is generally portable.
It is but the datatypes generally aren't.

I forgot to add this:
If they mention Business intelligence, you will also need to know about ETL and star/snowflake schemas.

I'm actually majoring in Business Intelligence, how fucked am I?

Honestly?

I always felt in the same situation as you. In a sense, still do.

Then I got a job, and my very first task was completely on the database side, adding some stuff I had to research beforehand to a table. Pretty simple, yet scared me to death.

Then I had to learn PHP from scratch because I had to update some legacy code that saved stuff from a POST request to also add metadata on the file in a database. (And we don't even use PHP, we're a C++/C# house.) Added just 20 lines of stuff in the end, but I felt like I learned a lot.

Then I had a couple of days to figure out a way to MIGRATE CLIENTS IN PRODUCTION WITHOUT LOSING DATA because the previous schema design we had had some issues and we wanted to expand into multiple products. Good thing we have more than one ambient so I could tinker and prepare some scripts and procedures to help make it reliable. Somehow it worked.

Then the last couple of weeks I tried doing something myself with a database, so I'm making my very own reader for the old /prog/ textboard database dump, which uses SQLite. And I'm having a blast with this "school homework".

Bottom line is, do something as simple as it is so you can think of it less of a boogeyman. Try manipulating something that already exists, try making a very simple db and tinker with it, just try stuff.

BI is good, is like AI without the memes, but if they tie you to a vendor specific technology it can be awful, lots of money for sure but it would be like working for SAP or Microsoft.

You can learn SQL in a week. Just go to the w3schools sql tutorial and take notes on SELECT, UPDATE, DELETE, and INSERT INTO

Then build a tiny CRUD app that uses SQL as the persistent data store.

I recommend using sqlite to learn how to use databases in your code at first.

What programming language are you using to execute the queries?

SELECT
FROM
WHERE
GROUP BY
HAVING
ORDER BY

k

garbage

Attached: a8dd27e9016ec1c79e7dee78c9834608.png (1208x236, 15K)

How do I build a CRUD app?

with programming ;)

youtube.com/watch?v=knUitQQnpJo

OP here I learned the syntax for SQL now.

Is that enough to put it on my resume? lulz

Try to think how SQL is implemented under The Hood. I think it helps a lot on interviews. Eg. "what is The difference beetwen merge and hash join and what about theirs complexity"

Database system by silberchaltz
Just read the book

db.cs.cmu.edu/courses/
youtube.com/channel/UCHnBsf2rH-K7pn09rb3qvkA/videos

The datatypes are close to the same with some infuriating differences, but this only matters if you're moving data between databases or you're writing build scripts for multiple databases.

t. Has written an application that allows running arbitrary parameterized queries on one database and inserting the results into a generated table in another database ad-hoc with cross support for Oracle, SQL Server, MySQL, Postgresql and DB2.
What a pain in the ass.

a database is essentially a lot of excel sheets. For performance, you keep multiple sheets (tables) and reference row numbers from one sheet to another, or use a third table that references both previous row numbers.

now if you want information from sheet 1 and sheet 2, you can look at sheet 3's references. The way you do this is with SQL. Follow me here. Select from sheet 3, and select from sheet 1 and 2 based on the reference row IDs in my sheet 3 (join)

now seriously get on hacker rank and do their sql problems.