Although , It is out of box but I would like to share here. I am very choosy in food. When my mother/wife cooked food and I didn’t like the taste then I explicitly said I didn’t like but when food taste was awesome then I didn’t say a word.
My mother taught me “You should appreciate every thing which is good.” Your single appreciation word do things
1. You yourself feel better
2. The person who did the good thing will be motivated to do more good things (in my case more tasty food wow )
This lesson of my mother is now one of the rule life.
So here I would like to say one of the best tools I came across is “SQL Sentry plan Explorer”. There are various great features of this tool but I would like to share few things which attract me more
1) It comes in two versions (Basic & professional ) .Basic version is absolutely free free free.
2) It makes SQL developer’s life easy. You can easily cross check query plan easily.
see below snap.
You can also view logical read ,table scan and various other useful data
You can download this from http://www.sqlsentry.com/
Most of the time when you write code for a web application you need to test it again and again. You have to run a whole flow of positive or negative test cases to check whether your application is working or not.
Now suppose your application have 20 pages and you need to traverse each individual page and may be perform some operation and on each change of your development you need to perform same thing.
sometimes, this thing will irritate you and you will skip testing which may be harmful because most of the time it happens when you skipped something you took a deep breath and at that moment your application crashed .
So , as a responsible developer we do not have to skip any test scenario but next question is how to reduce this effort which you feel boring sometime.
I can say we can reduce this effort by a installing a simple Firefox add-in which is absolutely free. The add in “Selenium add in”
you can download it from https://addons.mozilla.org/en-US/firefox/addon/selenium-expert-selenium-ide/
once you have installed this you will find the selenium icon near by search bar as shown below
when you click this icon you will get a selenium interface as shown below
The basic concept of this tool is what ever you will run in browser it has capability of recording those steps so it is just play button and pause button game, no rocket science. You can easily run and use this.
I am sure it will reduce your testing effort and when when selenium ide will play your test cases you can take a deep breath and enjoy your coffee and snacks.
I hope this tip may be helpful to you somewhere.
Sometimes , We need to know what is the structure of stored procedure ? , How many columns will be return ?
So to determine this we have easy stored procedure provided by SQL Server which is sp_describe_First_Result_Set.
Below is the template to run it. You can provide your stored procedure name as variable
Execute sp_Describe_First_Result_set ‘ProcedureName’
In below snap I used Adventureworks database and try to find what will be the output columns of the stored procedure “uspgetBillOfMaterials”
As you see in below image after running above query we got all the result set columns
I hope this tip help you somewhere.
Sometime, due to some security reference your application require to stop right click on web page.
In such case you need to write just simple code as shown below.
So now when you run your web page and right click you will get following message.
So just each code and you are good to go.
Hope you like it.
Thanks & Best Regards,
Happy New Year 2014. It give me immense pleasure to introduce new Windows phone App which is QuickAccess. You can use this utility app i am pretty much sure it will help you in many ways. You can instantly send SMS, E-mail with pre decided template to a group. so download and enjoy.
Thank & Regards,
Some times it may be possible you require to make zip of a file or directory.
so here is simple example.
To start it you have to download “SevenZipSharp.dll”, “7z.dll” you can download sdk from http://www.7-zip.org/sdk.html
Once you download sdk copy above 2 DLL in your project bin folder.
Now write below code which i am writing here
2: public bool CompressFolder(String
11: SevenZipCompressor sz = new SevenZipCompressor();
15: sz.CompressionLevel =
18: sz.CompressionMode =
21: sz.CompressionMethod =
24: sz.FastCompression =
27: sz.CompressDirectory(backupFolder, BackupPath + "\\" +
28: DateTime.Now.Date.ToString("yyyyMMddHHmmss") +
33: return true;
36: catch (Exception
41: throw ex;
Now let me describe the code to you.
This is function which compress the folder to 7zip what ever pass as a paramter
in this function we have created a sevenzip compressor object
in the above line we set the DLLpath which is basically your bin folder path
sz.CompressionLevel = CompressionLevel.Ultra; is compress level which can be different according to your need.
sz.CompressDirectory(backupFolder, BackupPath + "\\" + DateTime.Now.Date.ToString("yyyyMMddHHmmss") + "_7Zip.7z");
above row compress the directory of backupfolder and rename with datetime_7zip.7z
I hope this will help you.
Thanks & Best Regards,
Many times we require XSD from XML which we can utilize in our code. so to achieve this we need to run a simple command which will create your XML in XSD. Now you are thinking what is that command so here we go
you just need to write following command on command prompt
XSD.EXE “YourXML file Name” /outputdir:
XSD.exe “d:\myxml.xml” /outputdir:
When you run it it will generate the XSD file in system32 folder.
I hope you like it.
Thanks & Regards,
As a programmer I would like to share some of the best tips which I found so far and this is one of the tip which I am going to share right away
suppose you have following piece of code
string Names= namecollection.Split(GetDelimeter());
List<string> NameList = new List<string>();
foreach (string name in Names)
if (!string.IsNullOrEmpty(name ))
sb.Append(name .Trim() + ",");
NameList .Add(name .Trim());
Now you can write above for each code & if condition in following way
foreach (string Nam in Names.Where(Nam=> !string.IsNullOrEmpty(Nam)))
sb.Append(Nam .Trim() + ",");
It is much faster then a earlier code which shown
Hope you like this. Enjoy Reading
Sometimes you stuck in situation where you need to run same set of queries on different servers.
Sometimes it is a real pan when you need to fetch records from all the server then basic approach you follow run query on different instance once by one.
I would like to share here one important facility provided in SQL Server management studio which is
With the help of Register Servers option you can run same query for the entire servers which you have registered.
You can access the “Register Servers” option from View ==> Register servers OR by pressing “CTRL + ALT + G” keys.
As shown below fig
Once you press the menu or follow above keys then you will get Register Servers option screen as shown in below fig.
You can right click on Local Server Groups and can create your own group also
Once the group is created you can move your Registered servers on which you want to run query in that group with right click move option on Group Folder
As you did this job your database server will come in the particular group folder as shown in below fig
Now right click on your group folder and go for option New Query
As you go for option new query a new query window will be open there
Now write proper query which you want to run on same database at different servers and execute it with F5 option
You will find when you will execute the result will show in query result window which is just below the query with starting column server name.
Now you have option whether you want merge result or Individual result.
To check that option you need to go Tool –> Option then Query Result option as shown below fig
This trick will help you in many ways to get the results from different server as well as to find results from different servers.
Thanks & Regards,
Keep Learning, Keep Sharing
Today I am going to share one of the interesting options of SQL Server Management studio which may be unknown to most of us.
Now you are thinking what it is? So the cool feature is you can
run DOS command in your SQL Server Management studio
I know your next question is how?
My answer is just follow below step
Go To Tool –> Option
After option window open you need to select Query Execution tree and Select checkbox for
“By default, Open new queries in SQLCMD Mode”
Now open new Query window and write following command
!! Dir C:\
And hit F5
You will find below in the query result you have directory & files of your current C drive.
Just check below fig to understand.
In this way you can run various DOS commands.
!! Dir C:\New Folder
Isn’t it cool feature.
I hope you enjoyed it.
Keep Learning, Keep Sharing