Drop Down MenusCSS Drop Down MenuPure CSS Dropdown Menu

Wednesday, April 27, 2011

Avoid Temp Table use Table Data Type

Avoid Temp Table use Table Data Type
Micrsoft indroduced table data type in sql server altenative to using temporary  table
Table variables store a set of records, so naturally the declaration syntax looks very similar to a CREATE TABLE statement, as you can see in the following example:
DECLARE @Student TABLE
{
SNO INT ,SNAME NVARCAHR
}
IF YOU WANT INSERT RECORD
INSERT INTO  @ Student VALUES(2,’JSSUTHHAAR’)

OR
INSERT INTO @Student SELECT SNO,SNAME FROM STUDENT

List Of Table Name In Sql Server

List Of Table Name In Sql Server

SELECT *FROM INFORMATION_SCHEMA.TABLESWHERE

Or


 SELECT [name]FROM sys.tables;
table_type = 'BASE TABLE'

Reset Identity Column

Reset Identity Column
DELETE FROM STUD
DBCC CHECKIDENT(STUD,RESEED,0)