Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Update ideas???
Message
From
30/09/1998 12:11:48
 
 
To
29/09/1998 10:32:06
General information
Forum:
Visual FoxPro
Category:
Stonefield
Title:
Miscellaneous
Thread ID:
00141934
Message ID:
00142444
Views:
31
Hi Bob.

>Is there any possible way that I could use the update facility when we allow our users to change the database?
>
>For example, I was thinking we could send the 'default' data dictionary which could be compared to the customers. Then, any differences would be made to the newly shipped datadictionary files. After this is done an update can be run?

It's always complicated when you want to allow your users to add their own fields; it's even more so in VFP since the DBF header isn't the only place a table structure is defined now.

1. Client-specific meta data tables.

Have a copy of COREMETA and SDTMETA in a special subdirectory) that exists only at the client site and defines which fields they've added; you never touch these files. When you ship an update, you'd merge the contents of theset tables with the COREMETA and SDTMETA you ship them, then you do the update. However, there's an additional complication: you also have to add these fields to the DBC. Unless you're familiar with the DBC structure, this isn't for the faint-hearted <g>. Because of the potential for mix-ups here, I don't recommend this approach (except perhaps for free tables).

2. Use a 1:1 related table for "custom" fields.

Say you have a CUSTOMER table and your client wants to add new fields. Have a separate table called CUSTUSER into which the new fields go, along with the primary key for the associated CUSTOMER record. CUSTUSER would be a free table not managed by SDT, so SDT would never try to make the client's structure match yours. You can set a relation between these tables in your forms and reports so the CUSTUSER record is automatically positioned to the appropriate record; it then logically acts like an extension of CUSTOMER.

3. Have pre-defined custom fields.

For example, have some fields like TEXT1, TEXT2, DATE1, DATE2, LOGICAL1, LOGICAL2, etc. Allow the users to assign their own captions to these fields (and if you want to get clever, only display them in forms and reports if the user has indicated that they're using these fields). Since these fields already exist, the client's structures always match yours.

Doug
Previous
Reply
Map
View

Click here to load this message in the networking platform