Friday, December 7, 2012

Windows: Configuring Local Users: lusrmgr.msc

lusrmgr.msc

SQL Server backup results


SELECT a.name, b.type, DATEDIFF(MINUTE,b.backup_start_date , b.backup_finish_date),
b.backup_start_date ,
b.backup_finish_date
FROM master..sysdatabases a
LEFT OUTER JOIN msdb..backupset b ON a.name = b.database_name
WHERE DATEPART(DW,b.backup_start_date) IN (6, 7)
AND b.type NOT IN ( 'L', 'I')

Friday, April 27, 2012

Managing Session Timeouts in .NET

If you are using ASP.NET 2.0, use have to check in the IIS. Open the IIS, click on the Application Pools, Select the Application pool for your application. Right Click on that, Select Properties. In the Performance tab, Set the idle timeout as your desired minutes for "shutdown worker processes after being idle for ..... minutes". Apart from this you have to set the timeout in web.config as said by the other friends.

Sunday, April 8, 2012

import/export BLOB

http://blog.rptea.com/post/Simple-scripts-to-insert-File-to-BLOB-field-and-export-BLOB-to-File-system.aspx

CREATE TABLE [dbo].[TmpBin](
     [MyId] [int] IDENTITY(1,1) NOT NULL
   , [MyDesc] [varchar](50) NULL
   , [MyBin] [varbinary](max) NULL ) 
ON [PRIMARY] 

INSERT INTO (MyDesc, MyBin) 
Select 'MyDesc01' 
   , BulkColumn from Openrowset( Bulk 'C:\temp\image1.jpg', Single_Blob) as tt 

Insert TmpBin(MyDesc, MyBin) 
Select 'MyDesc02' 
, BulkColumn from Openrowset( Bulk 'C:\temp\image2.jpg', Single_Blob) as tt

INSERT INTO TmpBin(MyDesc, MyBin) 
SELECT 'MyDesc03' 
     , BulkColumn 
FROM Openrowset( Bulk 'C:\temp\image3.jpg', Single_Blob) as tt

Tuesday, March 27, 2012

What language uses .do extension?

No, No, No! The .do extension is strictly for JavaServer Pages using the struts framework. The .do extension tells the Application Server to find a config file which calls the proper action class to process the form. Struts is the ultimate "separate content from display" implementation. Go to www.sun.com or to apache.org to find out more about JSP and Struts.

Monday, January 23, 2012

Visual Studio Command to Collapse/Expand all sections of code

CTRL + M + O will collapse all
CTRL + M + L will expand all
CTRL + M + P will expand and disable outlining
CTRL + M + M will collapse/expand the current section

CTRL + M, CTRL + L collapses/expands (toggles) all regions

Monday, November 28, 2011

MS-Word Easter Egg

Open MS-Word
type =Rand(3,8)
press Enter


On the Insert tab, the galleries include items that are designed to coordinate with the overall look of your document. You can use these galleries to insert tables, headers, footers, lists, cover pages, and other document building blocks. When you create pictures, charts, or diagrams, they also coordinate with your current document look. You can easily change the formatting of selected text in the document text by choosing a look for the selected text from the Quick Styles gallery on the Home tab. You can also format text directly by using the other controls on the Home tab. Most controls offer a choice of using the look from the current theme or using a format that you specify directly. To change the overall look of your document, choose new Theme elements on the Page Layout tab. To change the looks available in the Quick Style gallery, use the Change Current Quick Style Set command.
Both the Themes gallery and the Quick Styles gallery provide reset commands so that you can always restore the look of your document to the original contained in your current template. On the Insert tab, the galleries include items that are designed to coordinate with the overall look of your document. You can use these galleries to insert tables, headers, footers, lists, cover pages, and other document building blocks. When you create pictures, charts, or diagrams, they also coordinate with your current document look. You can easily change the formatting of selected text in the document text by choosing a look for the selected text from the Quick Styles gallery on the Home tab. You can also format text directly by using the other controls on the Home tab. Most controls offer a choice of using the look from the current theme or using a format that you specify directly. To change the overall look of your document, choose new Theme elements on the Page Layout tab.
To change the looks available in the Quick Style gallery, use the Change Current Quick Style Set command. Both the Themes gallery and the Quick Styles gallery provide reset commands so that you can always restore the look of your document to the original contained in your current template. On the Insert tab, the galleries include items that are designed to coordinate with the overall look of your document. You can use these galleries to insert tables, headers, footers, lists, cover pages, and other document building blocks. When you create pictures, charts, or diagrams, they also coordinate with your current document look. You can easily change the formatting of selected text in the document text by choosing a look for the selected text from the Quick Styles gallery on the Home tab. You can also format text directly by using the other controls on the Home tab. Most controls offer a choice of using the look from the current theme or using a format that you specify directly.