Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Updatig DBC/DBF onto client site
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00451561
Message ID:
00452432
Views:
26
Fred,Auke,
Thanks for your reply which gives me food for thought.

I was hoping there was sopmething already out there but I'll have a go.

Regards,

Gerard




>>I find myself continually amending DBC/DBf in the office and then needing to upgrade these onto the client's site, without zapping any data.
>>Without using a tool such as Stonefield (which I'm fairly sure would do it but I dont want to intoduce more variables at this stage), is there any 'easy' way of ensuring that Files on site are in sync with files at the office.
>>
>>Currently, I have to take a copy of the files, manually MODI DATA, and replicate each change to both the DBC and DBF's
>>
>>Regards,
>>
>>Gerard
>
>Along the same lines as Auke, create a program to do it. I start with GENDBC to give you the majority of the code. Then you have to test for the existance of the table to decide to create or not. Then step though each field to see it exists, then if it is the correct data type and size.
>
>I use my correctdata.prg to make changes in my development data that way it is anyways up-to-date.
>
>Here's a code snippit
>
>******************************************************
>WAIT CLEAR
>WAIT WINDOW [ Updating Person Table... ] NOWAIT
>
>LOCAL cpath, iretval, aryfields
>
>IF NOT USED([player])
> SELECT 0
> USE cybersports!player SHARED
>ENDIF
>
>IF USED([player])
>
> SELECT player
>
> DO WHILE NOT FLOCK([player]) AND icnt < 100
>
> ***
> WAIT [] TIMEOUT .1
> icnt = icnt + 1
> ENDDO
>
> IF FLOCK([player])
> USE IN player
> USE player EXCL
>
> DIMENSION aryfields(1)
> AFIELDS(aryfields,[player])
>
> IF ASCAN(aryfields,[ASSNCODE]) = 0
> ALTER TABLE player ADD COLUMN assncode c(10)
> ELSE
> ALTER TABLE player ALTER COLUMN assncode c(10)
> ENDIF
>***********************************************
>
>Hope this helps.
Previous
Reply
Map
View

Click here to load this message in the networking platform