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

Conditional charting

Status
Not open for further replies.

victorthomas

Programmer
Nov 26, 2003
12
US
Happy Holidays everyone! I need some help!

I have to chart off numerical data in a database.

For the x-axis there are 3 different possible sets of data that can be "pulled" out of the database.

Data Sets
---------
1. Numerical value <> 0
2. Numerical value = 0
3. <NULL>

Data Set #1
-----------
Data set #1 is fine whenever there is a negative or positive number in the database not equal to zero it passes the value to the x-axis bar chart and life is good.

Data Set #2 and #3
------------------
This is the catch, I have to be able to VISUALLY display on the chart weather a charted x-axis value is a ZERO or a <NULL>.

Any ideas?

Thank you.

Victor Thomas

 
How would a NULL be represented as opposed to a zero?

You're graphing on numeric values, null is not a numeric value, hence your dilema.

But you can't state that you want to use a non number with numbers and not state how that might be repesented diffferently from a zero...

Perhaps you can alter these values to -99999 or some such and use the formula instead of the field in your graph.

-k
 
My Client is adamant that I don't use a &quot;-99999&quot; or some other such identifier hence my dilema.

I did some CR KB surfing and found c2005689


and of this code I did a spin off of sorts:

if Maximum ({@Oswestry Null Detector [713,718,719,720]}, {PATIENTS.LASTNAME}) = true then
lcase({PATIENTS.LASTNAME}) else
if Maximum ({@Oswestry Null Detector [713,718,719,720]}, {PATIENTS.LASTNAME}) = false then
ucase({PATIENTS.LASTNAME})

I discovered that I could intercept the x-axis values ({PATIENTS.LASTNAME}) and alter its appearance per numerical value Oswestry (measure of patient diability) using what I call a <NULL> detector.

I could assign ucase() or lcase() to ({PATIENTS.LASTNAME})if Oswestry was a null. That works fine, the graph prints and assigns an ucase() or lcase to the ({PATIENTS.LASTNAME}) in the x-axis.

BUT.... Client says it's TOO hard to read, which honestly it is especially on a busy chart.

My dilema is if I intercept and alter the actual content of ({PATIENTS.LASTNAME}) in anyway example:

if isnull(oswestry) then
x_axis_lastname := ({PATIENTS.LASTNAME}) + &quot;<NULL>&quot;

which will change the value of a string &quot;thomas&quot; to &quot;thomas <NULL>&quot;.

I found out that drives CR haywire and I get some nasty looking graphs.

Do you know any work around?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top