‎2008 Dec 15 11:07 AM
Hi All,
I have a requirement where I have to copy data from one struc to other. The algo implemented is something as under:
1. Select data from source acc to package size.
Total_records = total_records + number of records fetched.
2. move data to target structure.
3. write this data to a file on app server
3. If tota_records >= some number 'XYZ', then
4. call a report in background to read data from file specified in step3, and put this data in target table.
5. end select.
Now, since I have to split the complete data into multiple tasks for updation, I want to create separate files on the app sever for diff set of records.
For ex, for the first10000 records file name shud be X1 . Using this file step4 would be processed.
For next 10000 records file generated is X2. Using this file the 10000 records selected are processed using step4.
MY QUERY IS: HOW CAN I GENERATE FILENAMES SUCH AS X1 ,X2 ETC ON THE APPLICATION SERVER. CAN I DO THAT DIRECTLY USING OPEN DATASET <FILENAME>?
Thanks-
HS.
‎2008 Dec 15 11:10 AM
hi,
yes you can directly download data into application server using
OPEN DATASET
‎2008 Dec 15 11:10 AM
hi,
yes you can directly download data into application server using
OPEN DATASET
‎2008 Dec 15 11:11 AM
HI,
Yes you can do with the open dataset...before calling the Open Dataset generate the file name dynamically.
‎2008 Dec 15 11:18 AM
Hi Harmeet,
It maybe an idea to create all your files first before you start to process them. This way you know you have considered all the source data.
Che
‎2008 Dec 15 11:20 AM
Hi ,
Yes this can be done .You can mention file path name and use OPEN DATASET and transfer records according to your requirement
‎2008 Dec 15 11:30 AM
I need to know that if a file name is non existent on app server, then will it be created when i use it.
for ex: dir_temp is the dir name.
in my report I use filename as dir_temp/X1 , then will this file X1 be created on app server.
‎2008 Dec 15 11:35 AM
The file will be created if it does not already exist.
Have you even tried reading the help on the OPEN DATASET statement?