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

Chart Question - Don't chart a point whose value is = some number/0

Status
Not open for further replies.

djmurphy58

Technical User
Feb 28, 2003
73
US
I have created a report with an embedded chart. The report prints out the following info:

WorkDate: The date that work was done on a construction site for a particular cost code

DailyHours: The number of hours spent on that cost code on that day

DailyQty: The quantity of work that got done in the above number of hours

DailyMHF: (Daily Man Hour Factor) - a calculated value that is the DailyHours/DailyQty.

The embedded chart then charts the DailyMHF over time. It's called a trend chart.

On most days, a construction crew will work, for example, 8 hours doing, say excavation of dirt. Say their DailyQty is 1000 CY (cubic yards), then their DailyMHF is 8/1000 or .008.

However, there are some days in which the construction crew will work for a number of hours and literally get zero quantity done. A typical reason for this may be because they were delayed by weather, or some other contractor.

This is where the problem comes up - Access will NOT display the chart in the case of ZERO quantity. This is because any number divided by zero is of course undefined. In order to get around this problem, instead of plugging in zero for the quantity, I could put in a very small number - like .0001, or .001, or .01 - you get the idea. Access will then display the report, but the vertical scale on the chart is super large in order to fit in that one day's data where the crew got zero quantity done. In other words, rather than the chart showing a typical MHF of .008 for that day, it shows 800 (if I put in a qty of .01 instead of zero). This totally screws up the scale of the chart - you know what I mean.

SO - is there a way I can tell Access to simply NOT plot the day's data whenever the quantity is equal to zero???? You know, can Access simply skip right over it???

Thank you very much,
Dennis
 
NEVERMIND!!!! I FIGURED IT OUT, YIPPEE!!!

In my query, I simply had to write ">0" in my criteria. And it works!!!!

Thanks,
Dennis
 
While this does suppress the errant value, it also somewhat "misLeads" the user, as the general appearance would tend to indicate hte M-F "week", while the errant (missing) value(s) provide only a FOUR day "week". In my opinion, it would be more useful -from a users perspective- to simply represent the days with a zero, which should not be a problem for the Ms. Chart applet. this can be accomplished with a simple calcualted field using the IIF function. For assistance on the function, use the ubiquitous {F1} (a.k.a. HELP)




MichaelRed
m.red@att.net

Searching for employment in all the wrong places
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top