Wednesday, November 7, 2012

How to check which process using TCP/IP Ports in Windows


Run the following command from a command prompt to find the PID of the process which is using TCP port 80 and/or 443. 
   
    netstat -aon | find ":80" 

    netstat -aon | find ":443"

You will see an output similar to the following. Remember the actual PID will vary from case to case.
    TCP    0.0.0.0:80    0.0.0.0:0    LISTENING    3604 
    TCP    0.0.0.0:443   0.0.0.0:0    LISTENING    3320

Now using Task Manager you can easily find out to which process the above PID belongs and take appropriate action.

http://support.microsoft.com/kb/973094

Friday, July 13, 2012

GDI+ .NET Color & HatchStyle Chart

Color Chart

HatchStyle Chart

Tuesday, July 10, 2012

Page Layout Using DIV


100% height and scroll able div

<html>
  <body style="overflow:hidden;">
    <div style="overflow:auto; position:absolute; top: 0px; left:0px; right:0px; bottom:0px">
    </div>
  </body>
</html>


Fix height header and footer and scroll able main content

<html>
  <body style="overflow:hidden;">
      <div id="header" style="overflow:hidden; position:absolute; top:0; left:0; height:50px;"><div>
      <div id="leftNav" style="overflow:auto; position:absolute; top:50px; left:0px; right:200px; bottom:50px;"></div>
      <div id="mainContent" style="overflow:auto; position:absolute; top:50px; left: 200px; right:0px; bottom:50px;"></div>
      <div id="footer" style="overflow:hidden; position:absolute; bottom:0; left:0; height:50px"></div>
  </body>
</html>

Note: for IE the main content div require doctype definition, without this the div height will not expand to the bottom position.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Tuesday, June 19, 2012

SQL Server version information



SQL Server 2012 version information

The following table lists the major releases of SQL Server 2012.
ReleaseProduct Version
SQL Server 2012 Service Pack 111.00.3000.00
SQL Server 2012 RTM11.00.2100.60


SQL Server 2008 R2 version information

The following table lists the major releases of SQL Server 2008 R2.

ReleaseProduct version
SQL Server 2008 R2 Service Pack 210.50.4000.0
SQL Server 2008 R2 Service Pack 110.50.2500.0
SQL Server 2008 R2 RTM10.50.1600.1
For more information information about the latest service packs for SQL Server 2008 R2, click the following article number to view the article in the Microsoft Knowledge Base:
2527041  How to obtain the latest service pack for SQL Server 2008 R2
For more information about the latest cumulative updates available for SQL Server 2008 R2, click the following article number to view the article in the Microsoft Knowledge Base:
981356  The SQL Server 2008 R2 builds that were released after SQL Server 2008 R2 was released
2567616  The SQL Server 2008 R2 builds that were released after SQL Server 2008 R2 Service Pack 1 was released


SQL Server 2008 version information

The following table lists the major releases of SQL Server 2008.
ReleaseProduct version
SQL Server 2008 Service Pack 310.00.5500.00
SQL Server 2008 Service Pack 210.00.4000.00
SQL Server 2008 Service Pack 110.00.2531.00
SQL Server 2008 RTM10.00.1600.22
For more information information about the latest service packs for SQL Server 2008, click the following article number to view the article in the Microsoft Knowledge Base:
968382  How to obtain the latest service pack for SQL Server 2008
For more information about the latest cumulative updates available for SQL Server 2008, click the following article numbers to view the articles in the Microsoft Knowledge Base:
956909  The SQL Server 2008 builds that were released after SQL Server 2008 was released
970365  The SQL Server 2008 builds that were released after SQL Server 2008 Service Pack 1 was released
2402659  The SQL Server 2008 builds that were released after SQL Server 2008 Service Pack 2 was released
2629969  The SQL Server 2008 builds that were released after SQL Server 2008 Service Pack 3 was released


SQL Server 2005 version information

