COMMAND column in V$SESSION table

Is there any table which stores all the meaning of various values that can be stored in COMMAND column of V$SESSION table
Like 3 is for SELECT and 47 for Execute, I found some documentation in data dictionary but was wondering if there is some table that can be used when a trigger or procedure is running to pull the values on the fly.
Thx

You can find the various values for V$SESSION.COMMAND in Table 7-5 COMMAND Column of V$SESSION and Corresponding Commands found in the link below to build your own table.
http://download-east.oracle.com/docs/cd/B19306_01/server.102/b14237/dynviews_2088.htm#sthref3985

Similar Messages

  • COMMAND column in V$SESSION just show s SELECT

    Hi,
    i queried command column in v$session, but it shows only 3(which is for SELECT) and 0 (which is for unknown), even i update some thing its not shown.
    Thanks

    Hi Pavan,
    following is the list for that
    Number     Command     Number     Command
    1     CREATE TABLE     2     INSERT
    3     SELECT     4     CREATE CLUSTER
    5     ALTER CLUSTER     6     UPDATE
    7     DELETE     8     DROP CLUSTER
    9     CREATE INDEX     10     DROP INDEX
    11     ALTER INDEX     12     DROP TABLE
    13     CREATE SEQUENCE     14     ALTER SEQUENCE
    15     ALTER TABLE     16     DROP SEQUENCE
    17     GRANT OBJECT     18     REVOKE OBJECT
    19     CREATE SYNONYM     20     DROP SYNONYM
    21     CREATE VIEW     22     DROP VIEW
    23     VALIDATE INDEX     24     CREATE PROCEDURE
    25     ALTER PROCEDURE     26     LOCK
    27     NO-OP     28     RENAME
    29     COMMENT     30     AUDIT OBJECT
    31     NOAUDIT OBJECT     32     CREATE DATABASE LINK
    33     DROP DATABASE LINK     34     CREATE DATABASE
    35     ALTER DATABASE     36     CREATE ROLLBACK SEG
    37     ALTER ROLLBACK SEG     38     DROP ROLLBACK SEG
    39     CREATE TABLESPACE     40     ALTER TABLESPACE
    41     DROP TABLESPACE     42     ALTER SESSION
    43     ALTER USER     44     COMMIT
    45     ROLLBACK     46     SAVEPOINT
    47     PL/SQL EXECUTE     48     SET TRANSACTION
    49     ALTER SYSTEM     50     EXPLAIN
    51     CREATE USER     52     CREATE ROLE
    53     DROP USER     54     DROP ROLE
    55     SET ROLE     56     CREATE SCHEMA
    57     CREATE CONTROL FILE     59     CREATE TRIGGER
    60     ALTER TRIGGER     61     DROP TRIGGER
    62     ANALYZE TABLE     63     ANALYZE INDEX
    64     ANALYZE CLUSTER     65     CREATE PROFILE
    66     DROP PROFILE     67     ALTER PROFILE
    68     DROP PROCEDURE     70     ALTER RESOURCE COST
    71     CREATE MATERIALIZED VIEW LOG     72     ALTER MATERIALIZED VIEW LOG
    73     DROP MATERIALIZED VIEW LOG     74     CREATE MATERIALIZED VIEW
    75     ALTER MATERIALIZED VIEW     76     DROP MATERIALIZED VIEW
    77     CREATE TYPE     78     DROP TYPE
    79     ALTER ROLE     80     ALTER TYPE
    81     CREATE TYPE BODY     82     ALTER TYPE BODY
    83     DROP TYPE BODY     84     DROP LIBRARY
    85     TRUNCATE TABLE     86     TRUNCATE CLUSTER
    91     CREATE FUNCTION     92     ALTER FUNCTION
    93     DROP FUNCTION     94     CREATE PACKAGE
    95     ALTER PACKAGE     96     DROP PACKAGE
    97     CREATE PACKAGE BODY     98     ALTER PACKAGE BODY
    99     DROP PACKAGE BODY     100     LOGON
    101     LOGOFF     102     LOGOFF BY CLEANUP
    103     SESSION REC     104     SYSTEM AUDIT
    105     SYSTEM NOAUDIT     106     AUDIT DEFAULT
    107     NOAUDIT DEFAULT     108     SYSTEM GRANT
    109     SYSTEM REVOKE     110     CREATE PUBLIC SYNONYM
    111     DROP PUBLIC SYNONYM     112     CREATE PUBLIC DATABASE LINK
    113     DROP PUBLIC DATABASE LINK     114     GRANT ROLE
    115     REVOKE ROLE     116     EXECUTE PROCEDURE
    117     USER COMMENT     118     ENABLE TRIGGER
    119     DISABLE TRIGGER     120     ENABLE ALL TRIGGERS
    121     DISABLE ALL TRIGGERS     122     NETWORK ERROR
    123     EXECUTE TYPE     157     CREATE DIRECTORY
    158     DROP DIRECTORY     159     CREATE LIBRARY
    160     CREATE JAVA     161     ALTER JAVA
    162     DROP JAVA     163     CREATE OPERATOR
    164     CREATE INDEXTYPE     165     DROP INDEXTYPE
    167     DROP OPERATOR     168     ASSOCIATE STATISTICS
    169     DISASSOCIATE STATISTICS     170     CALL METHOD
    171     CREATE SUMMARY     172     ALTER SUMMARY
    173     DROP SUMMARY     174     CREATE DIMENSION
    175     ALTER DIMENSION     176     DROP DIMENSION
    177     CREATE CONTEXT     178     DROP CONTEXT
    179     ALTER OUTLINE     180     CREATE OUTLINE
    181     DROP OUTLINE     182     UPDATE INDEXES
    183     ALTER OPERATOR

  • 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

  • How to get only column names from different tables as single table columns

    Hi All,
       I have one requirement in which we want only column names from different tables.
    for example :
     I have three tables T1 ,T2, T3 having
      col1 clo2 clo3 -->  T1 , 
      col3 col5 ,clo6 --> T2 ,
      Clo6 col8 col9 --> T3
    columns i want to get only all  Column names from all table as single Resultset not any data from that how can i get that empty resultset 
    because this empty result i want to bind in datagridview(front end) as Empty resultset 
    Please tell me anyways to do this
    Niraj Sevalkar

    If I understand you want an empty result set, just with metadata. SET FMTONLY do the trick:
    SET FMTONLY ON
    SELECT Col1, Col2, Col3, ....., Coln
    FROM
    T1 CROSS JOIN T2 CROSS JOIN T3
    SET FMTONLY OFF
    Another alternative is to include an imposible contition
    SELECT Col1, Col2, Col3, ....., Coln
    FROM
    T1 CROSS JOIN T2 CROSS JOIN T3
    WHERE 1 = 0
    If you are using a SqlDataAdapter in your client application. You can use the FillSchema method. the select command may be any select statement that returns the columns you want. Under the covers FillSchema will call SET FMTONLY ON.
    If you are using SqlCommand.ExecuteReader you can pass SchemaOnly to CommandBehavior argument. SET FMTONLY ON is called under the covers. Again the select command may be any select statement that returns the columns you want.
    "No darás tropezón ni desatino que no te haga adelantar camino" Bernardo Balbuena

  • How to get only selected table columns from a DB table to be display in pag

    hi i have some 18 columns in my database table, but i need to add only the selected columns to be added to my table component. How can i do it. any idea regarding this. Please help me out to solve this problem.
    Thank You in Adavnce.

    This is an ambiguous question but I will give 2 answers for 2 interpretations
    1 In the Outline window, right-click the rowset in the Session bean (or whatever bean you put the rowset in, by default it is the session bean). In the top pane, select or clear the checkboxes to determine which columns are obtained by the query.
    2 Right click the Table component and choose Table Layout, move the columns you don't want to the left panel
    Resources: http://developers.sun.com/prodtech/javatools/jscreator/learning/tutorials/2/databoundcomponents.html
    If you meant a different question, please clarify

  • What is the meaning of "PSEUDO" and "NONE" in v$session table.

    Hi
    What is the meaning of "PSEUDO" and "NONE" in v$session table.
    V$SESSION:
    SERVER      VARCHAR2(9)      Server type (DEDICATED| SHARED| PSEUDO| NONE)
    thanks
    siva

    PSEUDO is the server column's value of killed sessions, until they are cleaned up by PMON.
    A dedicated server session will always have DEDICATED as server value, while a shared server session has SHARED when it's active, and NONE when it's inactive.

  • DUPLICATE A COLUMN IN A SAME TABLE ?

    Do u know a way to duplicate a column in a same table without using the "INSERT INTO" function ?

    Here is Answer Why we want to do this.
    Today I face the problem.I want to change the name of the column with out loss of data.In oracle we don't have this facility. but through logic you can do it.
    Suppose a table name Temp with Column names
    Rollno ,Name,Amount
    I want to change the column name Amount to NewAmount.
    Follow the following steps.
    1. Add new column with alter command
    2. Update new Column with the above statement.
    3. drop the old column.
    null

  • No of minuts in McuJoinsAndLeaves and session tables ????

    Hi All,
    I am trying to find out the  No. of minutes in McuJoinsAndLeaves table(lcscdr DB) and session table(Qoeetrics DB) are exactly same or not..?? if no. of minutes are same in both table............please tell me conditions ????
    Thanks
    Brij

    Which column did you refer to?
    Please compare these two tables according to the following link.
    McuJoinsAndLeaves Table
    http://technet.microsoft.com/en-us/library/gg398316.aspx
    Session Table
    http://technet.microsoft.com/en-us/library/gg398635.aspx
    In my lab, I didn’t see the same data from these two tables.
    Lisa Zheng
    TechNet Community Support

  • Nsert/Update and Add Column at the same Table and at the "same" Time

    Hello,
    I want Insert/Update and Add Column at the same Table and at the "same" Time but in different sessions.
    Example:
    At first the "insert/update" statement:
    Insert into TestTable (Testid,Value) values (1,5105);
    After that the "add" statement:
    Alter table TestTable add TestColumn number;
    - sadly now I get the message: ORA-00054: resource busy and acquire with NOWAIT specified
    "insert/update" statement:
    Insert into TestTable (Testid,Value) values (2,1135);
    After that the execute commit.
    I don't know when the first session set the commit statement so I want that the DB the "Alter Table..." statement execute if it's possible.
    If it's possible I want to save a repeat loop with the "Alter Table..." statemtent.
    Thanks for ideas

    Well I want to walk in the rain without and umbrella and still stay dry, but it ain't gonna happen.
    You can't run a DDL statement against a table with transactions pending. Session 2 has to wait until session commits or rollbacks (or until the session is killed). That's just the way it is.
    This makes sense if you think about it. The data dictionary has to be consistent across all sessions. If session 2 was allowed to change the table structure whilst session 1 has a pending transaction then the database is in an inconsistent state. This is easier to see if you consider the reverse situation - the ALTER TABLE statement run by session 2 does a DROP COLUMN TESTID rather than adding a column: now what should happen to session 1's INSERT statement? You have retrospectively invalidated a statement that was perfectly legal when it was executed.
    If it's possible I want to save a repeat loop with the "Alter Table..." statemtent.Fnord.
    Cheers, APC

  • About the last_call_et column in v$session

    Hello,
    Can someone help me about a behaviour that is very strange ...
    We have connection about SAS on a database which manipulate Oracle table and others SAS Structure.
    The query is a "join" about that table and a "SAS Table" between million of lines in the Oracle table one ....
    It last a long time ....
    During the query, we have time to see at the v$session table...
    At any time (it lasts 3h), we saw that the column 'last_call_et' of the v$session never change : it continuesly stay at 0.
    What does it mean ? it means that SAS send a query every second ? Or this column shows the last "internal call"?
    If this is the right reason, i would'nt understand why, when i take the same query( launched by SAS) in TOAD, there is no the same behaviour and this behaviuor is in that case the right behaviour : the session is ACTIVE but the last_call_et respresents really the time since i launched the query... So why when SAS do it, the last_call_et stay at 0 ? it works like SAS launch every second this query !!!!
    Can someone help me ?
    Thanks ...

    Jonathan Lewis wrote:
    user12046632 wrote:
    When you say :
    A FETCH is a database call :
    That means that it must affect the value of 'last_call_et' or not ?"A Fetch is a database call"
    "last_call_et" -- certainly sounds like that could be something to do with database calls, perhaps End Time of LAST database CALL.
    A parse is also a database call, as is an execute ... I feel that perhaps I was a little too concise with my description. You asked why SAS could be doing lots of calls (although that wasn't exactly how you put the question) and I replied that calls could include fetches. And yes, the last_call_et is reset on every fetch (amongst other things - and ignoring the special behaviour of background processes).Ok
    >
    (accordint to me, only to user's activity do so and not to "database internal callsl") ! isn't it ?You don't want to believe everything you read on the internet - even if it did come from the online manuals. But a "fetch" is not a "database internal call" anyway, it's a call from a client to the server.Be sure that i don't do so.
    But the explanation of Oracle of the term 'cal' is not so precise at all ...
    >
    Your follonwing explanations seems to answers contrarily ....
    But the question is there : what sort of call affetcs the value of "last_call_et"All database calls - which you should read as "all calls from the client to the server".Ok
    >
    >>
    >>
    When you say
    all_rows plan => parse call, execute call ..... with very long call time, lots of fetch calls
    first_rows_n plan => parse call, execute call ... with very short call time, lots of fetch calls
    In the first case you would see last_call_et constantly growing until the fetches started
    In the second case last_call_et would keep resetting to zero so fast you probably wouldn't see it as a non-zero value.
    I don't understand : ok for the conséquences on the timing ... but if there are a lot of fetch call in both cases : the behaviour on the 'last_call_et' has to be equal ?True - but in one case I've included an execute call that is active for a very long time, and in the other I've proposed an execute call that is active for a very short time. (And execute calls are calls, and I did ask you about the exact details of your observations.)Ok
    If we consider that every call reset to 0 the value of 'last_call_et',
    why, in the case of launching the same request by TOAD, shouldn't i see the reset to 0 when the fetches works (because in TOAD during the whole query, which means since the click on "launching query" to the retrieving of data, the value did not reset to 0) ?
    >
    >>
    When you say
    Having said that, I've just run a quick test in SQL*Plus on 11.1.0.6 and 10.2.0.3 to demonstrate this point, and 11g is behaving differently from 10g - in the case where the last_call_et should be growing it stays at zero.
    "in the case" : in the case of the v11 or the v10 ?11g
    In my case : i'am on a v10.2.0.3 ::: Is there a bug ?Not that I know of.ok. So it is in V11 that you have an incorrect behaviour ....
    >>
    >
    Regards
    Jonathan LewisLAST NEWS : we have relaunched the query in SAS and observed that we have the same context of plan in both cases (by SAS en y TOAD) : ALL_ROWS.
    Very strange ...
    Last question :
    Just to be sure : When you talk about "First Rows plan" : it means that the retrieve data are restricted to the first rows encountered
    or
    it is just the plan of the query which is in "that context" which means that the engine works so although the whole data are retrieved ....
    thanks for your return

  • Copying Long Raw Column Data to another table

    hi everyone,
    i am trying to Copy Long Raw Column Data to another table in the same schema. this is the situation
    Table A (col1 number,col2 long raw) with 100 records
    Table B (col1 number,col2 long raw) with 0 records
    now i want to copy col2 of the table A into the column 2 of the table B. but long raw data cant be retrieved in a select statement so is there any specific procedure that will copy long raw data or there is any simple way.
    i will be really grateful for anybody's help.
    thanx
    shakeel

    Dust off that old SQL*PLUS command "COPY" ...
    create table tablea (col1 number,col2 long raw)
    insert into tablea values (1, testrawio.chartoraw('this is line one'));
    insert into tablea values (2, testrawio.chartoraw('this is line two'));
    insert into tablea values (3, testrawio.chartoraw('this is line three'));
    create table tableb (col1 number,col2 long raw)
    copy from scott/tiger@larry insert tableb (col1, col2) using select col1, col2 from tablea
    Array fetch/bind size is 15. (arraysize is 15)
    Will commit when done. (copycommit is 0)
    Maximum long size is 80. (long is 80)
       3 rows selected from scott@tiger.
       3 rows inserted into TABLEB.
       3 rows committed into TABLEB at DEFAULT HOST connection.
    SQL>Now to prove it has worked :
    begin
       for lr in (select col1, col2 from tableb)
       loop
          dbms_output.put_line('col1 = '||lr.col1||
                               ' and col2 contains long raw equivalent of '||testrawio.rawtochar(lr.col2));
       end loop;
    end;
    col1 = 1 and col2 contains long raw equivalent of this is line one
    col1 = 2 and col2 contains long raw equivalent of this is line two
    col1 = 3 and col2 contains long raw equivalent of this is line three
    PL/SQL procedure successfully completed.
    SQL> Note : In order to load some test data and prove the method works I made use of a package called "testrawio" located at http://www.classicity.com/oracle/htdocs/forums/ClsyForumID125/7.html
    AMM

  • How to find the number of columns in an internal table DYNAMICALLY ?

    Hi,
    How to find the number of columns in an internal table DYNAMICALLY ?
    Thanks and Regards,
    saleem.

    Hi,
    you can find the number of columns and their order using
    the <b>'REUSE_ALV_FIELDCATALOG_MERGE'</b>
    call function 'REUSE_ALV_FIELDCATALOG_MERGE'
    EXPORTING
       I_PROGRAM_NAME               = sy-repid
       I_INTERNAL_TABNAME           = 'ITAB'
       I_INCLNAME                   = sy-repid
      changing
        ct_fieldcat                  = IT_FIELDCAT
    EXCEPTIONS
       INCONSISTENT_INTERFACE       = 1
       PROGRAM_ERROR                = 2
       OTHERS                       = 3
    if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif
    now describe your fieldcat . and find no of columns.
    and their order also..
    regards
    vijay

  • Find duplication values from multiple columns in a big table

    Hi All,
    I am working on a 11gR2 database in linux. i want to display record that have duplicate values in 2 columns.
    1. Table Structure :-
    CREATE TABLE A
    ID NUMBER(10),
    F_NAME VARCHAR2(100 BYTE),
    L_NAME VARCHAR2(100 BYTE)
    2. Sample Data:-
    Insert into A
    (ID, F_NAME, L_NAME) Values (1,'TONY' ,'SUMIT');
    Insert into A
    (ID, F_NAME, L_NAME) Values (2,'SUMIT' ,'KEITH');
    Insert into A
    (ID, F_NAME, L_NAME) Values (3,'NORA','SMITH');
    Insert into A
    (ID, F_NAME, L_NAME) Values (4,'APRIL','TONY');
    Insert into A
    (ID, F_NAME, L_NAME) Values (5,'ROSS','TAM');
    ID F_NAME L_NAME
    1 TONY SUMIT
    2 SUMIT KEITH
    3 NORA SMITH
    4 APRIL TONY
    5 ROSS TAM
    4. My requirement is i need display IDs that it's F_NAME or L_NAME has duplication in F_NAME or L_NAME columns.
    The result should be
    ID
    1 reason: F_NAME (TONY) equals to L_NAME of record 4, L_NAME (SUMIT) equals to F_NAME of record 2
    2 reason: F_NAME (SUMIT) equals to L_NAME of record 1
    4 reason: L_NAME (TONY) equals to F_NAME of record 1
    record 3, 5 aren't in the result because there is no duplication in F_NAME or L_NAME columns for NORA,SMITH, ROSS, TAM
    The table contains 10 million records, i really need to consider the performance.
    kindly suggest me the solution

    Note: Forum members please suggest better approach to this -- below.. convert into SQL :)
    I know I will be opposed by many people in this forum for posting such in-efficient solution.
    But trying to learn along with you.. its an interesting problem which must deal with all rows vs all rows to get all combinations.
    But I am still thinking how to write it in SQL, probably will learn from this post after we receive some good SQL solution for the code what I am currently doing now.
    step 1: created a table B similar to table A and added a column reason
    CREATE TABLE B
      ID      NUMBER(10),
      F_NAME  VARCHAR2(100 BYTE),
      L_NAME  VARCHAR2(100 BYTE),
      REASON  VARCHAR2(1000 BYTE)  --- ADDED THIS
    )Definetely inefficient :(
    BEGIN
       FOR rec_outer IN (SELECT * FROM A) LOOP
          FOR rec_inner IN (SELECT * FROM A) LOOP
             IF (rec_outer.f_name = rec_inner.l_name) THEN
                UPDATE B
                   SET reason =
                             rec_outer.id
                          || ' reason: F_NAME ('
                          || rec_outer.f_name
                          || ') equals to L_NAME of record '
                          || rec_inner.id
                 WHERE b.id = rec_outer.id;
             END IF;
          END LOOP;
          FOR rec_inner IN (SELECT * FROM A) LOOP
             IF (rec_outer.l_name = rec_inner.f_name) THEN
                UPDATE B
                   SET reason =
                          reason
                          || CASE
                                WHEN reason IS NULL THEN
                                   rec_outer.id || ' reason: '
                                ELSE
                             END
                          || 'L_NAME ('
                          || rec_inner.f_name
                          || ') equals to F_NAME of record '
                          || rec_inner.id
                 WHERE b.id = rec_outer.id;
             END IF;
          END LOOP;
       END LOOP;
       COMMIT;
    EXCEPTION
       WHEN OTHERS THEN
          rollback;
          RAISE;
    END;OUTPUT:
    ID     F_NAME     L_NAME     REASON
    1     TONY     SUMIT     1 reason: F_NAME (TONY) equals to L_NAME of record 4,L_NAME (SUMIT) equals to F_NAME of record 2
    2     SUMIT     KEITH     2 reason: F_NAME (SUMIT) equals to L_NAME of record 1
    3     NORA     SMITH     
    4     APRIL     TONY     4 reason: L_NAME (TONY) equals to F_NAME of record 1
    5     ROSS     TAM     Cheers,
    Manik.
    Edited : Added rollback

  • Language Session table in EBS

    Hi friends,
    In oracle EBS R12.1.3 we have two language preference options like 'AR' for Arabic and 'US' for English. Soon after the user changes the respective language and logs into the EBS application, those change languages will be stored as a code in session table for that EBS user.
    I need to know that session table name where does the language is get setted for the user who logs into the application, so that i can query the appropriate session language for the corresponding user from the table in db.
    Thanks in advance.
    Brgds,
    Mini

    Mini wrote:
    Hi Srini,
    Actually the problem that im facing is that i couldnt pass the USERENV('LANG') variable to the where clause in my APEX from EBS session.
    I have APEX 4.2 integrated with Oracle EBS R12.1.3, now from the EBS menu i can redirect to the apex page(by passing the apex login page) with EBS credentials.
    Im near to the stage of bringing Arabic and English language in APEX, as my db contains data in both the lang.
    But I need to bring it according to the USERENV(‘LANG’) that is set in the db for the users session from EBS login. But if I used the USERENV(‘LANG’) parameter in APEX it is not recognizing this EBS user language parameter. Whether you have any idea of how to make the APEX to recognize this EBS user language parameters.
    I dont know how to pass this EBS user session variable to the apex, so that the data will be visible according to the EBS session language they select(either 'AR' or 'US').
    If i give like below in the APEX report query of my where clause, means
    where language = userenv('lang')
    It is not working. But if i harcode like
    where language = 'AR' means then i can see the arabic datas from db in APEX, but how i can pass this userenv code dynamically according to the EBS logged in user to the APEX.
    Thanks
    Brgds,
    MiniThis is a different topic and I see that you have created another thread for it -- How to pass userenv('lang') of EBS user session to APEX 4.2 pages
    Please update the other thread instead of this one.
    Thanks,
    Hussein

  • How to rename a column name in a table? Thanks first!

    I tried to drop a column age from table student by writing the
    following in the sql plus environment as :
    SQL> alter table student drop column age ;
    but I found the following error
    ORA-00905: &#32570;&#23569;&#20851;&#38190;&#23383; (Lack of Key word)
    I have oracle enterprise edition 8.0.5 installed at windows 2000
    thank you
    And I want to know how to rename a column name in a table?
    thanks

    In Oracle 8i, your syntax would have worked.  However, if I
    recall correctly, in Oracle 8.0, you can't rename or drop a
    column directly.  One way to get around that problem is to
    create another table based on a select statement from your
    original table, providing the new column name as an alias if you
    want to change the column name, or omitting that column from the
    select statement if you just want to drop it.  Then drop the
    original table.  Then re-create the original table based on a
    select statement from the other table.  Then you can drop the
    other table.  Here is an example:
    CREATE TABLE temporary_table_name
    AS
    SELECT age AS new_column_name,
           other_columns
    FROM   student
    DROP TABLE student
    CREATE TABLE student
    AS
    SELECT *
    FROM   temporary_table_name
    DROP TABLE temporary_table_name
    Something that you need to consider before doing this is
    dependencies.  You need to make a list of all your dependecies
    before you do this, so that you can re-create them afterwards. 
    If there are a lot of them, it might be worthwhile to do
    something else, like creating a view with an alias for the
    column or just providing an alias in a select.  It depends on
    what you need the different column name for.

Maybe you are looking for

  • Raw files from Lumix gm1 camera

    I have Elements 10 which will not support RAW files from my new Lumix gm1. Is there an update to Elements 10 to do this or have I got to buy Elements 12 which will support these files?

  • How to create new row in Adf uix table

    hi, I am using Jdev 10.1.2 , Can any body tell me how to insert new row in table ? Thanx

  • Can we call another flavor using launch button or script button

    I am creating a Welcome screen ( 1st  flavor for SMEN transaction) . However I want to call another flavor ( 2nd flavor for SMEN transaction) from 1st flavor . Second flavor will have a few transactions ( for example which are used only for budgeting

  • (RAC) node 2 dont start automatically

    hi gurus, we have intalled a RAC (with 2 nodes) on database version 11.2.0.3. When we reboot node 1, it restart automatically but when we reboot node 2 we have to restart manually using: srvctl start instance -d DB_name -i NODE_2 how to check if we h

  • Create DVD image

    i started exe file but after 47% program writes "Cannot allocate enough memory. The program has been closed without installing." What have i do?