Database Basics

by ChessBase
9/15/2004 – Our series of articles on "Database Basics" is intended to show new users how to utilize the search features of chess databases. Part Three describes how to search for the various annotation forms that are used in ChessBase format games. Read all about it in the latest ChessBase Workshop.

ChessBase 17 - Mega package - Edition 2024 ChessBase 17 - Mega package - Edition 2024

It is the program of choice for anyone who loves the game and wants to know more about it. Start your personal success story with ChessBase and enjoy the game even more.



by Steve Lopez

In last week's ChessBase Workshop we learned how to perform game header searches on a chess database using the search mask in Fritz8. This week we're going to look a little deeper (literally) at some other search types.

The header searches we discussed last week involved searching for games by criteria given in the game list information (player names, ECO code, etc.). This type of search can be performed comparatively quickly, even on very large databases, because the program has only to look at the header information, not at the contents of the games themselves. Another kind of database search involves the annotations within the games; this kind of search usually takes a bit longer than a header search because the program has to look at information contained inside the game. [1]

[1] For ChessBase "old timers", increased search speed was the motivating factor behind the change in the ChessBase data format between ChessBase for Windows and ChessBase 6. In the old (pre-1996) format, all of the game information (header info, moves, annotations, etc.) was concentrated in the .cbf file. When you did even a simple search by player name, the program had to search the entire .cbf file for games played by that player -- and this included a whole lot of data which had nothing to do with the game headers. Starting with ChessBase 6, game data was split across multiple files: the games headers were contained within one file, the game moves within another, annotations within still another, etc. When you do a header search, for example, the program now has to search through just one file which contains only header information. This is much faster and more efficient than the old days when the program was required to search through everything regardless of whether or not it related to the game headers. This also leads directly to a point which will be covered in a later article in this series: a hierarchy by which the program performs combined header/data searches.

In Fritz8, open a database and bring up the search mask (as described in the previous ChessBase Workshop). This time around, though, click the "Annotations" tab at the top of the search mask. You'll see the following dialogue:

This dialogue gives you the opportunity to search for games containing specific annotations. Now this next bit might seem obvious to most readers but it deserves some emphasis for folks new to database use: for an "Annotation" search to work, at least some of the games in the database must be annotated. It sounds like a silly thing to point out but there are a lot of commercial databases which contain no annotated games (ChessBase's Big Database is an example). And the vast majority of databases you can download from the Internet also contain no annotations (The Week in Chess is an example of this; you'll seldom find an annotated game in TWIC). So for this kind of search to work, you must be using a database in which some of the games have annotations. It might be a ChessBase Training CD or the Mega Database; it might even be a database containing games you've annotated yourself. Either way, a database must contain annotations, otherwise an annotation search will always come up "empty".

We'll start in the middle of this dialogue to discuss the "check boxes" within the framed border. Clicking on one of these boxes and then clicking "OK" will cause the program to find all the games in which that particular type of annotation appeared.

