Hot Best Seller

SQL Cookbook

Availability: Ready to download

You know the rudiments of the SQL query language, yet you feel you aren't taking full advantage of SQL's expressive power. You'd like to learn how to do more work with SQL inside the database before pushing data across the network to your applications. You'd like to take your SQL skills to the next level. Let's face it, SQL is a deceptively simple language to learn, and man You know the rudiments of the SQL query language, yet you feel you aren't taking full advantage of SQL's expressive power. You'd like to learn how to do more work with SQL inside the database before pushing data across the network to your applications. You'd like to take your SQL skills to the next level. Let's face it, SQL is a deceptively simple language to learn, and many database developers never go far beyond the simple statement: SELECT columns FROM table WHERE conditions. But there is so much more you can do with the language. In the SQL Cookbook, experienced SQL developer Anthony Molinaro shares his favorite SQL techniques and features. You'll learn about: Window functions, arguably the most significant enhancement to SQL in the past decade. If you're not using these, you're missing out Powerful, database-specific features such as SQL Server's PIVOT and UNPIVOT operators, Oracle's MODEL clause, and PostgreSQL's very useful GENERATE_SERIES function Pivoting rows into columns, reverse-pivoting columns into rows, using pivoting to facilitate inter-row calculations, and double-pivoting a result set Bucketization, and why you should never use that term in Brooklyn. How to create histograms, summarize data into buckets, perform aggregations over a moving range of values, generate running-totals and subtotals, and other advanced, data warehousing techniques The technique of walking a string, which allows you to use SQL to parse through the characters, words, or delimited elements of a string Written in O'Reilly's popular Problem/Solution/Discussion style, the SQL Cookbook is sure to please. Anthony's credo is: When it comes down to it, we all go to work, we all have bills to pay, and we all want to go home at a reasonable time and enjoy what's still available of our days. The SQL Cookbook moves quickly from problem to solution, saving you time each step of the way.


Compare

You know the rudiments of the SQL query language, yet you feel you aren't taking full advantage of SQL's expressive power. You'd like to learn how to do more work with SQL inside the database before pushing data across the network to your applications. You'd like to take your SQL skills to the next level. Let's face it, SQL is a deceptively simple language to learn, and man You know the rudiments of the SQL query language, yet you feel you aren't taking full advantage of SQL's expressive power. You'd like to learn how to do more work with SQL inside the database before pushing data across the network to your applications. You'd like to take your SQL skills to the next level. Let's face it, SQL is a deceptively simple language to learn, and many database developers never go far beyond the simple statement: SELECT columns FROM table WHERE conditions. But there is so much more you can do with the language. In the SQL Cookbook, experienced SQL developer Anthony Molinaro shares his favorite SQL techniques and features. You'll learn about: Window functions, arguably the most significant enhancement to SQL in the past decade. If you're not using these, you're missing out Powerful, database-specific features such as SQL Server's PIVOT and UNPIVOT operators, Oracle's MODEL clause, and PostgreSQL's very useful GENERATE_SERIES function Pivoting rows into columns, reverse-pivoting columns into rows, using pivoting to facilitate inter-row calculations, and double-pivoting a result set Bucketization, and why you should never use that term in Brooklyn. How to create histograms, summarize data into buckets, perform aggregations over a moving range of values, generate running-totals and subtotals, and other advanced, data warehousing techniques The technique of walking a string, which allows you to use SQL to parse through the characters, words, or delimited elements of a string Written in O'Reilly's popular Problem/Solution/Discussion style, the SQL Cookbook is sure to please. Anthony's credo is: When it comes down to it, we all go to work, we all have bills to pay, and we all want to go home at a reasonable time and enjoy what's still available of our days. The SQL Cookbook moves quickly from problem to solution, saving you time each step of the way.

