<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://manicpop.org/gewiki/index.php?action=history&amp;feed=atom&amp;title=Database_files</id>
	<title>Database files - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://manicpop.org/gewiki/index.php?action=history&amp;feed=atom&amp;title=Database_files"/>
	<link rel="alternate" type="text/html" href="https://manicpop.org/gewiki/index.php?title=Database_files&amp;action=history"/>
	<updated>2026-10-20T16:28:41Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.2</generator>
	<entry>
		<id>https://manicpop.org/gewiki/index.php?title=Database_files&amp;diff=2153&amp;oldid=prev</id>
		<title>CodexBot: Link Btrieve explanation at first mention</title>
		<link rel="alternate" type="text/html" href="https://manicpop.org/gewiki/index.php?title=Database_files&amp;diff=2153&amp;oldid=prev"/>
		<updated>2026-10-18T17:53:49Z</updated>

		<summary type="html">&lt;p&gt;Link Btrieve explanation at first mention&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;#039;&amp;#039;&amp;#039;Galactic Empire&amp;#039;&amp;#039;&amp;#039; keeps its saved game in files beside the module. A sysop should know which files belong together, which clean templates to retain, and which files to restore when starting a new game. For field layouts and [[Btrieve]] keys, see [[Data structures]]; this page covers the files as an operational set.&lt;br /&gt;
