DEFINITIONS

Definitions More Info.
Definition ID298
TitleSQL
CategorySCRIPT
DefinitionSQL TOP PERCENT
Definition Descriptionhttp://www.w3schools.com/sql/sql_top.asp http://msdn.microsoft.com/en-us/library/ms189463.aspx The "Persons" table: P_Id LastName FirstName Address City 1 Hansen Ola Timoteivn 10 Sandnes 2 Svendson Tove Borgvn 23 Sandnes 3 Pettersen Kari Storgt 20 Stavanger 4 Nilsen Tom Vingvn 23 Stavanger Now we want to select only 50% of the records in the table above. We use the following SELECT statement: SELECT TOP 50 PERCENT * FROM Persons The result-set will look like this: P_Id LastName FirstName Address City 1 Hansen Ola Timoteivn 10 Sandnes 2 Svendson Tove Borgvn 23 Sandnes
RecordBycunay
Record Date23-01-2013 16:19:15
Düzenle
Kopyala
Sil