Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Test and live databases
Message
 
À
18/08/1998 19:51:21
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00127885
Message ID:
00127980
Vues:
27
>>Like almost everybody, i have a test and a live database. When I need to add a new table or view, I start by creating it in my test database and do all the coding. Once this all work, I redo every modificatons done to my test database to the live one (wich chances that I mistype something.)
>>
>>Is there a better way to keep two databases in sync without actually doing things twice? Some of my tables have over 75 fields with long field name, so it quite time consuming creating them twice.
>>
>>Simply copying the table is no good, since it allways want the original database. If I free it, I lose every field name that are longer than 8 characters.
>>
>>How do you copy a view from one database to another?
>>
>>
>>TIA
>
>
>I have a utilitity here in the files section called genview (the download file is called gentable.zip) that receives a view name as a parameter and creates a programmatic definition of the view. With this definition in hand, you can open you real database and run the program and the view and all of its properties are ireplicated in the second database. The file gentable.prg does the same thing but for tables.

While this works without a hitch for the views, does GenTable update the DBF structure as well as the DBC? Otherwise you end up with an unValidated DBC file.

Sylvain, I prefer to use SDT for this. One of their options allows you to copy the new DBC tables plus the latest SDT tables into your live database, then run their Update program. Every table is updated, with all data and indexes being brought into the new structure. It isn't fast, but it's accurate and you can send these files to a customer or other site if the SDT code is installed.

HTH
Barbara
Barbara Paltiel, Paltiel Inc.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform