Jump to content
Software FX Community

Sorting issue on Crosstab charts


User (Legacy)
 Share

Recommended Posts

This is the normal behavior of Crosstab. With the Crosstab provider, the 

values in the column identified as Column Heading are transformed into

series. The order of the series is taken from their appearance order in the

provided resultset. For example, suppose you have configured a Crosstab

provider with the following column's configuration:

Date: RowHeading

Product: ColumnHeading

Sales: Value

With the following data you will obtain a chart with 3 series in the

following order -> Car, Bike, Boat:

Date Product Sales

1/1/2004 Car 1000

1/1/2004 Bike 1500

1/1/2004 Boat 500

1/2/2004 Bike 300

1/2/2004 Boat 800

1/2/2004 Car 500

1/3/2004 Boat 700

However, if you simply remove the first entry, then the series order will

change to Bike, Boat, Car since the resulting data will look like:

Date Product Sales

1/1/2004 Bike 1500

1/1/2004 Boat 500

1/2/2004 Bike 300

1/2/2004 Boat 800

1/2/2004 Car 500

1/3/2004 Boat 700

In this sample I used product's names, but I could have replaced it by

numbers and it wouldn't make a difference, since values in ColumnHeading are

treated as strings.

If you want to make sure your series are sorted in a particular order, you

must order the dataset by RowHeading + ColumnHeading (e.g. Date + Product,

in the sample above) and make sure all the possible ColumnHeading values

appear in the first RowHeading entry. In some cases you will need to add an

entry with value 0.

---

IG

Software FX

"Daniel Reber" <dreber@nospam.com> wrote in message

news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

> One of my clients pointed out a sorting issue on Crosstab charts. Notice

> in

> the attachment named numbering_issue that the series field is sorted 2, 1,

> 3. If I remove the first X-Axis value, "BATH COUNTY COMMUNITY HOSPITAL"

> the

> values are sorted (see without_first_hosp) correctly. Is this a known

> issue?

>

> Thanks

>

> Daniel Reber

>

>

>

Link to comment
Share on other sites

Thanks for your response...

I already have it grouped and sorted the way that you suggested.

What do you mean by "In some cases you will need to add an entry with value

0"

Thanks

Dan Reber

"Software FX Support" <support@softwarefx.com> wrote in message

news:cOeGGiznEHA.420@webserver3.softwarefx.com...

> This is the normal behavior of Crosstab. With the Crosstab provider, the

> values in the column identified as Column Heading are transformed into

> series. The order of the series is taken from their appearance order in

the

> provided resultset. For example, suppose you have configured a Crosstab

> provider with the following column's configuration:

>

> Date: RowHeading

> Product: ColumnHeading

> Sales: Value

>

> With the following data you will obtain a chart with 3 series in the

> following order -> Car, Bike, Boat:

>

> Date Product Sales

> 1/1/2004 Car 1000

> 1/1/2004 Bike 1500

> 1/1/2004 Boat 500

> 1/2/2004 Bike 300

> 1/2/2004 Boat 800

> 1/2/2004 Car 500

> 1/3/2004 Boat 700

>

> However, if you simply remove the first entry, then the series order will

> change to Bike, Boat, Car since the resulting data will look like:

>

> Date Product Sales

> 1/1/2004 Bike 1500

> 1/1/2004 Boat 500

> 1/2/2004 Bike 300

> 1/2/2004 Boat 800

> 1/2/2004 Car 500

> 1/3/2004 Boat 700

>

> In this sample I used product's names, but I could have replaced it by

> numbers and it wouldn't make a difference, since values in ColumnHeading

are

> treated as strings.

>

> If you want to make sure your series are sorted in a particular order, you

> must order the dataset by RowHeading + ColumnHeading (e.g. Date + Product,

> in the sample above) and make sure all the possible ColumnHeading values

> appear in the first RowHeading entry. In some cases you will need to add

an

> entry with value 0.

> ---

> IG

> Software FX

>

> "Daniel Reber" <dreber@nospam.com> wrote in message

> news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

> > One of my clients pointed out a sorting issue on Crosstab charts.

Notice

> > in

> > the attachment named numbering_issue that the series field is sorted 2,

1,

> > 3. If I remove the first X-Axis value, "BATH COUNTY COMMUNITY HOSPITAL"

> > the

> > values are sorted (see without_first_hosp) correctly. Is this a known

> > issue?

> >

> > Thanks

> >

> > Daniel Reber

> >

> >

> >

>

>

Link to comment
Share on other sites

For example, if your data doesn't show the value '1' in the first group of

RowHeadings, it will not show up first. So, in this case, you will need to

