TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
C# Corner
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Fetch a pattern of data in SQL Server
Venkatesan Jayakantham
May 04, 2012
2.6
k
0
0
facebook
twitter
linkedIn
Reddit
WhatsApp
Email
Bookmark
Fetch a pattern of data in SQL Server
Fetch a pattern of data:
Consider, If you want to fetch a specific pattern of data like I want to fetch customerkey which are able to divide by 100. A pattern of divide of 100 values.
In that case, the query created is as below.
SELECT TOP 1000 [CustomerKey]
,[GeographyKey]
,[CustomerAlternateKey]
,[Phone]
,[DateFirstPurchase]
,[CommuteDistance]
FROM [dbo].[DimCustomer]
where (CustomerKey % 100 =0)
Cheers,
Venkatesan Prabu .J
www.kaashivinfotech.com
Fetch a pattern of data in SQL Server
Next Recommended Reading
Convert Data Table to XML in SQL Server