Pages

Wednesday, February 25, 2009

Active Connections in SQL Server

@@CONNECTIONS
Returns the number of connections, or attempted connections, since SQL Server was last started.

Connections are different from users. Applications, for example, can open multiple connections to SQL Server without the user observing the connections.
To display a report containing several SQL Server statistics, including connection attempts, run sp_monitor.

SELECT GETDATE() AS 'Today''s Date and Time',
@@CONNECTIONS AS 'Login Attempts'

How to Get SQL Server Version

@@VERSION
Returns the date, version, and processor type for the current installation of SQL Server.

The information returned by @@VERSION is similar to the product name, version, platform, and file data returned by the xp_msver stored procedure, which provides more detailed information.

SELECT @@VERSION

Active transactions for the current connection

@@TRANCOUNT

Returns the number of active transactions for the current connection.

The BEGIN TRANSACTION statement increments @@TRANCOUNT by 1. ROLLBACK TRANSACTION decrements @@TRANCOUNT to 0, except for ROLLBACK TRANSACTION savepoint_name, which does not affect @@TRANCOUNT. COMMIT TRANSACTION or COMMIT WORK decrement @@TRANCOUNT by 1.

BEGIN TRANSACTION
UPDATE authors SET au_lname = upper(au_lname)
WHERE au_lname = 'White'
IF @@ROWCOUNT = 2
COMMIT TRAN
IF @@TRANCOUNT > 0
BEGIN
PRINT 'A transaction needs to be rolled back'
ROLLBACK TRAN
END

Sunday, February 8, 2009

Google Maps in ASP.NET

I came accross very good article on integrating google maps into ASP.NET application.

Basically we need to build one ASP.NET Server control that would allow us to harness the power of Google Maps in the code-behind model.

Check out the below link for complete information:

http://dotnet.sys-con.com/node/171162

Member of The Year Award from DotNetSpider

This time the Annual Super Gift Award goes to Mr. VIJAYA KRISHNA.

OUR HEARTY CONGRATULATIONS TO Mr. VIJAYA KRISHNA.

Members please join with me to congratulate him. The winner will be awarded with DIGITAL CAMERA.

Mr.Vijaya Krishna is one of the most active members of DotNetSpider. He joined DotNetSpider on 21st August, 2004. He received a couple of awards/gifts from DotNetSpider. He also got MVP award from Microsoft in the year 2008.

We can see the announcement of this award here: http://www.dotnetspider.com/forum/174149-Microsoft-MVP-Award-Vijaya-Krishna.aspx

He is also maintaining a blog on Microsoft Technologies. We can see his blog at : http://dotnetvj.blogspot.com. He has contributed a lot in the area of VB.NET, ASP.NET with SQL Server.

We can see his profile at the URL:
http://www.dotnetspider.com/member/vijay_birju.aspx.

Once again CONGRATULATIONS to Mr. Vijaya Krishna. Keep it up Vijaya.

One Cube Query Engine

"One Cube" stands for Oracle, SQL Server and Sybase.
"Query Engine" A place to resolve all the issues related to Database.

In this IT world, Database plays major/critical role in any applications. The main purpose of this group is to bring Oracle, SQL Server and Sybase at one place to resolve all the queries or provide extensive information on these.

In addition to this, community also address the queries related to DB2, My SQL and Informix.

You can use this community in following ways:
1) Knowledge sharing
2) Certification Preparation
3) Career Guidance
4) Interview preparation

If you are looking for a strong foundation in the database world or want to clear database certifications then, you are at the right place.

http://www.dotnetspider.com/sites/281/-One-Cube-Query-Engine.aspx