add it to the recordset with value 0, in order to show up first in the list

of series.

---

IG

Software FX

"Daniel Reber" <dreber@nospam.com> wrote in message

news:9aPiTt0nEHA.420@webserver3.softwarefx.com...

> Thanks for your response...

>

> I already have it grouped and sorted the way that you suggested.

>

> What do you mean by "In some cases you will need to add an entry with

value

> 0"

>

> Thanks

>

> Dan Reber

>

>

>

> "Software FX Support" <support@softwarefx.com> wrote in message

> news:cOeGGiznEHA.420@webserver3.softwarefx.com...

> > This is the normal behavior of Crosstab. With the Crosstab provider, the

> > values in the column identified as Column Heading are transformed into

> > series. The order of the series is taken from their appearance order in

> the

> > provided resultset. For example, suppose you have configured a Crosstab

> > provider with the following column's configuration:

> >

> > Date: RowHeading

> > Product: ColumnHeading

> > Sales: Value

> >

> > With the following data you will obtain a chart with 3 series in the

> > following order -> Car, Bike, Boat:

> >

> > Date Product Sales

> > 1/1/2004 Car 1000

> > 1/1/2004 Bike 1500

> > 1/1/2004 Boat 500

> > 1/2/2004 Bike 300

> > 1/2/2004 Boat 800

> > 1/2/2004 Car 500

> > 1/3/2004 Boat 700

> >

> > However, if you simply remove the first entry, then the series order

will

> > change to Bike, Boat, Car since the resulting data will look like:

> >

> > Date Product Sales

> > 1/1/2004 Bike 1500

> > 1/1/2004 Boat 500

> > 1/2/2004 Bike 300

> > 1/2/2004 Boat 800

> > 1/2/2004 Car 500

> > 1/3/2004 Boat 700

> >

> > In this sample I used product's names, but I could have replaced it by

> > numbers and it wouldn't make a difference, since values in ColumnHeading

> are

> > treated as strings.

> >

> > If you want to make sure your series are sorted in a particular order,

you

> > must order the dataset by RowHeading + ColumnHeading (e.g. Date +

Product,

> > in the sample above) and make sure all the possible ColumnHeading values

> > appear in the first RowHeading entry. In some cases you will need to add

> an

> > entry with value 0.

> > ---

> > IG

> > Software FX

> >

> > "Daniel Reber" <dreber@nospam.com> wrote in message

> > news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

> > > One of my clients pointed out a sorting issue on Crosstab charts.

> Notice

> > > in

> > > the attachment named numbering_issue that the series field is sorted

2,

> 1,

> > > 3. If I remove the first X-Axis value, "BATH COUNTY COMMUNITY

HOSPITAL"

> > > the

> > > values are sorted (see without_first_hosp) correctly. Is this a known

> > > issue?

> > >

> > > Thanks

> > >

> > > Daniel Reber

> > >

> > >

> > >

> >

> >

>

>

Link to comment
Share on other sites

So I need to:

1. Get distinct values for the column heading.

2. Add a row for every missing distinct ColumnHeading value of the first

RowHeading value, to the recordset.

3. Sort the recordset by RowHeading field, ColumnHeading field. <-- Not sure

if this step is needed

For example, in the example that I sent you I will need to add two rows:

"BATH COUNTY COMMUNITY HOSPITAL" 1 0

"BATH COUNTY COMMUNITY HOSPITAL" 3 0

and then sort the recordset:

rs.sort = "[hosp_name] ASC, [period] ASC"

Is that correct?

Thanks

Dan

"Software FX Support" <noreply> wrote in message

news:B3kSzY8nEHA.416@webserver3.softwarefx.com...

> For example, if your data doesn't show the value '1' in the first group of

> RowHeadings, it will not show up first. So, in this case, you will need to

> add it to the recordset with value 0, in order to show up first in the

list

> of series.

> ---

> IG

> Software FX

>

> "Daniel Reber" <dreber@nospam.com> wrote in message

> news:9aPiTt0nEHA.420@webserver3.softwarefx.com...

> > Thanks for your response...

> >

> > I already have it grouped and sorted the way that you suggested.

> >

> > What do you mean by "In some cases you will need to add an entry with

> value

> > 0"

> >

> > Thanks

> >

> > Dan Reber

> >

> >

> >

> > "Software FX Support" <support@softwarefx.com> wrote in message

> > news:cOeGGiznEHA.420@webserver3.softwarefx.com...

> > > This is the normal behavior of Crosstab. With the Crosstab provider,

the

> > > values in the column identified as Column Heading are transformed into

> > > series. The order of the series is taken from their appearance order

