Top 10 Recommended Books…

Comments: No Comments
Published on: July 29, 2014

So the title says it all, right?  Well, only really partially.

Recently an article was published listing the top 10 most recommended books for SQL Server.  That’s the part the title doesn’t say.  It is really important to understand that we are talking about the top 10 recommended books for SQL Server.

The beauty of the top 10 list is that I have a book on that list.  It caught me by surprise.  That is very cool.

If you are interested in finding a book, I recommend naturally that you check out my book.  But just as importantly have a look at the list.  This was a list that was published independently by SQL Magazine.  On the list you will find books by people like Kalen Delaney, Itzik Ben-Gan, and Grant Fritchey.

2012_Recipes

Check out the original list, here!

Transaction Log Management

Categories: Book Reviews, SSC
Comments: No Comments
Published on: October 7, 2013

I have had the distinct pleasure of being asked to review a book by RedGate.  The book is by a friend and respected community member Gail Shaw (blog | twitter).  The book is a stairways style book and is titled “SQL Server Transaction Log Management.”

sql-server-transaction-logs-200

 

I read this book with the intent to provide an in-depth analysis and technical review.  I was happy to take on the challenge of reviewing this book and happy with what I gleaned from the book.

Let’s start with my overall impression of the book.  This book is ideal for every junior DBA and every accidental dba out in the workforce.  If I need to repeat that statement I will, or you can flash back and reread that statement as many times as you need.

My next observation about this book is that it seems obvious that it was written with a community undertone.  There are numerous references to community resources and individuals who are ever-present in the community.  That community tone can be an extension of RedGate as a whole.  Community appears to be fairly important to RedGate overall.

I enjoyed reading the book, and I enjoyed the demo scripts.  An absolute must with this book is the demo scripts that can be downloaded and sampled (see page 13 for more code sample links).  They are an absolute must to help illustrate the points that Gail and Tony are making.

I do have a minor critique that is more along the lines of readability.  The first critique may be a bit zealous, but I found it difficult to read various characters such as I and 1 due to the choice of font in the paragraph text.  The numeric 1 is a different font and looks like an I in paragraph versus the numeric 1 in the chapter headings and image text that actually looks like a numeric 1.  There are a few cases where the font appeared to change as well making it seem disjointed.  Again, that is a really a minor issue and nothing related to the technical content.  An example of this font switching may be seen on Page 29 and 30.

That said, something I like to do with books such as this is try to take something of interest from each of the chapters.  So, here is a list of points of interest for each chapter.

Chapter 1

Many DBAs (part-time, accidental or even full time) along with Vendors (I am adding them to this group), do not backup their databases correctly.  Many in these groups “perform full backups on their databases, but they don’t perform transaction log backups” (page 21).

This book underscores that problem and helps show those groups how to implement transaction log backups and better manage their database transaction logs.

Chapter 2

Another item that many DBAs neglect to do is manage the log file fragmentation.  “Log file fragmentation can degrade the performance of SQL Server processes that need to read the log ” (page 41).  On some databases, I have seen this degradation cause delays in the range of 20-30 minutes or worse when bringing a database online.  Do you want to take that risk?

Chapter 3

This chapter covers a topic that I see happening on a regular basis – even with “seasoned” DBAs.  That topic is concerning databases that are in “pseudo-full.”  This mode of operation is baffling to me.  I don’t quite understand why people place a database in full recovery model and then never take a full backup of the database.  The database transaction log will continue to truncate as if it were in simple recovery model.

I also particularly enjoyed reading about some really easy ways to break a transaction log chain.  There are a few methods listed on how to break the chain, but more as a caution to not use them as opposed on showing you how to use them.  One method is the switch from Full recovery to Simple recovery to try and control a runaway log.

One method that wasn’t mentioned ( at least not until Chapter 7) was backing up the transaction log to a NUL device.  Backing up to a NUL device is just as destructive to the log chain as any method mentioned in the book.

One thing this chapter does not delve into is the implications of breaking the log chain.  By Design that is covered in Chapter 7.  One item that was not covered in great deal was that of log-shipping.  Think of the implications of a Mirrored or Log-shipped database that is in the multi-terabyte range.  Do you want to be the one to have to copy a full backup cross-country in order to rebuild log-shipping because you created a log backup to the NUL device?

Chapter 4

This chapter is summed up succinctly in the summary section of the chapter.  “If you wish to measure exposure to data loss in minutes rather than hours, don’t use SIMPLE model” (page 61).

Chapter 5

Have you ever heard the expression “measure twice cut once”?  In this chapter we see a subtle reminder of the importance to double-check these types of things.  Did you know that records in the backupset table could be manipulated?  Do you rely only the results of queries to the backupset table to confirm that backups were taken?  That just might be a mistake.