30 review for SQL Cookbook

  1. 4 out of 5

    Stacy Park

    good stuff in this bitch

  2. 5 out of 5

    Michael Pilgrim

    I read this book cover-to-cover rather than using it in the manner intended. The intention is that, when one has a problem to solve, one would find the most similar problem in the table of contents. The repetition of reading multiple similar solutions by reading the entire book helped solidify the concepts. I've read other reviews here that criticize the SQL Cookbook because using the table of contents in the manner intended might lead to a solution that depends on concepts explained in prior so I read this book cover-to-cover rather than using it in the manner intended. The intention is that, when one has a problem to solve, one would find the most similar problem in the table of contents. The repetition of reading multiple similar solutions by reading the entire book helped solidify the concepts. I've read other reviews here that criticize the SQL Cookbook because using the table of contents in the manner intended might lead to a solution that depends on concepts explained in prior solutions. The solutions are not always self-contained. Such criticisms are valid and are part of the reason that I read the book in its entirety. I have since implemented much of the material in my work and have improved a great deal as a result. Highly recommended.

  3. 5 out of 5

    Feedmegarbage

    If you NEED to learn the amazingly complex and available functionality in SQL queries, this is the book for you. Simply explained and elegantly detailed, this book is truly a must have for anyone with any level of SQL expertise, from the new beginner to the seasoned veteran.

  4. 5 out of 5

    Doug

    You too can write SQL like the Jedi of old.

  5. 5 out of 5

    Fiona Dax

    Perfect , Perfect and Perfect For Non-Experience and Seniors

  6. 5 out of 5

    Gabriel Le Gall

    Overall, one of the best SQL references out there ! I love how the book is structured : problem/solution/discussion, it is such a stimulating way to learn. I also think some of the recipes are extremely useful (e.g. 13.4, 6.6, 9.10, 14.1, 14.2, 12.14, 12.13 and much more !). I have encountered many situations in which I would have liked to have read this book earlier. Finally, I think the Appendix B is interesting and challenging although quite redundant (some solutions are almost exactly the same Overall, one of the best SQL references out there ! I love how the book is structured : problem/solution/discussion, it is such a stimulating way to learn. I also think some of the recipes are extremely useful (e.g. 13.4, 6.6, 9.10, 14.1, 14.2, 12.14, 12.13 and much more !). I have encountered many situations in which I would have liked to have read this book earlier. Finally, I think the Appendix B is interesting and challenging although quite redundant (some solutions are almost exactly the same as other ones in the same chapter). I have found some mistakes here and there in the book (https://www.reddit.com/r/SQL/comments...) but if I had a point to make, it would probably be about the complexity of the solutions proposed. Sometimes, I feel like the solutions are overshooting so much the original problem. For instance : Appendix B, Question 12 : "You want to find students who take all courses" Solution proposed : SELECT sno,sname,age FROM (SELECT s.sno,s.sname,s.age, COUNT(t.cno) OVER (PARTITION BY s.sno) AS cnt, COUNT(distinct c.title) OVER() AS total, ROW_NUMBER() OVER(PARTITION BY s.sno ORDER BY c.cno) AS rn FROM courses c LEFT JOIN take t ON (c.cno = t.cno) LEFT JOIN student s ON (t.sno = s.sno) ) x WHERE cnt = total AND rn = 1 Seemingly equivalent solution : SELECT t.sno, COUNT(*) as cnt FROM [take] t GROUP BY t.sno HAVING COUNT(*) = (SELECT COUNT(DISTINCT cno) FROM [take]) I whish the book was prioritizing parsimony a little bit more, but maybe I'm just missing something

  7. 4 out of 5

    Tanya

    Thumbed through this initially and found some new tricks right away. So far it's been easy to find things for specific problems I need to solve. Thumbed through this initially and found some new tricks right away. So far it's been easy to find things for specific problems I need to solve.

  8. 5 out of 5

    E

    I mean, just the best. This was like a little bible for me when i was learning MS SQL on the job. It had a purpose. It met that purpose. Pretty simple.

  9. 5 out of 5

    Oleksandr Stefanovskyi

    The book is well organized and structured from simplest to more complex reciepes. It covers top most used RDBMs that is realy helpfull to be informed about all of them but not only the one you are using. There are a lot of well written descriotions to queries so it is easy to understand if you even do not know some key word usage. I was focused on the Oracle solutions. Great reference book that will teach you a lot of neat tricks. Book contain alot of examples that probably will be used by me in The book is well organized and structured from simplest to more complex reciepes. It covers top most used RDBMs that is realy helpfull to be informed about all of them but not only the one you are using. There are a lot of well written descriotions to queries so it is easy to understand if you even do not know some key word usage. I was focused on the Oracle solutions. Great reference book that will teach you a lot of neat tricks. Book contain alot of examples that probably will be used by me in futuere. So I could say for sure that I will be reading it again from time to time.

  10. 4 out of 5

    Jake Losh

    Rather good. A bit dated in spots, bit the core ideas are still solid. Nice to see some solutions to problems I came up with (as a SQL autodidact) that I thought were"hacky" were actually the canonical way if solving those sorts of problems. I see now clearly some of the strengths and weaknesses of specific SQL flavors now, too. Lastly, I should be using window functions more. Rather good. A bit dated in spots, bit the core ideas are still solid. Nice to see some solutions to problems I came up with (as a SQL autodidact) that I thought were"hacky" were actually the canonical way if solving those sorts of problems. I see now clearly some of the strengths and weaknesses of specific SQL flavors now, too. Lastly, I should be using window functions more.

  11. 5 out of 5

    Goce Bonev

    Abbriviations for fields and table names used in queries like: emp, empno, deptno, cnt, sal, mgrs, prez, smen and others make reading the examples hard and set a very bad example for writing good readable queries. Other than that it is a great book.

  12. 5 out of 5

    Yesi Days

    Libro con queries avanzadas, en caso de que no tengas mucho conocimiento de SQL te recomiendo algún libro introductorio como la serie de "dummies" y posteriormente continúes con este o se puede volver confuso. Muestra diferentes funciones y sus aplicaciones en la vida real. Libro interesante. Libro con queries avanzadas, en caso de que no tengas mucho conocimiento de SQL te recomiendo algún libro introductorio como la serie de "dummies" y posteriormente continúes con este o se puede volver confuso. Muestra diferentes funciones y sus aplicaciones en la vida real. Libro interesante.

  13. 4 out of 5

    Ferhat Culfaz

    Some useful snippets of information on the various SQL flavours but could be too simple for advanced users.

  14. 4 out of 5

    Adam

    Good cookbook but a not enough on joins. Joins are the backbone of all SQL work and i felt like there was some missed opportunity there to really teach that subject well.

  15. 5 out of 5

    John Doe

    Why would anyone want to read something like this when you can just Google everything? Never mind. 😑

  16. 4 out of 5

    indy

    I purchased this as an eBook in a Humble Bundle and boy was that a bargain! I'm glad to have this in my dev toolkit; it's already informed and inspired some of my work. I purchased this as an eBook in a Humble Bundle and boy was that a bargain! I'm glad to have this in my dev toolkit; it's already informed and inspired some of my work.

  17. 5 out of 5

    Ashraf Bashir

    The book covers many RDBMs, it is categorized by different topics, each topic contains many recipes. The recipes are well organized from most simple to more complex, so it takes you step by step to learn the details of each topic. Also there is a well documented description of queries. I like it a lot! So why I rated it 3/5 ? Because it is boring! And it has many repetitions of same ideas across recipes, and some recipes will not be understood unless you read first the previous recipe which make The book covers many RDBMs, it is categorized by different topics, each topic contains many recipes. The recipes are well organized from most simple to more complex, so it takes you step by step to learn the details of each topic. Also there is a well documented description of queries. I like it a lot! So why I rated it 3/5 ? Because it is boring! And it has many repetitions of same ideas across recipes, and some recipes will not be understood unless you read first the previous recipe which makes it hard to randomly jump to a recipe. But in general it serves as a very good book to learn about SQL different topics and it use-cases in a "problem-solution" approach, with some amazing tricks which bring your 'Aha!' moments ;) ... Worth reading, especially that it won't take so much of your time; because you do not have to read each solution's description if you understand how the solution works.

  18. 5 out of 5

    David Siefert

    Focused on the Oracle solutions. Great reference book that will teach you a lot of neat tricks.

  19. 4 out of 5

    Jose Seco Sanz

    This is too much for me.

  20. 5 out of 5

    Eddie Welker

    great book for those who occasionally use sql, but don't want/need to learn it from head to toe. great book for those who occasionally use sql, but don't want/need to learn it from head to toe.

  21. 4 out of 5

    Phil

  22. 5 out of 5

    Rachel

  23. 4 out of 5

    Sunny

  24. 4 out of 5

    Chris

  25. 5 out of 5

    Frazell Thomas

  26. 4 out of 5

    Aleksey

  27. 4 out of 5

    John B

  28. 4 out of 5

    Mikhail V. Evstiounin

  29. 4 out of 5

    Anji

  30. 5 out of 5

    Kellie

Add a review

Your email address will not be published. Required fields are marked *

Loading...