in

> > the

> > > provided resultset. For example, suppose you have configured a

Crosstab

> > > provider with the following column's configuration:

> > >

> > > Date: RowHeading

> > > Product: ColumnHeading

> > > Sales: Value

> > >

> > > With the following data you will obtain a chart with 3 series in the

> > > following order -> Car, Bike, Boat:

> > >

> > > Date Product Sales

> > > 1/1/2004 Car 1000

> > > 1/1/2004 Bike 1500

> > > 1/1/2004 Boat 500

> > > 1/2/2004 Bike 300

> > > 1/2/2004 Boat 800

> > > 1/2/2004 Car 500

> > > 1/3/2004 Boat 700

> > >

> > > However, if you simply remove the first entry, then the series order

> will

> > > change to Bike, Boat, Car since the resulting data will look like:

> > >

> > > Date Product Sales

> > > 1/1/2004 Bike 1500

> > > 1/1/2004 Boat 500

> > > 1/2/2004 Bike 300

> > > 1/2/2004 Boat 800

> > > 1/2/2004 Car 500

> > > 1/3/2004 Boat 700

> > >

> > > In this sample I used product's names, but I could have replaced it by

> > > numbers and it wouldn't make a difference, since values in

ColumnHeading

> > are

> > > treated as strings.

> > >

> > > If you want to make sure your series are sorted in a particular order,

> you

> > > must order the dataset by RowHeading + ColumnHeading (e.g. Date +

> Product,

> > > in the sample above) and make sure all the possible ColumnHeading

values

> > > appear in the first RowHeading entry. In some cases you will need to

add

> > an

> > > entry with value 0.

> > > ---

> > > IG

> > > Software FX

> > >

> > > "Daniel Reber" <dreber@nospam.com> wrote in message

> > > news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

> > > > One of my clients pointed out a sorting issue on Crosstab charts.

> > Notice

> > > > in

> > > > the attachment named numbering_issue that the series field is sorted

> 2,

> > 1,

> > > > 3. If I remove the first X-Axis value, "BATH COUNTY COMMUNITY

> HOSPITAL"

> > > > the

> > > > values are sorted (see without_first_hosp) correctly. Is this a

known

> > > > issue?

> > > >

> > > > Thanks

> > > >

> > > > Daniel Reber

> > > >

> > > >

> > > >

> > >

> > >

> >

> >

>

>

Link to comment
Share on other sites

That is correct. The third step is needed too.

---

IG

Software FX

"Daniel Reber" <dreber@nospam.com> wrote in message

news:SRnU0k9nEHA.416@webserver3.softwarefx.com...

> So I need to:

> 1. Get distinct values for the column heading.

> 2. Add a row for every missing distinct ColumnHeading value of the first

> RowHeading value, to the recordset.

> 3. Sort the recordset by RowHeading field, ColumnHeading field. <-- Not

sure

> if this step is needed

>

> For example, in the example that I sent you I will need to add two rows:

>

> "BATH COUNTY COMMUNITY HOSPITAL" 1 0

> "BATH COUNTY COMMUNITY HOSPITAL" 3 0

>

> and then sort the recordset:

>

> rs.sort = "[hosp_name] ASC, [period] ASC"

>

> Is that correct?

>

> Thanks

>

> Dan

>

>

> "Software FX Support" <noreply> wrote in message

> news:B3kSzY8nEHA.416@webserver3.softwarefx.com...

> > For example, if your data doesn't show the value '1' in the first group

of

> > RowHeadings, it will not show up first. So, in this case, you will need

to

> > add it to the recordset with value 0, in order to show up first in the

> list

> > of series.

> > ---

> > IG

> > Software FX

> >

> > "Daniel Reber" <dreber@nospam.com> wrote in message

> > news:9aPiTt0nEHA.420@webserver3.softwarefx.com...

> > > Thanks for your response...

> > >

> > > I already have it grouped and sorted the way that you suggested.

> > >

> > > What do you mean by "In some cases you will need to add an entry with

> > value

> > > 0"

> > >

> > > Thanks

> > >

> > > Dan Reber

> > >

> > >

> > >

> > > "Software FX Support" <support@softwarefx.com> wrote in message

> > > news:cOeGGiznEHA.420@webserver3.softwarefx.com...

> > > > This is the normal behavior of Crosstab. With the Crosstab provider,

> the

> > > > values in the column identified as Column Heading are transformed

into

> > > > series. The order of the series is taken from their appearance order

> in

> > > the

> > > > provided resultset. For example, suppose you have configured a

> Crosstab

> > > > provider with the following column's configuration:

> > > >

