blob problem

Hi, We’ve got a client on 2.60 Navison Server, whereas we use only 3.60 SQL Server. Client needed us to dataport data out of a backup table and into the production table under an emergency situation. Table has five blob fields, all containing text. Dataport wouldn’t handle the blob fields, so we restored the key/value data but not the blob data. Now, we need to restore the blob portion of the data. My understanding is: I’ll need to create a program iterating through the backup table, finding matching index value in production table, then updating missing field data. The question is, do I have to use streams to achieve this, or is there some easier method? waynewil

Hi, I would suggest that you write a routine that would run through the old table and find the match and bring it into the new table. Thanks Best regards Suresh New York.

Suresh, That’s what I intend to do. But keep in mind, I can’t overwrite the entire record – data has been accumulating. So I still have to handle the specific blob field values from source to target. Anyone else? Waynewil

How about exporting and importing the BLOB fields programmatically inside the dataport? The file names should be constructed from the primary key values and BLOB field names of the current record.

Maybe you can do the following (unless I misunderstood the question): Make a batch that exports the blob files. The filename of those files should include the key plus field number. Sample: If you key is “Customer, Postingdate” the filename should be something like 100000919031.txt (customer 10000, date 091003, field 1). Now write an batch that can import these files. But if you want to transfer fields between tables within one database it should be possible to do this without exporting. I think. Source.get(Key); Source.calcfields(Blob); Target.Key := Source.Key; Target.Blob := Source.Blob; IF not Target.insert then Target.modify; Code has not been tested.