Slashdot Mirror


Beginning SQL?

$ynergy writes "I have been seeing more and more job listings for SQL programmers so, naturally, my interest as been sparked. I have picked up a few materials but, soon realized that it would be easier to apply if I had experience using database software. Would everyone agree? So I am looking for resources, online or in print, that would give a beginner a real in depth look at using database SW." There are at least two issues here: a) learning standard SQL (pick a standard, any standard :) and b) learning all the idiosyncracies of a particular database system. Probably learning basic SQL is the way to start.

50 comments

  1. postgresql book online by Brandon+T. · · Score: 1

    The oreilly book 'practical postgresql' is online for free at http://www.commandprompt.com/ppbook/. It has some useful information about postgresql and sql in general.

  2. I learned by redhotchil · · Score: 2

    I learned SQL (MySQL style I guess, thats all I've ever used, flame me please, its only a filesystem or something) just by reading the online manual. After you see what it does, theres really not much to it. I think the programming is more on the other end, rather than on the SQL end.

    1. Re:I learned by cymen · · Score: 4, Informative

      Well that is kinda why people flame MySQL so much (*). In PostgreSQL and Oracle you have triggers and things like pl/sql and much more that I don't know about. Basically you can put a lot of the business logic in the database and use features that tie records together and protect against accidental deletions. Basically imagine another layer that handles a lot of checks and balances that free you from having to do the same in your perl/php/tcl/whatever code.

      That's why I have learned so far...

      * Plus of course ACID and all that other stuff that some people really love to argue about.

    2. Re:I learned by Anonymous Coward · · Score: 0

      And, most importantly, 'real' RDBMS systems offer query optimization, which is something your client-side code can't do either.

  3. Learning Database Systems by jefflinwood · · Score: 4, Insightful
    I would recommend that you learn either Microsoft's SQL Server, or Oracle 9i. Both are freely downloadable (for a trial, or for non-commercial purposes) from their respective web sites. A great resource for learning more is InformIT. Their database section requires you to create an account though.

    Some slashdotter's may tell you to learn MySQL or PostgreSQL because they are open source. This is true, and it's good because they come with almost any Linux distribution. Unfortunately, business aren't looking for those skills, so it won't help you.

    Here are some Monster stats (for open US jobs):

    • Oracle: More than 5000 (could include Oracle Apps)
    • SQL Server: 2686
    • MySQL: 101
    • PostgresSQL: 16 (under postgres, postgressql, postgresql)
    • IBM db2: 1100
    • Informix: 286
    • Sybase: 738
    • Microsoft Access: More than 5000.
    1. Re:Learning Database Systems by Urgoll · · Score: 1

      Yes, Oracle is the way to go. Not only because that's where the market is (though it does help), but also because most free databases don't implement full relational databases (they don't have all the ACID properties. While it's possible to work around those limitations, that's no way to learn a new skillset.

    2. Re:Learning Database Systems by Anonymous Coward · · Score: 0

      Agree, but postgresql does have the ACID properties, as well as support for most of the SQL specified by ANSI.

    3. Re:Learning Database Systems by Graspee_Leemoor · · Score: 2
      And you can get the complete SQL server 2000 documentation here

      That's all the documentation I ever use, apart from a crappy wrox book on sql server 7.

      graspee

  4. SQL for web nerds by Pathwalker · · Score: 4, Informative

    Phillip Greenspun's book SQL for Web Nerds is a very nice introduction to SQL. It would be a good idea to grab a copy of PostgreSQL or one of those Oracle demo cds that are as common as AOL cds, and work through the exercises in it.

    Please avoid MySQL if you are just learning SQL. You'll just have to unlearn all of the workarounds for the features (such as real transactions, and referential integrity to name two) which it is missing when you move to a real database.

    1. Re:SQL for web nerds by maeglin · · Score: 1

      Please avoid MySQL if you are just learning SQL. You'll just have to unlearn all of the workarounds for the features (such as real transactions, and referential integrity to name two) which it is missing when you move to a real database.

      Actually, for those reasons I'd say MySQL is a great starting point. With MySQL you can start with SELECT * FROM my_table without having to worry about the extra stuff PostgreSQL offers (and the added administration burden). Simple and clean. From that point you can move to PostgreSQL and learn constaints, transactions, PL/pgSQL, etc. When you're ready to play with the big dogs, you can then move on to Oracle 9i or DB2 where 90% of your time is spent on configuration, optimization and maintenance.

      PostgreSQL isn't a terrible starting point. Getting used to it's more unique features like table inheritance and virtually infinite extensibility, however, will bite you in the ass when moving on more than knowing how to survive without transactions will.

      dan

    2. Re:SQL for web nerds by Pathwalker · · Score: 2

      While I agree with you that some of the more advanced features of PostgreSQL would confuse someone who is learning SQL (At least Epochs on queries [1] are no longer an issue!) I feel that this is not a major issue as the fact that the features exist, does not mean that a new user will encounter them.

      Someone can start out just using the same basic SQL that would work on MySQL, Oracle, DB2 or any other database without having to worry about transactions (PostgreSQL will wrap each statement in a transaction if you do not set up a transaction block) or other concepts beyond using the database as a simple data store.

      When the user is starting to encounter tasks that Referential Integrity, server side functions, or transactions could make easier, they don't have to go through the effort of installing another database system, and moving their projects over. They can continue working in the same enviroment, and start using advanced concepts at their own rate.

      I suspect that a lot of people continue to use MySQL for projects that have grown beyond what it is suitable for because they do not want to have to go through the trouble of installing another database system, and instead apply far more effort in the creative use of table locks, and extensive application level logic to simulate the capabilities that a more complete database would give them. I suspect that had they learned on a different database, they would be more likely to realize when the time comes to move to a more complete system, as they would not have had the barrier of a platform change discouraging them from learning about these concepts.

      Personally, I think someone should start learning on PostgreSQL until they reach the level where they are using transactions and foreign keys. Then they should play with MySQL, and learn how useful it can be for read dominated tasks with lots of simple queries. After getting used to the speed of MySQL, and seeing under what circumstances it falls down, and PostgreSQL pulls ahead, they should experiment with tuning PostgreSQL to give them an introduction to how to tweak a database. After that, they should be ready for the powerful beast that is Oracle.

      1. Postgres used to track all of the changes to the database over it's lifetime. By specifying an Epoch for a query, you could run the query on the database as it appeared at a specific point in time in the past. I think this was removed in the change from Postgres95 to PostgreSQL.

    3. Re:SQL for web nerds by sigwinch · · Score: 2
      With MySQL you can start with SELECT * FROM my_table without having to worry about the extra stuff PostgreSQL offers.
      I disagree. If you are reading along with a tutorial, none of PostgreSQL's advanced features will bite you. You have to explicity use the features to run into them, and table inheritance is not the sort of thing you do accidentally, especially if you're using a generic "SQL For Dummies" type book.
      Getting used to it's more unique features like table inheritance and virtually infinite extensibility, however, will bite you in the ass when moving on more than knowing how to survive without transactions will.
      As long as you aren't trying to read straight through the reference manual, you won't come across the advanced non-portable features until you know enough to ignore them.
      --

      --
      Kuro5hin.org: where the good times never end. ;-)

    4. Re:SQL for web nerds by Anonymous Coward · · Score: 0

      I would say that if you are trying to learn SQL (and by extention database and application design), MySQL is bad place to start. Stored Procedures are useful at all levels, and things like constraints and foreign keys should be considered advanced knowledge or optional.

      Say what you will about MS-SQL, but the GUI tools are pretty accessible.

  5. Sybase SQL guides by roc_machine · · Score: 1

    I always had a hard time finding these on the Sybase site, so I thought I would throw them up on my webspace for this post. I used these for my University Databases course and they were golden. They're not great for learning SQL from scratch, but they're an excellent reference for those tricky queries or table manipulations you might run into. I still use them occasionally for non-sybase DBMSs as well. I hope you find them as useful as I did.

  6. 2 Good Sites by UnifiedTechs · · Score: 5, Informative

    My favorites are:

    www.sqlcourse.com

    www.sqlcourse2.com

    These are good beginner sites that allow you to practice through a java app.

    1. Re:2 Good Sites by wrinkledshirt · · Score: 2, Informative

      I second the recommendation of these two sites. Great quick guides to the syntax.

      Another good way to learn SQL (don't laugh) is to practice using Access databases queries. You can design the query visually, and then switch views into SQL view to see what code you end up with. There's some inevitable mangling that goes on, but I regularly do this when I've got several tables and I can't remember where the brackets need to go for all those inner joins. I'm sure others offer this ability too, but if they don't, at least you have that one.

      There are a few free database engines out there that have command line interfaces, so that'll force you to learn the language.

      Also, if you're hoping to get into SQL in general, learn it for two different engines. That'll give you some idea of what to prepare for, since invariably every SQL implementation is a little bit different (the way they handle strings, escape characters or wildcards, or certain features available in one that aren't SQL-compliant, etc.).

      Finally, if you're hoping to learn an API with it, get into PHP. It has very clean interfaces with several different databases.

      --

      --------
      Bleah! Heh heh heh... BLEAH BLEAH!!! Ha ha ha ha...

    2. Re:2 Good Sites by Anonymous Coward · · Score: 0

      I would actually recommend against using the Access Query Builder. The SQL it produces is usually overly verbose, and it sometimes does some unexpected things.

      (Although I should point out that I've been doing SQL for many years, and the query builders in Access and MS-SQL confuse the hell out of me!)

    3. Re:2 Good Sites by Anonymous Coward · · Score: 0

      Ah! Got your posting privileges back? Good for you.

  7. Tired of doing others homework by Anonymous Coward · · Score: 0

    Duh! If you can use a bloody search engine you need to be shot. #2 if you've made it this far as a DBA without learning a bit of SQL you should be hit in the head with a wet fish and thrown off a cliff. #3 if you've never been a DBA and are looking for a fast track to learning SQL don't you need to learn methodologies behind database design first.

    The last thing we need in IT now are a bunch of gold digging morons who learn just what they need to get by at a job and end up fucking it to high heaven causing dot com crashes causing a big mess for the rest of us who have a clue just so they could get an extra 5k a year.

    The other thing we don't need which I would expect this is are sleazy IT instructors willing to teach anyone anything for a buck that are to lazy to do any real work so they prey on the hopes and dreams of others in search of their next meal ticket. Like teaching java without teaching about OO design then releasing these people into the world as bonafied java programmers.

    Course this could just be the rambleings of another anonymous troll. Or is it?

    1. Re:Tired of doing others homework by Ambush_Bug · · Score: 1

      Enough already with the "use a search engine" comment. I think it's safe to assume that almost any "Ask Slashdot" question could be answered to some degree by typing the question into google...
      what you won't get from google is a decent, "peer reviewed" answer... just because some tutorial or site is on the 10th page of a google search doesn't mean it's not the best. Likewise, the first ten results might not be the most relelvant. People ask things of slashdot because they are looking for answers from people who have opinions and experience, not from bots who have been tricked by judicious usage of meta tags. I guess the next "First Post" will be "First Use Google Answer to Ask Slasdot".... geeze.

      That being said, fair enough on the rest of the comment.

    2. Re:Tired of doing others homework by Anonymous Coward · · Score: 0

      The original question borders on pure lameness anyway so the search comment seems appropriate here.

      We examine: It does say it as the farking tag line for gods sake. The whole news for nerds stuff that matters shiz. This numbfazes quesiton about how do I learn sql is neither nerd news or anything that matters.

      "Ruled no fowl by reason of stupid question on part of question submiter, still first down."

      BTW I do understand there is an air of intolerance in the first ac post but I don't think it is intentional just like mine is't but I for one am getting a bit nerved at the lameness in slashdot just for the fact that I've been reading it for so long and hate to see it die such a slow and painful death at the hands of its own lusers.

    3. Re:Tired of doing others homework by Ambush_Bug · · Score: 1

      Pure lameness? I guess being a beginner at something doesn't measure up to your level of "nerdiness"... that's sad. The guy said he had done a bit of research, but it seeemed like everything he found was geared to people who already knew what they were doing.... it's like telling a newbie "read the man page"... with experience, this is perfectly acceptable, but when you're just starting out, terse documentation doesn't make sense.

      I guess I won't debate whether it's nerd news or not... but it obviously matters to all those companies who are willing to pay big $$ for a database programmer.
      I still maintain my point... if you don't have anything productive to say, don't bother with posting... if you think the question was lame, tell CowboyNeal or somebody /. they picked a lame question... Geek snobbery isn't nice, and it isn't very useful... and you certainly won't stop "lusers" from being "lusers" by being mean to them.

    4. Re:Tired of doing others homework by Anonymous Coward · · Score: 0

      Hey man, I develop software that uses Oracle 9i, and have a good amount of experience. But I learned a few things from reading this thread. Sure it may be a simple question, but its cool to see the responses. I learned a little about other databases such as MySQL that I wasn't aware of before. I'd be equally happy seeing a "Beginning VHDL/Verilog?" ask slashdot question because of the wealth of information that will result. But I understand, you're just some lame-ass troll.

  8. Much more complex than it first seems by coyote-san · · Score: 5, Interesting

    This issue is a *lot* more complex than it first seems. There's a lot of really bad SQL code out there, and many of the authors don't even realize how little they know.

    The problem is that it takes time and experience to really develop a sense for how to use the data. If you're a programmer, you should have at least some familiarity with performance issues even if you don't always pick the best algorithm for the problem. Likewise with a SQL database you really need to understand why 3NF is important, why referential integrity is a really good idea, etc. It's not uncommon for databases to span many gigabytes and a bad design can literally cost millions of dollars as you throw more hardware and expensive database licenses at the problem.

    This isn't just theoretical - ghosting can be a problem with 3NF data, and you need to know how to recognize it and fix it. (More precisely, how to fix it without using 1NF or 2NF, which both have serious problems that 3NF fixes.)

    Then there's the issues of views. It's easy to understand read-only views, but updateable views make life incrediby interesting. But this is critical - a bad updateable view will create a lot of subtle errors in your database.

    Other issues - how do you access the data? This is everything from JDBC or Pro*C to JSP tag libraries. How do you handle bad data, or bad assumptions? (Nothing teaches you how hard it is to get a unique identifier like trying to actually find unique identifiers for real data.)

    Finally, many of these sites aren't just looking for SQL knowledge, they're looking for specific packages like Oracle Financials.

    I think the best way to illustrate just how much there is to learn is that a friend recently decided to get Oracle certification to help land jobs. She's been focusing on databases for almost a decade, yet she still had to study hard for the exams. I've been doing intermittent database work for even longer and have pulled several rabbits out of my hat - yet I know I would struggle to pass just one part (of four) of the exams.

    But on the question at hand, my advice is to get an introductory text and start solving some problems. Create a database listing your CDs, then extend it to handle DVDs and VHS tapes, then extend it again to handle books and magazines. Create an index to keep track of your softball or bowling league stats - the teams, the players, the individual and team stats. You'll learn more from one or two reasonably large problems than you'll learn from a dozen books.

    --
    For every complex problem there is an answer that is clear, simple, and wrong. -- H L Mencken
    1. Re:Much more complex than it first seems by Anonymous Coward · · Score: 0

      What is this guy talking about?
      This is a bunch of croak.

      "This isn't just theoretical - ghosting can be a problem with 3NF data, and you need to know how to recognize it and fix it. (More precisely, how to fix it without using 1NF or 2NF, which both have serious problems that 3NF fixes.)

      Everyone worth their salt knows that in order to use 3NF you have to use 1NF and 2NF. That's standard SQL. Anyone who says otherwise doesn't know what their are talking about or they are talking from a vendor's perspective.

  9. Design by highcaffeine · · Score: 5, Insightful

    Do *not* learn the actual query language first. Learn database theory and design before anything else. Don't even consider doing anything with a database until you know the six forms of normalization (at a bare minimum you need to know the first three; the second three are "gravy" for many applications and not even appropriate all the time). This includes knowing the requirements to reach each level of normalization within a database.

    I have seen so many database layouts for various applications that have practically brought me to tears through their sheer stupidity. These were layouts designed purportedly by people who "knew SQL." There is a tremendous difference between "knowing SQL" and "knowing proper database design and implementation." Unfortunately, many people who claim to be database programmers do not realize there is a difference and assume that since they know the syntax of SQL, they know how to design a database.

    I would recommend that you begin with "Database Systems" by Connolly and Begg. Read it cover to cover, then read it again. When you're done reading it the second time, skip through to the end of each section and do all the exercises without rereading any of the text. Once you can answer a majority of the questions correctly, then begin to consider designing database layouts. Before you look the book up on fatbrain or amazon, be warned that it is not light reading. It's 1,200+ pages, but is well worth it.

    The ISBN is: 0201708574.

    When you actually understand how databases work and how to effectively use them, you will thank yourself tremendously for taking the time up front. If you dive right in to learning the syntax of the query language without understanding the basics of design and implementation, you will make one stupid mistake after another with no end in sight. Then, someone more knowledgeable than yourself will come along and will have to start everything over from scratch to fix your screwups.

    Doing it right the first time is especially important when designing databases for large systems. If you screw something up and don't learn from your mistake until you have millions of records in tables that are being quickly updated 24/7, fixing that mistake is going to be a nightmare and could very well cost your company a tremendous amount of money through downtime and resources spent on the fix and conversion.

    Trying to keep this post from getting too long: the key is that there is absolutely no substitute for a solid understanding of the theory behind database design. You simply cannot be anything more than a witless hack at databases without this understanding. You will churn out terrible database layouts almost every time (unless you have an unbelievably lucky streak) and your projects will suffer because of this.

    Sorry if this sounds harsh, but it really, truly is worth spending the time to learn the theory and design before trying to apply your efforts to a real world project. Of course, if you're impatient you can play around with a server at the same time you learn the theory. But do not make the mistake of neglecting the theory in favor of quickly learning the syntax.

    1. Re:Design by cymen · · Score: 2

      I don't put a lot of stock in Amazon.com reviews but this one is odd - almost half are negative and from apparently younger readers while a bit more than half are positive (and generally written with more care). The 2nd edition paperback can be brought for $26 used from Amazon.com.

    2. Re:Design by Urgoll · · Score: 1

      I can only second that. After trying to design databases before learning the theory in depth (thinking that an introductory undergrad-level class was enough), I had to face the truth: Database design is a complicated task.

    3. Re:Design by sql*kitten · · Score: 2

      I would recommend that you begin with "Database Systems" by Connolly and Begg. Read it cover to cover, then read it again. When you're done reading it the second time, skip through to the end of each section and do all the exercises without rereading any of the text. Once you can answer a majority of the questions correctly, then begin to consider designing database layouts. Before you look the book up on fatbrain or amazon, be warned that it is not light reading. It's 1,200+ pages, but is well worth it.

      I agree with all the points in the parent post - "knowing" SQL (or indeed, any other programming language) is to software engineering as bricklaying is to civil engineering. SQL is like playing the piano, easy to learn, hard to master. I have personally experienced large scale projects that have literally cost millions of dollars to re-work after someone who "knew SQL" had made a mess of the database. Probably the most laughable was a billing system that updated customers balances in-place (in the same table that stored the customer's name and address!) rather than recording transactions and calculating balances with a roll-up. The front-end software the same team had written was flawed and recording the wrong numbers (in some cases, they had bound the columns to the wrong fields, in others they had added where they meant to subtract, etc), and since no raw data history was recorded anywhere (another bit of bad design was automating dumping the audit logs whenever that disk looked like it was getting full), all that money had simply... disappeared.

      The book I recommend is this one. Ignore the reviewer, who has missed the point: good database design is difficult, and this book is for people who can handle the (math) theory behind it.

    4. Re:Design by belldandy · · Score: 1
      I agree with the majority of this post, except for the book choice. I found Connolly And Begg to be a much less idea book as compared to "Fundamental of Database Systems" by Elmarsri/Navathe ISBN 0805317481. Granted it has been about 4 years since I last really read either book, but from what I remember, Elmarsri was a much more consice and clear read.

      The book seems to also have gone up in price since I bought it (by about 15$!), but used is great too :).

      -Tammie

  10. Book recommendation by crudeboy · · Score: 1
    I think it's more or less necessary to learn and understand the concepts of database design, including modelling, normalization etcetera before picking up a specific dbms-product.

    I would recommend Database Processing by David M. Kroenke, ISBN 0130648396.

    After having read and understood that book I would start looking at a commercial dbms like Oracle, DB2 or MS SQL Server as they are they most frequently used.

    In my opinion MySQL and Postgres are fine products, but if you're looking to get an overpaid job, go with Oracle...

  11. Size by mnordstr · · Score: 0, Redundant

    Why is ie. Oracle 9i a 2.5gig installation and requires 512mb ram, while MySQL requires a few 10megs and virtually no ram? What does Oracle give, that MySQL doesn't? I'm looking for something very revolutionary, because 2.5 gigs can't just be transaction support =)

    1. Re:Size by rtaylor · · Score: 3, Informative

      Load a billion records into your MySQL database through 20 tables, then do random 10 table joins. Thats why.

      Postgresql doesn't do quite as well as Oracle (much much smaller gap now though) but it has a smaller starting size.

      --
      Rod Taylor
    2. Re:Size by Anonymous Coward · · Score: 0

      Why is ie. Oracle 9i a 2.5gig installation and requires 512mb ram, while MySQL requires a few 10megs and virtually no ram? What does Oracle give, that MySQL doesn't?
      It's a server application - no one is making an embedded Oracle database. Pl/SQL, better scalability, real support, industry recognition, the list goes on and on.
      I'm looking for something very revolutionary, because 2.5 gigs can't just be transaction support =)
      Oracle is a real database with 20+ years of active development and MySQL is a toy for when your data really isn't that important, or you're a cheapskate Linux user.

  12. also by Anonymous Coward · · Score: 0

    The Dummies Guide to SQL, if it's still in print.

    Still, though, try coding the book inventory system for a library, just for the heck of it. Checking out isn't so easy to do.

    In the bargain bin, you may find The Linux Database, part of the Slackware series. Quite good on theory.

  13. the other design topic by Anonymous Coward · · Score: 0

    The other thing you have to worry about is bad input, especially with any sort of web database, it's too easy to recook the URL to include a "DROP." That'll hose things.

    You think you have input overflow problems with C? You haven't seen what can happen with a web based SQL system. School of hard knocks, baby.

  14. Because MySQL isn't a real database by Anonymous Coward · · Score: 0

    I'm guessing you're just trolling here, but I'll give you the benefit of the doubt..

    What does Oracle give, that MySQL doesn't?

    How about transactions, triggers, stored procedures, ACID, foreign keys, views, etc?

    MySQL isn't a real database, it's an SQL-like interface to data storage. Go read up on the features of a real SQL database.

    1. Re:Because MySQL isn't a real database by mnordstr · · Score: 2

      Yes, I know that. But with 2.5gigs it should be able to do genetic research =)

    2. Re:Because MySQL isn't a real database by bakes · · Score: 2

      The 2.5 gig also includes stuff like the OEM agent and management server, the management tools (all with GUI), the names server, development libraries (for C and Java, plus others like Cobol and Fortran), network configuration tools (also GUI), the graphical installer tools, documentation, and sample database. There is undoubtedly lots of other stuff but I don't have access to an Oracle installation at the moment to tell you what is in each directory.

      Next time you do an install, maybe you can uncheck the parts of the distribution that you don't want.

      --
      Ho! Haha! Guard! Turn! Parry! Dodge! Spin! Ha! Thrust!
  15. Use what you can apply. by mountainhouse · · Score: 1

    I'd use whatever SQL I could easily lay my hands on, and that allowed me to build some sort of application. I find it real hard to learn a tool just for the sake of learning it. It comes so much more easily when you apply it. I see a number of comments comparing SQLs. Personally, I started with Oracle, and currently use mostly NCR Teradata (Try inserting 30 million 200 bytes rows into a table in 8 seconds with Oracle ;-) ). I'd say about 80% of my Oracle knowledge transferred, even though Teradata is pretty strange animal (very distributed). Do others have opinions about what percentage of SQL knowledge transfers from one flavor to another?

  16. Ugh! by Chacham · · Score: 3

    Why can't people be clear?!

    First you say: job listings for SQL programmers

    Then you think you wish you: had experience using database software

    and compound it by believing: that would give a beginner a real in depth look at using database SW.

    Then michael (with his double at-sign) comments: a) learning standard SQL (pick a standard, any standard :) and b) learning all the idiosyncracies of a particular database system. Probably learning basic SQL is the way to start.

    You're all wrong!

    What do you want? There are *four* separate issues here.

    1. Learning SQL
    2. Learning embedded SQL
    3. Learning DB management (and CASE, etc.)
    4. Learning DB ideosynchracies
    I will assume that issue 3 and 4 are not the case. (because anyone who gets these things mixed up probably would be pretty horrible at designing tables anyway. :-)) Rather 1 and 2 are important. Number 1 is easy. Just find a good book. The most up-to-date standard is probably a waste of time since it adds little, and is most likely not yet fully implemented. Personally, I found the book, "Understanding SQL" by Martin Gruber to be an excellent book. He skips design until the end of the book. Which is a good thing. Learning design first is silly, since you have no idea as to what you are designing for. But, most likely, you should skip the designing pages yourself, and let the DBA create the tables in the company's well-defined format.

    For issue 2, read the documentation of the language you need. They all do it differently.

  17. SELECT by Anonymous Coward · · Score: 0

    SELECT * FROM table;

    See it is not hard.

  18. Oracle and PostgreSQL by RinkSpringer · · Score: 1

    We learn Oracle quite extensively at school. I have found that PostgreSQL resembles Oracle far better than MySQL did.

    As for anything, to learn is to do... therefore, I recommend you get both PostgreSQL and Oracle from the websites. Oracle is freely available for educational purposes, and PostgreSQL is free anyway.

    Besides, PostgreSQL has a very good SQL reference, which also lists what is and what is not ANSI SQL (boy, it came as a great surprise to me that LIMIT is *not* ANSI SQL!)

    Anyway, I recommend you get both of these database systems, find some tutorials here and possibly using Google, and learn by experimenting... that usually is the best way.

    Good luck!

  19. Great SQL book for DB2 by Anonymous Coward · · Score: 1, Informative

    There is an amazing SQL book by Graeme Birchall called DB2 SQL Cookbook, downloadable as an PDF. It contains all the funky stuff you can do with SQL on DB2. DB2 is pretty close to the ANSI SQL standard so a most of the stuff should work on other databases as well... The url is: "http://ourworld.compuserve.com/homepages/Graeme_B irchall/HTM_COOK.HTM

  20. dbo.Slashdot by PDHoss · · Score: 3, Funny


    SELECT FreeTips FROM SlashdotAudience WHERE Subject = 'SQL';



    --
    ======================================
    Writers get in shape by pumping irony.
  21. Learning SQL by hether · · Score: 2

    Try www.sqlcourse.com and www.sqlcourse2.com
    That's where I learned SQL. It uses an interpreter and a live practice database.

    --

    Most people would die sooner than think; in fact, they do.
  22. Learning SQL the definitive guide. by Anonymous Coward · · Score: 0

    I spent the last year learning SQL and discovered that very few people actually know what they are doing b'se the commercial products almost never follow the standard.
    So if you want to be good, learn the SQL standard.( the best text is "Database Principles, Programming and performance by Patrick & Elizabeth O'Neil.
    Then specialize in either T-SQL or PL which ever you prefer.
    I studied the book, took an indepth M$ class in SQL server and played around with Oracle 8 and 9i, but landed my 1st job working on Informix b'se no one knew it, all I had to do was pick a $100 Informix bible and got the job done. (Would never have got the job done without standard SQL knowledge).
    Another thing you should know is that Data is very expensive so It's hard to get an entry level job.

  23. 3rd Normal Form and split-happy by Tablizer · · Score: 1

    (* This isn't just theoretical - ghosting can be a problem with 3NF data, and you need to know how to recognize it and fix it. (More precisely, how to fix it without using 1NF or 2NF, which both have serious problems that 3NF fixes.) *)

    Sometimes people take the normalization rules too extremes and try to divide entities into sub-entities. I suggest one not get split-happy.

    Normalization should remove unnecessarily duplicate data, but if you start to use it as a sub-grouping mechanism, then you can create problems IMO. Just because two fields are somewhat "related" today, does not mean they will be tomarrow. The normalization rules as worded sometimes don't consider possible future changes.

    Just a caution to keep in mind.