<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://thewebjedi.com/cs/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Jedi Meditations</title><link>http://thewebjedi.com/cs/blogs/meditations/default.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007.1 (Build: 20917.1142)</generator><item><title>Working with Active Directory in .NET 3.5</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2008/11/07/working-with-active-directory-in-net-3-5.aspx</link><pubDate>Fri, 07 Nov 2008 20:22:37 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:356</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=356</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2008/11/07/working-with-active-directory-in-net-3-5.aspx#comments</comments><description>&lt;p&gt;Many projects that I’ve worked on over the years have required some kind of interface with Active Directory. Back in the good ol’ ASP days, there was &lt;a href="http://msdn.microsoft.com/en-us/library/aa772170.aspx"&gt;ADSI&lt;/a&gt; (Active Directory Services Interface), and .NET uses the &lt;a href="http://msdn.microsoft.com/en-us/library/system.directoryservices.aspx"&gt;System.DirectoryServices&lt;/a&gt; namespace to essentially wrap ADSI with managed code. It’s been a long time since I worked directly with ADSI, but working with AD up to and including the .NET Framework 2.0 was never a very straight-forward task.&lt;/p&gt;  &lt;p&gt;Take for example the classic requirement of simply obtaining the current user’s full name from AD. Say you have a web site that uses either IIS/NTFS to protect pages using ACLs, or uses ASP.NET Forms Authentication with an AD Provider. Obtaining the user’s login name is relatively easy, using the Page’s &lt;a href="http://msdn.microsoft.com/en-us/library/system.web.ui.page.user.aspx"&gt;User&lt;/a&gt; object:&lt;/p&gt;  &lt;p&gt;string loginName = User.Identity.Name;&lt;/p&gt;  &lt;p&gt;But getting the user’s full name from AD requires several lines of code involving &lt;a href="http://msdn.microsoft.com/en-us/library/system.directoryservices.directorysearcher.aspx"&gt;DirectorySearcher&lt;/a&gt; and &lt;a href="http://msdn.microsoft.com/en-us/library/system.directoryservices.searchresult.aspx"&gt;SearchResult&lt;/a&gt; objects:&lt;/p&gt;  &lt;div style="font-size:11pt;background:white;color:black;font-family:consolas;"&gt;   &lt;p style="margin:0px;"&gt;&lt;span style="color:blue;"&gt;string&lt;/span&gt; firstName = &lt;span style="color:blue;"&gt;null&lt;/span&gt;;&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:blue;"&gt;string&lt;/span&gt; lastName = &lt;span style="color:blue;"&gt;null&lt;/span&gt;;&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&amp;#160;&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:#2b91af;"&gt;DirectoryEntry&lt;/span&gt; entry = &lt;span style="color:blue;"&gt;new&lt;/span&gt; &lt;span style="color:#2b91af;"&gt;DirectoryEntry&lt;/span&gt;();&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:#2b91af;"&gt;DirectorySearcher&lt;/span&gt; searcher = &lt;span style="color:blue;"&gt;new&lt;/span&gt; &lt;span style="color:#2b91af;"&gt;DirectorySearcher&lt;/span&gt;(entry);&lt;/p&gt;    &lt;p style="margin:0px;"&gt;searcher.PropertiesToLoad.Add(&lt;span style="color:#a31515;"&gt;&amp;quot;givenName&amp;quot;&lt;/span&gt;);&lt;/p&gt;    &lt;p style="margin:0px;"&gt;searcher.PropertiesToLoad.Add(&lt;span style="color:#a31515;"&gt;&amp;quot;sn&amp;quot;&lt;/span&gt;);&lt;/p&gt;    &lt;p style="margin:0px;"&gt;searcher.Filter = &lt;span style="color:#a31515;"&gt;&amp;quot;(&amp;amp;(objectCategory=person)(samAccountName=jsmith))&amp;quot;&lt;/span&gt;;&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:#2b91af;"&gt;SearchResult&lt;/span&gt; result = searcher.FindOne();&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:blue;"&gt;if&lt;/span&gt; (result.Properties[&lt;span style="color:#a31515;"&gt;&amp;quot;givenName&amp;quot;&lt;/span&gt;].Count &amp;gt; 0) firstName = result.Properties[&lt;span style="color:#a31515;"&gt;&amp;quot;givenName&amp;quot;&lt;/span&gt;][0].ToString();&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:blue;"&gt;if&lt;/span&gt; (result.Properties[&lt;span style="color:#a31515;"&gt;&amp;quot;sn&amp;quot;&lt;/span&gt;].Count &amp;gt; 0) lastName = result.Properties[&lt;span style="color:#a31515;"&gt;&amp;quot;sn&amp;quot;&lt;/span&gt;][0].ToString();&lt;/p&gt; &lt;/div&gt;  &lt;p&gt;Ick. Thankfully, .NET 3.5 has added the &lt;a href="http://msdn.microsoft.com/en-us/library/system.directoryservices.accountmanagement.aspx"&gt;System.DirectoryServices.AccountManagement&lt;/a&gt; namespace which abstracts most of this code and makes it super-easy to deal with AD Principals in a strongly-typed manner:&lt;/p&gt;  &lt;div style="font-size:11pt;background:white;color:black;font-family:consolas;"&gt;   &lt;p style="margin:0px;"&gt;&lt;span style="color:#2b91af;"&gt;PrincipalContext&lt;/span&gt; pc = &lt;span style="color:blue;"&gt;new&lt;/span&gt; &lt;span style="color:#2b91af;"&gt;PrincipalContext&lt;/span&gt;(&lt;span style="color:#2b91af;"&gt;ContextType&lt;/span&gt;.Domain);&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:#2b91af;"&gt;UserPrincipal&lt;/span&gt; user = &lt;span style="color:#2b91af;"&gt;UserPrincipal&lt;/span&gt;.FindByIdentity(pc, &lt;span style="color:#a31515;"&gt;&amp;quot;jsmith&amp;quot;&lt;/span&gt;);&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:blue;"&gt;string&lt;/span&gt; firstName = user.GivenName;&lt;/p&gt;    &lt;p style="margin:0px;"&gt;&lt;span style="color:blue;"&gt;string&lt;/span&gt; lastName = user.Surname;&lt;/p&gt; &lt;/div&gt;  &lt;p&gt;Gotta love progress!&amp;#160; :-)&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=356" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category></item><item><title>Home Theater PC</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2008/10/14/home-theater-pc.aspx</link><pubDate>Tue, 14 Oct 2008 19:59:05 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:349</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=349</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2008/10/14/home-theater-pc.aspx#comments</comments><description>&lt;p&gt;I love having the ability to play computer video files on my living room television. Back in the old days (about 3 or 4 years ago), I used a modded original XBox with XBox Media Center (XBMC) to perform this task. XBMC was great because it worked with just about every video format out there. In fact, I don’t think I ever ran across a video file that XBMC wouldn’t play. Ahh, those were the good ol’ days.&lt;/p&gt;  &lt;p&gt;Unfortunately, the original XBox doesn’t have the horsepower necessary for playing today’s high-definition video files. Though I now have an XBox 360, the only high-definition video it will play is Windows Media or MPEG files. Oh, there are many solutions for performing on-the-fly transcoding from your PC for unsupported files, but I haven’t seen any that preserve multi-channel surround sound along with that transcoding. And modding the 360 may be possible, but it doesn’t seem as popular as the original XBox mods, so I’m not going down that dark alley.&lt;/p&gt;  &lt;p&gt;Instead, I recently bought and built a relatively cheap home theater PC (HTPC). Building a PC for dedicated home theater use isn’t a new idea – people have been doing it for years. But the concept has recently spiked in popularity with many generic components now available allowing people to build some pretty nice systems for not too much money. Still, putting a working HTPC together is not for the weak-hearted as the industry still has a long way to go before the technology is mature. At the outset of this project, I was worried that I wouldn’t be able to achieve the usability I wanted because of several factors: home network speed, audio/video codec configuration issues, integration with my Harmony remote control, proper display on my aging high-def TV, and more. In the end, it turned out to be a lot less effort than I anticipated.&lt;/p&gt;  &lt;p&gt;The system I put together consisted of the following:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;&lt;a href="http://www.antec.com/usa/productDetails.php?lan=us&amp;amp;id=92480"&gt;Antec NSK2480&lt;/a&gt; mATX chassis (has no IR sensor or front-panel display) &lt;/li&gt;    &lt;li&gt;&lt;a href="http://www.giga-byte.com/Products/Motherboard/Products_Overview.aspx?ProductID=2814"&gt;Gigabyte GA-MA78GM-S2H&lt;/a&gt; mATX motherboard with integrated ATI HD 3200 graphics &lt;/li&gt;    &lt;li&gt;AMD Athlon 5200+ EE CPU &lt;/li&gt;    &lt;li&gt;2GB Crucial PC6400 RAM &lt;/li&gt;    &lt;li&gt;500GB Western Digital Hard Drive &lt;/li&gt;    &lt;li&gt;Windows Media Center remote control &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;The entire package cost me less than $500. I chose this chassis because it looks like a piece of audio/video gear and fits nicely in my A/V rack. It was inexpensive, comes with a nice power supply, and has quiet case fans. This motherboard is a popular HTPC choice because of its micro-ATX form factor, integrated ATI graphics which handles high-def video with aplomb, the built-in HDMI connector, and built-in optical S/PDIF output connector. I was originally going to get an Athlon 4850 CPU, but there were none left in stock. So I got the slightly more power-hungry 5200 for only $10 more. The Windows Media Center (WMC) remote control was only $30, and I only bought it for the IR receiver that it comes with (since I planned to used my Harmony remote instead).&lt;/p&gt;  &lt;p&gt;Assembling the PC was a breeze, so I had no issues there. After installing Vista Ultimate as the OS, it was time to start getting my hands dirty with codec configuration. Before I get into that, I should mention that I was pleasantly surprised to find the WMC remote could be used to place the machine in and out of sleep mode. Excellent! Unfortunately, the IR code that is used for this also turns my XBox 360 on and off. I haven&amp;#39;t yet resolved this minor annoyance.&lt;/p&gt;  &lt;p&gt;Back to the codec thing. In preparation for what I assumed would be a nightmare of configuration trial and error, I spent some time over at &lt;a href="http://www.avsforum.com/"&gt;AVS Forums&lt;/a&gt; researching the recommended installation incantations. Though many senior members strongly recommended against installing pre-packaged “codec packs,” several others indicated they had very good luck with &lt;a href="http://shark007.net/"&gt;Vista Codec Pack&lt;/a&gt; (VCP). So, I tried out VCP and what do you know – it worked great! All my high-definition content (including the relatively new .mkv format) worked like a charm in Vista Media Center! I had some small issues getting DTS and Dolby Digital 5.1 surround sound formats to output properly to my surround processor, but I had that working within 15 minutes. So, the codec nightmare I had feared turned out to be a non-issue after all.&lt;/p&gt;  &lt;p&gt;I did have one video glitch, however, but it wasn’t a surprise. My TV is a circa 1999 Toshiba rear-projection HDTV set. When this thing was built, HDMI wasn’t even a gleam in some video engineer’s eye. All I have are component inputs on the back of my set. I did buy an HDMI-to-component converter off eBay that works fairly well, but it appears to introduce a slight horizontal and vertical offset that unfortunately cannot be corrected with ATI’s driver software alone. Thankfully, the multi-talented Swiss-army knife of video signal software, &lt;a href="http://www.entechtaiwan.com/util/ps.shtm"&gt;PowerStrip&lt;/a&gt;, was able to remedy this for me.&lt;/p&gt;  &lt;p&gt;After all this, I was pretty happy using Vista Media Center to browse my server for video files and play them back over my gigabit home network. I can completely control the HTPC and VMC with my Harmony remote control, and everything just works. However, having used XBox Media Center for years, I knew there was a better way to control the HTPC than with VMC. A friend at work told me about &lt;a href="http://www.team-mediaportal.com/"&gt;MediaPortal&lt;/a&gt;, a sort-of spin-off from XBMC for Windows machines. MediaPortal is somewhat more slick than VMC with my personal killer feature being the integration with the &lt;a href="http://www.imdb.com"&gt;Internet Movie Database&lt;/a&gt; (IMDB). Instead of browsing video files alphabetically with thumbnails (which are usually black squares since movies often start with a black screen), I can now browse my videos by genre and by using the poster cover art. It’s a much better way to work with your movie collection.&lt;/p&gt;  &lt;p&gt;I’ll still be tweaking with my HTPC for several weeks I’m sure, but for the moment I am extremely satisfied and impressed with how easy this was to put together. Stop watching video on your teeny-tiny computer screen – get yourself a nice HTPC today!&amp;#160; :-)&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=349" width="1" height="1"&gt;</description></item><item><title>Car Dilemma Solved - Mostly</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2008/08/17/car-dilemma-solved-mostly.aspx</link><pubDate>Sun, 17 Aug 2008 11:58:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:339</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=339</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2008/08/17/car-dilemma-solved-mostly.aspx#comments</comments><description>&lt;p&gt;I few months ago, I &lt;a href="http://thewebjedi.com/cs/blogs/meditations/archive/2008/05/17/new-car-search-t-55-days-and-counting.aspx"&gt;blogged about my search&lt;/a&gt; for a replacement vehicle as my existing lease was about to end. My lament was that I absolutely loved my existing car (a 2004 Volvo XC70) but that the lease buyout price was far too high given its current market value. And leasing a new version of the same model was somewhat price-prohibitive. I began an exhaustive search for a replacement, but nothing else really caught my fancy.&lt;/p&gt; &lt;a href="http://thewebjedi.com/cs/photos/favourite_photos/images/original/2004-Volvo-XC70.aspx" target="_blank"&gt;&lt;img src="http://thewebjedi.com/cs/photos/favourite_photos/images/341/640x480.aspx" alt="" width="" align="right" border="0" height="" hspace="10" /&gt;&lt;/a&gt;&lt;p&gt;So, on the lease termination date I returned my car. It was a sad moment - tears were shed (well, no, not really). I was going to wait until the following month to see if Volvo&amp;#39;s lease deals were more attractive, though if you&amp;#39;ve been following the news in the automotive industry lately you&amp;#39;ll know that almost every car manufacturer is taking a bath on lease returns lately, with most manufacturers either raising their lease rates or discontinuing their lease programs altogether. This option was looking like a long shot and, as it turned out, it was.&lt;/p&gt; &lt;p&gt;So I starting looking at used XC70s to replace my returned 2004. A few days after I returned the car, I saw a gem of a car online. It was a nice 2004 XC70 and the price was agreeable. I dug a little deeper and realized that this was my car that I had just returned! So I scooted on down to the local Volvo dealer and said I&amp;#39;d like my car back, please.&lt;/p&gt; &lt;p&gt;Me and my precious 2004 XC70 have been reunited. However, it&amp;#39;s making some odd noises now - perhaps a new Volvo is still in my future after all.&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=339" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Toys/default.aspx">Toys</category></item><item><title>HTC Touch As An iPhone Replacement</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2008/08/17/htc-touch-as-an-iphone-replacement.aspx</link><pubDate>Sun, 17 Aug 2008 11:32:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:338</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=338</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2008/08/17/htc-touch-as-an-iphone-replacement.aspx#comments</comments><description>&lt;p&gt;In January of this year (2008), I was getting the itch to buy something to replace both my cell phone and my Palm PDA (I used the Palm as my MP3 player). I wanted an all-in-one solution so I wouldn&amp;#39;t have to carry around two pieces of technology with me. Being the geek that I am, I was naturally interested in the iPhone but at that time it still wasn&amp;#39;t available in Canada, and wouldn&amp;#39;t be available at all through my preferred mobility provider which uses a CDMA network. So entranced was I by this new Apple technology that I seriously considered getting an iPod Touch and just keeping my old cell phone. I&amp;#39;d still have two items to carry around, but at least one of them would be super-cool.&lt;/p&gt; &lt;p&gt;&lt;img src="http://www.engadget.com/media/2007/09/iphone-vs-iphone-440.jpg" alt="" width="439" align="right" border="" height="240" hspace="10" /&gt;In doing some research, I came across an interesting Windows Mobile phone from HTC called the &amp;quot;Touch.&amp;quot; It has no number or key pad and instead relies almost completely on its touch sensitive screen for controlling the device (much like the iPhone). Windows Mobile was never designed to be operated by a touch screen, so HTC includes this glitzy little interface called Touch Flo which is neat enough, but doesn&amp;#39;t really replace the standard Windows Mobile interface. However, the real advantage of the HTC Touch was the network fee - it came with an UNLIMITED data plan for only $7 a month! For replacing my MP3 playing Palm, the HTC Touch uses a microSD card, so I could at least approximate the storage capacity of an 8GB iPod Touch.&lt;/p&gt; &lt;p&gt;So that&amp;#39;s what I did. I bought the HTC Touch with an 8GB microSD card and I&amp;#39;ve been mostly happy with it. Unlike the iPod or iPhone, the HTC has both regular and stereo bluetooth, so I also bought a pair of Motorola S9 bluetooth headphones, which work and sound pretty darn good. So, things have been good - mostly. There are some serious downsides to this solution, however.&lt;/p&gt; &lt;p&gt;First, I&amp;#39;ve mentioned that Windows Mobile is not really a mobile OS designed for touch screens so it has nowhere near the usability or cool flashiness of the iPod Touch/iPhone. Second, the battery life is atrocious - with the bluetooth radio on all the time and playing MP3s for about an hour a day, the device won&amp;#39;t last 24 hours without a recharge. These aren&amp;#39;t deal-breakers mind you, just a little annoying. What is more than just a little annoying is the fact that the HTC tends to corrupt the contents of the microSD card every once in a while (a couple of times a month on average). This is a known issue all over several Internet forums, but no one knows why and a fix is not forthcoming from HTC. So I just live with it, growling when it happens and re-copying my MP3s over when it does. I expect this doesn&amp;#39;t happen on the iPhone.&lt;/p&gt; &lt;p&gt;The latest &amp;quot;gotcha&amp;quot; with using the HTC as an iPhone replacement is with my car stereo, or pretty nearly any car stereo that supports &amp;quot;MP3 players.&amp;quot; Usually this means they have an AUX jack that you can plug your MP3 player&amp;#39;s headphone jack into. And I suppose that works well enough - it&amp;#39;s certainly way better than using a tiny FM transmitter to do the same thing. But if you&amp;#39;re lucky enough to have a decent car stereo, it will also come with an iPod dock connector so that you can completely control your iPod through the car stereo system! Playlists, artist names and song titles show up right on the car stereo display, and the iPod can be controlled with the steering-wheel radio controls, if your car is so equipped (mine is). But, if you don&amp;#39;t have the magical device from Apple, all you&amp;#39;ve got is the AUX jack. Boo. (I understand that come vehicles also let you plug in any USB memory stick that contains MP3s and will work much like the iPod control - alas, my car does not have this option.)&lt;/p&gt; &lt;p&gt;So, do I buy an iPod so I can have the convenience (and cool) factor when I&amp;#39;m in my car (not to mention the absence of corrupted memory cards)? Do I go back to having two items of technology to lug around? I&amp;#39;m very tempted, though having everything on my cell phone is mighty handy. I suppose if it was really worth it to me, I could dump the HTC and switch mobility providers and get the iPhone now that it&amp;#39;s available in Canada. Honestly though, paying $75 a month for the privilege isn&amp;#39;t really enticing, not to mention the early termination fee I&amp;#39;d face with my existing provider. But I still have my eye on a new iPod. :)&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=338" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Toys/default.aspx">Toys</category></item><item><title>New Car Search: T-55 Days And Counting</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2008/05/17/new-car-search-t-55-days-and-counting.aspx</link><pubDate>Sat, 17 May 2008 15:03:28 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:335</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=335</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2008/05/17/new-car-search-t-55-days-and-counting.aspx#comments</comments><description>&lt;p&gt;The lease on my beloved 2004 Volvo XC70 is up in July and I&amp;#39;ve been caught up in new car shopping fever for the past few months. Since my current car has been an absolute paragon of reliability and I utterly love it to death, a new 2008 XC70 would seem to be the obvious choice. And it is, except that it&amp;#39;s awfully bloody expensive. I was hoping to reduce the amount of money I pay every month for my transportation, so I decided to try out some other less expensive alternatives. Since the XC70 is actually quite competitively priced in its class, cross-shopping with similar models (Audi, BMW) wasn&amp;#39;t really an option. Other Volvo models aren&amp;#39;t really that much cheaper so I&amp;#39;m not considering those, either. So I started with some more commonly popular vehicles.&lt;/p&gt; &lt;p&gt;My first test drive was with the uber-popular Hyundai Sonata. I took their top trim level car (V6, leather, climate control, other niceties) for a drive and was thoroughly unimpressed. My main beef with this car was the short travel length of the suspension - it kept bottoming out on me. So much so in fact, that I thought there must have been something wrong with the car. But no, this is apparently how it rides. I understand that the 2009 model of this car is a complete redesign so I may have to revisit it in the future and see if it has improved. Unfortunately, my disappointment with this car was to be the first in a long line of disappointments.&lt;/p&gt; &lt;p&gt;My next test drive was with a top trim level Nissan Rogue. Though smaller than the big Murano, the Rogue is still SUVish in size and style. So SUVish in style, in fact, that my wife was sure it was going to roll over while we were driving it. And while the Rogue is wonderfully fuel-efficient, its 4 cylinder engine coupled with a CVT transmission means that it goes nowhere fast. My next test drive was going to be a Subaru Outback, but due to some crazy cash incentives from Subaru the dealer had none left in stock! I may still investigate this alternative, though reviewers claim the economically priced V4 is quite sluggish, and the more suitable V6 is almost as expensive as the XC70 so I&amp;#39;m not holding out much hope.&lt;/p&gt; &lt;p&gt;Other cars I have tested included the Volkswagen Passat which actually wasn&amp;#39;t too bad. It handled well, had very nice acceleration, and was more or less comfortable. The same could be said of the Honda CR-V I drove, too (except for the acceleration part). However, as was starting to become painfully clear to me, my expectations were way too high for any car to meet. Naturally, none of the cars I was driving were even in the same class as the XC70 and while I knew this intellectually, I couldn&amp;#39;t help but compare every car I drove to the Volvo. The result was that every test drive left me feeling empty inside (pathetic, I know).&lt;/p&gt; &lt;p&gt;On a whim, I even took a Mercedes C230 (they had no C300s in stock) out for a drive. It was the sport trim model, and I&amp;#39;m not a sporty car guy (bet you figured that out already, didn&amp;#39;t you) so you can see where this is headed. The Mercedes is a fantastic feat of engineering genius and high-quality manufacturing that more or less exactly failed to impress me. I would have taken the more luxurious &amp;quot;Elegance&amp;quot; trim level for a drive, but as you can probably guess they didn&amp;#39;t have one in stock.&lt;/p&gt; &lt;p&gt;So, I now have roughly 55 days until my Volvo lease expires and I have no idea what I&amp;#39;m going to do. Paying the buyout for my car isn&amp;#39;t an option since it&amp;#39;s much more than what the car is worth on the market today. Leasing a new 2008 XC70 leaves me in the poor house for another 4 years, though it is obvious I will not be satisfied with anything else. Actually, I have my eye on a 2009 instead of a 2008 since the 09 has a much better engine option and has integrated Bluetooth (for the two phone calls a year I make from my car - yes, Bluetooth is VERRRRY important to me). And that much better engine is going to cost even MORE money. I am totally, 100%, unequivocally screwed.&lt;/p&gt; &lt;p&gt;So what is it that I like so much about the Volvo? Two words: creature comfort. You&amp;#39;d be hard-pressed to find anyone who would disagree with the statement that Volvo has the absolute best seats in the automotive industry. I could ride all the way from Halifax to Vancouver and not feel the least bit fatigued, they are that good. And on this car the seats are at the perfect height to make getting into and out of the car totally effortless. So, the moment I get into the driver&amp;#39;s seat of any other car I am immediately unhappy. And, while many driving enthusiasts would likely find the wagon&amp;#39;s handling less than ideal, it is just about perfect for me. The steering has just the perfect amount of resistance, the suspension has the perfect blend of comfort and firmness, and the turbocharged engine with the all-wheel drive transmission has plenty of power. What more could I ask for (except for a lower price)?&lt;/p&gt; &lt;p&gt;So, seeing as how any car other than the Volvo is going to leave me terribly unsatisfied, I believe I have two real choices: suck it up and get the new Volvo, or simply buy some used late-model version of pretty much anything bigger than a Hyundai Accent. In the latter case, I may not be happy, but at least I won&amp;#39;t be paying much for my unhappiness (as opposed to say, a new VW Passat). Stay tuned as my pathetic melodrama continues to unfold over the next several weeks.&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=335" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Toys/default.aspx">Toys</category></item><item><title>On The Edge (and falling off a cliff)</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2008/01/06/on-the-edge-and-falling-off-a-cliff.aspx</link><pubDate>Sun, 06 Jan 2008 17:38:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:330</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>1</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=330</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2008/01/06/on-the-edge-and-falling-off-a-cliff.aspx#comments</comments><description>&lt;p&gt;&lt;span style="background-color:lightyellow;font-weight:bold;"&gt;UPDATE (Feb. 19, 2008):&lt;/span&gt; If you&amp;#39;re too busy to read the book, take a look at this &lt;a href="http://www.onnetworks.com/videos/play-value/budokon---part-2"&gt;8 minute video&lt;/a&gt; - it gives a pretty decent summary!&amp;nbsp;&lt;/p&gt;&lt;p&gt;Ars Technica recently began &lt;a href="http://arstechnica.com/articles/culture/a-history-of-the-amiga-part-1.ars"&gt;running a series&lt;/a&gt; on the history of the Amiga, my favourite computer of all time. From the comments posted to this series I discovered that in 2005 a book was published on the entire history of Commodore. Well, the entire history starting from 1974, anyway. Through hours of interviews with various engineers and executives of Commodore, the book titled &lt;a href="http://www.amazon.ca/Story-Commodore-Company-Edge/dp/0973864907/ref=sr_1_1?ie=UTF8&amp;amp;s=books&amp;amp;qid=1199632690&amp;amp;sr=8-1"&gt;On the Edge: The Spectacular Rise and Fall of Commodore&lt;/a&gt; by Brian Bagnall tells the story of Commodore&amp;#39;s pioneering role in the microcomputer industry, its rise to glory in the early to mid 1980&amp;#39;s, and ending with its bankruptcy on April 29, 1994.&lt;/p&gt; &lt;p&gt;Commodore was actually founded in Toronto in 1958 by &lt;a href="http://en.wikipedia.org/wiki/Jack_Tramiel"&gt;Jack Tramiel&lt;/a&gt; and Manfred Kapp as a typewriter manufacturer. After a stock scandal in the &amp;#39;60s, Commodore was bought by Canadian financier Irving Gould in 1966 who kept Jack Tramiel on as CEO to move Commodore into the then lucrative calculator sector. In the mid 70s, the calculator market was getting overcrowded, so Jack started looking for cheaper calculator parts. This lead to Commodore&amp;#39;s purchase of MOS Technology, a semiconductor manufacturer. At the time, MOS had recently hired Chuck Peddle, who soon developed the legendary &lt;a href="http://en.wikipedia.org/wiki/6502"&gt;6502 microprocessor&lt;/a&gt;. (Interesting side node: Chuck Peddle&amp;#39;s parents hailed from the Canadian Maritime provinces, though the book does not detail from where specifically. A quick look at Canada411 shows a high concentration of Peddle&amp;#39;s in Cape Breton, however.) The 6502 was extremely important to the nascent microcomputer industry because while the comparable 6800 from Motorola cost $300 (which Chuck Peddle was also involved with), the 6502 cost only $25. The 6502 became the processor in Commodore&amp;#39;s first microcomputer, the PET 2001. It was also used in the Apple I and Apple II computers, and Atari&amp;#39;s home computer models (the famous Atari 2600 game console used a variant of the 6502). The 6510 used in the world&amp;#39;s top-selling computer model of all time, the Commodore 64, was a direct descendant of the 6502.&lt;/p&gt; &lt;p&gt;While I found this book to be a long read (it is 557 pages), I was thoroughly enthralled with it. While it did not focus too much on the personal lives of those involved (an aspect I enjoyed in another computer history book I recently read, &lt;a href="http://thewebjedi.com/cs/blogs/meditations/archive/2006/12/26/54.aspx"&gt;Showstopper&lt;/a&gt; by G. Pascal Zachary), it did cover a lot of detail, including technical detail, which naturally I loved. It also detailed a lot of business transactions and, for me, illuminated much of how the business world works, or at least the dysfunctional business world of Commodore. Did you know that Steve Jobs offered to sell Apple to Commodore in the late 1970s? Jack turned them down because he thought $200,000 was an outlandish price. Oops. Of course, if Commodore had bought Apple, they&amp;#39;d be dead now, too. And did you know that the most successful microcomputer in 1977 was not from either Apple nor Commodore, but was in fact Tandy&amp;#39;s &lt;a href="http://en.wikipedia.org/wiki/TRS-80"&gt;TRS-80&lt;/a&gt;? Perhaps the most satisfying fact in the book is that Bill Gates learned his lesson on software licensing when Jack Tramiel negotiated a deal to use Microsoft&amp;#39;s BASIC in Commodore computers. Jack sold tens of MILLIONS of computers with the same Microsoft BASIC in them and he only paid Microsoft a one-time fee of $10,000. Microsoft received absolutely no royalties on any Commodore computer sold in the late 70s to mid 80s. Ha!&lt;/p&gt; &lt;p&gt;Much of the book pays special attention to Commodore&amp;#39;s founder and CEO until 1984, Jack Tramiel. Jack had a couple of battle cries that were interesting: &amp;quot;Business is War&amp;quot;, and &amp;quot;Computers for the masses, not the classes.&amp;quot; The first quote refers to Jack&amp;#39;s belief that you didn&amp;#39;t succeed by competing with competitors, you succeeded by destroying them completely. The second was Jack&amp;#39;s continual insistence on driving down the cost of computers. There are many stories in the book that illustrate this. For instance, the original case design for the PET was to be made as a futuristic-looking molded plastic design. However, Commodore at the time owned an office supply company in Toronto, so they instead used an angular sheet-metal case because it cost less. The case for the C-64 is the exact same one as the VIC-20, because Jack didn&amp;#39;t want to spend money designing a new case, which actually ended up causing the engineers to lose weeks worth of time trying to cram the C-64 guts into the VIC-20 case. Jack had some interesting characteristics, many of which I&amp;#39;ve noticed in other &amp;quot;successful&amp;quot; businessmen. However, what makes a successful businessman doesn&amp;#39;t appear to be totally compatible with what makes a successful human being, in my humble opinion. One case in point is the fact that when Chuck Peddle left Commodore in the 1980s to begin his own start-up, out of spite Jack filed a lawsuit that completely destroyed Chuck needlessly (Jack and Chuck had once been very good friends). A hero of the microcomputer era struck down by a mean-spirited, greedy CEO.&lt;/p&gt; &lt;p&gt;Still, I have to wonder if Commodore would ever have succeeded as much without a guy like Jack at the helm. Another very interesting, but oddly secretive character in the Commodore saga was its owner, Irving Gould. The book paints this man as a mostly absent father-figure, who, when his CEOs would become successful with his company, he would fire them out of fear they were gaining too much power. After Jack took Commodore to a billion-dollar company with the C-64, Irving fired him in 1984. After Commodore lost hundreds of millions over the next several quarters, ex-Pepsi executive Tom Rattigan was put in place as the company&amp;#39;s CEO and he turned it around in a matter of months! Once Commodore was successful again, Rattigan was let go by Gould, too. Commodore never recovered after this, and eventually failed at the inept hands of CEO Mehdi Ali (nicknamed the &amp;quot;speed bump&amp;quot; by Commodore engineers, who burned an effigy of him in Dave Haynie&amp;#39;s &lt;a href="http://www.frogpondmedia.com/dbv/"&gt;Deathbed Vigil video&lt;/a&gt;) in 1994.&lt;/p&gt; &lt;p&gt;Commodore was the first company to put a microcomputer on the market, they were the first to sell over one millions units, and they were the first with a multimedia computer (the Amiga, R.I.P.) before the word &amp;quot;multimedia&amp;quot; existed. Despite all this, they self-destructed and have become pretty much just a footnote in the annals of the birth of the microcomputer industry. If you love computers as much as I do, and want to learn what it was like to be a computer engineer back in the heyday, you HAVE to read this book. If you&amp;#39;re tired of the &amp;quot;revisionist history&amp;quot; that paints Apple as the founder of the microcomputer, you HAVE to read this book. If you ever look back nostalgically on that old Commodore computer you owned in the 1980s (and wonder why the 1541 disk drive was so slow), you HAVE to read this book. It will make you laugh, it will make you cry, and it will make you pound your fists in anger. What more can you ask from a book, especially a non-fiction one such as this?&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=330" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category></item><item><title>Rules for Checking In Code to Source Control</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/11/14/rules-for-checking-in-code-to-source-control.aspx</link><pubDate>Wed, 14 Nov 2007 18:50:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:329</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=329</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/11/14/rules-for-checking-in-code-to-source-control.aspx#comments</comments><description>&lt;p&gt;The golden rule of checking in code is: 
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;&lt;em&gt;Don&amp;#39;t check in code that will break the build.&lt;/em&gt;&lt;/strong&gt; &lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;Nobody likes code that won&amp;#39;t compile. Also see Scott Hanselman&amp;#39;s &lt;a href="http://www.hanselman.com/blog/FirstRuleOfSoftwareDevelopment.aspx"&gt;First Rule of Software Development&lt;/a&gt;. 
&lt;p&gt;In order to help verify that your pending check-in will continue to result in a healthy build, you may wish to view the following rules and procedures that I find helpful. 
&lt;ol&gt;
&lt;li&gt;Try to work on small chunks of code and features at any given time. As &lt;a href="http://timstall.dotnetdevelopersjournal.com/tips_to_avoid_breaking_the_build.htm"&gt;Tim Stall points out&lt;/a&gt;, &amp;quot;It&amp;#39;s easier to integrate 5 small things than 1 big thing.&amp;quot;&lt;br /&gt;&lt;br /&gt;&lt;/li&gt;
&lt;li&gt;Before checking in anything, perform a &amp;quot;get latest&amp;quot; on your entire solution&amp;#39;s code-base. Resolve any version conflicts before proceeding. &lt;br /&gt;&lt;br /&gt;&lt;/li&gt;
&lt;li&gt;If you have any web sites in your solution that have references to&amp;nbsp;web services, make sure you update all web references. &lt;br /&gt;&lt;br /&gt;&lt;/li&gt;
&lt;li&gt;Perform a build on your entire solution. Obviously, fix any compilation errors. &lt;br /&gt;&lt;br /&gt;&lt;/li&gt;
&lt;li&gt;Database scripts. Ahhh, these are lovely, aren&amp;#39;t they? Unless you&amp;#39;re fortunate enough to be using some cool database tools (like Visual Studio for Database Professionals), you don&amp;#39;t likely have any compile-time error checking for your database scripts. It is essential that you ensure all your database scripts for changing the schema, updating the programming (e.g., stored procs), and inserting default foundation data work properly. If they don&amp;#39;t, you&amp;#39;ll soon have a swarm of angry developers beating down your door. The best way to do this is to run the update scripts on your machine and test the software. Update scripts should be written in such a way that they first check to see if a particular update has been applied first before trying to apply it again. This makes it much easier to test, and for other developers to apply to their database copies. &lt;br /&gt;&lt;br /&gt;&lt;/li&gt;
&lt;li&gt;Check in ALL files you have checked out. This is a tricky one, since perhaps you know that a particular file doesn&amp;#39;t work properly, even though it will compile properly. Unfortunately, you may not know what dependencies exist on this file from some of the other files that you&amp;#39;re checking in. So, while you may think you&amp;#39;re doing a favour for the rest of your development team by not checking in a file you know to not work properly, you may actually be more causing grief by checking in code that won&amp;#39;t build! &lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;
&lt;p&gt;Even if you use a fancy-shmancy tool that performs delayed commit or source integration (such as &lt;a href="http://www.jetbrains.com/teamcity/"&gt;TeamCity&lt;/a&gt;), as a professional developer you should really follow these guidelines to save yourself (and your team) pain and suffering.&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=329" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Source+Control/default.aspx">Source Control</category></item><item><title>XBox 360 Fun</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/09/28/xbox-360-fun.aspx</link><pubDate>Fri, 28 Sep 2007 18:52:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:321</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=321</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/09/28/xbox-360-fun.aspx#comments</comments><description>&lt;p&gt;I had been holding off buying an XBox 360 since I&amp;#39;m really not that much of a gamer and when I do play I totally suck anyway. For us non-gamer types, the XBox Live Marketplace sounds interesting&amp;nbsp;since it offers high-definition movies, but alas as a Canadian I am deprived of such a useful&amp;nbsp;feature (though Microsoft has said this will be available in Canada by the end of 2007). However, with last week&amp;#39;s release of Halo 3, I really had no choice but to break down and get myself one. Halo is just about the only video game I&amp;#39;ve played in, oh, ten years so once again I bought an expensive piece of hardware just so I could play this damn intoxicating game.&lt;/p&gt;
&lt;p&gt;I decided to get an XBox Elite primary for the larger hard drive, since outside of Halo I expect my only primary use of the machine will be for buying and watching high-def content. I ordered my machine&amp;nbsp;through Dell Canada and got a deal where Halo 3 was included for free (I also got $30 off an extra controller with the play and charge kit). For a company that almost exclusively sells their stuff through an on-line web site, their on-line order tracking is really poor. I placed my order 2 weeks before Halo 3 was scheduled to ship. I got an email stating an &amp;quot;expected ship date&amp;quot; of September 21st (the Friday before Halo&amp;#39;s release). However, when I clicked on the order number to go directly to Dell&amp;#39;s site for an update, it said the order (or more presicely a single line-item on the order) wouldn&amp;#39;t ship until the 27th. The other line item had no details for the ship date, so was the first line item&amp;#39;s ship date also for the entire order?&lt;/p&gt;
&lt;p&gt;Naturally, being the instant gratification freak that is typical of my generation, I checked the site for updates several times a day. I even called Dell in an attempt to gain clarification. I was told that this deal was extremely popular, but that it probably wouldn&amp;#39;t ship until a day or two AFTER Halo&amp;#39;s release. Grrrr.....&amp;nbsp;&amp;nbsp;But then, on the 21st (this was the original &amp;quot;expected ship date&amp;quot;) something went haywire on Dell&amp;#39;s order tracking site and it now said an &amp;quot;expected DELIVERY date&amp;quot; of the 24th! Woo-hoo! Hours later, however, and it was back to a SHIP date of the 27th. Boo. I checked again on the morning of the 25th to find that it had actually shipped the day before (though no notification email was sent to me). They shipped it by air, and it actually arrived on the 25th! So, good marks for execution but an F for a rather useless order tracking system.&lt;/p&gt;
&lt;p&gt;Anyway, I hooked up my new toy that evening and was relieved to find the cooling fan was much more quiet than my original XBox. I used my original XBox with XBox Media Center to stream video from my PC to my television in the living room and the fan was always distracting. The DVD drive is another story - it is quite noisy when it&amp;#39;s in use&amp;nbsp;even though it&amp;#39;s the vaunted Benq drive which is supposed to be the most quite DVD drive in the 360s. I&amp;#39;d hate to hear what the noisy ones sound like.&lt;/p&gt;
&lt;p&gt;I won&amp;#39;t bore you with a review of Halo 3 since the entire gaming community has already given it plenty of thumbs-up. I haven&amp;#39;t even played it much yet, though it looks like Halo, feels like Halo, and sounds like Halo. That&amp;#39;s a good thing. Since I totally suck, I play on the&amp;nbsp;&amp;quot;easy&amp;quot; setting but in Halo 3 it is way&amp;nbsp;TOO easy - I haven&amp;#39;t died yet! I think I&amp;#39;ll restart on the normal difficulty setting and see how I fare. Oh, and the new hammer weapon totally rocks! &lt;/p&gt;
&lt;p&gt;One thing that I wasn&amp;#39;t looking forward to about the 360 was the fact that while it can play video from a PC, it only supports WMV and MPEG video formats. My original XBox with XBMC plays just about every video format on the planet and I like it that way. Thankfully, some clever programmers developed an ingenious (and free, let&amp;#39;s not forget free) piece of software that allows you to play just about any video format on the 360. It&amp;#39;s called &lt;a class="" href="http://tversity.com/home"&gt;Tversity&lt;/a&gt; and what it basically does is &amp;quot;transcode&amp;quot; a video file on-the-fly to an XBox 360 supported format. Since I just upgraded my rig to a quad-core system, I can easily transcode high-def material without breaking too much of a sweat. This is great stuff.&lt;/p&gt;
&lt;p&gt;So, I&amp;#39;m quite happy with my new Halo 3 Machine (let&amp;#39;s call it what it really is). Hell, I might even try to do the XBox Live multi-player thing too if I can think up a decent gamer tag. My usual nicknames are all taken, so this might take a while. (UPDATE: I am now known as UnhingedBeaker.)&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=321" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Entertainment/default.aspx">Entertainment</category><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Toys/default.aspx">Toys</category></item><item><title>SQL Server 2005 Syntax Incompatible with SQL Server 2000</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/09/26/sql-server-2005-syntax-incompatible-with-sql-server-2000.aspx</link><pubDate>Wed, 26 Sep 2007 19:22:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:317</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>8</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=317</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/09/26/sql-server-2005-syntax-incompatible-with-sql-server-2000.aspx#comments</comments><description>&lt;div&gt;On a recent project we use SQL Server 2005 for development but the product officially supports installation on both SQL Server 2005 and SQL Server 2000. During development we&amp;#39;ll create tables in the database (using SQL 2005) using the GUI tools in either Visual Studio or Management Studio. When it comes time to create the installation scripts, we&amp;#39;ll &amp;quot;Generate CREATE scripts&amp;quot; from these GUI tools. With SQL 2005 (well, at least the version we&amp;#39;re using, which is SP2), the CREATE TABLE script will now use a SQL 2005 specific syntax that will not work on SQL 2000.&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;For example, here is an auto-generated script that runs on SQL 2005, but not on SQL 2000:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font style="BACKGROUND-COLOR:#ffffff;" color="#339966"&gt;CREATE TABLE [dbo].[Order](&lt;br /&gt;&amp;nbsp;[orderID] [int] NOT NULL,&lt;br /&gt;&amp;nbsp;[customerID] [int] NOT NULL,&lt;br /&gt;&amp;nbsp;[orderDate] [datetime] NOT NULL,&lt;br /&gt;&amp;nbsp;[shipDate] [datetime] NOT NULL,&lt;br /&gt;&amp;nbsp;[shipperID] [int] NOT NULL,&lt;br /&gt;&amp;nbsp;[shipperTrackingNumber] [varchar](50) NULL,&lt;br /&gt;&amp;nbsp;CONSTRAINT [PK_Order] PRIMARY KEY CLUSTERED &lt;br /&gt;(&lt;br /&gt;&amp;nbsp;[orderID] ASC&lt;br /&gt;)WITH (PAD_INDEX&amp;nbsp; = OFF, STATISTICS_NORECOMPUTE&amp;nbsp; = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS&amp;nbsp; = ON, ALLOW_PAGE_LOCKS&amp;nbsp; = ON) ON [PRIMARY]&lt;br /&gt;) ON [PRIMARY]&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font style="BACKGROUND-COLOR:#ffffff;" color="#339966"&gt;GO&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;If you try to run this on SQL 2000, you&amp;#39;ll get the following error:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#ff0000"&gt;Server: Msg 170, Level 15, State 1, Line 11&lt;br /&gt;Line 11: Incorrect syntax near &amp;#39;(&amp;#39;.&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;It would appear as though SQL 2000 does not like the syntax of the primary key constraint&amp;nbsp;included in the CREATE TABLE statement. Alternatively, the following script works on both SQL 2000 and SQL 2005:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;CREATE TABLE [dbo].[Order] (&lt;br /&gt;&amp;nbsp;[orderID] [int] NOT NULL ,&lt;br /&gt;&amp;nbsp;[customerID] [int] NOT NULL ,&lt;br /&gt;&amp;nbsp;[orderDate] [datetime] NOT NULL ,&lt;br /&gt;&amp;nbsp;[shipDate] [datetime] NOT NULL ,&lt;br /&gt;&amp;nbsp;[shipperID] [int] NOT NULL ,&lt;br /&gt;&amp;nbsp;[shipperTrackingNumber] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL &lt;br /&gt;) ON [PRIMARY]&lt;br /&gt;GO&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;&lt;/font&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;ALTER TABLE [dbo].[Order] ADD &lt;br /&gt;&amp;nbsp;CONSTRAINT [PK_Order] PRIMARY KEY&amp;nbsp; CLUSTERED &lt;br /&gt;&amp;nbsp;(&lt;br /&gt;&amp;nbsp;&amp;nbsp;[orderID]&lt;br /&gt;&amp;nbsp;)&amp;nbsp; ON [PRIMARY] &lt;br /&gt;GO&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Now, if that was the only problem I could probably live with that. But wait! There&amp;#39;s more! When you create an object in SQL Server, it&amp;#39;s generally good practice to first make sure the object doesn&amp;#39;t already exist. In my day-to-day use, my scripts will often check for general objects, or foreign-key constraints. SQL 2005 uses the following code for these operations:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;IF&amp;nbsp; EXISTS (SELECT * FROM sys.foreign_keys WHERE object_id = OBJECT_ID(N&amp;#39;[dbo].[FK_Order_Customer]&amp;#39;) AND parent_object_id = OBJECT_ID(N&amp;#39;[dbo].[Customer]&amp;#39;))&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Run this on SQL 2000 and you&amp;#39;ll get:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#ff0000"&gt;Server: Msg 208, Level 16, State 1, Line 1&lt;br /&gt;Invalid object name &amp;#39;sys.foreign_keys&amp;#39;.&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Also, the following code is used by SQL 2005:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;IF&amp;nbsp; EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N&amp;#39;[dbo].[Order]&amp;#39;) AND type in (N&amp;#39;U&amp;#39;))&lt;br /&gt;DROP TABLE [dbo].[Order]&lt;br /&gt;GO&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;which will give you the following on SQL 2000:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#ff0000"&gt;Server: Msg 208, Level 16, State 1, Line 1&lt;br /&gt;Invalid object name &amp;#39;sys.objects&amp;#39;.&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Microsoft changed the way that meta-data is stored in SQL 2005 to improve security, amongst other things, but this means that these scripts won&amp;#39;t work on SQL 2000. Thankfully, however, they did provide &amp;quot;views&amp;quot; in SQL Server 2005&amp;nbsp;which mimic the old behavior on SQL 2000. To fix these errors on SQL 2000, you can use the following syntax which will work on both SQL 2005 and SQL 2000:&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;IF&amp;nbsp; EXISTS (SELECT * FROM dbo.sysforeignkeys WHERE fkeyid = OBJECT_ID(N&amp;#39;[dbo].[FK_Order_Customer]&amp;#39;) AND rkeyid = OBJECT_ID(N&amp;#39;[dbo].[Order]&amp;#39;))&lt;br /&gt;ALTER TABLE [dbo].[Order] DROP CONSTRAINT [FK_Order_Customer]&lt;br /&gt;GO&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;&lt;/font&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;font color="#339966"&gt;IF&amp;nbsp; EXISTS (SELECT * FROM dbo.sysobjects WHERE id = OBJECT_ID(N&amp;#39;[dbo].[Order]&amp;#39;) AND type in (N&amp;#39;U&amp;#39;))&lt;br /&gt;DROP TABLE [dbo].[Order]&lt;br /&gt;GO&lt;/font&gt;&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;Thankfully, there is a way around this if you&amp;#39;re using SQL Management Studio. Instead of right-clicking on a table to generate a CREATE script, right-click on the Database and select &lt;strong&gt;Tasks -&amp;gt; Generate Scripts&lt;/strong&gt;. This will open the Script Wizard dialog. On the Choose Script Options page, set the &amp;quot;Script for Server Version&amp;quot; property to &amp;quot;SQL Server 2000&amp;quot; and your CREATE scripts will now be fully compatible. A little more clicking is required, but at least your scripts will work on both server versions.&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;img src="http://thewebjedi.com/cs/photos/misc/images/318/original.aspx" border="0" alt="" /&gt;&lt;/div&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=317" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/SQL+Server/default.aspx">SQL Server</category></item><item><title>The Easy Way To Alternate Background Colours on a Repeater</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/06/18/291.aspx</link><pubDate>Mon, 18 Jun 2007 22:21:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:291</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>5</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=291</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/06/18/291.aspx#comments</comments><description>&lt;P&gt;The ASP.NET Repeater is one of my favourite controls because it provides total flexibility in the layout of your data. I'll often use it to generate a list of data similar to a DataGrid or DataList. However, if I want to alternate the background colour of each row of data, the usual prescribed method is to use the AlternatingItemTemplate. But this is a such a waste of code and can be a pain to maintain if your ItemTemplate has any kind of complexity.&lt;BR&gt;&lt;BR&gt;There is a much easier method, though. A shortcut if you will. If you're using your Repeater to generate table rows, you can use the following code in your &amp;lt;tr&amp;gt; tag to change the CSS class for each alternating row:&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;tr&lt;/SPAN&gt;&lt;SPAN&gt; &lt;SPAN&gt;class&lt;/SPAN&gt;&lt;SPAN&gt;="&lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;%&lt;/SPAN&gt;# IIf(Container.ItemIndex Mod 2 = 0, "rowOdd", "rowEven") &lt;SPAN&gt;%&amp;gt;&lt;/SPAN&gt;&lt;SPAN&gt;"&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;Or, in C#:&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;SPAN&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN&gt;tr&lt;/SPAN&gt;&lt;SPAN&gt; &lt;SPAN&gt;class&lt;/SPAN&gt;&lt;SPAN&gt;="&lt;/SPAN&gt;&lt;SPAN&gt;&amp;lt;%&lt;/SPAN&gt;# Container.ItemIndex % 2 == 0 ? "rowOdd" : "rowEven" &lt;SPAN&gt;%&amp;gt;&lt;/SPAN&gt;&lt;SPAN&gt;"&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;Easy peasy. This isn't really all that ingenious but every time I want to use this technique I forget the syntax (it's the "Container.ItemIndex" I can never remember) so I decided to write a blog entry so I'll have it for reference.&amp;nbsp; :-)&lt;BR&gt;&lt;BR&gt;&lt;/P&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=291" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Entertainment/default.aspx">Entertainment</category></item><item><title>A Cool ASP.NET 2.0 Feature (Well, Almost)</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/06/17/290.aspx</link><pubDate>Sun, 17 Jun 2007 10:26:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:290</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>0</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=290</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/06/17/290.aspx#comments</comments><description>Whenever I start a new web project, one of the first things I do is create a "Base" class for all my ASPX code-beside (&lt;a href="http://aspalliance.com/244"&gt;"code-behind" is so .NET 1.1&lt;/a&gt;) class declarations to inherit from. This makes it easy to have useful properties such as CurrentUser available in all pages automatically. Such a practice is quite common these days, and has been covered in several articles including &lt;a href="http://aspnet.4guysfromrolla.com/articles/041305-1.aspx"&gt;this one&lt;/a&gt;.&lt;br&gt;&lt;br&gt;Recently, I have found it useful to have some boolean properties on the base class which control the rendering of certain elements. For example, a current project I'm working on has the requirement to restrict the user's ability to navigate backwards by using the browser's "Back" button. This is accomplished via the use of the &lt;a href="http://uchiblogsat.blogspot.com/2007/01/no-more-back-button.html"&gt;JavaScript "history.forward()" hack&lt;/a&gt;. Now, some pages in the application require this while others do not. So the best way to handle this is to have a base-class property called DisableBackButton and set it to "true" when I want to prevent the user from going back to the previous page. And, in fact, this is what I did and it works well.&lt;br&gt;&lt;br&gt;However, setting such properties can only be achieved with programmatic code. For example, to turn this property "on" for a certain page, I would have to write "DisableBackButton = true;" in the Page_Load event handler. This is fine, but it feels "dirty" and unsophisticated to me. I would much prefer to set this property in a "declarative" fashion on the actual ASPX file rather than writing code to set it. Say, wouldn't it be cool if I could just add an attribute to the @Page directive that said DisableBackButton="True"? Well, it turns out that in ASP.NET 2.0,&lt;a href="http://weblogs.asp.net/scottgu/archive/2005/08/02/421405.aspx"&gt; you can do exactly this&lt;/a&gt;!&lt;br&gt;&lt;br&gt;Well, almost. If you read all the comments in that link you'll see that it isn't all that simple, unfortunately. First, if you're using a base class like I am, you also have to set the "CodeFileBaseClass" attribute in the @Page directive. Ick. I think this is something that the compiler can determine for itself without me having to tell it explicitly. Requiring me to add it manually just means there's another possible point-of-failure and yet something else that has to be maintained. Still, it's not a too terrible price to pay for the cool declarative property setting feature I'm trying to achieve. But, that isn't the only problem. While the project will now compile, you'll still get ASP.NET validation errors in all your pages saying that "DisableBackButton" is a not a valid attribute for the @Page directive. Grrrr. To stop this message from clogging your Visual Studio errors window, you have to open up Visual Studio's XML-based schema file and &lt;a href="http://blogs.msdn.com/mikhailarkhipov/archive/2006/02/01/522614.aspx"&gt;add the attribute&lt;/a&gt;. Now this is really a problem since this schema file is used for ALL Visual Studio web projects, not just the one you're working on right now. And it also means that if you share the code with someone else, you have to tell them to go modify their schema file, too. This is completely unacceptable.&lt;br&gt;&lt;br&gt;In the end I decided to go the old-fashioned route and set this property programmatically in each page that needed it. While the declarative route would have been uber-cool, there are just too many road-bumps down that path. Here's hoping Orcas (or Shamu as my wife calls it) does something to address this problem.&lt;br&gt;&lt;br&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=290" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category></item><item><title>Making Reporting Services Work On Vista (64-bit)</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/06/14/288.aspx</link><pubDate>Thu, 14 Jun 2007 09:18:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:288</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=288</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/06/14/288.aspx#comments</comments><description>A couple of weeks ago I got a new laptop (that went along with my new job) and at the urging of some on my co-workers (and against my better judgement) I installed Vista Enterprise 64-bit on it. And that's another story all together. I also installed SQL Server 2005 (64-bit, naturally) and after fighting with the new IIS 7 on Vista (see this &lt;a href="http://support.microsoft.com/kb/934164"&gt;Microsoft Support Article&lt;/a&gt; for more info), I managed to get Reporting Services installed too.&lt;br&gt;&lt;br&gt;However, I had never configured it until today. I brought up the Reporting Services Configuration Manager and focused my attention on the first "red X" in the list, which was the "Report Manager Virtual Directory." I was able to set up the virtual directory, but the damn red X wouldn't turn into a green checkmark no matter what I did. I searched the Internet and found all kind of Reporting Services on Vista horror stories, but no story that fit my exact problem. After looking at the various Reporting Services .config files for clues, I went back to the Configuration Manager window and clicked on the "Report Server Virtual Directory" item, which had a green checkmark. Aha! The damn thing WASN'T set up, even though it had a happy green checkmark. Once I set up both the Report Server and Report Manager virtual directories with the proper application pool settings outlined in the above referenced Microsoft Support article, I was able to complete the Reporting Services configuration and now it works great!&lt;br&gt;&lt;br&gt;Moral of the story: don't trust green checkmarks - they're not always correct.&lt;br&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=288" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category></item><item><title>Amiga Rumour Mill In Full Swing</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/05/01/247.aspx</link><pubDate>Tue, 01 May 2007 19:04:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:247</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=247</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/05/01/247.aspx#comments</comments><description>Well, following up on my &lt;a HREF="/cs/blogs/meditations/archive/2007/01/22/77.aspx"&gt;complete surprise&lt;/a&gt; to learn that AmigaOS was still being developed, it now seems as though the arrival of new Amiga hardware is imminent! Though I'll believe it when I see it, it's nice to see that there are still some die-hard Amiga addicts out there.&lt;br&gt;&lt;br&gt;To see the details of the new hardware announcement, check out these press releases from amiga.com:&lt;br&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.amiga.com/news/?art=26&amp;amp;PHPSESSID=8b79f778226861f4ab0573d002e08330"&gt;New Hardware Designs from ACK Software Controls, Inc. and Amiga, Inc.&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.amiga.com/news/?art=27&amp;amp;PHPSESSID=8b79f778226861f4ab0573d002e08330"&gt;Entry Level Design Details from ACK Controls and Amiga&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;And while Amiga is no longer owned by the management-challenged Commodore of the early '90s, it's seems they're still up to their old tricks of questionable tactics. The mainstream personal computer industry has pretty much given up on PowerPC, but Amiga has chosen it as their CPU. Curious. Add to that the decision to use a 66MHZ PCI slot for the graphics card? Holy crap - that predates AGP which is now obsolete! I'm not sure what their business plan is, but I really can't see too many people buying these things. Still, it will be interesting to see what develops.&lt;br&gt;&lt;br&gt;I wonder if it will still run Speedball?&amp;nbsp; :-)&lt;br&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=247" width="1" height="1"&gt;</description></item><item><title>Microsoft Adds Powerful Tool For Database Developers</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/04/08/220.aspx</link><pubDate>Sun, 08 Apr 2007 16:44:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:220</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=220</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/04/08/220.aspx#comments</comments><description>I've been dying to try out Microsoft's latest addition to the Visual Studio Team Suite set of products - Data Dude, or more properly know as &lt;a href="http://msdn2.microsoft.com/en-us/teamsystem/aa718807.aspx"&gt;Visual Studio 2005 Team Edition for Database Professionals&lt;/a&gt;. Recently I finally took some time to watch a series of webcasts (at 1.5x speed - the only way to learn!) on MSDN and figure out how this thing works. After spending a couple of hours watching these webcasts, I am able to present you with the Coles Notes version of what Data Dude does and how it works.&lt;br&gt;&lt;br&gt;Data Dude essentially represents your entire database as a series of text files. You can think of this as the "source code" for your database. Individual .sql files (which are just text files) containing DDL (data description language - SQL commands that create database objects) are stored within the new "Database" project type in Visual Studio. So, if you want to create a new table called "Customer" for example, Data Dude creates a new .sql file called "Customer.sql" which contains the DDL commands to create that table. In this respect, it's not a whole lot different than the old Visual Studio "Database" projects where you might have manually stored .sql scripts to keep them under version control.&lt;br&gt;&lt;br&gt;What Data Dude brings to the table, however, is a lot more automation and validation to this entire process as well as the ability to "build and deploy" your database to any SQL Server instance. So, you have this big collection of .sql scripts to create tables, views, indexes, procedures, and functions and Data Dude does this wicked cool thing where it "parses" all the SQL in these files and validates them. So, if you a .sql file for your Customer table and it contains a field called "customerID" and in the .sql file for a stored procedure that SELECTs from that table you have written the field as "custID", you'll get a build error! Nice stuff.&lt;br&gt;&lt;br&gt;You can either start your database project from scratch, or you can reverse engineer from an existing database. Once you have a your database project in a state where you're ready to deploy it, you can perform a deployment operation against any SQL Server instance that you can connect to. Data Dude will examine the differences between the source files it has and the existing database on the target and only deploy those updates that are required. For a new database this would obviously be everything, but for a database that your reverse engineered and only changed one stored procedure for example, only that stored procedure is changed on the target. Sweet!&lt;br&gt;&lt;br&gt;Now that your database is represented as simple text files, you can easily place your database definition under source control. One of the problems that I've experienced working with a team of developers is that while the procs and functions might be under source control, the schema (tables, views, etc.) generally isn't. So, one developer might make a schema change on their local SQl Server instance, update a proc too, check-in the proc, but forget to tell other developers about the schema change. Naturally, when another developer tries to apply the latest version of that proc against their development database, it blows up. Data Dude does away with that by making it oh-so-easy to put your entire schema under source control. So now, another developer can get the latest version of the database project from source control, do a deploy against their local development SQL server, and the schema change AND the proc will get updated.&lt;br&gt;&lt;br&gt;In addition to providing features for comparing schemas, it also allows to perform data comparisons between tables in different databases. So during development when you're adding new rows to lookup tables, for example, you can now easily deploy those updates to another database (such as a testing or production system) by performing a data compare.&lt;br&gt;&lt;br&gt;But wait! There's more!&lt;br&gt;&lt;br&gt;Data Dude also adds the ability to run unit tests against your database. Using Visual Studio 2005's existing unit testing framework, you can create tests that run against your tables, procs, or just about anything. To help you with this, you can create Data Generation Plans that automatically fill your tables with random data. You have a lot of control over how the data is generated, including number of rows and minimum and maximum values. So, the ability to run unit tests combined with the automatic population data makes for a very powerful combination to help you write quality database code.&lt;br&gt;&lt;br&gt;If you can, I'd recommend that you spend a few hours with Data Dude learning how to take advantage of its capabilities. It may be a "release 1" product and while it's not perfect, it's still a great tool for database development in a team environment. And when they add ERD diagramming features in the next release or two, it will be the only way to develop databases.&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=220" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category></item><item><title>Bitten By Windows Genuine Advantage</title><link>http://thewebjedi.com/cs/blogs/meditations/archive/2007/03/01/161.aspx</link><pubDate>Fri, 02 Mar 2007 00:18:00 GMT</pubDate><guid isPermaLink="false">84eedfc3-6cff-4193-9dbb-31c18f89aa36:161</guid><dc:creator>Andre Perusse</dc:creator><slash:comments>2</slash:comments><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://thewebjedi.com/cs/blogs/meditations/rsscomments.aspx?PostID=161</wfw:commentRss><comments>http://thewebjedi.com/cs/blogs/meditations/archive/2007/03/01/161.aspx#comments</comments><description>



&lt;p class="MsoNormal"&gt;Last weekend I was home doing some paperwork and I had to
send a fax to my insurance agent. I hadn't sent a fax in several months and not
since I had reimaged my computer with Vista and Office 2007. So I opened Word
and looked in the templates for a fax cover page. Word ships with several
templates as standard, but it also includes a link to an Internet-based gallery
of templates. I selected one of the Internet-based templates and was informed
that this feature required that Microsoft verify that my Office installation
was "genuine." Sure, whatever, I thought to myself and I hit the
"Continue" button. To my shock, Office reported that the validation
had failed! My Office installation wasn't genuine!&lt;/p&gt;&lt;p class="MsoNormal"&gt;&lt;br&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;



&lt;p class="MsoNormal"&gt;&lt;o:p&gt;&lt;/o:p&gt;That's odd, I mumbled. There's a link that takes you to a more
detailed explanation of what is wrong with the validation. I clicked on it and
the resulting web page told me my Office installation hadn't been activated
yet. It said all I had to do to fix it was run any Office app and it would
automatically start the activation process. I shook my head and cursed at
Microsoft for inflicting this garbage on me. I double-checked Word and sure
enough, it claimed that it was already activated. So I concluded that Microsoft's
"genuine" validation routine was on crack. I get all
my Microsoft software directly from MSDN, so there's no way my Office
installation was phony.&lt;/p&gt;&lt;p class="MsoNormal"&gt;&lt;br&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;



&lt;p class="MsoNormal"&gt;&lt;o:p&gt;&lt;/o:p&gt;I futzed around with the web site a bit more trying to
figure out how I could convince the Great Genuine Validation Gods that I didn't
steal this copy of Office. No go. I called the tech support number and was
quickly transferred to another call center because I got my copy from MSDN.
This new call center told me they couldn't help me on the weekend unless my
"business" was experiencing a Severity One emergency. Call back
Monday, he said. I was irked as hell about this but there was little I could
do. So I hauled out my laptop which had Office installed from the exact same
CD. It worked fine, I got my stupid template, and I sent my fax.&lt;/p&gt;&lt;p class="MsoNormal"&gt;&lt;br&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;



&lt;p class="MsoNormal"&gt;&lt;o:p&gt;&lt;/o:p&gt;Due to my employer's current MSDN configuration, it was
difficult for me to log a support incident with Microsoft about this so I
didn't bother looking at it again until this evening. I suspected that
something went awry with my Office install on Vista so I set about trying to
"repair" it from the CD. Nope, no good. I was getting ready to uninstall
and reinstall as a last resort when I remembered that I had installed Microsoft
Project 2007 at the same time I had installed Office Professional, but I had
never run Project at all. Hmmm, I thought to myself, I'll bet the Genuine Gods
are pissed off because I've never run Project, so they're not going to let me
into their special Internet club! So I ran Project (which installed using a
different product key than Office and thus needs its own activation), it
immediately wanted to be activated, I activated it and promptly closed it. I
went back into Word, tried to open an Internet-based template, went through the
"Genuine" validation voodoo, and it worked!&lt;/p&gt;&lt;p class="MsoNormal"&gt;&lt;br&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;&lt;p class="MsoNormal"&gt;&lt;o:p&gt;&lt;/o:p&gt;So, my question to Microsoft is: Why the hell did I have to
active Microsoft Project so that I could download a Word template? In what
twisted demon dimension does this bent logic make any sense? Good grief. (But I still think the Ribbon interface is way cool.)&lt;br&gt;&lt;/p&gt;&lt;img src="http://thewebjedi.com/cs/aggbug.aspx?PostID=161" width="1" height="1"&gt;</description><category domain="http://thewebjedi.com/cs/blogs/meditations/archive/tags/Tech/default.aspx">Tech</category></item></channel></rss>