i have sql script (ex:a.sql) that generates 10 csv files
ex: a.csv
b.csv
c.csv .........
but donot want 10 separate csv files
i want a single csv files with 10 different tab that contains all data
is it possible from unix
In the script or command you do:
Then the first line will create a new file.csv file or else overwrite any existing file.csv, the second and third lines will append to the file.csv file.
...
i want a single csv files with 10 different tab that contains all data
is it possible from unix
...
A csv file is a plain text file with no formatting. As such, it cannot have "tabs" (unless I am missing something here.)
In case you mean an Excel workbook with more than one worksheet (a "tab" being a "worksheet"), then you can use perl.
This perl program loops through each csv file in the current directory and prints the data to a worksheet in the workbook "alldata.xls" in the current directory. The name of the csv file is the name of the worksheet.
In fact, you can reduce some overhead by avoiding the creation of these csv files in the first place.
If you know the structure of your SQL script (which, I am assuming, contains a lot of "spool" commands if your database is Oracle), then you can:
(1) Loop through the SQL script, saving each SQL or PL/SQL "block" in an array or an equivalent data structure.
(2) Connect to Oracle via DBI.
(3) Loop through the array created in Step (1) and execute a "block" per iteration.
(4) Create a worksheet and print the results in it.
(5) Repeat Steps (3) and (4) for the entire array.
(6) Close the DBI connection.
Hi,
I have the following reports that get generated every 1 hour and this is my requirement:
1. 5 reports get generated every hour with the names "Report.Dddmmyy.Thhmiss.CTLR"
"Report.Dddmmyy.Thhmiss.ACCD"
"Report.Dddmmyy.Thhmiss.BCCD"
"Report.Dddmmyy.Thhmiss.CCCD"... (1 Reply)
Hi,
We have developed Some BO reports in Webi and our requirements is as follows
1)ETL File will be generated and sent to BO server through autosys and once BO server receives that ETL file then BO reports are scehduled on Event based and triggered automatically.(If any failure in report... (0 Replies)
Hi,
We are planning for a report generation program in Linux.For that we are planning to use Oracle reports 6i on linux.
Could anybody please confirm if the Oracle 6i reports are compatible on Linux (0 Replies)
I have been asked to upload a font file for barcodes (3of9.ttf) to a unix server so that users of Oracle Reports on Oracle 10g can pick up this font. Where should this file be placed? (0 Replies)
Hi unixers, :)
Anyone have any links or online tutorials for Shell Scripting with respect to Oracle .
Any example of script calling any Oracle procedure or function or passing parameters is highly appreciated. (6 Replies)
Hi,
We are planning to migrate oracle 8.1.7.2 (8i) currently installed on a host with HP unix 11.0 to a host with HP Unix 11i.
The method we are adopting is backup and restore of all file systems.
Could this be a problem, apart from linking libraries on the target system.
Thanks for the... (1 Reply)
HI
I am battling to find why oracle reports dont work from the Oracle applications and work from the Command line
Finally, whern these reports error out in the Oracle apps, I see the error that the x server killed the process.
Please let me know if any one has some chi-chi sheet on the os setup... (1 Reply)