This chapter shows the need to also query sys.database_recovery_status to confirm backups of the database log.  If you are not double checking your log backups then please start doing so.

Chapter 6

This chapter covers Bulk Logged and some common uses for this chapter.  Some concerns are also illustrated in this chapter about the use of Bulk Logged in various scenarios.  There is also a discussion on pros and cons as well as Best Practice.  A major concern with Bulk Logged is discussed, and for that you should read the book.

I particularly enjoyed the demo on space savings regarding the use of Bulk Logged in this chapter.  Have a run at the demo and enjoy what you learn from this chapter.

Chapter 7

Besides the script on page 141 for finding open transaction information and the warnings about CDC, I found the section on Mismanagement to be an absolute gem.

There is a lot of mis-information available on the internet.  The information concerning transaction logs can be quite dangerous.  This section discusses some of the more prominent problems that may be found through internet searches.  The debunking of some of these dangerous myths is a must read.

Chapter 8

This chapter covers some of the Golden Rules of transaction log management.  A SQL Server Database is NOT a set it and forget type of venture.  By extension, a transaction log is even less of a set it and forget it undertaking.

One of very first things debunked in this myth busting chapter is that concerning the use of multiple transaction logs.  Simply put, don’t do it.  There is an edge case where adding a second transaction log is helpful – but once the issue is resolved the additional log file MUST be removed.

One thing you may find in your internet searches is what is deemed a best practice to manage your transaction log growth explicitly.  This chapter discusses that and demonstrates the benefits to manually managing your transaction logs.

In this chapter we also see a renewed discussion concerning log fragmentation.  Here we see more things that are affected by a highly fragmented transaction log.  To underscore the importance of proper management of your transaction log and the number of log fragments there is a very good demo script.  Check it out.

Chapter 9

To top off all the great information, we conclude with something that is all too frequently overlooked by many (especially those in the earlier defined groups).  You must monitor your transaction log!!

Conclusion

There is a lot of great information throughout this book.  There are also some great demo scripts throughout the book.

One final note is in regards to something that I often see vendors doing.  It was touched upon in this book and warned against.  Please do not store backups of different types or even different databases in the same backup file.  This is a practice that will almost certainly guarantee you of a larger scale disaster.  What if you have one corrupt backup within that mass accumulation of backups within the same file?

I enjoyed this short book.  I recommend it be on every junior or accidental DBAs bookshelf.  I’d also recommend it be in every employers library for use by all IT employees.

Freedom

Categories: Book Reviews, News, SSC
Comments: No Comments
Published on: February 7, 2012

Not too long ago, I blogged about a Book called Daemon.  Freedom is the sequel to Daemon.

I enjoyed reading this book.  The story continues from Daemon, but in a largely different direction.  I like the direction the book took, for the most part.  I was hoping that there would be more tech talk and not so much of the sci-fi tek.  I liked the sci-fi tek, I just thought it would have been more down to earth to keep it closer to reality.

Daemon was scarily real.  The exploits were real, the danger seemed real.  In Freedom, I felt it made a big reach.  When looking at both books together though, it seems like a natural progression.

I like the plot.  The story culminates with a confrontation at a compound in Texas.  I really thought that the confrontation was a huge let-down.  I really expected more conflict at that point.  Everything was mounting to that, but the ultimate goal was to demonstrate that the group of people from the darknet still could think for themselves.

In the end, it was a good story.  I would like to have some of the technology.  I must also admit that Freedom was harder to put down than Daemon for me.  I found myself rooting in favor of the Daemon.  I started rooting for the Daemon at the end of the first book.

Daemon

Categories: Book Reviews, News, SSC
Comments: 1 Comment
Published on: January 4, 2012

At the recommendation of Jorge Segarra (Blog | Twitter),  I got the book Daemon.  Well, I actually got that about a year ago as a gift – but it was on my list of books to read because Jorge recommended it.

I have finally finished reading it and will be starting Freedom very shortly.  I am glad I bought Freedom prior to finishing Daemon since the ending leaves to many open story lines.  I really hate to finish a book on a cliff hanger and then have to wait for the next book.

While reading the book, you sit there and wonder if your servers are patched.  You also wonder if the network has been properly secured against intrusion.  But in the end, you accept that it doesn’t matter how secure the network is because the most successful way to hack a network is via social engineering.

Reading the book from an IT perspective, you understand that much of it is plausible.  You also find yourself slobbering over some of the tech that is described.  I really want some of those security systems, at least two AutoM8s, and an omnipresence stereo system (for lack of a better term).  A Razorback would be interesting to own too. ;)