> > > > Date: RowHeading

> > > > Product: ColumnHeading

> > > > Sales: Value

> > > >

> > > > With the following data you will obtain a chart with 3 series in the

> > > > following order -> Car, Bike, Boat:

> > > >

> > > > Date Product Sales

> > > > 1/1/2004 Car 1000

> > > > 1/1/2004 Bike 1500

> > > > 1/1/2004 Boat 500

> > > > 1/2/2004 Bike 300

> > > > 1/2/2004 Boat 800

> > > > 1/2/2004 Car 500

> > > > 1/3/2004 Boat 700

> > > >

> > > > However, if you simply remove the first entry, then the series order

> > will

> > > > change to Bike, Boat, Car since the resulting data will look like:

> > > >

> > > > Date Product Sales

> > > > 1/1/2004 Bike 1500

> > > > 1/1/2004 Boat 500

> > > > 1/2/2004 Bike 300

> > > > 1/2/2004 Boat 800

> > > > 1/2/2004 Car 500

> > > > 1/3/2004 Boat 700

> > > >

> > > > In this sample I used product's names, but I could have replaced it

by

> > > > numbers and it wouldn't make a difference, since values in

> ColumnHeading

> > > are

> > > > treated as strings.

> > > >

> > > > If you want to make sure your series are sorted in a particular

order,

> > you

> > > > must order the dataset by RowHeading + ColumnHeading (e.g. Date +

> > Product,

> > > > in the sample above) and make sure all the possible ColumnHeading

> values

> > > > appear in the first RowHeading entry. In some cases you will need to

> add

> > > an

> > > > entry with value 0.

> > > > ---

> > > > IG

> > > > Software FX

> > > >

> > > > "Daniel Reber" <dreber@nospam.com> wrote in message

> > > > news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

> > > > > One of my clients pointed out a sorting issue on Crosstab charts.

> > > Notice

> > > > > in

> > > > > the attachment named numbering_issue that the series field is

sorted

> > 2,

> > > 1,

> > > > > 3. If I remove the first X-Axis value, "BATH COUNTY COMMUNITY

> > HOSPITAL"

> > > > > the

> > > > > values are sorted (see without_first_hosp) correctly. Is this a

> known

> > > > > issue?

> > > > >

> > > > > Thanks

> > > > >

> > > > > Daniel Reber

> > > > >

> > > > >

> > > > >

> > > >

> > > >

> > >

> > >

> >

> >

>

>

Link to comment
Share on other sites

Hmmm...you have a great product but I think that this is a pretty hefty

workaround for something that should be part of the control.

Also, I have an issue with adding data to a data analysis application. Our

clients are primarily hospitals, and some of the analysis that they will be

going is to see what the morbidity (death) and infection rates that each of

their sites have. They will be jumping up and down if they see that one of

their sites has a rate of "0" for either case. Can a NULL be used instead?

For example:

"BATH COUNTY COMMUNITY HOSPITAL" 1 NULL

"BATH COUNTY COMMUNITY HOSPITAL" 3 NULL

If it can be done how will the NULL be displayed?

Thanks

Dan Reber

"Software FX Support" <noreply> wrote in message

news:HadJfEFoEHA.416@webserver3.softwarefx.com...

> That is correct. The third step is needed too.

> ---

> IG

> Software FX

>

> "Daniel Reber" <dreber@nospam.com> wrote in message

> news:SRnU0k9nEHA.416@webserver3.softwarefx.com...

> > So I need to:

> > 1. Get distinct values for the column heading.

> > 2. Add a row for every missing distinct ColumnHeading value of the first

> > RowHeading value, to the recordset.

> > 3. Sort the recordset by RowHeading field, ColumnHeading field. <-- Not

> sure

> > if this step is needed

> >

> > For example, in the example that I sent you I will need to add two rows:

> >

> > "BATH COUNTY COMMUNITY HOSPITAL" 1 0

> > "BATH COUNTY COMMUNITY HOSPITAL" 3 0

> >

> > and then sort the recordset:

> >

> > rs.sort = "[hosp_name] ASC, [period] ASC"

> >

> > Is that correct?

> >

> > Thanks

> >

> > Dan

> >

> >

> > "Software FX Support" <noreply> wrote in message

> > news:B3kSzY8nEHA.416@webserver3.softwarefx.com...

> > > For example, if your data doesn't show the value '1' in the first

group

> of

> > > RowHeadings, it will not show up first. So, in this case, you will

need

> to

> > > add it to the recordset with value 0, in order to show up first in the

> > list

> > > of series.

> > > ---

> > > IG

> > > Software FX

> > >

