dbTalk Databases Forums  

paradox .db structure change

comp.databases.paradox comp.databases.paradox


Discuss paradox .db structure change in the comp.databases.paradox forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Fred Evans
 
Posts: n/a

Default paradox .db structure change - 03-25-2006 , 05:10 AM






Hello all,

just a general question.

I have a program written apparently in delphi that uses .db files ( they say
that these are paradox files.)

I need to go a long way round to get to the question. I program in dbase 4.2
and one of the things that dbase allows is that the programmer may change
the structure of the database file by adding or taking out fields or
changing the field length. This enables the programmer to add fields to the
database where additional info will be stored. unmodified dbase code will
still run because it ignores the additional fields.

Generally speaking could I do this to .db files and should existing code
still run without change?

The program that I have has a stock file and I need to add more fields to
the table to cater for some specific requirements that I have.

I will be adding the data to the table using dBASE PLUS but the original
code that used the same database table will still be used to do the
accounting



Reply With Quote
  #2  
Old   
Steven Green
 
Posts: n/a

Default Re: paradox .db structure change - 03-25-2006 , 05:26 AM






Quote:
This enables the programmer to add fields to the database where additional
info will be stored. unmodified dbase code will still run because it
ignores the additional fields.

Generally speaking coud I do this to .db files and should existing code
still run without change?
those statements are NOT necessarily correct.. yes, it is quite easy to add
fields to a table w/o making code changes.. but there are also a gazillion
pieces of code that WILL have to change when you change your fields..


--
Steven Green - Waldorf Maryland USA

Diamond Software Group
http://www.diamondsg.com/main.htm
Paradox Support & Sales - Corel CTech Paradox

Diamond Sports Gems
http://www.diamondsg.com/gemsmain.htm
Sports Memorabilia and Trading Cards

"Fred Evans" <fred (AT) polyflexseals (DOT) co.za> wrote

Quote:
Hello all,

just a general question.

I have a program written apparently in delphi that uses .db files ( they
say
that these are paradox files.)

I need to go a long way round to get to the question. I program in dbase
4.2
and one of the things that dbase allows is that the programmer may change
the structure of the database file by adding or taking out fields or
changing the field length. This enables the programmer to add fields to
the
database where additional info will be stored. unmodified dbase code will
still run because it ignores the additional fields.

Generally speaking could I do this to .db files and should existing code
still run without change?

The program that I have has a stock file and I need to add more fields to
the table to cater for some specific requirements that I have.

I will be adding the data to the table using dBASE PLUS but the original
code that used the same database table will still be used to do the
accounting





Reply With Quote
  #3  
Old   
Mike Kennedy
 
Posts: n/a

Default Re: paradox .db structure change - 03-25-2006 , 06:22 AM



Fred,

Quote:
Generally speaking could I do this to .db files and should existing code
still run without change?
As Steve said, the system might still work perfectly, or might not.

You should either check through ALL the Delphi code for any issues that
might arise, or just make a copy of everything in a test rig, and
give-it-a-whirl. Either way, you'll have to check "everything", including
annual procedures, unusual functions, backups/restores, etc, etc.

The current code might be dependent on the exact fields in a table, and
might get very confused if additional fields appear anywhere, even at the
end of records. Eg, it might treat these records as corrupted, or as signals
to apply some "updates", etc, etc... If it finds such new fields, it might
drop the contents of them!.

You might consider keeping all you new fields in separate tables, and doing
your own "linking" back to the old tables. It'll be a little more work for
you, but you won't screw up the existing apps.

- Mike




Reply With Quote
  #4  
Old   
Liz McGuire
 
Posts: n/a

Default Re: paradox .db structure change - 03-25-2006 , 10:22 AM



This is the best advice you can get for extending an application for
which you don't have control over the code or GUI.

Liz


Mike Kennedy wrote:
Quote:
You might consider keeping all you new fields in separate tables, and doing
your own "linking" back to the old tables. It'll be a little more work for
you, but you won't screw up the existing apps.

Reply With Quote
  #5  
Old   
Fred Evans
 
Posts: n/a

Default Re: paradox .db structure change - 03-25-2006 , 01:06 PM



yes mike-- this is a good idea. It occurred to me that even though the
existing code runs maybe I would not be so fortunate in the next update.

regards fred


"Liz McGuire" <liz (AT) paradoxcommunity (DOT) com> wrote

Quote:
This is the best advice you can get for extending an application for
which you don't have control over the code or GUI.

Liz


Mike Kennedy wrote:

You might consider keeping all you new fields in separate tables, and
doing
your own "linking" back to the old tables. It'll be a little more work
for
you, but you won't screw up the existing apps.



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.