| Message |
I can see one potential problem. Maybe "desc" is a reserved word, although it works for me.
[EDIT] The word "DESC" is indeed an SQL word (short for descending) so I am puzzled why it ever worked. I am guessing your version of the SQLite engine was earlier and does not allow "desc" in that way. If you had a version of MUSHclient which is 4.60 or earlier this might be the case.
I've updated the plugin to use "description" instead. Try grabbing the latest plugin (it should be version 1.2) and then follow my instructions above to delete the database and start again (it needs to make a new database with "description" rather than "desc").
Because of this change, anyone else who is using the plugin will need to delete the database and start again. Sorry.
As an alternative (if you have already mapped a lot of rooms - this won't be you Forral) you can do this:
- Close MUSHclient so the database is not in use.
- Grab the "command line tool" from the SQLite3 web site, eg.
http://www.sqlite.org/sqlite-3_7_3.zip
- Unzip that and put sqlite3.exe into your MUSHclient directory.
- Open a command window (Run -> Cmd), change directory to the MUSHclient directory, and type:
sqlite3 materiamagica.com_23.db .dump > materiamagica.sql
(The number 23 might be 4000 - it is whatever port you use to connect).
- Use a text editor like Crimson Editor to open up the resulting file materiamagica.sql.
- A few lines down change "desc" to "description":
CREATE TABLE rooms (
roomid INTEGER PRIMARY KEY AUTOINCREMENT,
uid TEXT NOT NULL, -- vnum or how the MUD identifies the room
name TEXT, -- name of room
description TEXT, -- description
building TEXT, -- which building it is in
shop INTEGER, -- 1 = shop here
train INTEGER, -- 1 = trainer here
notes TEXT, -- player notes
date_added DATE, -- date added to database
UNIQUE (uid)
);
- Further down find these lines and change "desc" to "description" in two places:
INSERT INTO sqlite_master(type,name,tbl_name,rootpage,sql)
VALUES('table','rooms_lookup','rooms_lookup',0,
'CREATE VIRTUAL TABLE rooms_lookup USING FTS3(uid, name, description)');
CREATE TABLE 'rooms_lookup_content'(docid INTEGER PRIMARY KEY, 'c0uid', 'c1name', 'c2description');
- Save your changes to materiamagica.sql.
- Rename the original database:
ren materiamagica.com_23.db materiamagica.com_23.db.old
- Recreate the database from the SQL:
sqlite3 materiamagica.com_23.db < materiamagica.sql
- Download and install the amended plugin.
- Start MUSHclient again and try the mapper.
That should fix up the name of the "desc" column to work with the amended plugin.
Of course, only do all this work if you have mapped hundreds of rooms - otherwise it would be quicker just to start again. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | top |
|