Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How do I change data DataSet read from a file?

Status
Not open for further replies.

GreenKnight

Programmer
Nov 9, 2001
17
0
0
GB
Hi,

I am trying to transport specific data from one (Oracle) database to another. At the moment I am exporting a series of datasets to XML files (using
Code:
TADODataSet.SaveToFile(<filename>, pfXML);
).

I want to load the tables into new datasets, and manipulate the fields in the dataset prior to inserting the data into my database. I am using
Code:
TDataSet.LoadFromFile(<filename>)
to read the data in (which works fine for getting the data), but I cannot change any of the data in this dataset! It is set as read-only for some reason, and I can't change this.

Can anyone suggest a method for importing this data?

The two other methods I'm trying to avoid are:
1) Load the data directly into a temporary table, amend the data in this table, copy the data to the existing table, and drop the temporary table.

2) Load the data into a class hierarchy I design, manipulate the data, then write it to the database.

Thanks in advance,
Rod.
 
Just a guess: have you tried a clientdataset pointing to your adodataset? That might make it editable.

Good luck! TealWren
 
It am using a
Code:
TADODataSet
object. Sorry if I didn't mention that.

GK.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top