Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

crostab

Status
Not open for further replies.

OCM

MIS
Sep 12, 2002
226
US
Greetings,

I used the following formula to determine if a given course is (day, evening, etc.) .which works fine in a vertical report format, but gives wrong count (doubles) when in crosstab report. Plese see example below

Var1
= If([Section Number]) InList( "75" ; "75A" ; "75B" ; "75C" ; "85" ; "99" ; "S175" ; "S175A" ; "S175B" ; "S199" ; "S275" ; "S275A" ; "S275B" ; "S285" )
Then "Online" ElseIf [Section Number] InList ( "65" ; "65A" ; "S165" ; "S265" ) Then "Hybrid" ElseIf FormatDate ([Meeting Start Time] ; "HHmm") >=
"1700" Then "Evening" ElseIf(IsNull ([Meeting Start Time]) ) Then "Other" Else "Day"

Var2
= Min([Total Enrolled Distinct]) In ([Section ID] ; [Section Number] ; [Term] ; [Course Name] ; [Meeting Start Time]


Course term section # start time type total
P-099 2012-WI 05 1:00 PM hybrid 14
P-111 2011-FA 01 12:30 PM Day 26
2011-FA 11:30 AM Day
P-241 2012-SU S-101 other 23

In my crostab where there exists multiple start times, I get the count doubled (below). I just want the crostab to function as my vertical format (above)

Course Day Hybrid Other total
P-099 28 28
P-111 52 52
P-241 23

Regards,

OCM
 
hi,

Using a crosstab report for analysis is like sticking a finger in your eye. It's a really poor data source.

Can't you use the source data that the crosstab was generated from? THAT would be much simpler and would save your eye.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Skip thanks.

So, what would be an example if the goal is to find out the count/percentage of cources given: (online, hybrid, day or evening etc) to make appropriate decisions?

Regards,

OCM
 
first of all, no one can determine in your examples, where one field ends and another begins.

Please put a unique delimiter between each data element and repost. This will enable anyone to copy your example and paste into an Excel sheet and parse on the unique delimiter.

Please include and example of the results that you expect related to the source example(s).

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Sure, I can provide a sample screenshot to show what my crosstab displays currently, and a sample how I expect to see the result.

What is the best way to attach this to the post?

TIA,


OCM
 
Observe instructions immediately below the Attachment Textbox below.

However many members, including YT, are prohibited from accessing external data files by compeny security policy and firewall software. It is preferred to post tabular examples 1) using the TGML tags (click HELP icon adjacent Preview) and 2) embedding spaces to pad or a COMMA for TABS and post directly.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top