Solved

dbase III to dbase V

Posted on 1999-01-16
17
773 Views
Last Modified: 2012-08-13
I have .dbf file in dbase III and III+.
I wish to convert these into dbase V (I have dbase5 for DOS)
so that the date field can accept (and show) the year in 4-digit form. My (Clipper 5.2e) software is Y2K compliant with the setcentury ON.
Thank you
0
Comment
Question by:sallym98
  • 6
  • 6
  • 3
  • +1
17 Comments
 
LVL 4

Expert Comment

by:siabod
ID: 1026287
export the file from db3 in csv file formate and import it into db5 again

i think thats the easiest way



0
 

Author Comment

by:sallym98
ID: 1026288
18-01-1999
Thank you siabod. But I am no computer nerd. Please be kind enough and be more specific. How should I do that ? EXPORT command in dbase5 help didn't show the "csv" format.
Once again, tks a lot.
0
 
LVL 5

Expert Comment

by:chewhoung
ID: 1026289
Excuse me but I though dbf file only store 2 digit for year no matter what version it is?
What you need to do is change your code in Clipper so that it will show/accept four digit for year.
put this code in the main Clipper program, and change all your input/output of date field to four digit year:

set date format to 'dd/mm/yyyy'
or
set date format to 'mm/dd/yyyy'
0
 
LVL 4

Expert Comment

by:siabod
ID: 1026290
hmmm... well you can use copy to bla.dbf type delimited also
that will give you a tab-delimited file

what chewhoung said is true also....
if you want a 4 digit field in your database, consider a text field with the following structure: yyyymmdd
that makes it still usefull for SORT
0
 
LVL 5

Expert Comment

by:chewhoung
ID: 1026291
One important thing in Clipper Y2k compliance:
use the set epoch command:

set epoch to 1920

read up the help for this command if you don't understand.
0
 

Author Comment

by:sallym98
ID: 1026292
Well ! siabod and chewhoung. You are the EXPERTS.

My NEXT question :
Our in-house programmer has gone stateside for a better job, and we are stuck with an .EXE (clipper5.2e/Blinker 3.0) w/o source.
Have included the SETCENTU command into the .exe with an off-the-shelf Y2K-fix. Worked fine as is!
Have de-compiled w/RESCUE5 that generated quite neat codes including .LNK and .RMK they claim useful to Remake the application.
Our company is willing to compensate your precious time spent to do the following : (we have 2 similar programs) :
1. provide me with a batch file so that I just blindly re-compile the applications.
2. next stage, whenever there is a modification that requires Coding, you will do the job. (I am no programmer myself, and now I donot want to search for new local programmers whereas the same problem might happen again).
3. the source to be re-compiled will be modified by me to accept local language as well.

Thks a lot for your kind assistance so far.
0
 
LVL 4

Expert Comment

by:siabod
ID: 1026293
i think i'll pass this one to chewhoung, i think he's better in these things than i am....
0
 
LVL 1

Accepted Solution

by:
GerardKeating earned 100 total points
ID: 1026294
Sally,

dBase III (and dbase II, dbase III+, VI, V etc) all store the dates with the full year.

If your Clipper 5.2e program is not showing the full century, even with Century on, they check the code used to display the dates.

It IS possible to override the set century setting. look for something like "99/99/99" in the code, this is a formatting code to display a date. The version listed above will supress the century.

IF you find code like this, change it to "99/99/9999".

Also check for multiple Set Century commands, it could be turn on at the start of the program, and they turned off later.

cheers

Gerard
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Author Comment

by:sallym98
ID: 1026295
GerardKeating's proposed answer - all together with PAM/SIABOB/CHEWHOUNG are in all fairness EXCELLENT in that they all have pinpointed the very nature of the problems I may have encountered.
But this has resumed to ONE final solution i am looking for :
HOW TO RE-COMPILE A DE-COMPILED PROGRAM. I shall need a batch file (i am no programmer) so to be able to compile the source codes generated by RESCUE5 and their .LNK and .RMK files.
Anyone familiar with RESCUE5 may help.
Tks a lot & Best Rgds to ALL who have taken the time to scrutinize my problems.
 
