MUIbase Support This Project
programmable relational database
with graphical user interface
This page is also available in Deutsch


Below documentation is part of the MUIbase dictribution and is also available in PDF.

[ << ] [ >> ]           [Top] [Contents] [Index] [ ? ]

12. Search For

For record browsing you can use a search dialog to search for a specific record. The search feature uses a search pattern that you provide and checks all records for a successful match with this pattern. If it finds one then this record will be displayed in the table mask.

12.1 Search Dialog

To open the search dialog select menu item `Table - Search for'. This will open a window containing

  • a string field for entering the search pattern. Use the characters `*' and `?' as jokers. The character `*' matches any number of characters (including zero characters) whereas `?' matches exactly one single character.
  • a field `Case sensitive'. If you check it, searching uses case sensitive string comparison, otherwise case insensitive string comparison is used.
  • a field `All fields'. If checked then all fields of a record are tested for a successful match with the search pattern. Otherwise only the attribute which has been the active one when the search dialog has been opened is tested. In case the active object at the time when opening the search dialog has not been an attribute object, this field is checked and disabled automatically.
  • two radio buttons for the search direction, `Forward' and `Backward'.
  • two radio buttons for specifying from which record the search should be started. `First/last record' will start the search from the first or last record depending on the search direction. `Current record' starts the search from the current record.
  • two buttons `Search' and `Cancel' for leaving the window.

After you have entered a search pattern and left the dialog with the `Search' button MUIbase starts searching for a matching record. The comparison of an attribute field with the search pattern is always done string based, attribute fields of non-string types are therefore converted to strings first.

If a matching record is found, it is displayed as the current record in the table mask. Otherwise a `Search pattern not found' message appears.

If you search on an attribute that is used as the first attribute for ordering and your search pattern doesn't start with a joker (`*' or `?') then an improved search algorithm (binary search) is used that makes use of the record order. This can speed up searching significantly.

12.2 Forward/Backward Search

Two further menu items allow to search for the next and the previous occurrence of the search pattern. Select menu item `Table - Search forward' for browsing to the next record that matches the search pattern, and `Table - Search backward' to go to the previous matching record.

12.3 Search Pattern Examples

Here are some search pattern examples:

  • `Lassie' searches for records that have the string `Lassie' in one of the search attributes.
  • `*x*' searches for records that have the letter `x' in one of the search attributes.
  • `???' searches for records that have exactly three characters in one of the search attributes, e.g. a record with an entry `UFO'.

[ << ] [ >> ]           [Top] [Contents] [Index] [ ? ]

This document was generated on Oktober, 10 2017 using texi2html