> > > "Daniel Reber" <dreber@nospam.com> wrote in message

> > > news:9aPiTt0nEHA.420@webserver3.softwarefx.com...

> > > > Thanks for your response...

> > > >

> > > > I already have it grouped and sorted the way that you suggested.

> > > >

> > > > What do you mean by "In some cases you will need to add an entry

with

> > > value

> > > > 0"

> > > >

> > > > Thanks

> > > >

> > > > Dan Reber

> > > >

> > > >

> > > >

> > > > "Software FX Support" <support@softwarefx.com> wrote in message

> > > > news:cOeGGiznEHA.420@webserver3.softwarefx.com...

> > > > > This is the normal behavior of Crosstab. With the Crosstab

provider,

> > the

> > > > > values in the column identified as Column Heading are transformed

> into

> > > > > series. The order of the series is taken from their appearance

order

> > in

> > > > the

> > > > > provided resultset. For example, suppose you have configured a

> > Crosstab

> > > > > provider with the following column's configuration:

> > > > >

> > > > > Date: RowHeading

> > > > > Product: ColumnHeading

> > > > > Sales: Value

> > > > >

> > > > > With the following data you will obtain a chart with 3 series in

the

> > > > > following order -> Car, Bike, Boat:

> > > > >

> > > > > Date Product Sales

> > > > > 1/1/2004 Car 1000

> > > > > 1/1/2004 Bike 1500

> > > > > 1/1/2004 Boat 500

> > > > > 1/2/2004 Bike 300

> > > > > 1/2/2004 Boat 800

> > > > > 1/2/2004 Car 500

> > > > > 1/3/2004 Boat 700

> > > > >

> > > > > However, if you simply remove the first entry, then the series

order

> > > will

> > > > > change to Bike, Boat, Car since the resulting data will look like:

> > > > >

> > > > > Date Product Sales

> > > > > 1/1/2004 Bike 1500

> > > > > 1/1/2004 Boat 500

> > > > > 1/2/2004 Bike 300

> > > > > 1/2/2004 Boat 800

> > > > > 1/2/2004 Car 500

> > > > > 1/3/2004 Boat 700

> > > > >

> > > > > In this sample I used product's names, but I could have replaced

it

> by

> > > > > numbers and it wouldn't make a difference, since values in

> > ColumnHeading

> > > > are

> > > > > treated as strings.

> > > > >

> > > > > If you want to make sure your series are sorted in a particular

> order,

> > > you

> > > > > must order the dataset by RowHeading + ColumnHeading (e.g. Date +

> > > Product,

> > > > > in the sample above) and make sure all the possible ColumnHeading

> > values

> > > > > appear in the first RowHeading entry. In some cases you will need

to

> > add

> > > > an

> > > > > entry with value 0.

> > > > > ---

> > > > > IG

> > > > > Software FX

> > > > >

> > > > > "Daniel Reber" <dreber@nospam.com> wrote in message

> > > > > news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

> > > > > > One of my clients pointed out a sorting issue on Crosstab

charts.

> > > > Notice

> > > > > > in

> > > > > > the attachment named numbering_issue that the series field is

> sorted

> > > 2,

> > > > 1,

> > > > > > 3. If I remove the first X-Axis value, "BATH COUNTY COMMUNITY

> > > HOSPITAL"

> > > > > > the

> > > > > > values are sorted (see without_first_hosp) correctly. Is this a

> > known

> > > > > > issue?

> > > > > >

> > > > > > Thanks

> > > > > >

> > > > > > Daniel Reber

> > > > > >

> > > > > >

> > > > > >

> > > > >

> > > > >

> > > >

> > > >

> > >

> > >

> >

> >

>

>

Link to comment
Share on other sites

For Chart FX, all the series names are strings and thus it does nothing with 

its order, i.e. a series called '1' is the same as a series called 'Car',

and not necessarily everyone will want the series sorted alphabetically. We

have plans to support series ordering in a future release of Chart FX.

On the other hand, your suggestion of using NULL instead of 0 will do the

trick without adding an unneeded extra value of 0 to your chart.

---

IG

Software FX

"Daniel Reber" <dreber@nospam.com> wrote in message

news:46i2$CKoEHA.3352@webserver3.softwarefx.com...

> Hmmm...you have a great product but I think that this is a pretty hefty

> workaround for something that should be part of the control.

>

> Also, I have an issue with adding data to a data analysis application.

> Our

> clients are primarily hospitals, and some of the analysis that they will

> be

> going is to see what the morbidity (death) and infection rates that each

> of

> their sites have. They will be jumping up and down if they see that one

> of

> their sites has a rate of "0" for either case. Can a NULL be used

