- Paperback: 240 pages
- Publisher: O'Reilly Media; 1 edition (June 12, 2008)
- Language: English
- ISBN-10: 0596516142
- ISBN-13: 978-0596516147
- Product Dimensions: 7 x 0.6 x 9.2 inches
- Shipping Weight: 13.6 ounces (View shipping rates and policies)
- Average Customer Review: 4.0 out of 5 stars See all reviews (7 customer reviews)
- Amazon Best Sellers Rank: #1,678,229 in Books (See Top 100 in Books)
Enter your mobile number or email address below and we'll send you a link to download the free Kindle App. Then you can start reading Kindle books on your smartphone, tablet, or computer - no Kindle device required.
To get the free app, enter your mobile phone number.
Essential SQLAlchemy 1st Edition
Use the Amazon App to scan ISBNs and compare prices.
See the Best Books of 2017 So Far
Looking for something great to read? Browse our editors' picks for the best books of the year so far in fiction, nonfiction, mysteries, children's books, and much more.
Frequently bought together
Customers who viewed this item also viewed
Mapping Python to Databases
About the Author
Rick Copeland is a senior software engineer with retail analytics firm Predictix, LLC, where he uses SQLAlchemy extensively, primarily for web application development. He has been using Python full-time for development since 2005, in projects as diverse as demand forecasting, business web applications, compilers, and hardware synthesis.
If you are a seller for this product, would you like to suggest updates through seller support?
Top customer reviews
The first few chapters are the weakest point. Their is a lot of code that introduces a lot of moving parts with very little explanation. The first chapter tries to do too much and introduce all the components. This is tantamount to sticking the whole book in the first 15 pages which results in confusion. This is a failing of the book.
As the detail topical coverage begins the book continues to falter; however, this could be the nature of the code it covers. The "get going" chapter involves metadata, engines, sessions, etc all of which can be handled in different ways and are discussed in "we'll come back to it" detail. This is also confusing. However, I think you just need to know a lot before you can do anything interesting and the book is in an (understandable) rush to get to something interesting. It may have been better to introduce these as a black box and come back to it at the end.
Once a connection is up and running the book nicely deconstruction the API and gradual progression from known to unknown through the SQL Expression Layer and then ORM. The final chapters on Elixir and SqlSoup were a much appreciated addition.
From a general content standpoint I'd say the code samples are strong and do a good job of showing SQLAlchemy off. The prose are not as strong. The book rarely goes beyond "this is what X is and how to use it." I would have preferred a more structured discussion of when to do what and the implications of doing so. With these limitations I'd say plan to read this sitting at a computer and working with each code sample in the REPL.
Overall this book does a good job. It is a step up from the online docs which are extensive but have an unfavorable knowledge / word ratio and lack a good tutorial framework. The down side, as compared to the online docs, is that this book is 2+ years old and it is starting to show. Hopefully an updated edition is in the works.
Bottom Line: Worth the money.
I used the Kindle edition of this book, and found the ability to search for terms to be extremely valuable. I did also use the Kindle version of "Using SQLite" by Jay Kreibich because I had not used SQLite before, but database gurus could get by with this book alone.
Easy to read, clear examples, useful if you come from a programming, or database (SQL) background.
To be honest, the first chapter (the proverbial introduction) almost turned me off. The author starts out slowly enough, but then he starts touching on a huge number details, which were glazing my eyes over. However, the second chapter (getting started) started back at ground zero and stepped through everything in a nice clear fashion, and the rest of the book continued in that vein. He covers all the topics you would expect in a database programming book: queries, updates, joins, the built-in types, and how to hook in to provide support for your own types.
Something I didn't realize about SQLAlchemy coming into this is that SQLAlchemy is both an ORM (what I expected) as well as a high-level, database-independent API. Which is to say, you can just access the database as tables, columns and rows rather than as classes, attributes, and object instances. Although I'd personally prefer to use the ORM, I can imagine cases where it might not be the right tool for the job, and it's good to have a choice.
I was also surprised to see the ORM supports two styles of object-relational access: the data mapper pattern (which I had seen in Django and Hibernate) and the active record (used in Ruby). The author does a good job of explaining both of these and how to use them. He even devotes a whole chapter to Exlir, which is an extension that implements the active record pattern.
In conclusion, Essential SQLAlchemy provides a thorough presentation of the SQLAlchemy tool for interfacing Python code to SQL databases. The author covers a number of different methods in which SQLAlchemy can be used to access databases from Python, and he provides plenty of details of the various APIs available to the programmer.