I really enjoyed the book.  There was plenty of talk of databases, data security, and data breaches.  There was also a nice mix of espionage, treason, and mystery.  The plot seems to continue to twist and turn – which kept me involved.  At many points, you are also greeted with cold hard reality with some of the decisions that must be made and with regards to how politics work.

Go get this book and read it.  I’m off to read Freedom now.  I find myself expecting a myriad of possible conclusions while hoping for a better conclusion.

Throne of Fire

Categories: Book Reviews, News, SSC
Comments: No Comments
Published on: November 22, 2011

Finally, I have completed another book.  I took the opportunity while traveling to catch up on some reading.  Better yet, I was able to do this while testing out my Kindle.

The book I just finished is “Throne of Fire” by Rick Riordan.  This is the second book in the Kane Chronicles series and is very similar to the popular series about Percy Jackson (by the same author).

Sadly, some of my dislikes about the Percy Jackson books are present in this series as well.  I can get past some of that because the story is good (grammar and spelling mistakes throughout).

The two Kanes (Carter and Sadie) embark in this book to awaken the sleeping crazy Zeus.   The meet new friends and new challenges.  There are bumps and twists throughout the book.  And the one thing that kinda bugs me is that the climax is at the end of the book – creating a cliffhanger.  Now I am stuck waiting for the next book to be published – arghhh.

I liked the story.  I thought it was entertaining.  I would certainly let me children read the book.  It is a nice adventure and a good escape from the daily stresses.

Check it out sometime.

Beyonders

Categories: Book Reviews, News, SSC
Comments: No Comments
Published on: September 16, 2011

It has been a looooong time since I wrote a little book review.  It’s nice to take time out with a little fantasy to ease and please the brain.

Just because I haven’t written a review in a long time doesn’t mean that I stopped reading books.  I actually have a queue of books finished that could have a review written.  For now, I’ll just write a review on the latest book completed and probably never get around to the others – though they would be worthwhile.

Beyonders is the name of the book I recently completed.  This is a fantasy novel that is the first in a three book series.  For now, I am somewhat stuck waiting for book two.  Knowing that the book is part 1 of 3 can help you assume that this book ends in a cliff hanger.  That is somewhat frustrating – I was into the book and really wanted to reach the finale much sooner than the anticipated two years for the remaining tomes.

In Beyonders, two earth children get “warped” to an alternate dimension.  The are transported to a place that is void of heroes.  In this world, magic reigns supreme.  These two children must solve an enigma and become heroes in order to be able to return to earth.

These kids meet interesting people along the way, make several friends, and make even more enemies.  There is plenty of peril along the way.  The kids must solve the puzzle by gaining pieces to a word along their quest.  This word can defeat the wizard and restore peace to the world.  By the end of the first book, the kids have retrieved all the syllables to this word.  Shortly after completing the word the book ends and you must wait until the next book to continue the quest.

The plot had plenty of twists and turns to keep you interested.  It also portrayed these youth quite well as longing to return to their families and friends  Neither of them knew each other prior to being sucked into this new world.  Both show a lot of concern for the other as the book progresses and their friendship forms.

I would recommend reading this – especially if you have teenagers into these types of stories.

The Lost Hero – A review

Comments: No Comments
Published on: January 25, 2011

With what looks to be five books planned in a new series by Rick Riordan, people have some good fantasy ahead of them.

I just finished the first installment in this new series and must say that I am pleased with the story line.  New characters, new aspects of mythology and a third series revolving around those principles.  Rick Riordan has got a really hot topic and something working for him with all three of his series.

In this series we are introduced to the Roman versions of the mythological gods.  With the Roman aspects of these gods, we also get a new class of “evil god.”  Book one takes off from the final prophecy in the Percy Jackson series and brings three new demigods as the central focus.  I like the powers of these new demigods.  I also like the personalities of each.  Rick has done a great job of illustrating their characteristics without making them sound too much like heroes from prior books.

I did not like the grammatical problems constantly repeated throughout this book.  The same thing happened in the Percy Jackson series and got better with each book.  This is not an issue with the dialog but more to do with editing.  An example would be “Jason sat to next to the tree.”  Stuff like that is easily skipped by many people but sticks out like a sore thumb to me.

Overall, I highly recommend the book if you enjoy mythology and fantasy.

MockingJay – a review

Comments: 1 Comment
Published on: January 4, 2011

After a long wait, I have finally read the final installment in the “Hunger Games” trilogy.  I read the other two books earlier in the year in 2010 and then had to wait for the third book to come out.   Once the book came out (September 2010) I had to find some time to read the book.  Actually, I had to make time to read it.  Reading helps to de-stress and I just needed to do it.  you can read my reviews of the other books here and here (d’oh didn’t write one for the first book).

