SQL Developer formatted output

Hello,
Could you please help me in getting the formatted output on Oracle sql developer tool, I am not able to find andy options to set
I have copy paste the result from this tool to excel, I am getting plain text out put, I have more columns and readablity is not there
Regards,
Neil
Edited by: NeilCSE on Apr 6, 2010 6:01 AM

Hi,
try this.
I am on windows
SQL> spool c:\emp_text.txt;
Started spooling to c:\emp_text.txt
SQL> select ename||'|'||empno from emp;
ENAME||'|'||EMPNO
JAMES|7900
FORD|7902
MILLER|7934
SMITH|7369
ALLEN|7499
WARD|7521
JONES|7566
MARTIN|7654
BLAKE|7698
CLARK|7782
SCOTT|7788
KING|7839
TURNER|7844
ADAMS|7876
14 rows selected
SQL> spool off;
Stopped spooling to c:\emp_text.txtThen open in excel as delimeted by |
Regards,
Bhushan

Similar Messages

  • SQL developer script output problem

    HI,
    when I use sql plus every column is separated while in sql developer is mixed, or coalesced.
    I cannot clearly see the columns in the output.
    tnx

    I assume you are using the F5 "Run Script" option to execute your queries; in this case the output is produced in a sql plus like text.
    But since not all of the formatting options of sql plus are completely implemented in SQL Developer the output is not guaranteed to be like the one produced by sql plus.
    The easiest thing to do in this case is running your queries with the F9 "Run Statement" this will produce output in an excel like table that can be controlled by right clicking on the table headers and selecting the appropriate auto-fit behavior.

  • SQL Developer formatting script output

    Im new to sql developer. I have been unable to format the script output to decrease the width of the column below.
    All numeric columns seem to use 22 underscores. I would like to format this to make it more presentable to users.
    I have tried column, substr, and the various trims. While these work in native unix, they do not seem to work in
    SQL Developer. Up till now I have found SQL Developer to be a very usefull tool. I hope this is just a matter of me not
    having enough knowledge of the product and not a problem with it.
    Any and all assistance greatly appreciated.
    MACCNO
    3021202

    788184 wrote:
    What I need is to produce the following (column is numeric 5)
    HEAD1
    12345
    instead of what comes out currently
    HEAD1
    12345
    Yes, have checked preferences but could not see anything to change.
    Edited by: 788184 on 12/08/2010 19:55I think the problem is related to SQL*PLUS. SQL Developer tries to mimick SQL*PLUS whan you run something as a script. The mimicking s not perfect though.
    The size of this line depends on the typeof the database field. For numbers a larger line is taken. For varchar2 it depends from the size of the values or the header.
    If you are absolutly sure that data inside this column is always smaller, then you could try the following thing.
    select cast(HEAD1 as varchar2(5)) as HEAD1 from yourTableBe careful since this will do a number to string conversion. But since it seems to be for reporting purposes that should be ok.

  • Headless sql developer - format.sh

    Hey All.
    We have a lot of plsql code that isn't formatted consistently. We're trying to use format.sh that's shipped with sql developer from the command line.
    I've tried -Djava.awt.headless=true, but wasn't quite sure how to use it.
    I've tried setting DISPLAY to 0, 0.0, and localhost:0.0 and nothing seem to work.
    I can get format.bat to work on windows xp just fine. Any ideas? Thanks.
    format.sh input=<infile> output=<outfile>
    Oracle SQL Developer
    Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved.
    java.awt.HeadlessException:
    No X11 DISPLAY variable was set, but this program performed an operation which requires it.
    at java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:159)
    at java.awt.Window.<init>(Window.java:432)
    at java.awt.Frame.<init>(Frame.java:403)
    at javax.swing.JFrame.<init>(JFrame.java:202)
    at oracle.ide.IdeCore$StartupWindow.<init>(IdeCore.java:1960)
    at oracle.ide.IdeCore.startupImpl(IdeCore.java:1148)
    at oracle.ide.Ide.startup(Ide.java:703)
    at oracle.ideimpl.DefaultIdeStarter.startIde(DefaultIdeStarter.java:35)
    at oracle.ideimpl.Main.start(Main.java:184)
    at oracle.ideimpl.Main.main(Main.java:146)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at oracle.ide.boot.PCLMain.callMain(PCLMain.java:62)
    at oracle.ide.boot.PCLMain.main(PCLMain.java:54)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at oracle.classloader.util.MainClass.invoke(MainClass.java:128)
    at oracle.ide.boot.IdeLauncher.bootClassLoadersAndMain(IdeLauncher.java:189)
    at oracle.ide.boot.IdeLauncher.launchImpl(IdeLauncher.java:89)
    at oracle.ide.boot.IdeLauncher.launch(IdeLauncher.java:65)
    at oracle.ide.boot.IdeLauncher.main(IdeLauncher.java:54)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at oracle.ide.boot.Launcher.invokeMain(Launcher.java:713)
    at oracle.ide.boot.Launcher.launchImpl(Launcher.java:115)
    at oracle.ide.boot.Launcher.launch(Launcher.java:68)
    at oracle.ide.boot.Launcher.main(Launcher.java:57)

    Hi,
    Keep in mind that 0.0 represents the main console which you may not even be at. For example, I can start multiple vncserver sessions, one at :1, another at :3, then depending on which I connect to ...
    1. env | grep DISPLAY will show either :1.0 or :3.0
    2. who output should also show which display each <userid> pts/<n> points to.Similar considerations if you connect via ssh -X <hostname>.
    And how you set the display depends on your shell. For example, if it is not set and you wish to display to :1...
    1. export DISPLAY=:1.0 for bash-like shells (bash, sh, etc)
    2. setenv DISPLAY :1.0 for C shell based shells (csh, tcsh, etc)Hope this helps,
    Gary

  • SQL Developer Script Output too limited for student - how to increase?

    I'm just a student trying to migrate from notepad and SQL Plus to using the SQL Developer for the comprehensive course project. Unfortunately, the script output is way too limited... it only reports a fourth of my last assignment's results - not enough to use in the project. How specifically can this be increased. I have version 1.1.0.21 running on Windows XP on a laptop with 512k memory.
    Thanks much for any/all assist. I don't want to go back to notepad!!

    Thank you for the advice, but I had tried that. My script is 305 lines counting blank lines and the SQL developer displays only about 35 lines of results corresponding to 58 lines of input. When I run the same script in SQL Plus in a console window using the @filename command, I get the entire output.
    My input and output follow:
    Input:
    spool project-test-out.txt
    prompt 'name'
    prompt 'Assignment X, parts 2b - 2h and 3a - 3b '
    create table Customer (
         CustID Integer,
    Name Char(10),
    State Char(2),
         primary key (CustID) );
    create view CustID_List (ID_Cust) as (select custID from Customer);
    create table Inventory (
    PartID Integer,
    Item Char(10),
    Cost Float,
    OnHand Integer,
         primary key (PartID) );
    create table Invoice (
    InvNum Integer,
    InvDate DATE,
    CustID Integer,
         primary key (InvNum),
    foreign key (CustID) references Customer);
    create table Invoice_Item (
    InvNum Integer,
    PartID Integer,
    Quantity Integer,
         foreign key (InvNum) references Invoice,
         foreign key (PartID) references Inventory);
    insert into customer values ( 101, 'Kerry', 'MA' );
    insert into customer values ( 102, 'Edwards', 'NC' );
    insert into customer values ( 103, 'Cheney', 'TX' );
    insert into customer values ( 104, 'Bush', 'TX' );
    insert into Inventory values ( 1, 'Boots ', 149.95, 6 );
    insert into Inventory values ( 2, 'Spurs ', 12.95, 24 );
    insert into Inventory values ( 3, 'Buckle ', 19.95, 4 );
    insert into Inventory values ( 4, 'Hat ', 60.00, 12 );
    insert into Inventory values ( 5, 'Holster', 75.00, 8 );
    insert into Inventory values ( 6, 'Saddle ', 350.00, 2 );
    prompt 'Part grad 3b - unsatisfying solution, limitations of Oracle 10g Express'
    prompt 'After many trials, found oracle discussion on web stating that'
    prompt 'Oracle 9 does not allow subqueries in the trigger WHEN clause.'
    prompt 'What a pain. Thus the solution here has become rather inelegant.'
    prompt 'The trigger and following select statement are byproducts of various'
    prompt 'simplification attempts, none of which worked.'
    select ID_Cust from custID_List;
    create trigger Invoice_CustID_CK before insert on Invoice
         REFERENCING NEW AS newCustID
         FOR EACH ROW
         BEGIN
              if (:newCustID.CustID = 205 )
    --     {{want line below but it generates error of: subquery not allowed in }}
    -- {{this context }}
    --          if (:newCustID.CustID NOT IN
    --               (Select ID_Cust from CustID_List))
              then :newCustID.CustID := NULL;
              end if;
         END;
    run;
    show errors trigger Invoice_CustID_CK;
    insert into invoice values ( 201, '01-Aug-2006', 101 );
    insert into invoice values ( 202, '02-Sep-2006', 101 );
    insert into invoice values ( 203, '05-Oct-2006', 103 );
    insert into invoice values ( 204, '07-Oct-2006', 102 );
    insert into invoice values ( 205, '09-Oct-2006', 205 );
    insert into Invoice_Item values ( 201, 1, 1 );
    insert into Invoice_Item values ( 201, 2, 1 );
    insert into Invoice_Item values ( 202, 5, 2 );
    insert into Invoice_Item values ( 203, 1, 2 );
    insert into Invoice_Item values ( 203, 2, 2 );
    insert into Invoice_Item values ( 203, 3, 2 );
    insert into Invoice_Item values ( 203, 4, 2 );
    insert into Invoice_Item values ( 204, 4, 2 );
    insert into Invoice_Item values ( 204, 1, 1 );
    select * from invoice;
    select * from customer;
    select * from invoice_item;
    select * from inventory;
    prompt 'Preparation for part 2b - create view showing onhand and starting inventory'
    alter table inventory add (start_inventory integer);
    update inventory
    set start_inventory = onhand;
    create view inv_changes as
    select partid, sum(quantity) as sales_by_id
    from invoice_item
    group by partid;
    create table inventory_invoiced as
    select inventory.partid, item, cost, onhand, start_inventory, COALESCE (sales_by_id, 0) as sales_by_id_NZ
    from inventory left outer join inv_changes
    on inventory.partid = inv_changes.partid;
    select * from inventory_invoiced;
    update inventory_invoiced
    Set
    onhand = onhand - sales_by_id_NZ;
    select * from inventory_invoiced;
    prompt 'Part 2b - What item has the least on hand inventory after processing the invoices?'
    select item
    from inventory_invoiced
    where onhand = (select min(onhand) from inventory_invoiced);
    prompt 'Part 2c - How much does customer 101 owe?'
    create view cust101_orders as
    select distinct partID, quantity
    from invoice_item, invoice
    where invoice_item.invnum IN
    (select I.invnum from invoice I where I.custid = 101);
    select * from cust101_orders;
    select sum(quantity * cost) as cust101_bill
    from cust101_orders, inventory
    where cust101_orders.partID = inventory.partID;
    prompt 'Part 2d - Which customer has the biggest bill?'
    prompt ' desirable solution is to do part 2c as a general case '
    prompt ' using a stored function such that the custID is passed '
    prompt ' to the function. Unfortunately, neither function below '
    prompt ' compiles. First case trips on creating the view. Second'
    prompt ' case being arewrite without a view - ifit even works - '
    prompt ' trips on the complicated select'
    create or replace function ind_customer_bill
    (ind_customer_ID in integer)
    return Float
    IS ind_total_bill Float;
    begin
    create view cust_orders as
    select distinct partID, quantity
    from invoice_item.invnum IN
    (select I.invnum from invoice I where I.custid = ind_customer_ID);
    select sum(quantity * cost) into ind_total_bill
    from cust_orders, inventory
    where cust_orders.partid = inventory.partid;
    drop view cust_orders;
    return (ind_total_bill);
    end;
    show errors function ind_customer_bill;
    create or replace function ind_customer_bill
    (ind_customer_ID in integer)
    return Float
    IS ind_total_bill Float;
    begin
    select sum(quantity * cost) into ind_total_bill
    from inventory, (select distinct partID as interim_partID, quantity
              from invoice_item.invnum IN
              (select I.invnum from invoice I where I.custid = ind_customer_ID))
    where interim_partID = inventory.partid;
    return (ind_total_bill);
    end;
    show errors function ind_customer_bill;
    Prompt 'part 2d continued using shameful brute force technique'
    select * from cust101_orders;
    create view cust101_due as
    select sum(quantity * cost) as cust101_bill
    from cust101_orders, inventory
    where cust101_orders.partID = inventory.partID;
    create view cust102_orders as
    select distinct partID, quantity
    from invoice_item, invoice
    where invoice_item.invnum IN
    (select I.invnum from invoice I where I.custid = 102);
    select * from cust102_orders;
    create view cust102_due as
    select sum(quantity * cost) as cust102_bill
    from cust102_orders, inventory
    where cust102_orders.partID = inventory.partID;
    create view cust103_orders as
    select distinct partID, quantity
    from invoice_item, invoice
    where invoice_item.invnum IN
    (select I.invnum from invoice I where I.custid = 103);
    select * from cust103_orders;
    create view cust103_due as
    select sum(quantity * cost) as cust103_bill
    from cust103_orders, inventory
    where cust103_orders.partID = inventory.partID;
    create view cust104_orders as
    select distinct partID, quantity
    from invoice_item, invoice
    where invoice_item.invnum IN
    (select I.invnum from invoice I where I.custid = 104);
    select * from cust104_orders;
    create view cust104_due as
    select sum(quantity * cost) as cust104_bill
    from cust104_orders, inventory
    where cust104_orders.partID = inventory.partID;
    prompt 'and the answer to part 2d - biggest bill is'
    select *
    from cust101_due, cust102_due, cust103_due, cust104_due;
    prompt 'Part 2e - What items were the most popular (most sold)'
    select item
    from inventory_invoiced
    where sales_by_id_NZ >= ANY (
    select max(sales_by_id_NZ) from inventory_invoiced);
    prompt 'Part 2f - What was the value of the original inventory'
    select sum (start_inventory * cost) as total_start_inventory
    from inventory_invoiced;
    prompt 'Part 2g - What was the value of the ending inventory'
    select sum (onhand * cost) as total_ending_inventory
    from inventory_invoiced;
    prompt 'Part 2h - What customers did not place an order'
    -- after some testing of the inner nest parts wherein the left outer join
    -- results in a CustID_List entry 104 having a null entry in
    -- invoice's CustID list.
    select Name
    from customer
    where custID IN (select ID_Cust
    from (select ID_Cust, CustID
    from CustID_List left outer join invoice on
    ID_Cust = CustID)
    where CUSTID IS NULL);
    prompt 'Part 3a - What items were not purchased by anyone'
    select item as unpurchased
    from inventory_invoiced
    where sales_by_id_nz = 0;
    prompt 'Part 3b - table modifications for invoices to have valid CustID'
    prompt ' -- see 3b section at top of file, notes and trigger '
    drop view cust101_due;
    drop view cust102_due;
    drop view cust103_due;
    drop view cust104_due;
    drop function ind_customer_bill;
    drop view cust101_orders;
    drop view cust102_orders;
    drop view cust103_orders;
    drop view cust104_orders;
    drop table inventory_invoiced;
    drop view inv_changes;
    drop view custID_List;
    drop table invoice_item;
    drop table invoice;
    drop table inventory;
    drop table customer;
    Output:
    'name'
    'Assignment X, parts 2b - 2h and 3a - 3b '
    create table succeeded.
    create view succeeded.
    create table succeeded.
    create table succeeded.
    create table succeeded.
    1 rows inserted
    1 rows inserted
    1 rows inserted
    1 rows inserted
    1 rows inserted
    1 rows inserted
    1 rows inserted
    1 rows inserted
    1 rows inserted
    1 rows inserted
    'Part grad 3b - unsatisfying solution, limitations of Oracle 10g Express'
    'After many trials, found oracle discussion on web stating that'
    'Oracle 9 does not allow subqueries in the trigger WHEN clause.'
    'What a pain. Thus the solution here has become rather inelegant.'
    'The trigger and following select statement are byproducts of various'
    'simplification attempts, none of which worked.'
    ID_CUST
    101
    102
    103
    104
    4 rows selected
    trigger Invoice_CustID_CK Compiled.

  • SQL developer not showing compiler warnings

    I'm just testing out the new compiler warning contained in 11g related to the "when others" exception handler when it does not have a subsequent raise or raise_application_error.
    in SQL plus, this works fine:
    SQL> alter session set plsql_warnings='enable:all';
    Session altered.
    SQL>
    SQL> create or replace function do_stuff
      2  return number
      3  as
      4     v_return number;
      5  begin
      6
      7     v_return := 3;
      8     return v_return;
      9
    10  exception
    11  when others then
    12     return null;
    13  end;
    14  /
    SP2-0806: Function created with compilation warnings
    SQL> show errors;
    Errors for FUNCTION DO_STUFF:
    LINE/COL ERROR
    1/1      PLW-05018: unit DO_STUFF omitted optional AUTHID clause; default
             value DEFINER used
    11/6     PLW-06009: procedure "DO_STUFF" OTHERS handler does not end in
             RAISE or RAISE_APPLICATION_ERRORbut in SQL developer the output is:
    BANNER                                                                          
    Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production    
    PL/SQL Release 11.2.0.3.0 - Production                                          
    CORE     11.2.0.3.0     Production                                                        
    TNS for Linux: Version 11.2.0.3.0 - Production                                  
    NLSRTL Version 11.2.0.3.0 - Production                                          
    session SET altered.
    FUNCTION do_stuff compiled
    No Errors.Anyone experience this issue? is there some setting that makes SQL developer behave differently?

    it must be something I'm doing wrong, above, I was running under windows 7 pointing at the version above.
    I just tried it under an Enterprise Linux pointing at
    Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - Production          
    PL/SQL Release 11.2.0.2.0 - Production                                          
    CORE     11.2.0.2.0     Production                                                        
    TNS for Linux: Version 11.2.0.2.0 - Production                                  
    NLSRTL Version 11.2.0.2.0 - Production                                           and I get exactly the same script output and no compiler window....
    actually...... if I go into a procedure window from the schema browser and compile it there, then I get the correct warning messages..... the problem is I mostly develop from .sql files extracted from source control rather than directly from the schema browser, I just want the sql worksheet to be able to show me the same compiler log window.....

  • How to integrate the Data modeler in Sql developer

    Hi
    How can we integrate the data modeler into sql developer and use the data modeler?
    Thanks

    Integrating different oracle products (SQL Developer [Data Modeller], JDeveloper, ...) on platforms like Eclipse, Netbeans, JDeveloper Framework is a really missing feature.
    JDeveloper has a good approach for integrated Java and database development, but has not immediate benefits from from other development streams like SQL Developer.
    On daily work we must use more than three different tools for most common task
    - editing stored functions, procedures and packages with SQL-Developer (code formatter in Jdeveloper produces sometimes UNREADABLE code ( So we are using TOAD instead ). Why can't Jdeveloper use SQL-Developer formatting tools in bug fixed verrions from 1.5.5?
    - database modelling with SQL Developer Data Modeler without PLSQL package support ???
    - database development with JDeveloper, ADF and offline database model without capabilities for logical databse models
    Please put them all together!

  • Formatting SQL Output in SQL Developer

    I tried to google around a little bit and wasnt able to find an answer really.
    In 10g and in SQL plus i remember being able to format output as follows
    Using the generic HR schema and the following query i get the following output
    BREAK ON REPORT
    COMPUTE SUM LABEL TOTAL OF SALARY ON REPORT
    SELECT LAST_NAME, SALARY
    FROM EMP_DETAILS_VIEW
    WHERE JOB_ID='SA_MAN';
    Expected output
    LAST_NAME SALARY
    Russell 14000
    Partners 13500
    Errazuriz 12000
    Cambrault 11000
    Zlotkey 10500
    TOTAL 61000
    Now using SQL developer I am no longer getting the TOTAL line and only the following
    LAST_NAME SALARY
    Russell 14000
    Partners 13500
    Errazuriz 12000
    Cambrault 11000
    Zlotkey 10500
    Was this unique to SQL plus the formatting?
    Is there anything similar i can do in SQL Developer?
    Thanks in advance

    SQL Developer
    As its name implies, it was never intended to be a data reporting utility.
    It was designed to develop SQL & PL/SQL code.
    When your only tool is a hammer, all problems are viewed as nails.
    While a hammer is a GREAT tool, it is suboptimal to divide 1 board into 2 pieces.
    My father always told me to use the proper tool for the task at hand.
    You should consider following this advice.

  • Format script output in SQL developer

    HI,
    when I use sql plus every column is separated while in sql developer is mixed, or coalesced.
    I cannot clearly see the columns in the output.
    tnx
    Edited by: user10491698 on 07-Sep-2011 06:37

    You could ask in the {forum:id=260} forum ;-)

  • Can SQL Developer be used for Oracle Support "HTML Output" Diag Scripts ?

    Hi All,
    Oracle Support has asked me to run a diagnostic script (OTL_Diag.sql for anyone familar with the script) that produces output in HTML format using SQL*Plus to help troubleshoot an OTL problem we are having. Unfortunately I don't have SQL*Plus installed and my company is not on board with me installing it because of the SQL*NET connection required. Instead I have access to SQL Developer 3.1.0.7. While this works fine for most situations I'm having problems generating the required .html output file that Support needs.
    I've tried runing the OTL_Diag.sql a couple of ways using SQL Developer. First, I opened the file from SQL Developer and using the Run Script functionality (F5) I executed the code that way. This method did give me an opportunity to input the necessary parms and it did create the 'start' of the HTML file on my (Windows) file system, but the script seemed to abort with a java error that indicated some sort of format error (sorry, I'm not a java person so I can't provide any more info, but I'll be glad to get the exact error message if anyone thinks that will help solve my issue).
    My second approach was to open a SQL Window where I typed in @C:\OTL_Diag.sql without quotes. This approach also gave me the opportunity to enter the necessary input parms and it seemed to end normally. It also created the 'start' of the diaganostic output file on my Windows file system, but it 'completed' before any of the 'real' diaganostic output was written to the .html file.
    The Metalink note clearly specifies that the OTL_Diag.sql script is to be run with SQL*Plus 10.2 or above so I don't think I can complain too loudly to Oracle about this...but given that I don't have access to this product (and it is useless for me to again ask to install it) I am hoping someone out there has some ideas or insight as to how I can use SQL Developer to execute this diag script in a manner that will produce the required .html output file.
    Thanks in advance to anyone taking time to read my post !!
    Jeff
    Edited by: user13111861 on Jul 10, 2012 6:43 PM
    Edited by: user13111861 on Jul 10, 2012 7:51 PM

    >
    As a result, at this point in time my only available tool to run the OTL_Diag.sql script (provided by Oracle Support) is SQL Developer
    >
    Then you will have to edit the script, break it into pieces, execute each piece manually and save the output to feed into the next piece as required based on what the script is actually doing. Don't post the script or contents as that will likely violate your support agreement.
    As I already mentioned the script may be using syntax and/or commands that are simply not supported by sql*developer. One likely area is the script may be producing intermediate output scripts that are then processed by a later portion of the script. If that is the case then my suggestion to execute the pieces manually should work but you will need to do some trial-and-error to see.
    Even if you appear to be successful you will still have an issue when you communicate the results of your 'test' to Oracle support and they determine you didn't follow their instructions to use the proper tool.
    Sounds like your management is either ignorant or incompetent so I suggest you cover yourself by documentating the instructions from Oracle support and the direct orders you were given to disregard those instructions. No need to discuss that issue further but clearly there are resources available somewhere in the org that has the proper privileges or they wouldn't be able to maintain and support the database. If they want to pay for support they should heed their advice. Nuff said.

  • Oracle SQL Developer 3.2, SQL*Plus COLUMN FORMAT bug

    SQL*Plus command COLUMN truncates output result in SQL Developer.
    Script in Worksheet:
    column nn format 999
    select level nn from dual connect by level<=10;The Run Script (F5) result contains only 8 lines in Script Output window:
    NN
    1
    2
    3
    4
    5
    6
    7
    8
    Changing column alias:
    select level nn2 from dual connect by level<=10NN2
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    10 rows selected
    The output can contain no data for more formatted columns.
    ===============================================================
    About
    Oracle SQL Developer 3.2.09
    Version 3.2.09
    Build MAIN-09.30
    Copyright © 2005, 2012 Oracle. All Rights Reserved.
    IDE Version: 11.1.1.4.37.59.48
    Product ID: oracle.sqldeveloper
    Product Version: 11.2.0.09.30
    Version
    Component     Version
    =========     =======
    Java(TM) Platform     1.7.0_02
    Oracle IDE     3.2.09.30
    Versioning Support     3.2.09.30

    sqldeveloper64-3.2.09.30-no-jre.zip.
    My jdk now is 1.7.07 x64, Windows 7 x64.
    C:\Java\jdk17\bin>java -version
    java version "1.7.0_07"
    Java(TM) SE Runtime Environment (build 1.7.0_07-b11)
    Java HotSpot(TM) 64-Bit Server VM (build 23.3-b01, mixed mode)
    Gary Graham wrote:Also, I don't understand what you mean by
    The output can contain no data for more formatted columns.
    Sript:
    col owner format a10
    col table_name format a20
    col column_name format a20
    col comments format a50
    select
       row_number() over(order by column_name) r11,   
       count(*) over() c11,
       owner ow,
       table_name tn,
       column_name cn,
       comments co
    from all_col_comments t
    where owner='SYS' and table_name='INDEX_STATS';
    select
       row_number() over(order by column_name) r,   
       count(*) over() c,
       owner,
       table_name,
       column_name,
       comments
    from all_col_comments t
    where owner='SYS' and table_name='INDEX_STATS';
    select 1 from dual;
    prompt abcThe output truncated after headers of second queryR11 C11 OW                             TN                             CN                             CO                                                                                                                                                        
      1  25 SYS                            INDEX_STATS                    BLKS_GETS_PER_ACCESS           Expected number of consistent mode block gets per row. This assumes that a row chosen at random from the table is being searched for using the index
      2  25 SYS                            INDEX_STATS                    BLOCKS                         blocks allocated to the segment                                                                                                                    
      3  25 SYS                            INDEX_STATS                    BR_BLKS                        number of branch blocks in the b-tree                                                     
      4  25 SYS                            INDEX_STATS                    BR_BLK_LEN                     useable space in a branch block                                                           
      5  25 SYS                            INDEX_STATS                    BR_ROWS                        number of branch rows                                                                     
      6  25 SYS                            INDEX_STATS                    BR_ROWS_LEN                    sum of the lengths of all the branch blocks in the b-tree                                 
      7  25 SYS                            INDEX_STATS                    BTREE_SPACE                    total space currently allocated in the b-tree                                             
      8  25 SYS                            INDEX_STATS                    DEL_LF_ROWS                    number of deleted leaf rows in the index                                                  
      9  25 SYS                            INDEX_STATS                    DEL_LF_ROWS_LEN                total length of all deleted rows in the index                                             
    10  25 SYS                            INDEX_STATS                    DISTINCT_KEYS                  number of distinct keys in the index                                                      
    11  25 SYS                            INDEX_STATS                    HEIGHT                         height of the b-tree                                                                      
    12  25 SYS                            INDEX_STATS                    LF_BLKS                        number of leaf blocks in the b-tree                                                       
    13  25 SYS                            INDEX_STATS                    LF_BLK_LEN                     useable space in a leaf block                                                             
    14  25 SYS                            INDEX_STATS                    LF_ROWS                        number of leaf rows (values in the index)                                                 
    15  25 SYS                            INDEX_STATS                    LF_ROWS_LEN                    sum of the lengths of all the leaf rows                                                   
    16  25 SYS                            INDEX_STATS                    MOST_REPEATED_KEY              how many times the most repeated key is repeated                                          
    17  25 SYS                            INDEX_STATS                    NAME                           name of the index                                                                         
    18  25 SYS                            INDEX_STATS                    OPT_CMPR_COUNT                 optimal prefix compression count for the index                                            
    19  25 SYS                            INDEX_STATS                    OPT_CMPR_PCTSAVE               percentage storage saving expected from optimal prefix compression                        
    20  25 SYS                            INDEX_STATS                    PARTITION_NAME                 name of the index partition, if partitioned                                               
    21  25 SYS                            INDEX_STATS                    PCT_USED                       percent of space allocated in the b-tree that is being used                               
    22  25 SYS                            INDEX_STATS                    PRE_ROWS                       number of prefix rows (values in the index)                                               
    23  25 SYS                            INDEX_STATS                    PRE_ROWS_LEN                   sum of lengths of all prefix rows                                                         
    24  25 SYS                            INDEX_STATS                    ROWS_PER_KEY                   average number of rows per distinct key                                                   
    25  25 SYS                            INDEX_STATS                    USED_SPACE                     total space that is currently being used in the b-tree                                    
    25 rows selected
    R C OWNER      TABLE_NAME           COLUMN_NAME          COMMENTS                                        
    - - ---------- -------------------- -------------------- --------------------------------------------------

  • SQL Developer Migation Tool - formating generated SQL

    I am using SQL Developer version 2.1.1.64 to migrate MS SQL server to ORACLE via the Migration tool.
    My question is : Is there a way to format the generated ORACLE code?
    The reason I ask, our developmet team has coding standards for creating procedures. For example, use TABs for identation, not spaces.
    I changed the profiles under the SQL formatted (Tools>Preferences>Database>SQL Formatter>ORACLE Formatting) but it does not seam to affect the generation output.
    The code is always generated using spaces.

    Ctrl-shift-f7 invokes the formatter. This can be defaulted to your standards by choosing them from the preferences.
    B

  • SQL Developer 4.0 EA3. query result in export format problem

    Query output in export format (insert, csv, xml,...) is not working in 4.0 EA3.
    Query executed as script (F5) does not display anything:
    select /*insert*/ * from dual;
    SQL Developer 3 displays the result correctly:
    REM INSERTING into dual
    SET DEFINE OFF;
    Insert into "dual" (DUMMY) values ('X');
    About
    Oracle SQL Developer 4.0.0.13
    Version 4.0.0.13
    Build MAIN-13.30
    IDE Version: 12.1.3.0.41.131007.2031
    Product ID: oracle.sqldeveloper
    Product Version: 12.2.0.13.30
    Version
    Component    Version
    =========    =======
    Oracle IDE    4.0.0.13.30
    Java(TM) Platform    1.7.0_07
    Versioning Support    4.0.0.13.30

    That's been fixed for the next release.

  • Copying from Oracle SQL Developer to Microsoft Word doesn't retain formatting (Font,colors etc)

    Copying from Oracle SQL Developer Worksheet doesn't retain formatting (font,color etc...)in Microsoft Word but copying from other programs such as
    visual studio, chrome browser etc works fine. This doesn't work even after changed the setting to Keep Source formatting of Options-> Copy and Paste Settings

    Hi,
    I notice that you have cross posted in Answers forum and Oracle forum. Have you tried Mr. Peter's suggestion?
    Then, I recommend we check the Word settings:
    1. Go to: Options > Advanced > Cut, Copy and Paste
    2.  Make sure that Use smart cut and paste is ticked. 
    3. Click the Settings button next to this option
    4. Make sure that Smart Style
    Behavior is checked.
    If the issue still exists, please upload a sample through One Drive, I want to test.
    Regards,
    George Zhao
    TechNet Community Support

  • How to get server output in SQL Developer

    I am learning SQL Deverloper and am using it in a University environment as well as Oracle test instances at Oracle.
    I know my way around SQL some but I am just learning PL/SQL.  I want to run an anonymous block and see output for the "dbms_output.put_line" items.
    At school, I enter my block in the "SQL Worksheet" and receive the "anonymous block completed" in the "Script Output" screen.  Then there is a 3rd screen, the name of which I cannot remember, but I believe it is the equivalent of "server output".  When I open it I have to tell it which database I'm using.  Then, I see the dbms output lines in this 3rd section.
    The problem is when I am using SQL Developer at work, I see only 2 sections:  "SQL Worksheet" and "Script Output".
    I have looked but cannot find an option or a button or a window that is called something like "server output" or "view server output."
    Can a more experienced user please help me?
    I am using:
    SQL Developer Version 3.1.07
            Build MAIN-07.42
    Linux x86-64
    (Oracle Internal:
    Instance: http://celalnx38.us.oracle.com:10507/
    tnsnames: 10500)

    Hi Makel,
    There are no changes of which I am aware in the Dbms_Output view functionality between the 3.2 and 4.0 releases.
    As to your point about confusion, keep in mind the following:
    1. Each Worksheet tab and Dbms_Output tab include the name of the connection in use.  Match on that name when checking output results.
    2. Opening multiple Worksheets on the same connection name will share one database connection by default.
    3. Multiple Worksheets sharing a database connection also share one Dbms_Output tab.  That is by design.
    To force worksheets to use unshared connections:
    4. Change the default behavior of (2) via Tools -> Preferences -> Database -> Worksheet -> New Worksheet to use unshared connection.
    5. Or avoid (4's) overhead of always using unshared connections by opening one-off unshared Worksheets: Ctrl + Shift + N from a shared Worksheet.
    Finally:
    6. When using unshared Worksheets, one Dbms_Output tab may be opened per unshared Worksheet.  Note that the names of any unshared Worksheets will appear in Dbms_Output's Select Connection dialog drop down list. That should avoid any confusion.
    Hope this helps,
    Gary

Maybe you are looking for

  • How do I get the music from "On This iPod" onto my Library?

    Not all of the music on my iPod is on my iTunes but now with the new iTunes 11 when I plug in my device I can look at all of the stuff on my iPod under the tab "On This iPod". I've been trying to get all of my music from my iPod onto iTunes for ages

  • How to open document from mac when using windows without transferring the file?

    How can i open a document from mac when i am using windows without transferring it?

  • Java engine problem

    Hello all, i have a problem with the Java SP 18 and I welcome any answer on this problem. Description: OS: Windows 2003 R2 x64 DB: Oracle 10.2.0.2 x64 On this server already is installed Solution Manager 4.0 and  a mySAP ERP 2004 system with Java add

  • Sap R3 471 system copy error

    Dear all: Migration  evironment: Source system: DEV system:SAP R/3 Enterprise 4.7x110,non-unicode, SID:DEV,database schema:SAPPRD (because through brbackup / brrestore manner transplant from production system,then change the SID) DB:Oracle 9.2.0.4.0

  • How to display LOGO in ALV grid when using class CL_GUI_ALV_GRID

    Hello everyone, please let me know how to display Company logo as the header part in the report program with the class cl_gui_alv_grid. Thanks and regards, Padma.