pointer syntax



Another basic question that I can't find the answer to...

In the following code snippet, I would like processRecord to be able to
modify query1 by calling next, and having query1 stay changed when the
procedure returns.

while (not query1.eof) do
begin
processRecord(query1); { <--- I should use @query1 as a
parameter, right?}
prn.IncBar(1);
query1.next;
end;

What does the declaration of processRecord look like?
procedure TmyClass.processRecord( q : TQuery);

procedure TmyClass.processRecord(q^ : TQuery);


a bit more detail of what I'm trying to do:
This is part of a general report-generation module. The records in
query1 are sorted by a field. If there is more than one record with
that field, processRecord handles all those, and then returns. So the
next time processRecord is called, that field contains a different
value. The effect is that I can process groups of records.

-Corinna

.