I'm trying to mimic on how Oracle's send its SQL result to an a file when loading records to a table, creating indices, and creating tables in SQLCMD.
When creating a table in Oracle, we are able to generate an output file showing the structure of the table and the result which can either be that the creation of a table failed or all were successfully created. When loading data to tables in Oracle, we can produce an output file stating how many records were read, how many records were loaded successfully, and the records that failed. When creating indices in Oracle, we can produce an output file showing the indices that were created successfully, as well as those that failed. (FYI, that we call these output files as log files.)
I'm trying to mimic the above abilities in SQLCMD but with no success. I need to be able produce log files that shows what was performed correctly, along with a descriptive error message for those errors that may have occurred. Can someone point me in the right direction?
Our community of experts have been thoroughly vetted for their expertise and industry experience.
The Distinguished Expert awards are presented to the top veteran and rookie experts to earn the most points in the top 50 topics.