June 17, 2009 at 9:38 am
I Have a table "DemoPRofile" as shown below
dPId demoNo MTrip FTrip
10000MA021 1 0.52240 0.4314
10000MA021 2 0.0066 0.0102
10000MA021 3 0.0116 0.0076
10000MA021 4 0.0057 0.0041
10000MA007 1 0.0455 0.9932
10000MA007 2
Output required:
DPID MTRIP1 FTRIp1 mTRIP2 FTRIP2 MTRIP3 FTRIP3 MTRIp4 FTRIp4
10000MA021 0.52240 0.4314 0.0066 0.0102 0.0116 0.0076 0.0057 0.0041
June 17, 2009 at 3:42 pm
Hi,
you could either use (dynamic) Cross Tabs or the PIVOT function.
Dynamic cross tabs are used if you don't have a fixed number of target columns.
Please read the following two articles by Jeff Moden.
If you need further assistance please provide sample data as described in the link in my signature.
@jeff (if you come across: just added another plug post) 🙂
June 18, 2009 at 10:01 am
AWESOME.
Thanks for the info and it solved my problem.
Thank you .
Sree
June 18, 2009 at 1:46 pm
You're welcome.
(Even though I didn't add any information that I came up with. So, all the flowers belong to Jeff 🙂 )
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply