by Steve Lopez

Questions occasionally arise about the database texts used in ChessBase Magazine and on the training CDs: "How do you guys do that?" It's no great secret -- the tools exist in both ChessBase 7 and 8. We'll take a look at the process in the next couple of ETN issues.

However, there are a few caveats (as always). This won't be an instructional text on word processing; a few concepts (such as fonts, highlighting text, cutting and pasting text) will be assumed. It's also very helpful if you know a little about HTML coding; designing a database text and designing a web page are similar in several regards.

Another caveat (which I don't mean to overstress, but it's an important one) is that you as an author actually have something to say. I don't mean this in a demeaning way. What I'm saying is that the ability to create database texts is a very cool ChessBase feature but it's not something you want to use just for the fun of using it. The database texts in ChessBase Magazine (hereafter referred to as CBM) are a good example of how they should be used. The text becomes a sort of interactive magazine article, with photos, audio, video, crosstables, and links to games -- but the real guts of a database text is just that: the text. It's pointless to create a database text that contains nothing but game links, since the reader can just do a standard database search for the games anyway. The real value of a database text is the ability to add information that can't easily be included in the games themselves, like background info on the tournament site, interviews with players, etc. The big exception is using a database text as a table of contents to a large amount of information (for example, you can use it as an introduction to a database containing multiple tournaments or a mixture of tournaments and articles). Another possible use occurs when you're putting the games from a chess book into a database; I start each database with a short text file containing the book's title, author, publisher, and ISBN number. If the filename later doesn't tell me which book's games are in the database (because I have a mind like a sieve), I just open the game list, click on the database text entry, and see at a glance which electronic "book" I'm looking at.

We'll cover a few elements of style in these articles, typically in the examples, but these articles aren't a condensed version of The Beacon Handbook or some kind of Electronic Authoring for Dummies book. And on the subject of copyrights, my assumption is that you're going to be doing the writing yourself. Consult a copyright attorney for any questions about using the work of other authors (though, as a general rule that'll apply in most cases, don't if you're planning to distribute the database to other players).

The first step in the process is to create a new database (and then double-click on it to open it) or open an existing one. In ChessBase 8's game list window, go to the File menu, select "New", and then "Text" from the submenu. This opens a new window in which you'll start typing your text. You'll see several file tabs with the names of languages. No-brainer here -- pick the language you'll be using.

The next step is to create the header which will appear in the game list. Go to the Game menu and select "Edit text data". The "Language" option is obvious. The "Title" field lets you give the text a title, which will appear in the game list in the "Players" column. "Author" lets you put in the author's name, which will appear in brackets in the "Tournaments" column. The "Tournament" field and the "Details" button work just as they do in the "Save game" function, useful for occasions in which you plan to build a database containing several complete tournaments. "Round" is useful if you're planning to create a separate database text for each round of a tournament.

Note that you do not have to fill in every one of these fields. For example, if you're just creating a generic text to hold just the title and author name of a book you're saving to disk, fill out these two fields and leave the "tournament" fields blank.

Once you've filled this info in, click "OK". Next you'll go to the File menu and choose one of the "Save" options. You'll see one that defaults to the currently-open database; the "Save as" command lets you save the text into a different database. This brings up a very important bit of advice: save your work early and often. I'm not kidding here. Don't think you need to complete the entire text before you save it -- this will lead to severe embitterment in the event of a power outage before the text is finished. Just last week I lost three paragraphs of a book I'm writing because the electrical power went out for about two seconds. Also, computers do lock up, and this seems to happen to me all the time when I'm using a word processor. You're typing away and, the next thing you know, the screen freezes. So, as a general rule, I try to save my work every paragraph or two. It still sucks when you lose a couple of paragraphs due to a power outage, but you can usually recreate the work.

Should you also save your work to a floppy or CD? (See ETN, April 29th 2001) That's up to you, of course, but it can't hurt. As discussed in that previous article, data does become corrupted and hard drives do crash (and let's not even contemplate viruses). For the books I write, I save my work daily. I create separate folders on a rewritable CD (each folder's name is the data of the backup) and save each day's work into a new folder. There's a reason I do this, instead of just overwriting the same file: if I save my work on Monday, Tuesday, and Wednesday, but discover on Wednesday that my newly saved version is corrupted, I can go back to the Monday and Tuesday saves to see if they're OK. If so, I've only lost one or two days' work, instead of everything I've done up to that point (which would be the case if I was constantly overwriting my previous saves).

Most of the tools you'll need in creating a database text are in the Format menu, so named because the commands allow you to format your work (as opposed to formatting your hard drive, something altogether different). Let's have a tour of these commands, with a brief explanation.

The first command you'll see will say "Write-protected browser". Clicking this will "lock" your text so that you can't make any changes to it (but you can later unlock it, as we'll see in a minute). This is useful for texts that are completed -- you won't be able to accidentally delete or change anything you've already done (and accidents do happen -- I've occasionally wiped out a few paragraphs while working late at night and not paying attention to where the cursor is located). If you've write-protected a text in his manner and then go back to the Format menu, you'll see that this command has changed to read "Editor mode". Clicking this returns the database text to a state in which you can once again make changes to it. So this first menu command is a "toggle" that lets you switch back and forth between these two modes.

The next command is "Alignment", which opens a submenu with "Left", "Centered", and "Right". Just highlight a block of text and select one of these options to have the text line up either along the left or right margins or to center it. This also works with graphics -- you can highlight a graphic, make a choice here, and have the graphic positioned according to your pick.

The next command, "Indent", allows you to indent text, starting it a certain distance away from the left margin. An example can be found in almost any book -- the first line of a new paragraph is usually indented five characters or so from the left margin. Lazy schmucks like me don't use this in the electronic medium; since no paper is involved, I'll just insert a blank line between paragraphs (such as in the article you're presently reading). But some folks might like the way an indented paragraph looks, so the option is here. Another use for this is if you're creating an outline or quoting long text passages; in the latter case, the indentation helps remind the reader that it's material quoted from another source or organizes the outline's subheadings. The numerical value is given in points; if you're not sure about this, just play around with it to get the hang of it (otherwise I can have my wife, who's in the [paper] printing business, step in as a guest columnist to explain the concept of "points". However, I'd like this article to be somewhat shorter than Ben Hur, so I think I'll skip that option).

The next command is "Header"; this is similar to the H1, H2, H3, etc. tags when using HTML. It allows you to create "headline" style type. For example, you might put the article title at the top of the page and use "Main Header" on it to have it appear larger and bolder. If you choose to later subdivide your article into sections or chapters, you can use "Header 2 level" or "Header 3 level" on them. For example, you might write an article called "The Care and Feeding of Bad Pawn Structures". You'd use "Main Header" on this title. If you had a few subsections with titles like "Doubled Pawns", "Isolated Pawns", or "Backward Pawns", you could use "Header 2 level" on these. If the section on "Doubled pawns" was further subdivided into sections on "Doubled Pawns in the Center" and "Doubled Pawns on the Flanks", you could use "Header 3 level" on these titles. Just highlight the block of text constituting the tile and apply one of the header commands to it.

"No header" allows you to change your mind about a header designation. "Define header formats" lets you change the display parameters of these headers (as to font type, size, color, and special characteristics like bold or italic), so you can custom design your own headers.

The next command is "Style", with "Bold", "Italic", and "Underline" in the submenu. These are self-explanatory (I hope); as always, highlight the block of text and apply the style command of your choice.

Now we come to a fun one: "Font". This brings up a list of all of the fonts on your computer. You can highlight a block of text, invoke this command, and change the font type for that text, as well as the size of the lettering (the "style" boxes are in half-tone, but you can change styles using the "Style" command mentioned earlier). The handy display window will show a sample of both the size and appearance of the font.

As always, there's a fly in the ointment here. You can highlight a block of text and use some neato-keen font like "WingDings Alternative SuperSansSerif", but unless your reader has the same font on his computer, it won't display as WingDings Alternative SuperSansSerif; it'll just default back to something he does have (probably Ariel or System). Also, use varying font styles sparingly -- you can always tell a word processing/electronic publishing newbie, because he uses every dang font he owns within the same document. This makes it very hard to read and is just plain dumb. In most cases, you can just pick a font and stick with it for your whole document (maybe using something special for the headers only) and then use the "Style" effects (like bold and italic) for emphasis of certain words or phrases. I've seen web pages and e-books in which some artsy-type webmaster uses a whole heaping pile of fonts and, I can assure you, I don't stick around for long when that happens. If you want your work to be read, make it easy for the reader -- nobody's impressed by the number of fonts the author owns, especially since CDs containing thousands of fonts can be had for about $5 each.

If you're happy with a font type but just want to change the size, the next command ("Font size") gives you a handy shortcut. Just type a value into the dialogue and the size of the highlighted text will change accordingly.

The next command, "Color", lets you change the color of the highlighted text. Clicking on this command brings up the standard Windows palette display, with all of the various options it contains for selecting a color (the moveable crosshairs on the color palette, the various presets, or the dialogues for "Hue", "Sat", "Lum", and the primary colors).

The "Multimedia" command brings up a submenu with various options. The main ones are "Picture", "Video", and "Audio".

"Picture" lets you insert a still photo into the text. The catch is that the pic must be in .BMP format. Any decent graphics program will allow you to convert between file formats, so this is easily accomplished. Keep in mind, though, that a .BMP file is a lot bigger than a .GIF or .JPG file of the same pic. This might be important if you're creating a database for Internet download. If you want the database to be downloadable, go easy on the multimedia.

"Video" lets you insert a video clip into your text. A button (appearing as a small graphic of a camcorder) appears in the text at that point. When the reader clicks on it, a seperate popup window will appear and display the video. The video must be in .AVI format; again, conversion between formats is possible with third-party utility programs.

"Audio" will insert a button for an audio clip at that point in the text. The clip must be in .WAV format, and the usual yah-dah about conversion applies here as well.

Selecting any of these three options brings up the standard Windows file select dialogue. You just use it to go to the folder where the pic, vid, or sound clip is stored. Select it, click "OK" and the pic or button appears in your database text. Note that when you add multimedia to a database, ChessBase 8 will create a subfolder to store the multimedia. For example, if your database is called Mybook.cbh and is in a folder called Bases, CB8 will create folders called Bases/Mybook.bmp for pics, Bases/Mybook.avi for videos, and Bases/Mybook.wav for sound files. If you open those folders, you'll see that the files are numbered (for example, 1.bmp, 2.bmp, 3,bmp, etc.); CB8 renames the files when it copies them into the folders. However, the original files are still safe and sound (with their original names) in their original folders. If you decide to later archive that database (ETN, April 29, 2001), the special folders and files will also be compressed into the database archive file.

Three additional commands appear in the "Multimedia" submenu: "Picture alias", "Video alias", and "Audio alias". These are usful for occasions when you want to use the same pic, vid, or sound multiple times in the same database (not necessarily the same database text). Instead of adding the file a second time, the "Alias" commands bring up a dialogue that lets you choose one you've already used (thereby using the same multimedia file in both places in your text). This will drastically reduce the database size, compared to the size if you'd used multiple copies of the same multimedia file.

We still have several commands to cover, but I think that's enough to bust anyone's brain for one week. Next week, we'll see how to link to games in the database as well as to other texts in the database. This will lead straight into another rant about hypertext linking. So break out the Tylenol now and get ready -- Stevie's about to climb back onto the soapbox again. Uh-oh...

Until next week, have fun!

You can e-mail me with your comments, suggestions, and analysis for Electronic T-Notes.