Quantcast
Channel: WinDev Forum
Viewing all articles
Browse latest Browse all 1914

Problem importing data from xBase

$
0
0
I have a very weird problem: I have to import data from an xBase app that allowed all kinds of errors to creep in so I have to import the data programmatically.
The problem is in the following section of code:
sTmpID = dsComp.COMP_ID
IF HReadSeek(RBL_COMP,COMP_ID,sTmpID) THEN
Info(sTmpID +" already on file")
ELSE
RBL_COMP.COMP_ID = sTmpID
END
// catch duplicate names
sTmpName = dsComp.Name
IF HReadSeek(RBL_COMP,NAME,sTmpName) THEN
sTmpName += "** GA **"
END
RBL_COMP.NAME = sTmpName // Problem occurs here

dsComp is the xBase file and RBL_COMP is the HFSQL Classic file

The 1st 6 records import just fine. I have the debugger set to show dsComp.COMP_ID and RBL_Comp.COMP_ID and I am single stepping through the code.

On the 7th record both variables show AMER04 until the last line above runs and then RBL_COMP.COMP_ID magically changes to AMER02 (which has already been imported in record 4)

What can possibly cause this?

Viewing all articles
Browse latest Browse all 1914

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>