Up front – this was the third best book in the series.  I was mildly disappointed in this book.  The story was good but was just not as good as the first two.  It seemed to me that the author was trying to develop the story as the story unfolded.  The twists and turns in the plot were minor and mostly the plot was about the Mockingjay recovering from this or that.  It just wasn’t in true hunger games fashion.

It also seemed obvious to me that Plutarch (games master) was busy trying to orchestrate yet another Hunger Games.  That became painfully evident early on but was blaringly obvious when they are in the command center going over the map for Capitol City.  And if there was any doubt in the final chapters as to who did what in regards to a certain bombing event – you weren’t paying attention while reading.

I still liked the book and i still liked the series – I expected more and for it to be better.  If the book was to be another Hunger Games – then play that up a bit more.  It is the how the first two books were written and the description of the games that got people intrigued.

I would still say to go read the book and the entire series though.

Drumroll Please…

Comments: No Comments
Published on: November 29, 2010

Defensive Db Programming Chapter 10

After dragging this review on for months now, it is finally time to bring this bad boy home and wrap it up.  I have been working through a chapter by chapter review of the book by Alex Kuznetsov (Blog | Twitter).  Alex has been taking us through the process and various techniques to better program defensively.  This is the last installment in that series (yes shed a little tear).  This chapter is devoted to teaching us how to better deal with Modifications that Survive Concurrency.  Some of the problems associated with this are:

  • lost modifications, a.k.a. lost updates – such problems occur when modifications performed by one connection are overwritten by another; these typically occur silently; no errors are raised
  • resource contention errors – such as deadlocks and lock timeouts
  • primary key and unique constraint violations – such problems occur when different modifications attempt to insert one and the same row. (p. 337)

Another way of stating these types of problems is that there is a “Race Condition.”  You may have heard this term thrown around by the developers from time to time.  It isn’t made up and is a very real potential problem that must be dealt with accordingly.

I can’t give this chapter enough props nor enough due through a short blog post on it.  It is a lengthy chapter and covers a very important topic (my opinion).  Alex covers each of the race conditions and continues to show how to resolve that race condition.  He uses real world scenarios as you should have grown to see up to this point.  I will point out that I had not considered using RowVerssion to help resolve some race conditions.  That is at least one thing I have learned from reading this chapter.

Another thing that struck me and made me think is related to the TSQL patterns that Fail High concurrency.  Here two methods are scrutinized and a third method is proposed.  The third method is MERGE.  That is a subject about which I could learn a lot.

For the final time (since this series has come to a close), go get the book and read it.  You can find the rest of the articles by linking back through this link.

Defensive Db Programming Chapter 09

Comments: No Comments
Published on: November 22, 2010

It is down to the final two chapters of the book by Alex Kuznetsova.  Check out the previous chapter here.  The review of this book is certainly taking longer to produce than I had planned.  However, I think you find that the book is still worth it and that this little series is also worth it.  I hope that the spread of this series is at least getting to a few more people here and there and that more people may get a copy of “Defensive Database Programming”.

This chapter is about concurrent queries and Isolation Levels.  I think these seem to be a hot button of late – at least I have been hearing more and more talk about them than in the near past.  Alex starts the chapter with a stark realization.  He states:

Even the simplest SELECT, against one table, may retrieve incorrect results when the base table is being modified at the same time. (p. 297)

Think about that statement for a bit.  I imagine it won’t take you long to realize that it is true.  I am certain that you have come up with several examples that underscore that statement.

Alex then progresses through Isolation levels giving a demonstration of what will happen under the described circumstances.  This chapter is not intended to explain the differences between the Isolation levels, but merely to demonstrate what could happen – as has been the theme throughout the book to this juncture.  These examples that Alex uses first describe a theoretical problem and then he reproduces the theoretical problem with real world scenarios.

Alex also outlines in this chapter some considerations for choosing the correct Isolation level for your business needs.  Pros and Cons are weighed and usefulness of the Isolation level is discussed.  Alex also offers up the notion of using a query hint to issue a table lock when querying the database.  Due to the reciprocal effects Alex also states that it is almost never really an option.

Alex goes the extra mile in this chapter by discussing how we can minimize deadlocks.

In the end Alex makes a recommendation as to which Isolation level he would use.  Check it out and see for yourself.

«page 1 of 3




Calendar
September 2014
M T W T F S S
« Aug    
1234567
891011121314
15161718192021
22232425262728
2930  
Content
SQLHelp

SQLHelp


Welcome , today is Monday, September 22, 2014