Quantcast
Channel: SQL query to return a columns with given range - Database Administrators Stack Exchange
Browsing all 2 articles
Browse latest View live

Answer by Stephan for SQL query to return a columns with given range

Your best bet is probably to use dynamic SQL to pivot your data. Here try this out.IF OBJECT_ID('tempdb..#tblItems') IS NOT NULL DROP TABLE #tblItems;IF OBJECT_ID('tempdb..##tblItemsTotal') IS NOT NULL...

View Article



SQL query to return a columns with given range

I have a table tblItems with records having the same UniqueID and Description but with different dates and amount.Now I want to show the records by grouping them together using the UniqueIDs and then...

View Article
Browsing all 2 articles
Browse latest View live


Latest Images