Skip to content

Bioware Campaign Database - Replacement Info

TomRotflTomRotfl Member Posts: 26
edited August 2019 in General Discussions NWN:EE
Hello all,

I have just read latest NWN:EE patch note (I won't talk about how happy i am in seeing so much work being done, you guys are amazing!)

There is one paragraph though, that took my attention more than any other, and for which i have a couple of questions:
"CodeBase (“Bioware Campaign Database”) has been replaced with sqlite3, as the old database code would not work when compiled with a 64bit compiler. Moving forward, we will be writing new, minimal code to import existing CodeBase entries; but for now, old data remains inaccessible. All new database files end up in the database/ directory in your user home. They have the extension .sqlite3."

In my PW server, i use Campaign Database to allow anyone to persistently store their items, and have those items available to each character of the account.

To do that i use the 2 main functions available in the toolset:
"StoreCampaignObject" and "RetrieveCampaignObject" + [etc...]

Now, i imagine that those commands won't change, but what about the database files?
I read in the paragraph that there will be a tool to convert old database files, so i think something able to convert from .fpt and .dbf files into the new .sqlite3.

Will that tool be already available to developers when you'll release the full patch to anyone?
Is there anything to do, even starting now, to help this future conversion?
Will there be some mandatory specific passages to follow in order to update a PW server to the newest release? (I imagine that nwnx will be updates as well)

I know that there are still some months before final release, but i needed to make those questions to start thinking in the right direction :)

Thank you all!
Post edited by TomRotfl on

Comments

  • WilliamDracoWilliamDraco Member Posts: 175
    edited August 2019
    Once the new database hits live (NOT! in the current dev build) Every call to RetrieveCampaign*variable* will call a script that basically does the following:
    1) Try to read from the new (sqlite) DB. If it's there, return it.
    2) If it's not, try to read it from the old (CodeBase) DB. If it's there, save it in the new DB and then return it.
    

    Eventually, all data will naturally migrate over to the new DB as it is called.

    The SetCampaign*variable* will begin to target the new DB immediately with no interaction with the old DB.

    To my knowledge (Nothing more than reading discord chat) there is not intended to be a one-off mass-migration tool.
  • nivniv Member, Moderator, Developer Posts: 410
    When this ships to stable, the game will handle everything for you (in however way is needed). Right now though, on the dev patch, it doesn't yet read the old database files.
  • TomRotflTomRotfl Member Posts: 26
    Awesome, thank you both for the details!
Sign In or Register to comment.