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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report Net and Maximum Function

Status
Not open for further replies.

achaaran

Programmer
Jan 19, 2005
18
0
0
CA
Hello, I'm fairly new to reportnet, I used to work on Impromptu 7.0 beforehand.

My question for the community is how to use the MAXIMUM function. I know this seems easy, but I have one field that is grouped, and I want to get the maximum # for that group, so ideally, I want this:

Dept. Name. Salary
1 Joe 1,000
Mark 2,000
=====
2,000

2 Donna 9,000
Paula 2,444
=====
9,000

but, I am getting this:

Dept. Name. Salary
1 Joe 1,000
Mark 2,000
=====
9,000

2 Donna 9,000
Paula 2,444
=====
9,000

I have "Dept," grouped, so I don't get it? Anything glaringly obvious I'm missing?

Sorry for the lame report :)
 
This worked for me:

1.Group on Dept.
2.Select the fact and choose the aggregate button from the menu.
3.Select total (not maximum)
4.Select the fact again and change the rollup aggregate function from the properties menu and set is to maximum

Et voila, it works.



Ties Blom

 
Hey, thanks for the response, but alas it still isn't working. It ignores the grouping all together and just gives me the max for everything.

Why is it that the MAXIMUM function is causing difficulties but COUNT works flawlessly?

Is there something else I'm missing here? (Impromptu 7 was much easier :( ).
 
Can you check whether 'total' has the right effect?
'count' may work, but is pretty senseless for a fact..

Ties Blom

 
Ok, well I figured it out. Turns out that I am referencing a date in my catalog that isn't defined in the catalog...

Wierd huh, ok, well what I mean is:

There is something in the catalog called emp.datetime, I know for a fact there is a field called emp.date, but it's not defined in the catalog, I wrote it in the forumal anyways.

So it wouldn't let me do any sort of summary functions on it...thanks for your help, you got me thinking.
 
When you write catalogue you mean framework?
I am just a little curious why this should not work. You are trying to asses the max on the salary, which should be possible, as this is a numerical value.
Whether you address a date in the conditions should not make any difference.
Or perhaps this is a manually applied SQL query?

Ties Blom

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top