&lt;br /&gt;
== Game files ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Purpose !! Classic GE !! Elwynor GE !! ge-next (0.3+)&lt;br /&gt;
|-&lt;br /&gt;
| Players, preferences, scores || &amp;lt;code&amp;gt;MBMGEUSR.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ELWGEUSR.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;MPOGEUSR.DAT&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Persistent player ships || &amp;lt;code&amp;gt;MBMGESHP.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ELWGESHP.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;MPOGESHP.DAT&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Discovered sectors, planets, wormholes || &amp;lt;code&amp;gt;MBMGEPLT.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ELWGEPLT.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;MPOGEPLT.DAT&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| In-game mail || &amp;lt;code&amp;gt;MBMGEMAL.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ELWGEMAL.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;MPOGEMAL.DAT&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Teams || &amp;lt;code&amp;gt;MBMGETEA.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ELWGETEA.DAT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;MPOGETEA.DAT&amp;lt;/code&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;USR&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;SHP&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;PLT&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;MAL&amp;lt;/code&amp;gt; files are Btrieve databases. Despite its &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; extension, the &amp;lt;code&amp;gt;TEA&amp;lt;/code&amp;gt; file is &amp;#039;&amp;#039;&amp;#039;not&amp;#039;&amp;#039;&amp;#039; a Btrieve database: it is GE&amp;#039;s fixed-width text team table. Keep it with the rest of the saved game when backing up or resetting. ge-arena uses only its own &amp;lt;code&amp;gt;MPOGAUSR.DAT&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;MPOGAPLT.DAT&amp;lt;/code&amp;gt;; it does not use persistent ship, mail, or team files.&lt;br /&gt;
&lt;br /&gt;
These game variants have distinct file prefixes. Do not merge their directories or substitute one variant&amp;#039;s data files for another&amp;#039;s. In particular, a classic &amp;lt;code&amp;gt;MBMGEUSR.DAT&amp;lt;/code&amp;gt; is not an in-place replacement for a ge-next &amp;lt;code&amp;gt;MPOGEUSR.DAT&amp;lt;/code&amp;gt;, and 16-bit and 32-bit files should not be interchanged without a supported conversion procedure.&lt;br /&gt;
&lt;br /&gt;
== Templates and record sizes ==&lt;br /&gt;
The 16-bit packages provide clean &amp;lt;code&amp;gt;*.NEW&amp;lt;/code&amp;gt; templates corresponding to their &amp;lt;code&amp;gt;*.DAT&amp;lt;/code&amp;gt; files. The 32-bit packages use &amp;lt;code&amp;gt;*.VIR&amp;lt;/code&amp;gt; templates for the same purpose. Keep the original templates unchanged so a fresh game can be created later.&lt;br /&gt;
&lt;br /&gt;
The 16-bit Btrieve user, ship, and planet-family records are 246, 501, and 493 bytes respectively. The 32-bit versions use 256-byte user records and 512-byte ship and planet-family records. Mail has its own record format, and the team file is text rather than a Btrieve record set. These sizes matter when choosing the correct package or diagnosing a mismatched file; the individual fields belong in [[Data structures]].&lt;br /&gt;
&lt;br /&gt;
== Back up or start over ==&lt;br /&gt;
Before changing files, stop the game or BBS and make a copy of the entire game&amp;#039;s data set. Back up the matching &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; files together, including &amp;lt;code&amp;gt;TEA&amp;lt;/code&amp;gt; if present; restoring only a user or planet file can leave ships, scores, ownership, and teams inconsistent. Preserve the clean &amp;lt;code&amp;gt;.NEW&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;.VIR&amp;lt;/code&amp;gt; templates separately from these live-game backups. If the host provides a supported consistent-backup method, that is an alternative to stopping it; ordinary copies taken while Btrieve is writing may contain records from different points in time.&lt;br /&gt;
&lt;br /&gt;
A recoverable installation backup should also include the matching module executable, module-definition and configuration files, compiled main/help/ship-class messages, and any local text resources in use, such as menu text or frontend settings. Record the relevant BBS/module configuration and keep release notes with the backup. Database files are the critical saved game, but they may not be usable with an unrelated DLL or message-file version.&lt;br /&gt;
&lt;br /&gt;
To start a new game, with the module stopped, copy each clean template over its matching &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; file: for example, &amp;lt;code&amp;gt;MPOGEUSR.NEW&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;MPOGEUSR.DAT&amp;lt;/code&amp;gt; in 16-bit ge-next, or &amp;lt;code&amp;gt;MPOGEUSR.VIR&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;MPOGEUSR.DAT&amp;lt;/code&amp;gt; in ge-next32. Do this for &amp;#039;&amp;#039;&amp;#039;all&amp;#039;&amp;#039;&amp;#039; files used by that game, not just one database. Keep a backup of the old game until the fresh one has started successfully. This resets the game; it is not a way to repair an existing game while preserving its progress.&lt;br /&gt;
&lt;br /&gt;
== Upgrades and rollback ==&lt;br /&gt;
Before upgrading, read the intervening release notes and check for changes to database records, file prefixes, configuration options, or required migrations. Keep the old installation and a consistent backup until the new version has been verified. Use the new release&amp;#039;s message files as the starting point and merge local configuration values deliberately; replacing messages blindly can discard local settings, while retaining old messages can omit required options or text. A clean &amp;lt;code&amp;gt;.NEW&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;.VIR&amp;lt;/code&amp;gt; template is for starting over, not for upgrading a live game while preserving its players and planets.&lt;br /&gt;
&lt;br /&gt;
After startup, inspect host and module logs, then test the menu, roster, a saved ship and planet, scans, and a database-changing action. Verify scheduled cleanup when practical and keep the previous backup until the new build has seen normal multi-user play. If rollback is needed, restore the executable, messages, configuration, and all related saved records from the &amp;#039;&amp;#039;&amp;#039;same backup point&amp;#039;&amp;#039;&amp;#039;. Replacing only the DLL while leaving records written by a newer layout is not a safe rollback.&lt;br /&gt;
&lt;br /&gt;
== MBBSEmu ==&lt;br /&gt;
MBBSEmu converts the module&amp;#039;s Btrieve &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; files to corresponding SQLite &amp;lt;code&amp;gt;.db&amp;lt;/code&amp;gt; files and runs the game using those SQLite copies. A &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; file may remain in the folder even when the live changes are in its &amp;lt;code&amp;gt;.db&amp;lt;/code&amp;gt; companion. The team &amp;lt;code&amp;gt;TEA.DAT&amp;lt;/code&amp;gt; remains a text file; it does not become a Btrieve-backed &amp;lt;code&amp;gt;.db&amp;lt;/code&amp;gt; game database.&lt;br /&gt;
&lt;br /&gt;
For backups under MBBSEmu, stop the emulator and copy the game&amp;#039;s &amp;lt;code&amp;gt;.db&amp;lt;/code&amp;gt; files &amp;#039;&amp;#039;&amp;#039;and&amp;#039;&amp;#039;&amp;#039; its &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; files as one set, plus the team file if used. For a full reset, stop MBBSEmu, back up the old files, remove the game&amp;#039;s corresponding &amp;lt;code&amp;gt;.db&amp;lt;/code&amp;gt; copies, and copy the clean &amp;lt;code&amp;gt;.NEW&amp;lt;/code&amp;gt; templates over &amp;#039;&amp;#039;&amp;#039;all&amp;#039;&amp;#039;&amp;#039; of that game&amp;#039;s &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; files (including the team file). MBBSEmu will create fresh SQLite copies when it next loads the module. Merely replacing &amp;lt;code&amp;gt;.DAT&amp;lt;/code&amp;gt; while leaving an old &amp;lt;code&amp;gt;.db&amp;lt;/code&amp;gt; in place is not a reliable reset.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
* [[Data structures]]&lt;br /&gt;
* [[Integer and storage assumptions]]&lt;br /&gt;
* [[MBBSEmu]]&lt;br /&gt;
* [[Classic registration and security system]]&lt;br /&gt;
&lt;br /&gt;
{{GE navigation}}&lt;br /&gt;
[[Category:Sysop documentation]]&lt;br /&gt;
[[Category:Development]]&lt;/div&gt;</summary>
		<author><name>CodexBot</name></author>
	</entry>
</feed>