> instead?

>

> For example:

>

> "BATH COUNTY COMMUNITY HOSPITAL" 1 NULL

> "BATH COUNTY COMMUNITY HOSPITAL" 3 NULL

>

> If it can be done how will the NULL be displayed?

>

> Thanks

>

> Dan Reber

>

>

> "Software FX Support" <noreply> wrote in message

> news:HadJfEFoEHA.416@webserver3.softwarefx.com...

>> That is correct. The third step is needed too.

>> ---

>> IG

>> Software FX

>>

>> "Daniel Reber" <dreber@nospam.com> wrote in message

>> news:SRnU0k9nEHA.416@webserver3.softwarefx.com...

>> > So I need to:

>> > 1. Get distinct values for the column heading.

>> > 2. Add a row for every missing distinct ColumnHeading value of the

>> > first

>> > RowHeading value, to the recordset.

>> > 3. Sort the recordset by RowHeading field, ColumnHeading field. <-- Not

>> sure

>> > if this step is needed

>> >

>> > For example, in the example that I sent you I will need to add two

>> > rows:

>> >

>> > "BATH COUNTY COMMUNITY HOSPITAL" 1 0

>> > "BATH COUNTY COMMUNITY HOSPITAL" 3 0

>> >

>> > and then sort the recordset:

>> >

>> > rs.sort = "[hosp_name] ASC, [period] ASC"

>> >

>> > Is that correct?

>> >

>> > Thanks

>> >

>> > Dan

>> >

>> >

>> > "Software FX Support" <noreply> wrote in message

>> > news:B3kSzY8nEHA.416@webserver3.softwarefx.com...

>> > > For example, if your data doesn't show the value '1' in the first

> group

>> of

>> > > RowHeadings, it will not show up first. So, in this case, you will

> need

>> to

>> > > add it to the recordset with value 0, in order to show up first in

>> > > the

>> > list

>> > > of series.

>> > > ---

>> > > IG

>> > > Software FX

>> > >

>> > > "Daniel Reber" <dreber@nospam.com> wrote in message

>> > > news:9aPiTt0nEHA.420@webserver3.softwarefx.com...

>> > > > Thanks for your response...

>> > > >

>> > > > I already have it grouped and sorted the way that you suggested.

>> > > >

>> > > > What do you mean by "In some cases you will need to add an entry

> with

>> > > value

>> > > > 0"

>> > > >

>> > > > Thanks

>> > > >

>> > > > Dan Reber

>> > > >

>> > > >

>> > > >

>> > > > "Software FX Support" <support@softwarefx.com> wrote in message

>> > > > news:cOeGGiznEHA.420@webserver3.softwarefx.com...

>> > > > > This is the normal behavior of Crosstab. With the Crosstab

> provider,

>> > the

>> > > > > values in the column identified as Column Heading are transformed

>> into

>> > > > > series. The order of the series is taken from their appearance

> order

>> > in

>> > > > the

>> > > > > provided resultset. For example, suppose you have configured a

>> > Crosstab

>> > > > > provider with the following column's configuration:

>> > > > >

>> > > > > Date: RowHeading

>> > > > > Product: ColumnHeading

>> > > > > Sales: Value

>> > > > >

>> > > > > With the following data you will obtain a chart with 3 series in

> the

>> > > > > following order -> Car, Bike, Boat:

>> > > > >

>> > > > > Date Product Sales

>> > > > > 1/1/2004 Car 1000

>> > > > > 1/1/2004 Bike 1500

>> > > > > 1/1/2004 Boat 500

>> > > > > 1/2/2004 Bike 300

>> > > > > 1/2/2004 Boat 800

>> > > > > 1/2/2004 Car 500

>> > > > > 1/3/2004 Boat 700

>> > > > >

>> > > > > However, if you simply remove the first entry, then the series

> order

>> > > will

>> > > > > change to Bike, Boat, Car since the resulting data will look

>> > > > > like:

>> > > > >

>> > > > > Date Product Sales

>> > > > > 1/1/2004 Bike 1500

>> > > > > 1/1/2004 Boat 500

>> > > > > 1/2/2004 Bike 300

>> > > > > 1/2/2004 Boat 800

>> > > > > 1/2/2004 Car 500

>> > > > > 1/3/2004 Boat 700

>> > > > >

>> > > > > In this sample I used product's names, but I could have replaced

> it

>> by

>> > > > > numbers and it wouldn't make a difference, since values in

>> > ColumnHeading

>> > > > are

>> > > > > treated as strings.

>> > > > >

>> > > > > If you want to make sure your series are sorted in a particular

>> order,

>> > > you

>> > > > > must order the dataset by RowHeading + ColumnHeading (e.g. Date +

>> > > Product,

>> > > > > in the sample above) and make sure all the possible ColumnHeading

>> > values

>> > > > > appear in the first RowHeading entry. In some cases you will need

> to

>> > add

>> > > > an

>> > > > > entry with value 0.

>> > > > > ---

>> > > > > IG

>> > > > > Software FX

>> > > > >

>> > > > > "Daniel Reber" <dreber@nospam.com> wrote in message

>> > > > > news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

>> > > > > > One of my clients pointed out a sorting issue on Crosstab

> charts.

>> > > > Notice

>> > > > > > in

>> > > > > > the attachment named numbering_issue that the series field is

>> sorted

>> > > 2,

>> > > > 1,

>> > > > > > 3. If I remove the first X-Axis value, "BATH COUNTY COMMUNITY

>> > > HOSPITAL"

>> > > > > > the

>> > > > > > values are sorted (see without_first_hosp) correctly. Is this

>> > > > > > a

>> > known

>> > > > > > issue?

>> > > > > >

>> > > > > > Thanks

>> > > > > >

>> > > > > > Daniel Reber

>> > > > > >

>> > > > > >

>> > > > > >

>> > > > >

>> > > > >

>> > > >

>> > > >

>> > >

>> > >

>> >

>> >

>>

>>

>

>

Link to comment
Share on other sites

OK, thanks for your help.

Dan

"Software FX Support" <support@softwarefx.com> wrote in message

news:P%238pHYkoEHA.420@webserver3.softwarefx.com...

> For Chart FX, all the series names are strings and thus it does nothing

with

> its order, i.e. a series called '1' is the same as a series called 'Car',

> and not necessarily everyone will want the series sorted alphabetically.

We

> have plans to support series ordering in a future release of Chart FX.

>

>

>

> On the other hand, your suggestion of using NULL instead of 0 will do the

> trick without adding an unneeded extra value of 0 to your chart.

>

> ---

>

> IG

>

> Software FX

>

>

>

> "Daniel Reber" <dreber@nospam.com> wrote in message

> news:46i2$CKoEHA.3352@webserver3.softwarefx.com...

> > Hmmm...you have a great product but I think that this is a pretty hefty

> > workaround for something that should be part of the control.

> >

> > Also, I have an issue with adding data to a data analysis application.

> > Our

> > clients are primarily hospitals, and some of the analysis that they will

> > be

> > going is to see what the morbidity (death) and infection rates that

each

> > of

> > their sites have. They will be jumping up and down if they see that one

> > of

> > their sites has a rate of "0" for either case. Can a NULL be used

> > instead?

> >

> > For example:

> >

> > "BATH COUNTY COMMUNITY HOSPITAL" 1 NULL

> > "BATH COUNTY COMMUNITY HOSPITAL" 3 NULL

> >

> > If it can be done how will the NULL be displayed?

> >

> > Thanks

> >

> > Dan Reber

> >

> >

> > "Software FX Support" <noreply> wrote in message

> > news:HadJfEFoEHA.416@webserver3.softwarefx.com...

> >> That is correct. The third step is needed too.

> >> ---

> >> IG

> >> Software FX

> >>

> >> "Daniel Reber" <dreber@nospam.com> wrote in message

> >> news:SRnU0k9nEHA.416@webserver3.softwarefx.com...

> >> > So I need to:

> >> > 1. Get distinct values for the column heading.

> >> > 2. Add a row for every missing distinct ColumnHeading value of the

> >> > first

> >> > RowHeading value, to the recordset.

> >> > 3. Sort the recordset by RowHeading field, ColumnHeading field. <--

Not

> >> sure

> >> > if this step is needed

> >> >

> >> > For example, in the example that I sent you I will need to add two

> >> > rows:

> >> >

> >> > "BATH COUNTY COMMUNITY HOSPITAL" 1 0

> >> > "BATH COUNTY COMMUNITY HOSPITAL" 3 0

> >> >

> >> > and then sort the recordset:

> >> >

> >> > rs.sort = "[hosp_name] ASC, [period] ASC"

> >> >

> >> > Is that correct?

> >> >

> >> > Thanks

> >> >

> >> > Dan

> >> >

> >> >

> >> > "Software FX Support" <noreply> wrote in message

> >> > news:B3kSzY8nEHA.416@webserver3.softwarefx.com...

> >> > > For example, if your data doesn't show the value '1' in the first

> > group

> >> of

> >> > > RowHeadings, it will not show up first. So, in this case, you will

> > need

> >> to

