2GB limits on SQL*PLUS output file

Hi,
We are running 64bits Oracle 8.1.7.4 and SQL*PLUS 8.1.7.0 on 64 bit SunOS. There is no limit on file size on the unix login and I am able to work with file over 2GB.
However, I am not able the output over 2GB to text file from SQL*PLUS. The SQL*PLUS keeps running, but the file size fize does not incease after 2GB.
Can anyone help me?
Thanks,
CK

In SQL*Plus 9.0 the SQL*Plus I/O architecture was
rewritten and many (all?) 32 bit operating systems that
have 64bit I/O packages allow SPOOLing more than 2G.
See enhancement request 697548.
A dedicated OCI or Pro*C application may be faster for
spooling large files, depending on the output formatting
requirements.
-- CJ

Similar Messages

  • SQL Plus flat file

    I'm trying to write a SQL script that will generate a comma delimited file for use with Excel. When I execute the following line by line in SQL Plus, everything works fine. However, when I save the script in a file and open the file with SQL plus, it doesn't generate the file.
    Can someone please tell me what I'm missing here?
    Thank you very much.
    Robert
    set heading off
    set feedback off
    set trimspool on
    set echo off
    set pagesize 0
    spool c:\spool\data.txt
    select la.code ||','|| lai.code|| ',' || la.title as data
    from drLAInstanceMeeting laim
    inner join drLearningActivityInstance LAI on lai.id=laim.learningActivityInstanceID
    inner join drLearningACtivity LA on la.id=lai.learningActivityID
    where abs(meetingEnd - meetingStart) > (6/24);
    spool off

    I have continued to play with the above script, and found more information that may be helpful. When the script is executed I receive the following error:
    Is there something I need to do to use the SET command in a saved script?
    SQL> list
    1 set heading off
    2 set feedback off
    3 set trimspool on
    4 set echo off
    5 set pagesize 0
    6 spool c:\spool\data.txt
    7 select la.code ||','|| lai.code|| ',' || la.title as data
    8 from drLAInstanceMeeting laim
    9 inner join drLearningActivityInstance LAI on lai.id=laim.learningActivityInstanceID
    10 inner join drLearningACtivity LA on la.id=lai.learningActivityID
    11 where abs(meetingEnd - meetingStart) > (6/24)
    12 /
    13* spool off
    SQL> /
    set heading off
    ERROR at line 1:
    ORA-00922: missing or invalid option

  • Can I make SQL*Plus output more readable like this ?

    Version : 11.2
    Can I make sql results more readbale like below using SqlPlus ? ie. enclosing result columns neatly in a table like structure.
    +------------+------------+
    | department | Avg Salary |
    +------------+------------+
    | Finance    | 63863.2479 |
    | Hardware   | 66308.3700 |
    | HR         | 66402.6549 |
    | QA         | 66012.7119 |
    | Software   | 61928.2700 |
    | Switch     | 66413.2231 |
    +------------+------------+I think this is from MySQL or Postgress (the below doesn't anything about that)
    http://guylichtman.com/db-spring06/hw1_solution_sql.txt
    If not possible using SQL*Plus , can this be done using some other tools like PL/SQL developer (which we have) ?
    Not a business case . I just want to send some SQL training stuff to my friend.
    Moreover , during posting in OTN, it would be better to post some sample data , so that volunteer gurus can quickly understand what they are looking at.

    Hi,
    GarryB wrote:
    Version : 11.2
    Can I make sql results more readbale like below using SqlPlus ? ie. enclosing result columns neatly in a table like structure.The default output is in a table-like structure, with rows and columns, and with the columns aligned. It looks like you want extra lines around those rows and columns.
    +------------+------------+
    | department | Avg Salary |
    +------------+------------+
    | Finance    | 63863.2479 |
    | Hardware   | 66308.3700 |
    | HR         | 66402.6549 |
    | QA         | 66012.7119 |
    | Software   | 61928.2700 |
    | Switch     | 66413.2231 |
    +------------+------------+COLSEP is an easy way to get some of what you want:
    SQL> SET  COLSEP  "  |  "
    SQL> SELECT * FROM scott.dept;
        DEPTNO  |  DNAME           |  LOC
    ----------  |  --------------  |  -------------
            10  |  ACCOUNTING      |  NEW YORK
            20  |  RESEARCH        |  DALLAS
            30  |  SALES           |  CHICAGO
            40  |  OPERATIONS      |  BOSTONSQL*Plus can also generate HTML output, but you have to use a browser, not the SQL*Plus interface, to get see the output formatted.
    I think this is from MySQL or Postgress (the below doesn't anything about that)
    http://guylichtman.com/db-spring06/hw1_solution_sql.txt
    If not possible using SQL*Plus , can this be done using some other tools like PL/SQL developer (which we have) ?
    Not a business case . I just want to send some SQL training stuff to my friend.
    Moreover , during posting in OTN, it would be better to post some sample data , so that volunteer gurus can quickly understand what they are looking at.If we could get everyone on this forum to post any kind of formatted output, that would be wonderful! Personally, the extra lines wouldn't help me any, however.

  • SQL Developer output vs. SQL Plus output

    Hi, newb with issues showing output. I have a simple function that works correctly when called in SQL + however, when I right click and run in SQL Developer, I get a Run PL/SQL window with:
    v_Return := LISTEMPLOYEETELEPHONES();
    -- Modify the code to output the variable
    --DBMS_OUTPUT.PUT_LINE('v_Return = ' || v_Return);
    Where does the output go ? If I uncomment the DBMS_OUTPUT.PUT_LINE, I get a wrong number or types of arguments in call to '||'
    What am I doing wrong ?

    Hi mattgn,
    not to fire a discussion, just to be little more precise ;-)
    I don't get your answerWell, I hope pmacd55 gets it, as he's the one with
    the problem.This is a pubblic forum, everybody should get something useful here. I didn't stated that I was right and you wrong, not at all. Simply, If I don't get it, probably also somebody else will not get it as well.
    I misunderstood the first poster, my eyes slipper over "UNcomment": reading as "If I COMMENT the DBMS_OUTPUT.PUT_LINE, I get a wrong number or types of arguments in call to '||'" I thought that in some way SQL Developer could break the line before the submission of the statement.
    So, your hypothesis looks the right one.

  • SQL Plus Login issue

    Please assist...when i am trying to login following error is occuring ....
    Enter user-name: / as sysdba
    ERROR:
    ORA-01031: Message 1031 not found; No message file for product=RDBMS,
    facility=ORA

    Maran thanks for the prompts replies, i have already set the variables & restarted the machine but there is no change. please see below;
    C:\Documents and Settings\Administrator>sqlplus
    Error 6 initializing SQL*Plus
    Message file sp1<lang>.msb not found
    SP2-0750: You may need to set ORACLE_HOME to your Oracle software directory
    C:\Documents and Settings\Administrator>d:
    D:\>cd oracle
    D:\oracle>cd ora92
    D:\oracle\ora92>cd bin
    D:\oracle\ora92\bin>sqlplus
    SQL*Plus: Release 9.2.0.6.0 - Production on Fri May 11 17:31:09 2007
    Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
    Enter user-name: / as sysdba
    ERROR:
    ORA-01031: Message 1031 not found; No message file for product=RDBMS,
    facility=ORA

  • Set Up SQL*Plus Issue

    Folks,
    Hello. My Operating System is Oracle Linux 5. Database is Oracle DB 11gR1.
    I have tried to set up SQL*Plus in the following way:
    My directory: /home/myOracle/OracleDB_Home/bin
    SYSTEM_PASS=SYSTEM/SYSTEM
    export SYSTEM_PASS
    ./sqlplus SYSTEM/SYSTEM
    But this message comes up:
    Error 6 initializing SQL*Plus
    Message file sql<lang>.msb not found
    SP2-0750: You may need to set ORACLE_HOME to your Oracle Software directory.
    Where is message file sql<lang>.msb ? What is Oracle Software directory ?
    Can any folk help to solve this issue ?

    Duplicate post
    Re: Set Up SQL*Plus Issue

  • Im getting this error after trying to laounch SQL*Plus

    Hallo, guys!
    Help me on this one. I'm new to Oracle on Windows 2000 Professional
    Im getting this error after trying to laounch SQL*Plus
    Error 6 Initializing SQL*Plus
    Message file spl<lang>.msb not found
    SP2-0750:You may need to set ORACLE_HOME to your Oracle Software directory
    Urgent please respond
    Thanks
    sridhar

    Verify the contents of the following subkey in your Windows2000 registry:
    HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\KEY_YOUR_HOME_NAME
    Your Windows 2000 registry must contain several minimum parameters, defined as registry entries inside the above subkey (See http://download-east.oracle.com/docs/cd/B19306_01/win.102/b14304/registry.htm#i1006544). One of them is ORACLE_HOME, which could have been accidentally removed or changed. ORACLE_HOME must contain the home OS path to the SQL*Plus executable in your machine (For example, C:\Oracle\OraDB10g). I tried changing the name of the ORACLE_HOME registry entry in my machine and received the same exact messages you did when launching SQL*Plus.
    In your OS, verify also Control Panel > System Properties > Advanced > Environment Variables > System Variables > Path, and make sure the above ORACLE_HOME's path is included in the Path variable (preferably in the starting position)
    Regards,
    Luis Morales
    ConsiteNicaragua.com

  • Error 7 initializing SQL*Plus

    Hi,
    when I laucnh sqlplus I obtain this error:
    oracle@gami7ot1:/grid/app/9.2.0>sqlplus
    Error 7 initializing SQL*Plus
    Message file sp2<lang>.msb not found
    oracle@gami7ot1:/grid/app/9.2.0>which sqlplus
    /grid/app/9.2.0/bin/sqlplus
    I have these environment settings:
    oracle@gami7ot1:/grid/app/9.2.0>env
    _=/usr/bin/env
    LANG=en_US
    LOGIN=oracle
    SSH_TTY=/dev/pts/0
    PATH=/grid/app/9.2.0/bin:/usr/bin:/etc:/usr/sbin:/usr/ucb:/home/oracle/bin:/usr/bin/X11:/sbin:.:
    NLS_LANG=AMERICAN_AMERICA.UTF8
    ORACLE_BASE=/grid/app
    LC__FASTMSG=true
    EDITOR=vi
    LOGNAME=oracle
    MAIL=/usr/spool/mail/oracle
    ORACLE_SID=TEST
    LOCPATH=/usr/lib/nls/loc
    USER=oracle
    AUTHSTATE=compat
    SHELL=/usr/bin/ksh
    ODMDIR=/etc/objrepos
    HOME=/home/oracle
    SSH_CONNECTION=172.27.1.176 8799 172.27.13.210 22
    SSH_CLIENT=172.27.1.176 8799 22
    TERM=xterm
    MAILMSG=[YOU HAVE NEW MAIL]
    ORACLE_HOME=/grid/app/9.2.0
    PWD=/grid/app/9.2.0
    TZ=Europe/Rome
    A__z=! LOGNAME
    NLSPATH=/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat
    LIBPATH=/grid/app/9.2.0/lib:/grid/app/9.2.0/lib32:/usr/dt/lib:/usr/openwin/lib:/grid/app/9.2.0/ctx/lib
    LD_LIBRARY_PATH=/grid/app/9.2.0/lib:/grid/app/9.2.0/lib32:/usr/dt/lib:/usr/openwin/lib:/grid/app/9.2.0/ctx/lib
    this is my oratab:
    oracle@gami7ot1:/grid/app/9.2.0>cat /etc/oratab
    +ASM1:/grid/11.2.0:N            # line added by Agent
    #TEST:/grid/app/product/10.2.0:N
    TEST:/grid/app/9.2.0:N
    What I'm doing wrong?

    Hi BelMan,
    this works fine:
    oracle@gami7ot1:/home/oracle>export ORACLE_HOME=/grid/11.2.0
    oracle@gami7ot1:/home/oracle>export ORACLE_SID=+ASM
    oracle@gami7ot1:/home/oracle>/grid/11.2.0/bin/sqlplus
    SQL*Plus: Release 11.2.0.1.0 Production on Tue Jul 27 12:51:44 2010
    Copyright (c) 1982, 2009, Oracle. All rights reserved.
    Enter user-name:
    But I need to use 9.2.0.8 home!

  • SQL*Plus - multiple commands

    Is there a way to execute multiple commands in a single sql*plus command file, e.g.
    select count(*) from table1
    select count(*) from table2
    The above gets a syntax error becuase of the multiple commands

    Hi,
    If you just want counts from two tables, you could try:
    select
    (select count(*) from table1) Count_Tab1,
    (select count(*) from table2) Count_Tab2
    from dual;
    Regards Robert

  • SQL PLUS log input and output to file

    What is the way to log every activity in sqlplus, input and output to a file (interactively).
    I managed to do it using rlwrap and tee but the only problem is, it is displaying the password and logging it into file as well :D. I can remove it from the logfile but am unable to prevent from showing the password.
    I hope many might have wanted to do this, and some might have been succeeded. Please share your ideas!

    N:\tools>sqlplus siva
    SQL*Plus: Release 10.2.0.1.0 - Production on Thu May 19 03:12:04 2011
    Copyright (c) 1982, 2005, Oracle. All rights reserved.
    Enter password: password
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    SQL> exit
    Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining optionsThe password is displayed on screen and it is in the log file as well.
    Here is the some environmental setup;
    I've installed cygwin with rlwrap package
    I've renamed the original sqlplus.exe to _sqlplus.exe
    I've placed mysqlplus.bat and sqlplus.bat in N:\tools and this location includes in the pathwhere sqlplus.bat contains
    @echo off
    rlwrap -a"Enter" mysqlplus.bat %*perhaps this is more related to linux commands but I want to log input and output of sqlplus!
    :)

  • Hello, How do I tell sql+ to spool output file from windows to Unix server?

    Hello, How do I tell sql+ to spool output file from windows to Unix server?
    I am new to SQL+ and just learned how to spool the file. But file is saved in my local windows enviroment and since it's 2GB in size...I want to spool it directly to another remote unix server.
    Pls answer in detail... I have been to most of the thread and didn't see relevant answer to above question.
    Am I suppose to develope some script which FTP the spool file directly to the server I want to
    or
    i Have to use UTL_FILE Package ?
    Thanks for reply

    You may not be able to...
    SQL*Plus can only spool to the local machine. If you have mapped a directory on the Unix server from your Windows machine, you can specify that directory in your SPOOL command.
    You could telnet to the Unix server, run SQL*Plus there, and spool the file to a local (Unix) directory.
    If the Unix server is also the Oracle database server, you could use the UTL_FILE package rather than using SQL*Plus to spool a file.
    If the Unix server is also an FTP server, you could also FTP the file from your local machine to the server.
    Of course, I would tend to re-examine a requirement to regularly generate a 2 GB text file. It seems likely that there is a better way...
    Justin

  • SQL*Plus - how to suppress the SQL in a spool file

    This is my SQL*Plus script. I thought I had solved the problem, but it is back now and I don't know what I am missing. But I don't want the query at the top of the file.
    SET SERVEROUTPUT ON
    SET MARKUP HTML ON -SILENT
    SET ECHO OFF
    SET PAGESIZE 33
    SET TERMOUT OFF
    Spool C:\DuaneWilson.xls
    SELECT *
    FROM RPT_DS1_CNT_CAT_vw
    WHERE ROWNUM <=100
    ORDER BY CVBI_KEY;
    SET MARKUP HTML OFF
    SET ECHO ON
    SET PAGESIZE 20
    SET TERMOUT ON
    SET SERVEROUTPUT OFF

    It turns out when I run the script with the @ or Start with the file name, there is no SQL put out to the file. But when I just copy the text out of the file and run it at the prompt, the SQL appears in the output file. In reference to the -SILENT, I put that in after the MARKUP statement and got an error. Maybe I don't know where that goes. And I am not sure why there is a difference if it is run as a script or just pasted to the buffer. At least it should be the same in the output file, I would think.

  • Seek help to format spool file from SQL*PLUS

    I am running a Unix shell script to call a Oracle 11g SQL script from a Oracle database. In this SQL script, I need to connect to many different remote databases to select data, then sool these records as one big text file to a directory. Then email the file to related Group users. In the spool file, there is a line on the top of each page like this:
    DUMMY
    DB_NAME
    I know this is caused by connect to remote database in SQL*PLUS. My connection string is like this:
    Conn system/password@Oracle_SID
    How can I remove these lines or how to skip these lines into spool file? Please advise. Thanks in advnce. Wish all of you Happy New Year!!!

    Hi,
    It sounds like you have some kind of formatting (such as SQL*Plus TTITLE) producing the output you don't want. If that's the case, temporarily stopping the spooling might not help you. Find out what is causing the output that you don't want. You say that you know it is caused by the CONNECT statements, but it must be more than that. I've written scripts with CONNECT statements that don't have anything like what you reported at the top of each page; in fact, they don't even have pages: the output is one continuous stream. Find out what's putting the unwanted output there, and that will be a big clue as to how you can stop it.
    You say that you know the unwanted titles are there because of the CONNECT statements. If so, use database links instead of CONNECT. You don't have to use dbms_scheduler or utl_file; just eliminate the CONNECT statements. (I'm not saying that there's anything wrong with dbms_scheduler or utl_file; you should definitely investigate those tools. I'm just saying that using database links is independent of them.)
    What would happen if you did all your connecting to different databases at the OS level? Can you write a shell script that connects to each database in turn, and runs a SQL*Plus script in each one. Each SQL*Plus script would have a SPOOL or SPOOL ... APPEND command, or maybe you could build the SPOOL into a LOGIN.SQL script.

  • Fnd_file.put_line(FND_FILE.OUTPUT in Ora Apps in SQL*Plus program

    I have used fnd_file.put_line(FND_FILE.OUTPUT and fnd_file.put_line(FND_FILE.LOG many times for programs registered as PL/SQL Stored Procedure or used in DB Packages to write to the concurrent manager output and log files. No problem doing that. I have a simple program that I was going to register in Oracle Apps as a SQL*Plus script (instead of creating a DB procedure) that contains a PL/SQL block and will use fnd_file.put_line to write the output so it can be seen from the Concurrent Mgr View Requests. When the script runs the fnd_file.put_line(FND_FILE.OUTPUT... doesn't write to the output (or log) file. I am guessing fnd_file.put_line(FND_FILE.OUTPUT is not available to programs registered as SQL*PLUS.
    Is that correct? Am I missing something simple that would allow it to run without creating a DB procedure/package.
    I am testing this with a very simple script just to see if I can get something written to the output and log files.
    SET SERVEROUTPUT ON
    declare
    x varchar2(20);
    Begin
    select 'test'
    into x
    from dual;
    fnd_file.put_line(FND_FILE.LOG,'In the log file');
    fnd_file.put_line(FND_FILE.OUTPUT,'In the output file');
    end;
    Thanks for taking the time to read this and any offers to help

    I think you should post it in the relevant Oracle Apps forum and not here. It seems that - you may have some problem regarding any privileges or missing some property which needs to be configure.
    Regards.
    Satyaki De.

  • Can v read a client text file using SQL*plus??

    We have a requirement like this: We need to read a text file to find spelling mistakes. Problem is the file has to be always moved to the DB machine, which is a Linux box and then run a stored procedure which uses UTL_FILE. Now in order to show the spelling mistakes of the file the user will have to again copy the file with the spelling mistakses (output file) from Linux to Windows.
    Is there a way to do it using SQL*Plus, where the text file is in the client machine???? Then users don't have to copy the file to and from the Linux box.

    SQL*Plus is a client software and whatever code you write using SQL*Plus, it ultimately run on the server. So the answers to your question is "no".

Maybe you are looking for