I have some data that is pulled from an SQL table with and SQL Statement. When viewing the data output, the sort order (by firstname then by lastname) looks good. When I run it through the report I made, the order gets messed up.
my report is done up something fancy to generate a phone list. In the Group,Sort and Total, I have group on the field Dummy and then grouped on the field Heads.
Dummy is a field generated at the SQL statement (1 as [Dummy]), and the grouping is made so that I can have a footer after the full detail, but before the page footer.
Heads is a field generated at the SQL statement (LEFT(" & sortField & ", 1) AS Heads) which grabs the field designated as the sort field (first name or last name), which creates the letter Header for each detailed section. For example, the data output would look something like this:
[=====A======]
Amber Thomas
Art Smith
[=====B======]
Ben Dover
Blair Witch
Burt Renolds
ext.
Well, that is what is should look like. But this order is messed up, and I'm not sure why. The data outputs properly in the query, but the order differs once it hits the report. The Heads groups are right, but the sorts between the letters is off. There is not Sort set in the Groups, Sort and Total area. Is there somewhere else that a sort could be implemented? My only Scripts for this report are to force the page to be landscape and 11x17 on Report_Open, and for formatting the height of the Detail area in the Details_Format
Bookmarks