0
 
LVL 5

Expert Comment

by:chewhoung
ID: 1026296
sallym98,
Can you please tell me exactly who solved your problem?
And
What are you proposing?
Your company offer us a job to do?

GerardKeating,
please be sure when you answer. Dbase file does not store full date. They only store 2 digit for year.
0
 

Author Comment

by:sallym98
ID: 1026297
TO:GeradKeating.
Thks for your reminder. As you are postive that dBase does NOT store full date, I overcome it by setting the date field to Character. Just fine. One problem solved. Tks.

TO:CHEWHOUNG
Yes our Comapny does offer a job to do :
1. ASAP : to issue a batch file for RE-compiling an application (Clipper5.2e/Blinker3.0) that was de-compiled by RESCUE5. Quite neat source codes, as well as *.LNK and *.RMK to Rmake the application (RESCUE5 dixit).
Ready to send you the .exe, .prg and the .lnk for your perusal.
In the meantime, Best Regards to all.
0
 
LVL 5

Expert Comment

by:chewhoung
ID: 1026298
My email:chewhoung@yahoo.com
0
 
LVL 1

Expert Comment

by:GerardKeating
ID: 1026299
ChewHoung,

dBase files do Store full date, examine one in a text editor, or some others means if you want to confirm this, dates are stored as yyyymmdd, so today would be 19990121.

Sally,

Mail me the lnk,rmk files and i will do you a batch file to compile the system for you.

This batch file will assume you have clipper etc. installed on your system. You might indicate the drive/directory clipper in on, unless you have already set up a path to it.

cheers

gerard
0
 
LVL 5

Expert Comment

by:chewhoung
ID: 1026300
GerardKeating, OK, you are right, I've forgotten that.
The most important one is having the set epoch command in the source code.
0
 

Author Comment

by:sallym98
ID: 1026301
Gerard
Tks for your last comments. Sending you the .Lnk & .Rmk for the batch file, via another e-mail address.
Cordially. Sally.
Pls always reply to me either via expertsexchange or sallym98@hotmail.com
Cheers.

0
 

Author Comment

by:sallym98
ID: 1026302
>GerardKeating said:
>Dbase file does not store full date. They only store 2 digit >for year.

>ChewHoung said :
>dBase files do Store full date, examine one in a text editor, >or some others means if you want to confirm this, dates are >stored as yyyymmdd, so today would be 19990121.

Message :
"Fear is the most fearsome".
Application does read dBaseIII date-of-last-update as YY MM DD in a 3-bytes binary format.
You have to assume that the cc is correct because you have SET CENTURY ON in your source. Assuming is to guess 50% wrong. And read the date in ascii to confirm is Not always the best way to the application is actually reading the .dbf in a dBase format and might behave wrongly.
We are a Member-Club-Restaurant and our Members have an automatic discount-on-Bills when their Membership has not expired. What if on 31-12-1999 past one minute after midnight the date that the application is looking at shows some fancy cc ? When champagne was flowing ? Chaos. the real one.
To set the date to input/output yyyyddmm have to be followed with the "reading" in correct order (versus dd/mm/yy) : which order of digit ? Source has to be modified in many areas. That is why I need to compile. To see is to believe. I need to see the real ccyy/dd/mm (with slashes if possible - looks nicer)
Cheers.
0
 
LVL 5

Expert Comment

by:chewhoung
ID: 1026303
Reply to me via my email chewhoung@yahoo.com
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This article describes some very basic things about SQL Server filegroups.
APEX (Application Express) is used to develop a web application from Oracle. SQL Workshop is one of the tools that comes with Oracle APEX to query or modify the database objects or to make any changes to the structure.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now