🔒 All tools run entirely in your browser. No data leaves your device.

SQL*Plus Output Cleanup

Strip SQL*Plus banners, prompts, and footers from captured output and convert tabular results to CSV, Markdown, or JSON. Handles multiple result sets.

About this tool

SQL*Plus output is human-readable but not machine-friendly. A typical spool file is half banner, query prompts, session metadata, and "N rows selected." footers, wrapped around the actual tabular result. This tool strips the noise and converts the data into CSV, Markdown, or JSON that you can paste into a spreadsheet, a ticket, or a JSON-consuming script.

The parser works by finding the line of dashes SQL*Plus prints under the column headers. That line defines column positions, which are then used to slice each data row into fields. Multiple result sets are handled independently — blank lines separate them.

Best results come from cleaner capture. Before running your queries, set SET LINESIZE 32767 (so rows don’t wrap), SET WRAP OFF, SET TRIMSPOOL ON, SET FEEDBACK OFF, SET TERMOUT OFF. That removes most of the cleanup burden up-front. If you already have wrapped output, the parser still does its best but cannot perfectly reassemble rows that have been split.

Lines matching ORA-xxxxx, SP2-xxxx, or TNS-xxxxx error codes are preserved to a separate panel so you can see both the cleaned data and whatever went wrong.

Frequently asked questions

Will this work with SQL Developer output?

Mostly. SQL Developer emits cleaner tabular output than SQL*Plus and generally does not need cleanup. If you have saved output with the SQL Developer "Unload" option, pick CSV or JSON at export time instead of using this tool.

Can I extract multiple result sets from one SQL*Plus session?

Yes. Result sets are split by blank lines. Each is parsed independently so a spool file with several queries is handled in one pass. For JSON output, multiple result sets become an array of arrays; for CSV and Markdown they are separated by a blank line.

What about very wide columns that wrap?

Best effort. SQL*Plus wraps lines by default when output exceeds LINESIZE; the cleanup then sees a broken row that does not align with the dashes. Fix at capture time: `SET LINESIZE 32767` and `SET WRAP OFF` before running your queries, then recapture.

Does this handle international characters?

Yes. Input and output are UTF-8 throughout. If your SQL*Plus session wrote a different encoding, reconvert the file before pasting.

Are ORA errors preserved?

Yes. Any line starting with ORA-xxxxx, SP2-xxxx, or TNS-xxxxx is moved to a side panel so you see both the errors and the cleaned data.