Mombu the Programming Forum sponsored links

Go Back   Mombu the Programming Forum > Programming > Creating records
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 6th August 10:20
alanglloyd
External User
 
Posts: 1
Default Creating records



In article <zGqYa.11809$os2.174837@news2.e.nsc.no>, "Bjørge Sæther"
<bjorge@hahaha_itte.no> writes:

_Any_ data file should have a version number (or major and minor version
numbers) embedded in the first bytes of the data file. Then if you need an
update you can read as the old version, and write as the new.

That, of course, is if that sort of operation makes sense. For some changes you
cannot even do that.

Alan Lloyd
alanglloyd@aol.com
  Reply With Quote


  sponsored links


2 6th August 10:21
bjørge sæther
External User
 
Posts: 1
Default Creating records



"AlanGLLoyd" <alanglloyd@aol.com> skrev i melding
news:20030811032506.23406.00001365@mb-m27.aol.com...

?


Agreed. When using record type files, this means you'll ahve to declare a
new record type for each change. And - write a conversion routine that takes
data from the old to the new type. At that point, I believe the "easiness"
of typed records has gone down the drain, and putting the effort into
writing a dynamic storage mechanism would be better.


changes you


No, then one may need a migration application or whatever to deal with it.
But that's the same with all storage formats.

--
Regards,

Bjørge Sæther
bjorge@haha_itte.no
-------------------------------------
I'll not spend any money on American Software products
until armed forces are out of Iraq.
  Reply With Quote


  sponsored links


3 6th August 10:22
geir_baardsen
External User
 
Posts: 1
Default Creating records


Ok. I'll give it a try...
  Reply With Quote
4 14th August 13:40
bjørge sæther
External User
 
Posts: 1
Default Creating records


"Bruce Roberts" <ber@bounceitattcanada.xnet> skrev i melding
news:yGPZa.61$0I.2941@news20.bellglobal.com...

I meant 'dynamic' as opposed to 'static' Record Type Files. To me, storing
data in a database counts for 'dynamic'. It's not the best term, though...

--
Regards,

Bjørge Sæther
bjorge@haha_itte.no
-------------------------------------
I'll not spend any money on American Software products
until armed forces are out of Iraq.
  Reply With Quote
5 17th August 10:24
alf christophersen
External User
 
Posts: 1
Default Creating records


Use class nd streams and remember to define a base class from which
all classes derive. Declare a version datafield and store it in the
SavetoStream procedure. Use the version info to test whether another
field should be loaded or not. In that way you never to convert from
one record to another :-) Remember to use tPersistent as base for the
base class. Otherwise you get problems using tStream.
  Reply With Quote
6 28th August 10:21
marco van de voort
External User
 
Posts: 1
Default Creating records


Hmm. Small tools and reading/processing/writing existing file structures.
  Reply With Quote
Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666