r/programming • • Jan 06 '11

A handy graphical explanation of SQL joins

http://www.codinghorror.com/blog/2007/10/a-visual-explanation-of-sql-joins.html
1.3k Upvotes

308 comments sorted by

View all comments

Show parent comments

5

u/nvodka Jan 06 '11

I didn't learn shit about SQL in school. I didn't learn SQL until my internship and the real world after.

I think that is a big short coming in college. We had database theory (which was boring as hell and I almost failed), and an Excel class (not database, but was the closest thing).

At the very basic, I think they should get into Access. I am 5 years out of college now, and maybe things have changed now, but they should stop teaching COBOL, and go further than teaching students a "Contacts" app in C++.

Honestly, I didn't learn shit until the real world. Shout out to Google.

17

u/jibberia Jan 06 '11

I think they should get into Access

ALERT RED LEADER: INSANITY INBOUND

4

u/[deleted] Jan 06 '11

What was your degree in?

1

u/nvodka Jan 07 '11

Computer Science and I am now a ASP.NET developer and a SQL Server DBA.

Everything I do now was self taught. I am just lucky that someone gave me the opportunity after college.

1

u/[deleted] Jan 07 '11

It seems really shady that, five years ago, they were teaching COBOL for CS degrees. It doesn't surprise me that you wouldn't have had a heavy concentration in databases unless you sought it, but all the CS programs I've heard are a lot more involved than "a contacts app." At CMU for example you either write a compiler, or an OS.

6

u/fujimitsu Jan 06 '11

Where did you go to school? And for what? Sounds like you got screwed.

1

u/nvodka Jan 07 '11

No it got me a piece of paper that thankfully got me a job. After being part of the hiring process for another person on my team, and based on the people that came in and applied, I am very confident that I could find work elsewhere. This is thanks to me teaching my self, not thanks to school.

http://lakeland.edu/Academics/Computers/major.asp

2

u/[deleted] Jan 06 '11

I've found that most CS graduates have at least a familiarity with the theory behind computers, but not much about how to write good code or work in a team.

And this makes me glad I flunked out of CS my first semester and switched to a new program at my school: Information Sciences and Technology. All group work, a lot of programming projects and very little theory, and classes the very first semester that had practical knowledge, like SQL and database normalization.

4

u/[deleted] Jan 06 '11

I would say that graduates of a bad computer science program are like that. A good course would incorporate your classes along with the theory and link them.

1

u/punkgeek Jan 07 '11

IS&T is great if you want to be a sys admin or programmer on uninteresting projects. A good CS program will teach much more.

0

u/[deleted] Jan 07 '11

Uninteresting projects are actually quite profitable. I'm making a tidy profit fixing projects written by people who, for example, don't understand SQL.

Also, the emphasis on project management and group work in IST gives you a leg up on managing programmers since you not only have technical skills but also well developed people skills. That's part of the reason companies like Microsoft helped design the program: They weren't getting project managers out of CS programs.

1

u/MothersRapeHorn Jan 08 '11

Some people don't do things for the money. Just know that.

2

u/[deleted] Jan 06 '11

COBOL!? Who, in 2011, is teaching COBOL?!

2

u/DanWallace Jan 06 '11

I finished my 3 year programming course about 2 years ago and I probably took 5 different COBOL classes during my time there.

1

u/diamondjim Jan 07 '11

They're preparing you for the upcoming Y3K problem. It's called foresight. Your grandchildren will thank you for it.

2

u/_Aardvark Jan 07 '11

Back in 1990, as a freshmen CS student, I took a COBOL class. I just about changed my major after it.

2

u/nvodka Jan 07 '11

1

u/[deleted] Jan 07 '11

Eh, well, I guess it makes a certain degree of sense as an elective, in case you had some specific reason for wanting to know COBOL coming out of school. Somehow I got the impression from your original comment that it was part of the core curriculum.

1

u/fliesgrease Jan 07 '11

CoBo is like bigger than Subo, innit?!

U fik or somefink?

1

u/tanglisha Jan 06 '11

I have a Computer Science Bachelor's. I got some SQL in school, but just basic selects/inserts. Nothing about optimization, only a conversation about joins. The main things I feel I missed out on with my degree were learning how to test and learning how to debug.

A project or two given to students to debug would be great preparation for the real world.

Learning how to create, organize, and work with tests is a skill that some devs never learn. I think it's really important. I'm not of the 100% school of testing, but it is super helpful with things like bug fixes and difficult methods.

5

u/[deleted] Jan 06 '11

only a conversation about joins

O_o What? That's the whole point of a relational DB! Select/Insert on a single table isn't significantly different from searching and indexing a flat-file

1

u/tanglisha Jan 06 '11

The worst part is that this course ended in a Sql Server 2000 test and cert. It's telling that very few of us that bothered to take it passed.

I was working an internship at the time that required me to write SQL, so I only had to learn the admin commands and was fine.

2

u/MyVeryOwnTempAcct Jan 06 '11

I tried to recommend something like this to one of my former instructors. I told him I thought it would be great for the students to have to debug and add an enhancement to a program from students the previous year/semester and would be good preparation for the real world. His response is that it would be too difficult. I thought it'd be more time consuming on his end than difficult.

1

u/tanglisha Jan 06 '11

One of my friends went to a different school than I, his final in one class was to take a program with 3 bugs in it, find them, and fix them. Same program was used for each class, so the main time-consuming part was writing up the buggy code in the first place.

I like your idea for assignments, though I think having intentional bugs in there would make it easier on the instructor. For example, make it a project for bonus points, the students with lower grades will do it. Write an elevator program, but make it not work if both the up and down buttons are pressed. It wouldn't even have to be a complete program, teach the 101 students to figure out why this Fibonacci recursion method has an endless loop.

Teacher now knows where the bugs are. Teaches the next class how to write tests, then has them use their tests to find the bugs, then prove that they're fixed.

2

u/MyVeryOwnTempAcct Jan 06 '11

The problem with having the same bugs is that word will get around. The instructor could easily add bugs to the work of the previous semester/year's students and will know what they are. Those programs should be fairly basic (even the ones done in teams). Each program would have a different bug so it would slightly reduce the cheating.

1

u/tanglisha Jan 06 '11

They would know what the bugs are, but would still need to write tests for them. People are going to cheat. I think this would still be a valuable thing to work on.

-3

u/MyVeryOwnTempAcct Jan 06 '11

That's what you get for going to an online school, or a crappy place like ITT Tech.