Victor,
I would change my link fields to be a field with a combination of the firm
name and a unique ID number concatenated together, rather than just the ID
number. This field would auto-calculate in panel 1 so if the firm name
changed it would update automatically. The link to panel 2 would be set to
cascade changes so the link wouldn't get broken by a firm name change.
Presumably you already have a pile of data in this database that you don't
want to lose. So you'll need to make this change in some steps.
1) Make a good backup first.
2) Export all data from each panel using the 'Built-In Subreport' to a
unique file for each panel. Make sure it's in WP format so it can be
reimported later.
3) Delete data from both panels so you can play with the fields.
4) Create a new field in each panel with the same format, something like
A50. The field should be as long as the length of the firm name field plus
the number of digits in your ID field. Create new indexes in both Panels
using the new fields (just like the indexes that used the old ID number
field). Don't delete the old ID number fields or indexes yet. Also don't
change the edit order of the fields yet.
5) In panel 1, give this new field a formula to update on any change. The
formula would be:
cat.c[P1F1;apply.format["G999999";P1F2]]
(assuming P1F1 is the firm name field and P1F2 is the numeric ID field (you
may need to adjust the format for the number of digits in your field).
6) Set up new links between the panels based on the new fields, similar to
what you had using the ID number fields.
7) Reimport your data back into the panels.
8) Create a temporary report to update each of the records in panel 2. The
report should go through the old link on the ID number to grab the contents
of the new field in panel 1 and save it into the new field in panel 2.
9) Now test your new links from both panels and make sure they work
correctly.
10) At this point you could delete the indexes and links using the old ID
number and you could delete the ID number field from Panel 2 (but not from
Panel 1 since it's still used to calculate our new field's value).
I haven't gone into a lot of detail with these steps but you should have the
general idea. Hopefully this will help.
Tim Rude
----- Original Message -----
From: "Victor Warner" <[EMAIL PROTECTED]>
To: "DataPerfect Users Discussion Group" <[email protected]>
Sent: Monday, August 21, 2006 10:34 AM
Subject: Re: [Dataperf] Controlling sort order in a (sub) report
> Tim
>
> Thank you for the reply. The reason is that some firms have several
> branches, so to distinguish one entry from another panel I choose to use a
> unique code.
>
> I would welcome any ideas or suggestions on any easy way to change numeric
> codes to name of the firm in the second panel.
>
> Victor
>
> On Mon, 21 Aug 2006 15:33:06 +0100, Tim Rude <[EMAIL PROTECTED]> wrote:
>
> > Victor,
> >
> > The way you are linking (using the numeric ID code) makes this
> > difficult. Is
> > there a reason you can't link on the firm name instead?
> >
> > Tim Rude
> >
> > ----- Original Message -----
> > From: "Victor Warner" <[EMAIL PROTECTED]>
> > To: "DataPerfect Users Discussion Group" <[email protected]>
> > Sent: Monday, August 21, 2006 2:39 AM
> > Subject: [Dataperf] Controlling sort order in a (sub) report
> >
> >
> >> I would like have a particular sort order in a subreport based on the
> >> following criteria.
> >>
> >> There are two panels:
> >>
> >> 1. The first panel contains names and addresses of law firms (each name
> >> has an additional unique code)
> >>
> >> 2. The second panel contains two fields, a field for the unique code to
> >> the law firm and a field for the legal specialism of that firm. There
> >> is a
> >> panel link from the second panel to the first on the code.
> >>
> >> In the seocond panel I wish to create a two-level report based on legal
> >> specialism with a sub-report for the name of the firm from the first
> >> panel. This produces the report as expected except for one thing.
> >>
> >> The sorting of the name of the firm from the first panel is controlled
> >> by
> >> the unique code. Ie the name of the firm is sorted numerically
according
> >> to the order of the unique code. The unique code numbering does not
> >> match
> >> the alphabetical order of the name of firms.
> >>
> >> What I would like to acheive is the sub-report is sorted according to
> >> the
> >> alphabetical order of the name of the firm.
> >>
> >> I would be grateful to know if this possible.
> >>
> >> Victor Warner
> >> _______________________________________________
> >> Dataperf mailing list
> >> [email protected]
> >> http://lists.dataperfect.nl/mailman/listinfo/dataperf
> >>
> >
> > _______________________________________________
> > Dataperf mailing list
> > [email protected]
> > http://lists.dataperfect.nl/mailman/listinfo/dataperf
>
>
> _______________________________________________
> Dataperf mailing list
> [email protected]
> http://lists.dataperfect.nl/mailman/listinfo/dataperf
>
_______________________________________________
Dataperf mailing list
[email protected]
http://lists.dataperfect.nl/mailman/listinfo/dataperf