Display odd and even #'s separately in a report

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am trying to generate a report from a large address database by even #
houses and then by odd # houses. The house #'s are from 1 to 4 digits. How
can I sort my house street #'s into an odd # group and an even # group for
printing my report?

Thanks in advance!
 
The answer will depend on how the data is stored.

If the HouseNumber is in a separate field of type Number, you can create a
query type this into the Field row:
Odd: [HouseNumber] Mod 2
You can then use this Odd field in the Sorting And Grouping box in report
design view (View menu) to group the odd numbers together.

If the house numbers are always at the start of the Address field, but
that's a Text field, you could use:
Odd: Val([Address]) Mod 2
However, that's going to give unsatisfactory results of you have address
such as these:
2 / 32 Winding Way
1st Floor, 299 Main Street
 
Back
Top