[AccessD] Report Grouping

Gina Hoopes hoopesg at hotmail.com
Tue Oct 14 09:44:37 CDT 2003


Thank you, Gustav, I think that's exactly the solution I was looking for.

Gina
--------------------------------------------------------------------------------------------

Gustav Brock [gustav at cactus.dk] wrote:
Hi Gina

Assuming that

  STALLWORTH - 1080400000
  CHS - between "108175*" and "108176*" or like "40811*"
  VCHA - between "108100*" and "108210*"

should be something like this as no ranges overlap:

  STALLWORTH - 1080400000
  CHS - between "108175*" and "108176*" or like "40811*"
  VCHA - between "108100*" and "108120*"

you could create a table with the specific ranges:

Center      AreaMin         AreaMax
CHS         1081750000      1081769999
STALLWORTH  1080400000      1080400000
VCHA        1081000000      1081209999
CHS         4081100000      4081199999

Then modify your report source like this (only basic fields shown):

<SQL>

  SELECT
    Area,
    Center,
    Report
  FROM
    tblCenterData,
    tblCenterRange
  WHERE
    Area Between [AreaMin] And [AreaMax];

</SQL>

Note the missing join. Also, grouping and sorting should be left out - do 
that in your report.

Thus, this will be returned:

Area            Center          Report
1080400000      STALLWORTH      80025
1080400000      STALLWORTH      80010
1080400000      STALLWORTH      44740
1081000000      VCHA            50400
1081000000      VCHA            50200
1081000000      VCHA            50100
1081750000      CHS             59505
1081750000      CHS             59205
1081750000      CHS             59203

/gustav

_________________________________________________________________
Need more e-mail storage? Get 10MB with Hotmail Extra Storage.   
http://join.msn.com/?PAGE=features/es



More information about the AccessD mailing list