[sword-devel] modules to relational database

Troy A. Griffitts scribe at crosswire.org
Tue Nov 7 16:49:16 MST 2006

In regard to this thread.  It all boils down to simply comparing 
comparable entities.

Data storage:

A database stores and retrieves a chunk of generic data
The SWORD low level drivers store and retrieve chunks of generic data

You might argue that we need to add a new driver which can retrieve data 
from a database.  That might be a fine and reasonable argument.  I'll 
argue that our storage formats are specialize for speed and size and 
will probably beat any general RDBMS on the market, merely because we 
have the option of developing our storage format for very specific data.

Trying to move beyond "data storage", when comparing and RDBMS to SWORD 
seems to me invalid.

What SWORD builds on top of "data storage" is the same thing you will 
have to build on top of any data storage method you choose:

verse/key parsing (What does it mean when a user says: 

parsing localization for different languages,

book index organization decisions,

tag markup handling and conversion, in generally (specifics below)

strongs numbers



morphological information

cross references

section headings

words of Christ

Greek / Hebrew accenting

Greek variants

searching in any combination of these categories

book management: installation / removal

Basically, what it comes down to is that the advantage of using SWORD 
over an RDBMS is that you get to contribute to and use the contributions 
of all the things other people have had to write ON TOP OF "DATA 
STORAGE": Basically, Bible software tasks.  We have SOME mechanism for 
all these things, and we improving and adding more facilities all the 
time.  If you don't like the current way we do something, we provide a 
modular architecture which allows you to, say, change the way OSIS 
footnotes are handled, by replacing a very small class with one all your 

Now, one might not like the way we have tackled this architecture or 
these individual tasks and think they can do all the work themselves, as 
some do.  And I'm not faulting them for this.  We have far from perfect 
solutions for all of these things.  But what it comes down to, is that 
our goal here... at CrossWire... is to TRY to tackle these objectives as 
a community and work together to build a generic engine that does 
provide easy to use facilities for these specific tasks of processing 
Biblical texts and related materials (including, but mostly above, the 
data storage level).

You can choose to contribute to this common effort, or you can do it all 
yourself.  It's a free universe, mostly.


PS.  Still trying to wooo you into using our efforts, I will provide 
another example of a very common and basic Bible task.

Retrieve HTML markup from an OSIS text, for a specific translation, 
turning off footnotes, but including cross-references:

SWMgr library;
library.setGlobalOption("Footnotes", "Off");
library.setGlobalOption("Cross-references", "On");
cout << library.getModule("KJV")->RenderText("jn.3.16");

More information about the sword-devel mailing list