COLUMN command

In the query listed below, the line
column avail_reimb format 999,999,999.99 heading 'UNENCUMB|CARRY OVER|REIMB'
produces the headings
UNEMCUMB
REIMB
CARRY OVER
instead of
UNEMCUMB
CARRY OVER
REIMB
Any ideas why the second two heading items are switched? This problem
happens on both version 9.0.1 on NT and version 9.2 on Solaris.
set feedback off
set verify off
set pagesize 1000
set linesize 132
set headsep on
column extract_date new_value the_date noprint
select extract_date from basic02;
column avail_reimb format 999,999,999.99 heading 'UNENCUMB|CARRY OVER|REIMB'
column cy_reimb format 999,999,999.99 heading 'FUNDING|CHANGES'
select sum(a.fund_avail) avail_reimb,
sum(b.cfy_fund_auth) cy_reimb
from con_fund01 a, con_fund02 b
where substr(b.con_cog,1,1) like upper ('g')
and b.con = a.con (+)
and b.mfg_type_cd in ('0','9')
and b.purge_flag = 'N'

I've logged bug 2496738 against the SQL*Plus documentation.
I couldn't see any note that the COLUMN NEWLINE/FOLD_BEFORE/
FOLD_AFTER options are not supported in SET MARKUP HTML ON
mode. However this was a design feature/ restriction with
the workaround to specify SET MARKUP HTML PREFORMAT ON at
the top of the script. Is this w/a useful for you?
The documentation for the COLUMN options should be similar
to that of BREAK SKIP. See "SKIP n" at
http://otn.oracle.com/docs/products/oracle9i/doc_library/release2/server.920/a90842/ch13.htm#1007432
There was a bug fix in SQL*Plus 9.2 to prevent a possible
crash and to show a potentially undisplayed column for some
SELECT statements using COLUMN NEWLINE/FOLD_BEFORE/
FOLD_AFTER. This fix corrected (i.e. changed) the default
column width and column wrapping for some selects. The old
behavior (including potential crash) is available if SET
SQLPLUSCOMPATIBILITY is less than 9.2. If you have Oracle
Metalink access, see bugs 716638 and 2195379.
-- CJ

