Author Topic: Data Stores  (Read 1893 times)

mrticsay

  • Newbie
  • *
  • Posts: 21
    • View Profile
Data Stores
« on: February 20, 2009, 08:38:56 PM »
Corey,

Just getting started with the new data store feature, but have to say I like that this has been pulled out of the programs directory.

Why is the lib directory not part of the data store?  I have a number of customized files in their to handle my prize structure.  I'd like to pull those out of the program directory as well.

Thanks,
Michael

Corey Cooper

  • Administrator
  • Hero Member
  • *****
  • Posts: 6220
    • View Profile
Re: Data Stores
« Reply #1 on: February 23, 2009, 01:31:31 PM »
Good question.

The "lib" folder wasn't included because it is a folder that contains files that the TD uses, and that shouldn't be modified.  You might argue that it's OK to modify the autoPrizes.xml and prizeSuggestions.xml files, but the right thing to do is really leave those files alone and make your own if you wish to customize them.  Instead of editing autoPrizes.xml, for example, copy it to a new file and then point the TD to the new file.  You can save the file anywhere you like, and in your data store is probably the best place.  On the Preferences tab, press the Config Files button to point the TD at the new file.

I guess you could also argue that you may want to use different copies of these files in different data stores, but I didn't feel like this would be a common scenario at all, and didn't feel it warranted that much change to the way the TD currently works.  So no matter where you place your autoPrizes.xml file, when you switch data stores the TD will still be looking at the same autoPrizes.xml file.  You'll have to change the appropriate Config Files setting if you wish to point it to a new file.

Corey Cooper

  • Administrator
  • Hero Member
  • *****
  • Posts: 6220
    • View Profile
Re: Data Stores
« Reply #2 on: February 23, 2009, 01:33:52 PM »
Note that the "copy and edit the copy" paradigm is the right thing to do with any included file.  Files included with the TD are overwritten when you update the TD to a newer version.  Therefore, if you edit a file "in place", you'll lose your changes when you update...

mrticsay

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: Data Stores
« Reply #3 on: February 24, 2009, 08:35:38 PM »
Corey,

Thanks for the explanation. 

I have not modified the system files.  I copied and edited to create my own payout schedules.  I happened to keep them in the same directories as the originals.

I'm comfortable with the moving my versions of the files out of the /lib directory and into a place in the data store (which, of note, I did when I moved the other files).

So with your explanation of the purpose of /lib, I'm comfortable that no change is needed.

Thanks again for this feature...I now have one other program that I wish would move their data files from the program directory!

Thanks for the continued work on, and support of, this product!

Michael