> >> > > add it to the recordset with value 0, in order to show up first in

> >> > > the

> >> > list

> >> > > of series.

> >> > > ---

> >> > > IG

> >> > > Software FX

> >> > >

> >> > > "Daniel Reber" <dreber@nospam.com> wrote in message

> >> > > news:9aPiTt0nEHA.420@webserver3.softwarefx.com...

> >> > > > Thanks for your response...

> >> > > >

> >> > > > I already have it grouped and sorted the way that you suggested.

> >> > > >

> >> > > > What do you mean by "In some cases you will need to add an entry

> > with

> >> > > value

> >> > > > 0"

> >> > > >

> >> > > > Thanks

> >> > > >

> >> > > > Dan Reber

> >> > > >

> >> > > >

> >> > > >

> >> > > > "Software FX Support" <support@softwarefx.com> wrote in message

> >> > > > news:cOeGGiznEHA.420@webserver3.softwarefx.com...

> >> > > > > This is the normal behavior of Crosstab. With the Crosstab

> > provider,

> >> > the

> >> > > > > values in the column identified as Column Heading are

transformed

> >> into

> >> > > > > series. The order of the series is taken from their appearance

> > order

> >> > in

> >> > > > the

> >> > > > > provided resultset. For example, suppose you have configured a

> >> > Crosstab

> >> > > > > provider with the following column's configuration:

> >> > > > >

> >> > > > > Date: RowHeading

> >> > > > > Product: ColumnHeading

> >> > > > > Sales: Value

> >> > > > >

> >> > > > > With the following data you will obtain a chart with 3 series

in

> > the

> >> > > > > following order -> Car, Bike, Boat:

> >> > > > >

> >> > > > > Date Product Sales

> >> > > > > 1/1/2004 Car 1000

> >> > > > > 1/1/2004 Bike 1500

> >> > > > > 1/1/2004 Boat 500

> >> > > > > 1/2/2004 Bike 300

> >> > > > > 1/2/2004 Boat 800

> >> > > > > 1/2/2004 Car 500

> >> > > > > 1/3/2004 Boat 700

> >> > > > >

> >> > > > > However, if you simply remove the first entry, then the series

> > order

> >> > > will

> >> > > > > change to Bike, Boat, Car since the resulting data will look

> >> > > > > like:

> >> > > > >

> >> > > > > Date Product Sales

> >> > > > > 1/1/2004 Bike 1500

> >> > > > > 1/1/2004 Boat 500

> >> > > > > 1/2/2004 Bike 300

> >> > > > > 1/2/2004 Boat 800

> >> > > > > 1/2/2004 Car 500

> >> > > > > 1/3/2004 Boat 700

> >> > > > >

> >> > > > > In this sample I used product's names, but I could have

replaced

> > it

> >> by

> >> > > > > numbers and it wouldn't make a difference, since values in

> >> > ColumnHeading

> >> > > > are

> >> > > > > treated as strings.

> >> > > > >

> >> > > > > If you want to make sure your series are sorted in a particular

> >> order,

> >> > > you

> >> > > > > must order the dataset by RowHeading + ColumnHeading (e.g. Date

+

> >> > > Product,

> >> > > > > in the sample above) and make sure all the possible

ColumnHeading

> >> > values

> >> > > > > appear in the first RowHeading entry. In some cases you will

need

> > to

> >> > add

> >> > > > an

> >> > > > > entry with value 0.

> >> > > > > ---

> >> > > > > IG

> >> > > > > Software FX

> >> > > > >

> >> > > > > "Daniel Reber" <dreber@nospam.com> wrote in message

> >> > > > > news:r1fCvPOnEHA.420@webserver3.softwarefx.com...

> >> > > > > > One of my clients pointed out a sorting issue on Crosstab

> > charts.

> >> > > > Notice

> >> > > > > > in

> >> > > > > > the attachment named numbering_issue that the series field is

> >> sorted

> >> > > 2,

> >> > > > 1,

> >> > > > > > 3. If I remove the first X-Axis value, "BATH COUNTY

COMMUNITY

> >> > > HOSPITAL"

> >> > > > > > the

> >> > > > > > values are sorted (see without_first_hosp) correctly. Is

this

> >> > > > > > a

> >> > known

> >> > > > > > issue?

> >> > > > > >

> >> > > > > > Thanks

> >> > > > > >

> >> > > > > > Daniel Reber

> >> > > > > >

> >> > > > > >

> >> > > > > >

> >> > > > >

> >> > > > >

> >> > > >

> >> > > >

> >> > >

> >> > >

> >> >

> >> >

> >>

> >>

> >

> >

>

>

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...