Similar Messages

  • Formatting output columns - ala SQL*Plus 'column' command

    SQL_Developer 1.5
    Is there a way to format the output of queries for numbers, etc. like the 'column' command found in SQL*Plus?
    I realize I can use the TO_CHAR() function in the SQL but was hoping there was something easier.
    Thanks very much!
    -gary

    it could be that the column of the table that you are trying to insert the data has a small length.

  • SQL*Plus column command not working with Script Runner

    SQL Developer EA 2.1
    When running a script (interactive or from a file), the COLUMN commands are ignored. The documentation (User's Guide 1.7.1) says that COLUMN is supported, but the headings set in the column command are not changed. As a test, the SET FEEDBACK OFF command is processed.
    SET FEEDBACK OFF
    COLUMN ename HEADING 'Name'
    COLUMN job HEADING 'Job'
    COLUMN deptno HEADING 'Dept'
    SELECT ename as ename, JOB, DEPTNO
    FROM EMPLOYEES;
    The documentation for Script Runner (User's Guide 1.7.2) says that a much more limited set of SQL*Plus commands are available.
    Is this intended behavior? If so, the documentation should reflect that the COLUMN command is ignored.

    Hi,
    Doc bug logged:
    Bug 9015160 - OTNEA1: USER GUIDE COLUMN SUPPORTS 'COLUMN...NEWVAL' ONLY
    The user guide says column is supported, but
    Column supports the following new_value use only
    i.e. moving a value from a selected column to a substitution variable:
    column aval new_v a
    select 1 aval from dual;
    select '&a' || ' is 1' from dual;
    Output:
    AVAL
    1
    1 rows selected
    '1'||'IS1'
    1 is 1
    1 rows selected
    -Turloch

  • Hide or show the Artist and Album columns Command +B not working -itunes 11

    Command +B 
    Shortcut
    Hide or show the Artist and Album columns  is not working no respond..-itunes 11  my desktop working but not my laptop MBA.
    why is that?
    anyone help me?

    oh ok.. itunes 11.0.1 update fixed this issue  ... !!

  • NULL option of column command - ignore word after space in string

    Hi,
    I'm quit new to Oracle and SQL world.
    building simple SQL/Plus report through SQL Developer enviroment:
    I'm trying to use NULL option of COLUMN comand to output a meaningful string instead null.
    But, any word after space in string.
    Followings are what I wrote on worksheet and excute 'Run Script'.
    COLUMN firedate NULL 'active';
    COLUMN mentorid NULL 'no mentor';
    select lastname, firstname, mentorid, firedate from members;
    refer to line (COLUMN mentorid NULL 'no mentor';) the out put for the MentorId, display word no and ignore any word after space which is here word mentor.
    My environment:
    SqL Developer ver. 3.1.07.
    Oracle database 10g Express edition (10.2.0.1.0)
    windows XP
    Much appreciated.

    SQL Developer is still not 100% SQL Plus compatible. It may be that this isn't implemented properly yet.
    Does it work in SQL Plus?

  • Command column data in SYSMAINTPLAN_LOGDETAIL in MSDB database?

    Hi All,
    I have been facing the data issue in SYSMAINTPLAN_LOGDETAIL table in MSDB.
    When I query on this table, I don't see data in "COMMAND" column.
    And also I am not able to view T-SQL in maintenance plan history as it is disable.
    Can any one please let me know the solution how can I get command column data into the table?
    thanks in advance.
    Nik
    Regards, Naman

    Hi,
    In SQL Server 2000 symaintplan table was acessible directly  but from 2005 onwards this table is not directly accessible due to increased security this table gets updated when maintenance plan runs. I dont think its a data issue i ran below commands
    on my SQL Server found some rows had some entries for column 'command' while some of it does not. Also curious thing was when col 'succeeded' value was zero this col had some text present. 
    select * from msdb.dbo.sysmaintplan_logdetail where command <> '' and succeeded= 0--executing select * can take long time please note depending on rows presentselect * from msdb.dbo.sysmaintplan_logdetail where succeeded= 0
    I cannot find any online documentation on msdb.dbo.sysmaintplan_logdetails to actually see what is being captured in this column.But what I can guess is it captures command which actually executed.This is a system table its difficult to tell how actually column
    command is updated
    Please mark this reply as answer if it solved your issue or vote as helpful if it helped so that other forum members can benefit from it.
    My TechNet Wiki Articles

  • Help with FIXED LENGTH columns - using spool command

    Hi guys,
    I have a view I am trying to spool using fixed length columns, and the spacing is off. Ive tried numerous things such as specifiying the column width before running the query, using the rpad command, but nothing seems to work. I have to spool it to a text file in order for the users to import this file into another system. I would welcome any and all suggestions. Thanks so much. The following is the view:
    SELECT "EMPLOYEE_ID","FIRST NAME","INITIAL","LAST NAME","SUFFIX","TRAINING DATE","Course ID","Class ID", "We", "Make / Model", "Cali", "Barrell", "Serial Number", "Qualification", "Application", "SCORE", "Status", "Add Time", "Record Add ID","Record Add Date","Record Change ID","Record Change Date","RN" FROM
    (SELECT
    UPPER(RPAD(tbl.ssn,10)) AS "EMPLOYEE_ID",
    UPPER(RPAD('',12)) AS "FIRST NAME",
    UPPER(RPAD('',1)) AS "INITIAL",
    UPPER(RPAD('',20)) AS "LAST NAME",
    UPPER(RPAD('',5)) AS "SUFFIX",
    UPPER(RPAD(to_char(QUALDATE, 'mmddyyyy'),8)) AS "TRAINING DATE",
    UPPER(RPAD('P123',8)) AS "Course ID",
    UPPER(RPAD('',6)) AS "Class ID",
    UPPER(RPAD('P',4)) AS "We",
    UPPER(RPAD('',4)) AS "Make / Model",
    UPPER(RPAD('',4)) AS "Cali",
    UPPER(RPAD('',7)) AS "Barrell",
    UPPER(RPAD('',15)) AS "Serial Number",
    UPPER(RPAD('A',4)) AS "Qualification",
    UPPER(RPAD('D',4)) AS "Application",
    to_char((RAWSCORE/250)*100, 'fm000.00') AS "SCORE",
    UPPER(RPAD('PASS',4)) AS "Status",
    UPPER(RPAD('',8)) AS "Add Time",
    UPPER(RPAD('',8)) AS "Record Add ID",
    UPPER(RPAD('',8)) AS "Record Add Date",
    UPPER(RPAD('',8)) AS "Record Change ID",
    UPPER(RPAD('',8)) AS "Record Change Date",
    row_number()over(partition by firearms_scores.ID_NUMBER order by QUALDATE desc ) rn
    FROM FIREARMS_scores, TBL
    where scores.id_number=tbl.id_number
    and qualyear='2010' and coursecode='SA'
    order by employee_id)
    where rn =1

    Hi,
    You RPAD doesn't do anything, since they are same as:
    SQL> SELECT NULL AS "Record Add ID",
      2         NULL AS "Record Add Date",
      3         NULL AS "Record Change ID",
      4         NULL AS "Record Change Date" FROM DUAL;
    R R R R
    SQL>Can't see why COLUMN command shouldn't do what you want. Maybe you forgot the double quotes?
    SQL> COL "Record Add ID" FOR a18
    SQL> COL "Record Add Date" FOR a18
    SQL>
    SQL> SELECT NULL AS "Record Add ID",
      2         NULL AS "Record Add Date",
      3         NULL AS "Record Change ID",
      4         NULL AS "Record Change Date" FROM DUAL;
    Record Add ID      Record Add Date    R R
    SQL>P.S: You probably shouldn't set a column width which is smaller than the header length
    Regards
    Peter

  • In Numbers, how can i change only the year in a date formatted column of data?

    I'm using Numbers 3.5.2 on an iMac running Yosemite 10.10.2.
    This column is a listing of dates tied to info that needs to happen on a particular date each year. Rather than re-key all the dates so the year advances to 2015, it would be great if I could change just the year for the entire column, leaving the day and month intact.
    Thanks in advance for your help.

    If you already have a column of dates, and just want change the year in the entire column, rather than reenter the dates,  then you could use a formula something like this:
    The formula in B2, copied down the column:
        =DATE(YEAR(A2)+1,MONTH(A2),DAY(A2))
    Then select the new column, command-c to copy, and Edit > Paste Formula Results. The original column can then be deleted.
    SG

  • How to find column names in a table

    Am learning the basics of SQL Plus.
    Have entered the following query:
    SELECT * FROM t_ebb_session;
    This gives me the following output.
    USER_ID SESSION_ID LAST_ACCE
    However LAST_ACCE is not the full name of the column as I get 'Invalid column name when I use it in a select statement.
    How do I display the full name?

    By default, SQL*Plus will set the column display width of a character column to its size in the database, and the heading will be the column name in uppercase, truncated to fit that width if necessary. (There is a different rule for numeric columns.)
    You can override this with the COLUMN command, e.g:
    COLUMN some_column_name FORMAT a30 HEADING "Alternative Name"
    Check out the SQL*Plus documentation for all the COLUMN options.

  • Command link display wrong

    I have a table with a commandLink nested into a column. command link display itemID.
    When I click the commandLink , it will take me to the item edit page(ADF Dialog).
    ** The problem is, Sometime I click first item in the table, command link switch to display third item
    and open pop up page to third item data.
    i develop by Toplink , JDeveloper 10.1.3.3.0, connect to Oracle10gR2 Database.
    The table in page display data from DB View.
    Code JavaServer Face address.jspx :
    <af:table value="#{bindings.findVAddressesByKey1.collectionModel}"
    var="row" rows="#{bindings.findVAddressesByKey1.rangeSize}"
    first="#{bindings.findVAddressesByKey1.rangeStart}"
    emptyText="#{bindings.findVAddressesByKey1.viewable ? 'No rows yet.' : 'Access Denied.'}"
    selectionState="#{bindings.findVAddressesByKey1.collectionModel.selectedRow}"
    selectionListener="#{bindings.findVAddressesByKey1.collectionModel.makeCurrent}"
    binding="#{backing_app_App_guaadd.table1}" id="table1"
    width="100%" partialTriggers="cmdEditaddGuaLink">
    <f:facet name="selection"/>
    <af:column sortProperty="cgFirstTName" sortable="false"
    headerText="#{res['app_guaadd.guaFirstLast']}">
    <af:outputText value="#{row.cgFirstTName} #{row.cgLastTName}"/>
    </af:column>
    <af:column sortable="false"
    headerText="#{res['appaddcus.adShareFlag']}"
    binding="#{backing_app_App_guaadd.column1}" id="column1"
    rendered="false">
    <af:outputText value="#{row.adShareFlag}"
    binding="#{backing_app_App_guaadd.outputText1}"
    id="outputText1"/>
    </af:column>
    <af:column sortProperty="adWavArea" sortable="false"
    headerText="#{res['appaddcus.adwavarea_status']}"
    rendered="false">
    <afh:tableLayout width="100%">
    <afh:rowLayout>
    <afh:cellFormat halign="center">
    <af:selectBooleanCheckbox value="#{row.ad_wav_area}"
    disabled="true"/>
    </afh:cellFormat>
    </afh:rowLayout>
    </afh:tableLayout>
    </af:column>
    <af:column headerText="#{res['appaddcus.adtype_status']}">
    <*af:commandLink* text="#{(row.adType=='C')?res['appaddcus.adtype1_status']:(row.adType=='O')?res['appaddcus.adtype2_status']:(row.adType=='R')?res['appaddcus.adtype3_status']:res['appaddcus.adtype4_status']}"
    binding="#{backing_app_App_guaadd.commandLinkEdit}"
    returnListener="#{backing_app_App_guaadd.refreshPage}"
    id="cmdEditaddGuaLink"
    useWindow="true" windowWidth="1100"
    action="#{backing_app_App_guaadd.guaEditLink_Action}">
    <af:inputHidden value="#{row.adPersonType}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdPersonType}"/>
    <af:inputHidden value="#{row.adW1Size}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdW1Size}"/>
    <af:inputHidden value="#{row.adW1Pos}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdW1Pos}"/>
    <af:inputHidden value="#{row.adF1Pos}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdF1Pos}"/>
    <af:inputHidden value="#{row.adG1Pos}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdG1Pos}"/>
    <af:inputHidden value="#{row.adP1Size}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdP1Size}"/>
    <af:inputHidden value="#{row.adType}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdType}"/>
    <af:inputHidden value="#{row.adWavArea}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdWavArea}"/>
    <af:inputHidden value="#{row.adGuaSeq}"
    binding="#{backing_app_App_guaadd.inputHiddenEditAdGuaSeq}"/>
    </af:commandLink>
    </af:column>
    <af:column sortProperty="adType" sortable="false" rendered="false"
    headerText="#{res['appaddcus.adtype_status']}">
    <af:outputText value="#{(row.adType=='C')?res['appaddcus.adtype1_status']:(row.adType=='O')?res['appaddcus.adtype2_status']:(row.adType=='R')?res['appaddcus.adtype3_status']:res['appaddcus.adtype4_status']}"/>
    </af:column>
    </af:table>
    Any help is appreciated.
    Thanks.

    I'm having same issue in JDev 10.1.3.4. When I click first item in the table to go to the detail page, command link switch to display third item. This happens only after I click on the column sorting or after createInsert new record.
    I used af:setActionListener for link from the table:
    <af:commandLink text="#{row.UsrUserid}" action="editUser">
    <af:setActionListener from="#{row.rowKeyStr}"
    to="#{processScope.requestRowKey}"/>
    </af:commandLink>
    I got the value from the detail pagedef:
    <action IterBinding="SssUsersView1Iterator" id="setCurrentRowWithKey"
    InstanceName="SSSServiceAppModuleDataControl.SssUsersView1"
    DataControl="SSSServiceAppModuleDataControl"
    RequiresUpdateModel="false" Action="96">
    <NamedData NDName="rowKey"
    NDValue="#{processScope.requestRowKey}"
    NDType="java.lang.String"/>
    </action>
    Any suggestions? Thanks.

  • Columns tab in User Defined Report

    I've written a few user defined reports, but so far I've just filled in the SELECT command. I'm looking at the tab labeled "Columns" and trying to understand how that affects the report formatting.
    Am I right in assuming that this is equivalent to the COLUMN command in SQL*Plus? So "Name" maps to the column name in the SELECT, right? "hAlign" and "vAlign" are pretty self explanatory, and valid values for these are listed in the on-line help. But what about "Format"? What are valid values for this field? Do I use the format values from SQL*Plus, like "A30" for a 30 character wide column?
    Finally, is there a way to specify that a column is not to be displayed? I have a primary key that I don't want to display, but I do need to include in the SELECT, because the report has a Child query that needs to use this as a bind variable for a foreign key.

    <p>
    I've found part of the answer to my own question:
    </p>
    <p>
    Formats for the "format" field in the Columns tab are the formats used in the java.text.MessageFormat class. For example, you can use:
    </p>
    {0,date,yyyyMMdd hh:mm:ss}<p>
    The zero means the first argument; it will always be zero because we are only formatting one column. The second part tells what kind of formats to use, date or number. There is also a "choice" format type, which is related to number - works sort of like the DECODE function. The third part is the format itself, which can be one of several default formats like "currency", "percent" and "integer" for numbers, or "short", "medium", "long" or "full" for dates. I used an explicit format.
    </p>
    <p>
    I still don't have an answer to the second part of my question: How do I include a column in my query to be used as a bind variable in a child query, but exclude it from the report?
    </p>

  • How to remove column name in select clause

    Hello Guys,
    I just want to remove a column name in select clause. Because, I don't want to write all column names. I hope I express myself.
    In other words, I want the following.
    Select   * - unwanted_column  from table;
    instead of this
    Select col1, col2, col3, col4, ........ col 10000 from table;

    Hi,
    Sorry, there's nothing in SQL that means "all columns *except* ...". As the others have said, the only way to get those results in SQL is to list all the columns you do want.
    Your front end may have some feature that allows you to hide a specific column. For example, in SQL*Plus, you can use <tt> COLUMN ... NOPRINT </tt> , like this:
    COLUMN      dname     NOPRINT
    SELECT       *
    FROM       scott.dept
    ORDER BY  dname
    ;Output:
    `   DEPTNO LOC
            10 NEW YORK
            40 BOSTON
            20 DALLAS
            30 CHICAGOThere is a column called dname in the scott.dept table; the query above actually uses it. But, because of the COLUMN command, SQL*Plus won't display that column.
    Edited by: Frank Kulash on Feb 26, 2013 10:10 AM
    Changed scott.dept example.

  • InDesign command problems

    I work with Adobe CS 5. Using Configurator 3, I have created a panel in InDesign for the commands I use most often. However, I have run into the following problems:
    Some commands (e.g., Margins and Columns or Span Columns and some others) give me only a split-second flash of (presumably) a dialogue box but then nothing more.
    Some commands don't ever respond.
    Some commands work at first, but then, if I edit or recreate the panel, some of the previously working commands (e.g., Insert Hair Space, Clear Overrides, and some others) simply
    stop working.
    Also, I have tried to use some Widgets, but they never show up (e.g., the horizontal rule or the rectangular container). No color adjustments seem to be available for the panel, and nothing adjusts automatically.
    Some commands that I find inside InDesign -- such as the Balance Columns or Unbalance Columns commands that should be available on the control panel -- don't show up in searches on either word.
    I can edit a panel and sometimes get some of the previously working functions back, by removing them and placing them again. But that doesn't work every time (and is annoying to have to do), and even this does not help the commands that have never responded or which only flash me and then are gone. Nor does completely trashing the original panel and recreating from scratch fix the latter condition, though sometimes when I do this, some of the commands that have occasionally worked will again work in the new panel. But usually, some others that worked previously, now won't.
    SUMMARY: It seems the commands that WILL work, won't work consistently. And the ones that never worked yet, never will.
    Configurator 3 seems to be a great idea -- I was very happy to find it the other day, and the presentation video I watched about its upgrades for CS6 seemed encouraging. But so far, it does not seem like an idea whose time has come ... unless there is something I'm doing wrong or some reason why some commands don't work in CS5. If this is the case, please let me know. I also use Photoshop extensively and wanted to create a panel for it, but I'm not going to bother if Configurator 3 is truly so inconsistent as it seems.
    Does anyone have any thoughts, advice or experience with the program along the above lines?

    I'm sorry to hear that. If possible, could you send you panel to [email protected]? I will have a look.
    Do you make sure that you selected InDesign CS5/CS5.5 when creating panel for InDesign CS5?

  • Special Characters and spaces in Tablenames and Column Names are allowed ?

    Hi
    I have created two tables in Oracle10g
    as follows
    SQL> create table test(columna number,columnb varchar2(20),primary key(columna));
    Table created.
    SQL> insert into test values(1,'test');
    1 row created.
    SQL> commit;
    COMMIT är utfört.
    SQL> create table "test quote"("#" number,abc number,primary key("#"));
    Table created.
    SQL> insert into "test quote" values(1,2);
    1 row created.
    SQL> commit;
    COMMIT är utfört.
    SQL> select * from "test quote";
    # ABC
    1 2
    SQL> select * from test;
    COLUMNA COLUMNB
    1 test
    Now I want to cache the tables and their data into TimesTen
    The cache group for table test which is not having any spaces and special characters in table name and column names is created perfectly.
    But when I create the cache group for table "test quote" which is having special characters and spaces it gives error :
    Command>create readonly cache group w2 from testuser.test(columna number,columnb varchar2(20),primary key(columna));
    Command>select * from test;
    <1,test>
    1 row found.
    Command>create readonly cache group w3 from testuser."test quote"("#" number,abc number,primary key("#"));
    5140: Could not find TESTUSER.TEST QUOTE in Oracle. May not have privileges.
    Command Failed.
    Now there is contradiction that why cache group for table test is created successfully and why it is not being created for table "test quote".
    What I think is if special characters and spaces in column names and table names are possible in Oracle then it sould be possible in TimesTen.
    Any possible solution.
    Looking forward for your reply.
    Please help I am stuck badly.
    /Ahmad

    Hi
    Problem Solved ....... Remeber only Capital letters work with special characters ......
    /Ahmad

  • Activate profit center column in clearing transation

    Dear Expert
    I want to activate the column
    of profit center in clearing transaction
    F-32.

    After a small test i saw that the column 'Command' is used to select or not select line items,
    For example you have 3 line items in the liste
    1st item : 1000 $
    2nd item : 3000 $
    3rd item : 5000 $
    Amount assigned : 9000 $
    and if you put ' - ' in the Command's field of one line item, the amount assigned is changed :
    1st item : 1000 $  (command = - )
    2nd item : 3000 $
    3rd item : 5000 $
    Amount assigned : 8000 $
    so you can see that the system don't select the item for wich we have put ' - ' in Command's field

Maybe you are looking for

  • Link between Material Document number & Accounting document number

    Hi All, For material document there is a corresponding accounting document number generated.However this is not the rule in all cases. Where is the link between the two(Material Document & Accounting Document) ? In other words i want to list those ma

  • FM - Budget check at the time of procurement and at the time of Issue

    Hi For a Material there is a budget for a procurement ( Check should happen at the time of procurement and a seperate budget for consumption ( Check should happen at the time of issue).How can I map this in FM- BCS.I am thinking of creating two commi

  • "No Speakers or headphones are plugged in" problem

    A few days ago I had a problem with my cheap insignia speaker's subwoofer not working. I tried doing my usual open up and repair scenario. (All this was done while my speakers still plugged in my desktops front headphone jack). I was messing around w

  • Magnavox 37MF331D/37 LCD

    I hooked up my Mini to my LCD tv with a DVI-HDMI cable and I could see the desktop on the tv. It wasn't exactly right so I messed with the display settings and the screen went black then flashed blue. About every 30 seconds the screen turns blue then

  • HP8625 always requires restart print spooling

    Each time I return to the printer after a few hrs idle time, it will not function until I restart the spooler.  Doesn't matter if operating through wireless or USB connected.