Categories
Babbling Tips

How to ruin a very good site reputation !

I know that in recent times, I am kind of feeling more sensitive towards users experience in general, weather it is @ customer support for any item or @ email system … or this time @ one of my favorite download site (at least it used to be but not anymore).

For years I have used Download.com as my download site for windows application. Time to time I have used even reviews from CNET to lean about new/existing software .. but my recent experience has left a bad test in mouth to say, and I think I will not download from them ever Broken heart. Till now, when ever you want to download from this site all you had to do was to just search for that software, download it using link provided by the site and install the software.

But today when I tried this site to download “Revo Uninstaller” (an uninstaller application) instead of getting simple EXE, I got a custom installer designed by CBS Interactive (owner of CNET), it even has digital certificate from MSFT too so it “feels” more genuine. But I think it is wolf in disguise of sheep Annoyed (I am not sure about analogy but I guess you got the point).

So, this is how it begun … I downloaded an installer for “Revo Uninstaller” from www.Download.com and it gave me some 620Kb installer. As I begun installation using this installer, I have following screens …

CNET_1

First step is to indicate that I will be downloading and installing Revo Uninstaller.

Categories
SQL Server Tips

Policy Based Management in SQL Server

This great feature was introduced in SQL Server 2008 and since then it has been considered as one of “standard” method to administer database proactively. As the name suggests, it allows DBAs to create various policies to enforce certain rules to single database, to group of databases or to whole server… for example default database backup location has to be some particular drive or every new database has to be in full recovery mode or each SP that are created and that will be created has to have prefix “USP_” etc.

It is very common issue of collaborative database development that developers like to keep follow their own naming convention then industry standards or MSFT recommendations for database objects. And they usually choose proper names for any objects they create, based on function / purpose of that object. But sometimes they like to choose name which could effect how SQL Server Query Execution planner behaves and you might see performance impact. For example in case of Stored Procedures, use of prefix SP in front of the stored procedure name. Now, I am not an expert in performance tuning but I know basic thing that it causes Query Execution planner to look into system stored procedure list at first because SP keyword is reserved for system stored procedures.

So instead of routinely monitoring any change made by devs and modifying / rolling back their change for such a silly name, it is far more convenient to have SQL Server watch for any thing like that and if such event occurs simply fail the execution and let developer know about this mistake. And this is exactly what I am going to demo here Smile

Policy Based Management (aka PBM) is made of 3 components. Facets, Conditions and Policies. And the order it works is, you use existing facet in condition and based on that condition you create a policy to be implemented on either single database or whole server.

1) Facets : They are kind of hard to explain by simple definition. Think of it as a class of .NET which exposes various properties. For example, database has different properties like Size, Name, Status, Owner, etc.… And you can use any of these properties to define condition. See this post for more detailed definition of Facets. By default there are number of pre-defined facets exist in SQL Server and there is no option to create user defined facet. A typical facet for Store Proc looks something like below,

Categories
News

SQL Saturday # 184

One of my favorite event for which I always had to travel just too far .. either at NY or at MA for past few years … but this year CT is going to have it’s very own SQL Saturday. For anyone who have not heard about this great event then think of it as a code camp exclusively concentrated on SQL Server and it’s components like SSRS, SSIS and SSAS. In past two years I have been to SQL Saturdays of Boston twice and both of them were just great. Only thing that I really hated was drive of about 4 hours all the way to Waltham but once you are there you will realize that it is well worth of it 😀 …

But this year, SQL Saturday team has finally decided to have SQL Saturday event in CT at Quinnipiac University on March 2nd… which happen to be very close to my home. As always they have 5 tracks … DBA, Dev, BI, New Version of SQL Server (this time it is 2012) and Personal dev. No doubt all three … DBA, Dev and BI has really great session and speakers … and I am really not sure where I will go .. because all sessions seems great to me 🙁

Just as a side note they have $10 fee for lunch … or think it as an entry fee … but if you have been to any similar event then you know that it is worth more then that 😀 …

All details about time and session and registration can be found on SQL Saturday website.

That’s it for now … See you at the event …

Gaurang Sign

Categories
Bugs Tips

