We had an interesting issue today. We have stored procedure which gets the ids using a CTE and update attributes using the ID. The SP is timing out and when we try to execute the scripts in the sp separately, it worked without timeout issue.
After all the analysis we realized that it may be due to bad statistic issue.
We executed sp_updatestats commend to update statistics. The query worked in no time!
Thursday, February 26, 2009
Fiddler - HTTP trace tool
I came across an interesting tool, which trace the HTTP transaction. It was really simple and amazing tool which shows all the input and output happening in the HTTP 80 port. Even we can edit the delivered HTTP content and see the output in the browser.
You can download the tool from http://www.fiddler2.com. and the site all has a simple video to demonstrate the features.
It will be really helpful to debug ASP.Net / Web service code.
You can download the tool from http://www.fiddler2.com. and the site all has a simple video to demonstrate the features.
It will be really helpful to debug ASP.Net / Web service code.
Wednesday, February 25, 2009
Microsoft Research
It is interesting to read future technologies. Microsoft spends lot of its efforts towards research.
Check out http://research.microsoft.com for the cool features.
Check out http://research.microsoft.com for the cool features.
Data Type and it's Danger
I was working in a finance application. Recently we discovered the simple mistakes done the datatype and its dangerous implications.
1. Temp table column data type
We had a report SP which has temp tables. The data type of temp tables are set exactly matching to the base column. But when the report is executed it gets the consolidate values, so the data lost is happening.
2. GUID
In the latest stage of the project we have change the data from INT to GUID, which lead to break the existing codes. We need to have a special consideration for GUID data type.
3. VARCHAR
When declaring the VARCHAR it is mandate to specify size of the VARCHAR other it will be defaulted to 1 and data lost will happen.
4. NVARCHAR
Whenever you data has multi language characters we must use NVARCHAR, if you use VARCHAR the charters are set o ?.
1. Temp table column data type
We had a report SP which has temp tables. The data type of temp tables are set exactly matching to the base column. But when the report is executed it gets the consolidate values, so the data lost is happening.
2. GUID
In the latest stage of the project we have change the data from INT to GUID, which lead to break the existing codes. We need to have a special consideration for GUID data type.
3. VARCHAR
When declaring the VARCHAR it is mandate to specify size of the VARCHAR other it will be defaulted to 1 and data lost will happen.
4. NVARCHAR
Whenever you data has multi language characters we must use NVARCHAR, if you use VARCHAR the charters are set o ?.
Wednesday, February 18, 2009
Login failure when default DB deleted
When the defauld DB of the user is deleted. We could not able to login to DB.
Error Message:
Cannot open user default database. Login failed.
Login failed for user 'xyz'. (Microsoft SQL Server, Error: 4064)
Solution:
Change the default DB.
USE [master]
GO
ALTER LOGIN [FAREAST\v-prcher]
WITH DEFAULT_DATABASE=[AnyOtherExistingDBName],
DEFAULT_LANGUAGE=[us_english]
GO
Error Message:
Cannot open user default database. Login failed.
Login failed for user 'xyz'. (Microsoft SQL Server, Error: 4064)
Solution:
Change the default DB.
USE [master]
GO
ALTER LOGIN [FAREAST\v-prcher]
WITH DEFAULT_DATABASE=[AnyOtherExistingDBName],
DEFAULT_LANGUAGE=[us_english]
GO
Tuesday, February 17, 2009
Indian spice names
Be an Indian we use lot of local spice products. When you are out of tamil nadu, it is really hard to get the same just because you don't know the local name of the item.
For example
Pacha karpuram – cooking camphor
Sukku – Dry ginger
Sitharathai - licorice
Govenment of India has a web site which gives detailed information on this.
http://www.ccras.nic.in/PharmacopoeialWork/20081103_E-Books.htm
For example
Pacha karpuram – cooking camphor
Sukku – Dry ginger
Sitharathai - licorice
Govenment of India has a web site which gives detailed information on this.
http://www.ccras.nic.in/PharmacopoeialWork/20081103_E-Books.htm
Monday, February 16, 2009
Online FM
It is always interesting to listen to FM Radio, specially when you are out of Tamil Nadu. Here is the list of online tamil FMs
Suryan FM
http://www.techsatish.net/2006/12/27/suryan-fm-chennai-india/
http://www.loka.fm/Player.aspx
List of tamil FMs
http://www.tamilfms.com/
http://www.airtamil.com/
http://www.fmworldmusic.com/
http://live.shyamradio.com/index.aspx
http://tamilo.com/
From Canada
http://www.kalasam.com/
Hope the list is usefull. Add in the comment section, if you know more.
Suryan FM
http://www.techsatish.net/2006/12/27/suryan-fm-chennai-india/
http://www.loka.fm/Player.aspx
List of tamil FMs
http://www.tamilfms.com/
http://www.airtamil.com/
http://www.fmworldmusic.com/
http://live.shyamradio.com/index.aspx
http://tamilo.com/
From Canada
http://www.kalasam.com/
Hope the list is usefull. Add in the comment section, if you know more.
Monday, February 2, 2009
Paste without formatting
Get the application puretext from www.stevemiller.net/puretext. This handy application will clear all formatting from text you have stored in your clipboard. Nearly every publisher has a style sheet that they require you use, and frankly if you have any Word skill at all you always use styles for titles and headings at the very least. The most annoying thing though is that the text you copy from SSMS has formatting in it, so when you paste it into your documents you have this formatting that you need to get rid of in lieu of the stuff that the publisher wants. With Puretext you simply use a slightly different paste key (like Windows-V) and you get the plain text you need. Same time estimate for this feature. Before I found this application I used to paste into Notepad, the copy it to the clipboard and then into Word. Very tedious.
Note: Tips from blog http://sqlblog.com/blogs/louis_davidson/archive/2009/01/18/a-few-word-tips-and-tricks-for-writers.aspx
Note: Tips from blog http://sqlblog.com/blogs/louis_davidson/archive/2009/01/18/a-few-word-tips-and-tricks-for-writers.aspx
Subscribe to:
Posts (Atom)
Teams PowerShell
The PowerShell helps to get quick meta data around Teams. Install-Module -Name MicrosoftTeams Connect-MicrosoftTeams Get-TeamAllChannel...
-
I was trying to install SharePoint 2013, the setup was complaining about a pending system restart. Even after multiple restart / Shutdown. ...
-
Recently a new learner of C# asked me a question on C# Virtual & Abstract properties. It turned out to a deep dive. Detail follows. D...
-
source 1. Microsoft .NET Framework interview questions .NET 2. What is .NET Framework? 3. Is .NET a runtime service or a developm...