Wednesday, March 21, 2012

Make tbl_SP From Vertical to Horizontal

Hi,

What I need is the following, a StoredProc that make a Vertical (normal table) into a Horizontal Table :
So From:
CustNo__Item

__1______1
__1______3
__1______4
__2______2
__2______3
__2______7

To:
CustNo___1__2___3___4___7

_1_______X______X___X
_2__________X___X_______X

Anny help would be verry appriciatedYou might want to look at:

Rob's Cross tab article (http://www.sqlteam.com/item.asp?ItemID=2955)sql

No comments:

Post a Comment