Viewing 2 posts - 1 through 2 (of 2 total)
CREATE PROCEDURE [dbo].[Sp_Customer_Paging]
@PageSize INT=50,
@PageNumber INT=1
AS
Declare
@SQL varchar(4000),
@FirstRow INT,
@LastRow INT,
@TmpSQLDetail1 varchar(4000),
@TmpSQLDetail2 varchar(4000)
SELECT@FirstRow = (...
January 6, 2009 at 8:29 am
#921826
with Dups as (
SELECT *,row_number() over(partition by Company_name,Address order by Company_name,Address) as RowNum
FROM dbo.companies)
Delete from Dups where rownum > 1;
January 6, 2009 at 7:51 am
#921798