Many of these annotation types aren't ones you can create using Fritz8 (these require ChessBase to be able to add them to games), but Fritz will certainly find these annotation types if they're used in a database. We won't be discussing these annotation types in-depth -- most of them have been covered in detail in previous articles -- but we'll provide a brief description of them.

  • Colors -- This refers to the use of colored arrows and squares which emphasize moves of interest or key squares on the board.
  • Training -- Games which contain timed training questions (either generated automatically by Fritz' post-game analysis features or manually by a human annotator) will be discovered by using this search.
  • Multimedia -- Games which contain multimedia elements (pictures, sounds, or videos) will be found if this box is selected.
  • Pawn structure -- This will find games in which the human annotator has chosen to include one or more pawn structure popups.
  • Piece path -- Selecting this option will list the games in which a human annotator has included popups to illustrate the cumulative moves of a particular piece or pawn.
  • Variations -- One of the most useful selections you can make in this dialogue, checking this box will provide a list of all games containing replayable alternative variations.
  • Any text -- Selecting this option will bring up a list of all games containing text commentary. This, too, is one of the more useful toggles in this dialogue.
  • Any symbols -- This will provide a list of all games which use Informant-style evaluation and commentary symbols.
  • Critical Opening/Middlegame/Endgame position -- a special feature of ChessBase allows the commentator to mark positions as being of significant interest; these appear highlighted in a different color within the gamescore. Fritz will sometimes also highlight moves using these special designations. You can use this toggle to find all games in which a specific kind of critical position (Opening, Middlegame, or Endgame) appears.

This stuff is all pretty self-explanatory. If you want to find all the games in the database which contain replayable variations, you'd just put a check in the box next to "Variations" and click "OK". Within a few moments the program will provide a list of all games in which such variations appear.

It's possible (and often preferable) to use more than one of these toggles at a time. Clicking only "Variations" will provide a list of all games with replayable variations, regardless of whether or not they contain any text or symbols. But if you also include "Any text" and "Any symbols" as search parameters the search will turn up the games which use all three variation types within the same game: variations, symbols, and text commentary.

On the other hand, you might want to see only games with text commentary regardless of the use of any other annotation types. In this case you'd select only "Any text"; all games containing text will be identified and listed for you. [2]

[2] There's sometimes a slight hitch here which involves languages. For example, if you're searching a Chessbase Magazine database in which a commentator has annotated a game in French and you've not selected "French" as one of your language options the game will still appear in the game list after the search is complete but the game will appear to have no commentary. This isn't a "bug". The game does qualify as being text-annotated, but the fact that you don't have "French" selected as a visible language choice will mask out the game's text. This was discussed at length in a recent ChessBase Workshop

Clicking "Any text" means just that: any game which contains something that was typed within an annotation/commentary window. This might be something as simple as the word "Time" added at the end of the gamescore (meaning that one player lost because his flag fell) as the game's only annotation. This is why the search mask also lets you search for specific words or phrases and why you might want to use the "Text 1" and "Text 2" boxes instead of "Any text".

There are several reason why you might want to search for a specific word or phrase. One reason might be to use the search as a kind of "filter" to weed out games with fairly insignificant text usage (such as the word "Time" at the end of the game as described above). Another use might be to search for a specific game which you know uses a particular word in the commentary; for example, you might vaguely remember an old game annotated by Nigel Short in which he said he felt like a "real patootie" after a certain move. You could do a search for "patootie" to find that game (as well as any others in which that colorful expression was invoked).

You can search for multiple expressions by typing them in the "Text 1:" and "Text 2:" boxes. For example, you could type "professional" (without the quotes of course) after "Text 1:" and "computer" after "Text 2:" -- this will list all the games in which either "professional" or "computer" was used (not necessarily both words in the same game, though). Note that this differs substantially from the results obtained when using the check boxes. If you check both "Training" and "Critical Position Opening", you'll get all games in which both annotation forms are used in the same game. But typing words or phrases in both of the text search boxes will yield all games in which the "Text 1:" expression was used plus all games in which the "Text 2:" expression was used -- but this doesn't mean that all the games found will use both expressions in the same game; most (or all) will contain one or the other.

There's an additional tweak available here: the "Whole word" box. If you leave this box unchecked and type in the word "it" after "Text 1:", the search will turn up all games in which those two letters appear together, even if they're part of a longer word. So you'll end up with all games containing the word "it", plus the words "commit", "committed", "fit", "itself", "its", etc. If you want to find all games containing the word standing alone (not as a part of a longer word), you'll want to be sure to check this box. A better example is the word "mate". With the "Whole word" box checked, games containing the word "mate" will be found. If you uncheck this box, the search will include games that have the words "mate", "mated", "checkmate", and "material"(!) in the search result.

"Symbols" lets you hunt for games that contain particular symbols attached to moves. For example, typing "!!" (again without the quotes) lets you find brilliancies, while typing "??" will turn up games containing moves that the annotator thought were blunders. Note that Fritz will occasionally toss in these diacritical marks as part of its analysis, so this is a way to find games that Fritz has so marked.

Note, too, that you can use this dialogue to search for games containing specific Informant-style symbolic notation; Fritz' Help file has a list of the keyboard shortcuts for these symbols. You can use a shortcut to enter a particular symbol into this dialogue box and the search will turn up all games in which that symbol was used by the annotator. For example, you could use CTRL-3 to enter the "unclear" symbol (better known to non-chessplayers as the "infinity" symbol), click "OK", and the search result will be a list of games in which the annotator evaluated a position as "unclear".

The "Deleted" checkbox will bring up a list of games that have been marked for deletion. [3] This is pretty handy for those cases in which you're afraid you might have incorrectly marked a game to be deleted but it's buried somewhere deep in the bowels of your database. Using this toggle will bring up all games that have been "struck out" in the game list and are ready to be deleted. You can pick out the game you marked incorrectly, highlight it, and hit the "Delete" key to unmark it and remove the "ready to be deleted" status.

[3] The process of deleting games has been covered in-depth in previous articles. I just wanted to mention that deleting games is purposely a multi-step process. There's no "Undo" function when it comes to deleting games from a database; once you've deleted a game, it's gone forever with no chance of parole. So the process involves first marking games for deletion, followed by a second step which performs the actual physical deletion. I occasionally encounter users who accidentally delete games and want to "blame" the software. Sorry, but if you've deleted a pile of games in Fritz that you didn't mean to delete, you've been very unlucky (or, more accurately, very careless).

Finally there's the "Position" box. This has nothing to do with finding specific board positions (we'll cover that feature next week). Checking this box will instead bring up all games in the database which start with a position other than the normal opening position for a game of chess. This will include 19th century "odds" games as well as any middlegame tactics problems, endgame studies, or "fragmentary" games (from which the opening moves are missing or lost) that may reside in that database.

Here again you can combine criteria to perform more elaborate searches. You might recall seeing an annotated odds game in your database, a game which also included the word "lightning" as part of the text commentary. To find this game you'd type "lightning" in the "Text 1:" box and check the "Position" box -- the resulting search will turn up your desired game.

We've now covered half the tabs in the Search mask. Next time around we'll hit the one that seems to give users the highest level of confusion: the Position tab. Trust me, it's easy. We'll take it slowly and you'll soon be an expert in its use. It'll require a fair little bit of explanation though, so let's all rest up for a week and come back to hit it in seven. Until then, have fun!

© 2004, Steven A. Lopez. All rights reserved.

Reports about chess: tournaments, championships, portraits, interviews, World Championships, product launches and more.


Rules for reader comments


Not registered yet? Register