Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

blanks lines in between data rows show up when using SPOOL in SQLPlus

Tags:

oracle

sqlplus

I'm trying to spool a large query in sqlplus but for some reason, I see 2 blank lines every 558 rows to be exact.

I spool as such:

SET TERMOUT OFF
SET ECHO OFF
SET LINES 1000
SET FEEDBACK off
SET HEADING OFF
SET ARRAYSIZE 10000
SET NEWPAGE NONE
SET PAGESIZE 0
SET TRIMSPOOL ON
Spool D:\IPORT15.csv
select query
Spool OFF;
EXIT

I thought SET NEWPAGE was supposed to take care of that??

like image 845
lightweight Avatar asked Dec 05 '13 01:12

lightweight


People also ask

What is set Pagesize?

The PAGESIZE setting tells SQL*Plus the number of printed lines that will fit on one page of output. You can also use this setting to completely turn off all pagination functions.

What is set Linesize in Oracle?

SET LINESIZE sets the total number of characters that SQL*Plus displays on one line before beginning a new line. Keep LINESIZE as small as possible to avoid extra memory allocations and memory copying. However, if LINESIZE is too small, columns that cannot fit next to each other are put on separate lines.

How do I set the page size in SQL Plus?

At the SQL*Plus command line, type: set pagesize 30 - this will change the page size to 30 rows. set pause on - this will cause the output to pause every 30 lines; press the enter key to continue.


1 Answers

I was able to resolve this by setting: "SET PAGES 0"

like image 199
lightweight Avatar answered Oct 10 '22 00:10

lightweight