当前位置:网站首页>Three paging query methods of SQL Server
Three paging query methods of SQL Server
2022-04-22 05:10:00 【Haihong AA】
Judge version , And then execute
-- select serverproperty('productversion'),serverproperty('productlevel'),serverproperty('edition'), @@VERSION
--SQL2000:8.00.194 RTM Personal Edition Microsoft SQL Server 2000 - 8.00.194 (Intel X86) Aug 6 2000 00:57:48 Copyright (c) 1988-2000 Microsoft Corporation Personal Edition on Windows NT 6.2 (Build 9200: )
--SQL2008:10.50.1600.1 RTM Enterprise Edition (64-bit) Microsoft SQL Server 2008 R2 (RTM) - 10.50.1600.1 (X64) Apr 2 2010 15:48:46 Copyright (c) Microsoft Corporation Enterprise Edition (64-bit) on Windows NT 6.2 <X64> (Build 9200: )
--SQL2012:11.0.3000.0 SP1 Enterprise Edition (64-bit) Microsoft SQL Server 2012 (SP1) - 11.0.3000.0 (X64) Oct 19 2012 13:38:57 Copyright (c) Microsoft Corporation Enterprise Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1)
-- select CONVERT(numeric(20,2), LEFT(CONVERT(varchar,serverproperty('productversion')),CHARINDEX('.',CONVERT(varchar,serverproperty('productversion')),0)))
--SQL2000
select top 20 * from ShouFeiList where 1=1 and (1<>0) and ( nID not in ( select top 15000 nID from ShouFeiList where 1<>0 order by nID)) order by nID
--SQL2008
SELECT* FROM(SELECT *, ROW_NUMBER () OVER (ORDER BY nID) AS rowNumber FROM ShouFeiList where 1<>0) as T WHERE rowNumber BETWEEN 15000 and 15020
--SQL2012
select * from ShouFeiList Order by nID Offset 15000 Row Fetch Next 20 Rows Only
版权声明
本文为[Haihong AA]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204210628208240.html
边栏推荐
- Typescript function generics
- Reset kubernetes cluster
- Chapter 2 MySQL data types and operators
- Jackson
- Regular expression of shell script
- scanf、printf的输入输出(格式控制符)
- Write down the daily temperature
- Detailed explanation of Neptune w800 lighting (interruption) project
- style/TextAppearance.Compat.Notification.Info) not found.
- Objectbox usage record
猜你喜欢

Recently, it was found that Baidu cloud sharing should be set with extraction code, and can not be set to sharing without extraction code This article will teach you how to bypass Baidu to set up shar

Final Cut Pro mosaics in multiple places of the video at the same time
![Layer 3 switch [vlanif details] enable OSPF and router interworking [ENSP implementation]](/img/ff/587994174a0191ee9df2b8ad018eff.png)
Layer 3 switch [vlanif details] enable OSPF and router interworking [ENSP implementation]

JVM - G1 garbage collector

How to restrict Oracle sub query

MySQL double master and double slave + atlas data test

Feature Engineering - feature preprocessing (normalization, standardization)

KNN prediction minimum case summary

Error: ER_ NOT_ SUPPORTED_ AUTH_ MODE: Client does not support authentication protocol requested by serv
![[Reading Notes - > statistics] 07-01 introduction to the concept of discrete probability distribution geometric distribution](/img/47/2b22d990cd3ea83d57016d2dfc6f41.png)
[Reading Notes - > statistics] 07-01 introduction to the concept of discrete probability distribution geometric distribution
随机推荐
Flutter installation summary
PHP quickly raises a value in a two-dimensional array to an array key value, array_ The wonderful use of column
JS Chapter 12
Nexus private server - (II) console installation of version 3.2.0, initial password location
Error: ER_ NOT_ SUPPORTED_ AUTH_ MODE: Client does not support authentication protocol requested by serv
Data distribution, correlation analysis and visualization method of data exploratory analysis (EDA)
Libevent implementation client
Introduction to esmodule specification
The problem that the video in video becomes muted when the mouse scrolls
Uninstallation, installation and setting of MySQL
Anti chattering function and throttling function
2022.04.20 Huawei written examination
Common test methods
EMO-DB 數據集的 Speech 特征提取
KNN prediction minimum case summary
[I. XXX pest detection items] 3. Loss function attempt: focal loss
How to copy the variables in the chrome console as they are, save and download them locally
Considerations for importing idea package and calling its methods
Realization of online Preview PDF file function
Summary of common methods, advantages and disadvantages of robot UAV visual obstacle avoidance