M
mitzoe
I apologize for any inappropriate cross-posting, but wasn't sure where
whether this is a Pervasive or ADO.NET issue.
I'm trying to migrate data from a propietary system that's based on
btrieve into Pervasive SQL 9.5 using a .NET application written in
C#. The main problem is that the existing system stores its data in
separate folders and files, so I'm having to read each file and copy
its data to its corresponding P.SQL table.
There are hundreds of folders, so doing this by hand is not feasible,
thus my little application.
What I've done is create an array of the files appropriate to each
table, iterate and copy each file into the P.SQL data folder, query
the table, and put into a DataSet using the Fill method, appending to
the records already there.
So at this point I have a DataSet of all the records. I'm leaving the
last file copied for that table and trying to use the DataAdapter's
Update method to move the DataSet into P.SQL, but when I do so nothing
happens. No error, but when I query the table in P.SQL, it's still
just the single record that resides in that last data file.
I suspect the problem is that I'm using repeated Fill calls, but I'm
not sure. I've tried the DataSet's AcceptChanges method before
calling Update, but no dice. I'm new to ADO.NET's DataSet and
DataAdapter objects, so any help would be appreciated.
Thanks in advance.
Michael Itzoe
(e-mail address removed)
whether this is a Pervasive or ADO.NET issue.
I'm trying to migrate data from a propietary system that's based on
btrieve into Pervasive SQL 9.5 using a .NET application written in
C#. The main problem is that the existing system stores its data in
separate folders and files, so I'm having to read each file and copy
its data to its corresponding P.SQL table.
There are hundreds of folders, so doing this by hand is not feasible,
thus my little application.
What I've done is create an array of the files appropriate to each
table, iterate and copy each file into the P.SQL data folder, query
the table, and put into a DataSet using the Fill method, appending to
the records already there.
So at this point I have a DataSet of all the records. I'm leaving the
last file copied for that table and trying to use the DataAdapter's
Update method to move the DataSet into P.SQL, but when I do so nothing
happens. No error, but when I query the table in P.SQL, it's still
just the single record that resides in that last data file.
I suspect the problem is that I'm using repeated Fill calls, but I'm
not sure. I've tried the DataSet's AcceptChanges method before
calling Update, but no dice. I'm new to ADO.NET's DataSet and
DataAdapter objects, so any help would be appreciated.
Thanks in advance.
Michael Itzoe
(e-mail address removed)