Error Deploy01234: The target database schema provider could not be determined. Deployment cannot continue.

This was the error that I was getting when i was trying to deploy our database project to one of our test system in a batch script. To me it was a bit surprise because I had done same process many times in past and it has worked just fine. But today I spent hefty amount of time to resolve this issue. Whole error that I was getting was  something like below,

 

—— Deploy started: Project: Database, Configuration: Debug Any CPU ——

C:\Program Files\MSBuild\Microsoft\VisualStudio\v10.0\TeamData\Microsoft.Data.Schema.TSqlTasks.targets(120,5): Error Deploy01234: The target database schema provider could not be determined.  Deployment cannot continue.

   Done executing task “SqlDeployTask” — FAILED.

  Done building target “DspDeploy” in project “TheDatabase.dbproj” — FAILED.

Done executing task “CallTarget” — FAILED.

Done building target “DBDeploy” in project “TheDatabase.dbproj” — FAILED.

Done building project “TheDatabase.dbproj” — FAILED.

Build FAILED.

 

Categories
Babbling

The wiser we get ….. an IT example ?

Few days back I changed password of one of my email accounts in Gmail and I got this notification in email. Now funny thing is this email is in same account of which I had changed password !! I can understand the good intensions (!!) of great G but consider a scenario where this account got hacked by someone and that person has setup new password and G is sending notification of password changed to same account to notify original owner that password has been changed !! And how will this help me ?

Of course, Great G has other means to notify as well. You will get notification at your recovery account (if you have not ignored G’s requests to setup one Open-mouthed smile or that hacker has not changed it before modifying password !!). G even can prevent access to account if connection request originates from totally different location then it’s usual geographical location (which can be easily fooled by proxy or vpn or things like that).

Categories
How To Installer

Creating Application Shortcut in Programs for Windows Installer Project

It has been while since I posted something. Actually I was on very long vacation Open-mouthed smile for almost 2 months and during that time all I did was eating, traveling, sleeping and eating again … and now it is ended and I am back .. I think I have gained few pounds… so (just like every year) this new year I have taken resolution to get back in shape (that’s a different story that right now I am in crisis to stay resolute Confused smile).

Ok, enough babbling … I am sure everyone is familiar with shortcuts created for an application when we install it. Usually these shortcuts are created inside Programs’ menu (aka Start menu) and Desktop … sometimes you even have options to create in quick launch menu too. Actually it is very easy to achieve this in Windows Installation project and in this post I am going to show just that …

First step is to create new Visual Studio Installer project and give it any name. Since I am very bad with names, I simply gave it “TestMSI”. Then I added one text file I had for another post and added it installation. If you don’t know how to create an installation project or add a file into installation project then read this old 101 post. Once that file is added, say I want to create a shortcut of this file on user’s desktop and start menu. To create a shortcut in Start menu, select “File System” in MSI project and select “User’s Program Menu”. When it is selected, right click in work area and select “Create New Shortcut”.

Categories
SQL Server Tips

Database Snapshots … The Good, Bad and Ugly

In SQL Server 2005 MSFT introduced very new feature … Database Snapshots … which is basically a read-only view of database at the time when snapshot was taken. Just as a side note…even at the time this feature was introduced in SQL Server, other age old DBMSes like Oracle and DB2 were already offering similar feature in their systems. Database Snapshots can prove really useful if used wisely or can bite you back if used without any thoughts … hence … The Good, bad and ugly … Open-mouthed smile

Another note before starting … unfortunately Database Snapshots are kind of toys for rich only Broken heart … which means you have to have Enterprise edition to use this feature. But since I have developer edition … I am more like a lottery winner Winking smile … because all Enterprise features are available in Developer edition … with that being said … let’s prepare staging environment.

I have a test database with few sample tables that I have derived from AdventureWorks tables. I created this database into a temp HDD created using one of my favorite RamDisk software. Which gives me ability to blow up that drive without any issue at any time (which exactly what I will do at the end of this demo in the Ugly part Open-mouthed smile). But say if you don’t have enough RAM you can use USB thumb drive as a place to restore database backup. I restore database with following command …