Wednesday, September 24, 2008

Current Income Tax Slab

Income Tax Slab
Individual Male
Up to Rs. 1,60,000 NIL
Rs.1,60,001 – Rs.5,00,000 10%
Rs.5,00,001 -Rs. 8,00,000 20%
Above Rs. 8,00,000 30%
Individual Female
Up to Rs. 1,90,000 NIL
Rs.1,90,001 – Rs.5,00,000 10%
Rs.5,00,001 -Rs. 8,00,000 20%
Above Rs. 8,00,000 30%
Individual Senior Citizens
Up to Rs. 2,40,000 NIL
Rs.2,40,001 to Rs. 10,00,000 10%
Rs.1,90,001 – Rs.5,00,000 10%
Rs.5,00,001 -Rs. 8,00,000 20%
Above Rs. 8,00,000 30%

Saturday, September 13, 2008

Convert letters to Uppercase

Make on css class definition in your css file if it is or create new and assign CssClass property to the class you make. As shown below.

.ToUpperCase
{
text-transform: uppercase;
}



TextBox1.CssClass=ToUpperCase;

Wednesday, September 10, 2008

Connection Pooling in Asp.Net

Opening a database connection is a resource intensive and time consuming operation.

Connection pooling increases the performance of Web applications by reusing active database

connections instead of creating a new connection with every request. Connection pool manager

maintains a pool of open database connections. When a new connection requests come in, the pool

manager checks if the pool contains any unused connections and returns one if available. If all

connections currently in the pool are busy and the maximum pool size has not been reached, the new

connection is created and added to the pool. When the pool reaches its maximum size all new

connection requests are being queued up until a connection in the pool becomes available or the

connection attempt times out.

Connection pooling behavior is controlled by the connection string parameters. The

following are four parameters that control most of the connection pooling behavior:


Connect Timeout - controls the wait period in seconds when a new connection is requested,

if this timeout expires, an exception will be thrown. Default is 15 seconds.

Max Pool Size - specifies the maximum size of your connection pool. Default is 100. Most

Web sites do not use more than 40 connections under the heaviest load but it depends on how long

your database operations take to complete.

Min Pool Size - initial number of connections that will be added to the pool upon its

creation. Default is zero; however, you may chose to set this to a small number such as 5 if your

application needs consistent response times even after it was idle for hours. In this case the

first user requests won't have to wait for those database connections to establish.

Pooling - controls if your connection pooling on or off. Default is true.

Tuesday, September 9, 2008

Compare case sensitive or case-insensitive string

string str1="Mahmad";
string str2="mahmad"

String.compare(str1,str2,false); //false As third parameter is false which means cas should not be ignored


String.Compare( str1,str2, true ) // true As third parameter is false which means cas should be ignored

Monday, September 8, 2008

Comp off

Compensatory due off: Every employee works for Six/Five days in a week and get one/two day/s off. If an employee is called on such an Off day, he is entitled to enjoy a day off on a working day.

Saturday, September 6, 2008

CMM 5

CMM Capability Maturity Model
CMM 5
CMM 5 describes 5 stages in which an organization manages its work process.

The 5 steps of CMM are :

1. Initial : processes are ad-hoc,chaotic,or actually few processes are defines. We can say that the process is at the very initial stage of software development.

2. Repeatable : It is characteristic of processes at this level that some processes are repeatable.

3. Defined : All processes are defined,documented and integrated into each other for easy communication.

4. Managed : Processes are measured by collecting detailed data on the process and their quality.

5. Optimizing : Continuing process improvement is adopted. That is modification for better performance is carried out over times.

Friday, September 5, 2008

Check dataset is null or not

//To check if the dataset is null or not just count tables in that dataset
if (DS.Tables.Count>0)
{
//Dataset is not null do whatever you want
}

Tuesday, September 2, 2008

ACID rule

1. Atomic - Transaction is one unit of work and does not dependent on previous and next transactions.

2. Consistent - Data is either committed or roll backed, no transaction should be in middle state like some data is committed and some are not.

3. Isolated - No transaction sees the intermediate results of the current transaction i.e one transaction which is in its middle process should not be referenced by another transaction.

4. Durable - The values should persist if the data had been committed even the system crashes right after that transaction.

Monday, September 1, 2008

@@identity

After an INSERT, SELECT INTO, or bulk copy statement is completed, @@IDENTITY contains the last identity value that is generated by the statement. If the statement did not affect any tables with identity columns, @@IDENTITY returns NULL. If multiple rows are inserted, generating multiple identity values, @@IDENTITY returns the last identity value generated