Data Warehouse & Business Intelligence
MSBI and other knowledge base
Labels
ASP.Net
(1)
BIML
(4)
Business Intelligence
(1)
C#
(8)
Data Models
(1)
Data Types
(1)
Data Warehouse
(3)
Database Architecture
(1)
Database Management
(1)
Date Functions
(3)
ERD
(2)
Google Analytics
(4)
MobileApp Analytics
(1)
OoyalaAPI
(4)
Reference Sites
(1)
SalesForce
(4)
Scenarios
(6)
Script
(27)
SQL
(8)
SQL Job
(3)
SSAS
(2)
SSIS
(36)
SSRS
(4)
StoredProcedure
(8)
StoredProcedureFunction
(1)
T-SQL
(60)
Tableau
(1)
What's new
(1)
Monday, July 7, 2014
Calling the case condition inside the partition using row_number
,ROW_NUMBER() OVER (PARTITION BY CustomerId ORDER BY CASE [status]
WHEN 'active' THEN 1
WHEN 'new' THEN 2
WHEN 'cancelled' THEN 3
ELSE 4
END) AS RN
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.