The following table lists the major releases of SQL Server 2005.
ReleaseProduct version
SQL Server 2005 Service Pack 49.00.5000.00
SQL Server 2005 ServicePack 39.00.4035
SQL Server 2005 Service Pack 29.00.3042
SQL Server 2005 Service Pack 19.00.2047
SQL Server 2005 RTM9.00.1399


For more information information about the latest service packs for SQL Server 2005, click the following article number to view the article in the Microsoft Knowledge Base:
913089 How to obtain the latest service pack for SQL Server 2005

For more information about the latest cumulative updates available for SQL Server 2005, click the following article number to view the article in the Microsoft Knowledge Base:
937137 The SQL Server 2005 builds that were released after SQL Server 2005 Service Pack 2 was released
960598 The SQL Server 2005 builds that were released after SQL Server 2005 Service Pack 3 was released
2485757 The SQL Server 2005 builds that were released after SQL Server 2005 Service Pack 4 was released

SQL Server 2000 version information

The following table lists version number of the Sqlservr.exe file. 


ReleaseProduct version
SQL Server 2000 Service Pack 48.00.2039
SQL Server 2000 ServicePack 3a8.00.760
SQL Server 2000 Service Pack 38.00.760
SQL Server 2000 Service Pack 28.00.534
SQL Server 2000 Service Pack 18.00.384
SQL Server 2000 RTM8.00.194
For more information, click the following article number to view the article in the Microsoft Knowledge Base:
290211  How to obtain the latest SQL Server 2000 service pack



Older versions of SQL Server

SQL Server 7.0

Use the version number in the following table to identify the product or service pack level: 
Version numberService pack
7.00.1063SQL Server 7.0 Service Pack 4
7.00.961SQL Server 7.0 Service Pack 3
7.00.842SQL Server 7.0 Service Pack 2
7.00.699SQL Server 7.0 Service Pack 1
7.00.623SQL Server 7.0 RTM
For more information, click the following article number to view the article in the Microsoft Knowledge Base:
301511  How to obtain the latest SQL Server 7.0 service pack



SQL Server 6.5

Use the version number in the following table to identify the product or service pack level: 
Version numberService pack
6.50.479SQL Server 6.5 Service Pack 5a Update
6.50.416SQL Server 6.5 Service Pack 5a
6.50.415SQL Server 6.5 Service Pack 5
6.50.281SQL Server 6.5 Service Pack 4
6.50.258SQL Server 6.5 Service Pack 3
6.50.240SQL Server 6.5 Service Pack 2
6.50.213SQL Server 6.5 Service Pack 1
6.50.201SQL Server 6.5 RTM
For more information, click the following article number to view the article in the Microsoft Knowledge Base:
273914  Readme.txt for SQL Server 6.5 post-Service Pack 5a Update




For more information: http://support.microsoft.com/kb/321185

Tuesday, September 20, 2011

How To boot into text mode in linux fedora

Power on computer  when bios info shows up on the screen press F2 or F3, the GRUB boot screen appears.
Select the Fedora that you want to boot into, Press the a key boot kernel argument will show up. in the end of the argument string add '3'

    Original argument
  kernel /vmlinuz-2.6.40.4-5.fc15.x86_64 root=LABEL=/ acpi=on rhgb quiet

 
    after modified in the end of arguments add a 3
    kernel /vmlinuz-2.6.40.4-5.fc15.x86_64 root=LABEL=/ acpi=on rhgb quiet 3

  and press enter to be continue
   the number 3 will cause fedora boot into text mode.







Monday, September 19, 2011

Transaction Log issue for SQL Server

-- View Transaction log
DBCC Log(myDbName)




If the recovery model is set to SIMPLE the log data will be cleared automatically.

-- How to Change Recovery Model to simple
use myDbName
-- Change Recovery model to simple
ALTER DATABASE
myDbName SET RECOVERY SIMPLE
-- enable auto shrink option
ALTER DATABASE
myDbName SET AUTO_SHRINK ON
-- Shrink DB Log file
DBCC SHRINKFILE(
myDbName_log, TRUNCATEONLY)

-- This command help you to find out what is database log file name
USE myDbName
SELECT * FROM sys.database_files