41.3.2 Querying an Invoice

An invoice detail line is queried by first displaying the invoice header. Next, press the NEXT <F7> button to display the detail form. Press the QUERY button <F2> to get into the QUERY mode. While in the QUERY mode, enter the search pattern desired, and press the FIND FIRST <F3> button. If the search pattern matches more than one invoice, press the FIND NEXT <F3> button to display the next matching record.

To query the tax and discount screen, first display the invoice header. Then press the NEXT <F7> button twice to display the tax and discount screen.

As was explained above, the QUERY and FIND functions search for records in the file by starting at the beginning of the file and proceeding to the end of the file. When the QUERY button <F2> is pressed the first record in the file that matches the search pattern is being queried. When the FIND NEXT button <F3> is pressed the next record in the file that matches the search pattern is displayed.

The QUERY function can be made to start its search with the last matching record by pressing the FIND LAST (GOLD key <F1> before pressing the QUERY button <F2>). This means that the last record in the file that matches the search pattern is queried.

The direction of the FIND function's search can also be reversed if the FIND PREVIOUS button (GOLD key <F1> is pressed just before pressing the FIND <F3> key). As was explained above, each time the FIND NEXT button <F3> is pressed, the next record in the file that matches the search pattern is displayed. By pressing the FIND PREVIOUS button (GOLD key <F1> before pressing the FIND <F3> key) the direction of the search is reversed and the previous matching record is displayed. The GOLD <F1> FIND <F3> keys and the FIND <F3> key can be used to move back and forth in the file.