How achive below result in Oracle SQL

Hi All,
How to get the below result:
base table:
COLA COLB
112 01-JAN-2012
113 02-FEB-2012
114 02-MAR-2013
115 01-APR-2013
Result table:
COLA COLB COLC
112 01-JAN-2012 01-FEB-2012
113 02-FEB-2012 01-MAR-2012
114 02-MAR-2013 31-MAR-2013
115 01-APR-2013 02-APR-2013
Thanks!

How do I ask a question on the forums?
SQL and PL/SQL FAQ

Similar Messages

  • How to see dbms_output on oracle sql developer

    ned immediate help
    how to see dbms_output on oracle sql developer

    Hi,
    In sql developer u have a tab named DBMS Output in your result sheet. In that the first Icon is Enable DBMS Output. turn it on (After on it will give the message set serveroutput on in the sheet) and then run your code.
    In the code u have to use the dbms_output.put_line package.after running the code u have to see the result in DBMS Output tab.
    Regards,
    NTR

  • How to see history in Oracle SQL

    how to see history in Oracle SQL
    i.e
    create table.....
    select * from tablename....
    delete tablename;
    Now i want to see how many command run after login.......please tell me the command...

    user12261139 wrote:
    how to see history in Oracle SQL
    i.e
    create table.....
    select * from tablename....
    delete tablename;
    Now i want to see how many command run after login.......please tell me the command...I'm not aware of an easy way to see how many commands were run after logging on. Different tools have different capabilities, though.
    The ms-dos version of SQL*PLUS offers a Doskey option to use the up and down arrows to recover recently executed commands.
    The SQL Workshop in Apex has a command history. Some of the GUI tools might offer similar functionality.

  • How to update column in Oracle SQL Developer?

    Hi everybody,
    How can I update table in Oracle SQL Developer like in PL/SQL Developer use:
    Select * from table for update;
    Thank you~

    Do you mean you want to edit the result grid?
    You can't edit the result grid of a query, but you can edit the data tab of a table.
    Click on the table in the object browser
    Click on the data tab
    Optionally filter the results using the filter field at the top
    Type into the data cells.
    Click on the commit button

  • How to connect database using oracle SQL developer

    Hello
    I am newbie in EBS R12
    I downloaded Oracle SQL Developer
    and create new database conenction
    Connection name: ebs demo db connection
    username:
    password:
    Role: Default
    Connection type: Basic
    Hostname: ebstailin.demo.com
    Port: 1521
    SID: clone
    when i try this there is an error
    Status: Failure-Test failed: lo exception: The Network Adapter could not establish the connection
    no idea about this
    but i used the apps/apps as username and password
    please help
    thanks
    Edited by: cheesewizz on Jul 16, 2010 11:35 PM

    Hello
    Thanks for your reply
    I tried to connect and here is the result: see below
    [oracle@ebstailin 11.1.0]$ sqlplus / as sysdba
    SQL*Plus: Release 11.1.0.7.0 - Production on Sat Jul 17 15:35:31 2010
    Copyright (c) 1982, 2008, Oracle. All rights reserved.
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> CONNECT apps/apps
    Connected.
    SQL>
    But still cannot connect using ORACLE SQL Developer
    thanks

  • How to create databse in oracle sql developer

    Hi am using oracle sql developer but while connecting to the database i am getting error of network adapter
    if any buddy has a solution then fill free to post
    Thanx and Regards
    Umesh

    Can you be a little more specific with the error? The "network adapter" errors I've seen myself have been because SqlDeveloper can't connect to the database, either because the wrong host/port was given, or because a firewall was blocking the port.

  • How can i achive this result by writing SQL Query ?

    Dear Exparts,
    Here is my banner
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Prod
    PL/SQL Release 10.2.0.3.0 - Production
    "CORE     10.2.0.3.0     Production"
    TNS for 32-bit Windows: Version 10.2.0.3.0 - Production
    NLSRTL Version 10.2.0.3.0 - ProductionI have two table with relation. Here is the scripts of create table and insert data.
    TABLE
    CREATE TABLE TAB1
      T1_ID NUMBER(5)
    , T1_NAME VARCHAR2(100)
    ALTER TABLE TAB1 
    MODIFY (T1_ID NOT NULL);
    ALTER TABLE TAB1
    ADD CONSTRAINT TAB1_PK PRIMARY KEY
      T1_ID
    ENABLE;
    CREATE TABLE TAB2
      T2_ID NUMBER(5) NOT NULL
    , T2_T1_ID NUMBER(5)
    , T2_RV_NO VARCHAR2(20)
    , T2_RV_DATE DATE
    , T2_F1 VARCHAR2(20)
    , T2_F2 VARCHAR2(20)
    , T2_F3 VARCHAR2(20)
    , CONSTRAINT TAB2_PK PRIMARY KEY
        T2_ID
      ENABLE
    ALTER TABLE TAB2
    ADD CONSTRAINT TAB2_TAB1_FK1 FOREIGN KEY
      T2_T1_ID
    REFERENCES TAB1
      T1_ID
    ENABLE;INSERT DATA
    Insert into TAB1 (T1_ID,T1_NAME) values (1,'Test 1');
    Insert into TAB1 (T1_ID,T1_NAME) values (2,'Test 2');
    Insert into TAB2 (T2_ID,T2_T1_ID,T2_RV_NO,T2_RV_DATE,T2_F1,T2_F2,T2_F3) values (1,1,'00',to_date('01-OCT-2012','DD-MON-RRRR'),'Probation','05','Yes');
    Insert into TAB2 (T2_ID,T2_T1_ID,T2_RV_NO,T2_RV_DATE,T2_F1,T2_F2,T2_F3) values (2,1,'01',to_date('06-OCT-2012','DD-MON-RRRR'),'Confirm','06','Yes');
    Insert into TAB2 (T2_ID,T2_T1_ID,T2_RV_NO,T2_RV_DATE,T2_F1,T2_F2,T2_F3) values (3,2,'00',to_date('02-OCT-2012','DD-MON-RRRR'),'Probation','07','No');
    Insert into TAB2 (T2_ID,T2_T1_ID,T2_RV_NO,T2_RV_DATE,T2_F1,T2_F2,T2_F3) values (4,2,'01',to_date('09-OCT-2012','DD-MON-RRRR'),'Probation','07','Yes');
    Insert into TAB2 (T2_ID,T2_T1_ID,T2_RV_NO,T2_RV_DATE,T2_F1,T2_F2,T2_F3) values (5,1,'02',to_date('10-OCT-2012','DD-MON-RRRR'),'Confirm','06','No');Now i want to produce the following reports..
    Period:      06-OCT-2012 to 09-OCT-2012
    T2_RV_DATE     T1_NAME          T2_RV_NO     Revised_Column     Previous_Value     Revised_value
    06-OCT-2012     Test 1          01          T2_F1          Probation     Confirm
                                  T2_F2          05          06
    09-OCT-2012     Test 2          01          T2_F3          No          YesI just achieve Revised_Column     Previous_Value     Revised_value for a particular name.
    Here is my code
    SELECT T2_RV_NO,T2_RV_DATE,T1_NAME,'T2_F1' Revised_Column,PREVIOUS_VALUE,REVISED_VALUE
    FROM(
    SELECT T2_RV_NO,T2_RV_DATE,T1_NAME,'T2_F1',
    LAG(T2_F1) OVER (ORDER BY T2_RV_DATE) PREVIOUS_VALUE ,T2_F1 REVISED_VALUE
    FROM TAB2,TAB1
    WHERE TAB1.T1_ID=TAB2.T2_T1_ID
    AND TAB1.T1_ID=:EMP_ID)
    WHERE NVL(PREVIOUS_VALUE,'null')<>NVL(REVISED_VALUE,'null')
    AND T2_RV_DATE BETWEEN :BEGIN_DATE AND :END_DATE
    AND T2_RV_NO<>'00'
    UNION ALL
    SELECT T2_RV_NO,T2_RV_DATE,T1_NAME,'T2_F2' Revised_Column,PREVIOUS_VALUE,REVISED_VALUE
    FROM(
    SELECT T2_RV_NO,T2_RV_DATE,T1_NAME,'T2_F2',
    LAG(T2_F2) OVER (ORDER BY T2_RV_DATE) PREVIOUS_VALUE ,T2_F2 REVISED_VALUE
    FROM TAB2,TAB1
    WHERE TAB1.T1_ID=TAB2.T2_T1_ID
    AND TAB1.T1_ID=:EMP_ID)
    WHERE NVL(PREVIOUS_VALUE,'null')<>NVL(REVISED_VALUE,'null')
    AND T2_RV_DATE BETWEEN :BEGIN_DATE AND :END_DATE
    AND T2_RV_NO<>'00'
    UNION ALL
    SELECT T2_RV_NO,T2_RV_DATE,T1_NAME,'T2_F3' Revised_Column,PREVIOUS_VALUE,REVISED_VALUE
    FROM(
    SELECT T2_RV_NO,T2_RV_DATE,T1_NAME,'T2_F3',
    LAG(T2_F3) OVER (ORDER BY T2_RV_DATE) PREVIOUS_VALUE ,T2_F3 REVISED_VALUE
    FROM TAB2,TAB1
    WHERE TAB1.T1_ID=TAB2.T2_T1_ID
    AND TAB1.T1_ID=:EMP_ID)
    WHERE NVL(PREVIOUS_VALUE,'null')<>NVL(REVISED_VALUE,'null')
    AND T2_RV_DATE BETWEEN :BEGIN_DATE AND :END_DATE
    AND T2_RV_NO<>'00'but it's not work for multiple employee id
    Thanks in advance
    Edited by: Asked to Learn on Oct 6, 2012 9:18 PM

    Asked to Learn wrote:
    thanks members. i get a solution of my own for my reporting purpos. Thanks..Well why don't you post your solution? Why not be helpful to others like yourself who might search the forum looking for answers? Don't just take, give back.
    Cheers, APC

  • How to connect sqlserver use oracle sql developer?

    I created a non-oracle location connection in owb and can load data from sqlserver to warehouse. Now, I want to use sqlplus or sqldeveloper to connect sqlserver directly, But I got this error message"ora-03135:connection lost contact".
    How can I connect sqlserver in sqldeveloper or sqlplus?
    Thanks

    Hi Napo,
    SQLDeveloper can migrate to oracle, browse sqlserver and run and display results from single statements.
    I have not seen "ora-03135:connection lost contact" have you set up sqlserver for tcp/ip connection, checked the port is open (and not blocked by, for example, firewalls) and used the jtds driver to connect SQLDeveloper to sqlserver?
    Note that "ora-03135:connection lost contact" is an oracle error and does not seem related to sqlserver.
    Oracle also has heterogenous gateway products which may be useful
    Oracle® Database Gateway for SQL Server User's Guide
    http://download.oracle.com/docs/cd/B28359_01/gateways.111/b31049/toc.htm
    -Turloch

  • How to use parameters in oracle SQL script????

    Right now I am writing a SQL script to create a schema and build the objects of this schema....
    I use a .net winform program to run sqlplus to parse this sql script ...
    The problem is that the schema name and the tablespace's location and the sys password must be input by the user, so my SQL script should use these runtime input parameters instead of const parameters....
    So, how to use parameter in SQL script ...........
    Are there some example scripts in oracle home directory for me to refer to????

    Hi,
    UNISTD wrote:
    thanks .....
    what's the difference between variable , define, accept in sqlplus ???VARIABLE declares (but does not assign a value to) a bind variable. Unlike substitution variables, bind variables are passed to the back end to be compiled, and they can only be values in certain data types. You can not use a bind vaiable in place of an identifier, so to do something like
    CREATE USER  &1 ...a bind variable won't work.
    "DEFINE x = y" sets the substitution variable &x to have the value y. There is no user interaction (unless x or y happen to contain undefined substtiution variables).
    "DEFINE x" shiows the value of the substitution variable &x, or, if it is undefined, raises a SQL*Plus error. I use this feature below.
    ACCEPT sets a substitution variable with user interaction.
    And if the user miss some parameters in “sqlplus /nolog ssss.sql par1 par2 par5 par6”, how to use default value of the miss parameters??Don't you need a @ befiore the script name, e.g.
    sqlplus /nolog @ssss.sql par1 par2 par5 par6Sorry, I don't know of any good way to use default values.
    The foloowing works, but, as you can see, it's ugly.
    "DEFINE 1" display a message like
    DEFINE 1            = "par1" (CHAR)if &1 is defined; otherwise,it will display a SQL*Plus error message like
    SP2-035: symbol 1 is UNDEFINEDNotice that the former contains an '=' sign, but the latter does not.
    The best way I know to use default values is to run the DEFINE command, save the output to a filee, read the file, and see if it's an error message or not.
    So you can use a script like this:
    --     This is  DEFINE_DEFAULT.SQL
    SPOOL     got_define_txt.sql
    DEFINE     &dd_old
    SPOOL     OFF
    COLUMN     dd_new_col     NEW_VALUE     &dd_new
    WITH     got_define_txt     AS
         SELECT  q'[
              @got_define_txt
    ]'               AS define_txt
         FROM    dual
    SELECT     CASE
             WHEN  define_txt LIKE '%=%'
             THEN  REGEXP_REPLACE ( define_txt
                               , '.+"
    ([^"]*)
                         , '\1'
             ELSE  '&dd_default'
         END        AS dd_new_col
    FROM     got_define_txt
    {code}
    and start your real script, ssss.sql, something like this:
    {code}
    DEFINE          dd_new     = sv1
    DEFINE          dd_old     = 1
    DEFINE          dd_default     = FOO
    @DEFINE_DEFAULT
    DEFINE          dd_new     = sv2
    DEFINE          dd_old     = 2
    DEFINE          dd_default     = "Testing spaces in value"
    @DEFINE_DEFAULT
    {code}
    when this finishes running, the substitution variable &sv1 will either have the value you passed in &1 or, if you didn't pass anything, the default value you specified, that is FOO.
    Likewise, &sw2 will have the value you passed, or, if you didn't pass anything, the 23-character string 'Testing spaces in value'.
    Here's how it works:
    Define_default.sql puts the output of the "DEFINE x" command into a column, define_txt, in a query.  That query displays either the existing value of the substitution variable indicated by &dd_old or, if it is undefined, the default value you want to use, which is stored in the substitution variable &dd_default.  The substitution variable named in &dd_new is always set to something, but that something may be its existing value.
    Notice that the paramerters to define_default.sql must be passed as global varibales.
    Why didn't I just use arguments, so that we could simply say:
    {code}
    @DEFINE_DEFAULT  sv1  1  FOO
    {code}
    ?  Because that would set the substitution variables &1, &2 and &3, which are miost likely the very ones in which you're interested.
    I repeat: there must be a better way, but I'm sorry, I don't know what it is.
    I usually don't do the method above.  Instead, I always pass the required number of parameters, but I pass dummy or plce-holder values.
    For example, if I wanted to call ssss.sql, but use defulat vlaues for &1 and &3, then I would say something like:
    {code}
    @ssss  ?  par2  ?
    {code}
    and, inside ssss.sql, test to see if the values are the place holder '?', and, if so, replace them with some real default value.  The use has  to remember what the special place holder-value is, but does not need to know anything more, and only ssss.sql itself needs to change if the default values change.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How can I access the oracle/sql server jdbc driver class files from my cust

    I have a war file in which I have custom DataSource i.e mypackage.Datasource class. Its basically the need of my application. In this class we connect to datasource and link some of our programming artifacts .
    I have deployed the oracle jdbc driver and deploy my application as ear with datasources.xml in the meta inf file. Inspite of that my code fails to load the jdbc driver classes.
    Here is the extract of the code :
            Class.forName("oracle.jdbc.OracleDriver").newInstance();
             String url = "jdbc:oracle:thin:@dataserver:1521:orcl";
            Connection conn = DriverManager.getConnection(url, "weblims3", "labware");
            if(conn != null){
              out.println("the connection to the database have been achieved");
            out.println("conn object achived= " + conn);
    Class.forname fails in this case. I can see the ojdbc5.jar the driver jar in usr\sap\CE1\J00\j2ee\cluster\bin\ext\ojdbc5  . I even put the ojdbc.jar in web-inf/lib and application lib but does not help at all. Hope I have explained my problem clearly.
    I deployed the jdbc driver in the name of ojdbc5 .
    I am stuck here. It will be great help if anyone can help me in this. Thanks in advance.

    Bent,
    You can access the database from your Java portlet, just like from any other Java/JSP environment. Yes, you can use JDBC, as well as BC4J.
    The Discussion Forum portlet was built using BC4J, take a look at it's source to see how it was done.
    Also, check out Re: BC4J Java portlet anyone?, it contains a lot of useful information too.
    Peter

  • How to estimated time for oracle sql query

    i have query run every month on production server to collect some information
    data size is difference every month
    what i need to estimate the time before running
    how can i do that

    sorry this is what i get
    when i caculate time column it give me 10 sec
    but when i make this
    SQL> set timing on;
    SQL> select * from tab;
    3658 rows selected.
    Elapsed: 00:00:05.50
    so whay in the first give me 10 sec and the secand give me 5.50 sec
    SQL> explain plan for select * from tab;
    Explained.
    SQL> select * from table(dbms_xplan.display);
    PLAN_TABLE_OUTPUT
    Plan hash value: 457676135
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | 1243 | 104K| 182 (4)| 00:00:03 |
    | 1 | NESTED LOOPS OUTER | | 1243 | 104K| 182 (4)| 00:00:03 |
    |* 2 | TABLE ACCESS FULL | OBJ$ | 1243 | 98197 | 142 (5)| 00:00:02 |
    | 3 | TABLE ACCESS CLUSTER| TAB$ | 1 | 7 | 1 (0)| 00:00:01 |
    |* 4 | INDEX UNIQUE SCAN | I_OBJ# | 1 | | 0 (0)| 00:00:01 |
    PLAN_TABLE_OUTPUT
    Predicate Information (identified by operation id):
    2 - filter("O"."TYPE#"<=5 AND "O"."OWNER#"=USERENV('SCHEMAID') AND
    "O"."TYPE#">=2 AND "O"."LINKNAME" IS NULL)
    4 - access("O"."OBJ#"="T"."OBJ#"(+))
    18 rows selected.
    SQL>
    Edited by: 862640 on Nov 27, 2011 1:43 AM
    Edited by: 862640 on Nov 27, 2011 1:49 AM
    Edited by: 862640 on Nov 27, 2011 1:53 AM

  • How to present results from a sql-query in java

    Hi - I'm having problems finding out how to present data from a database-query in a nice looking way in a JFrame. Want to present them similar to the way they are presented in the database. Is there an easy way doing this?

    Tried to use a JTable, but it's difficult when data in the table should be able to change all the time, i.e the number of rows. What is a Html-table? Can i use it in an application?

  • How would you write tthis oracle sql in ABAP. Thank you verry verry much

    SELECT
    to_char(sum(dmbtr)),s.budat,shkzg,hkont
    FROM
    sapr3.bsas s,
    sapr3.bkpf k
    WHERE
    s.belnr=k.belnr AND s.gjahr=k.gjahr AND s.bukrs=k.bukrs AND k.bukrs='02' AND k.gjahr>=EXTRACT(YEAR FROM ADD_MONTHS(SYSDATE,-12)) GROUP BY s.budat,shkzg,hkont;

    GO THRU THE JOINS IN SELECT STATEMNET IN ABAP.
    I JOINED FOUR TABLES WITH DECLARED FIELDS.
    DATA: BEGIN OF I_KNA1 OCCURS 1,
          KUNNR LIKE KNA1-KUNNR,
          LAND1 LIKE KNA1-LAND1,
          NAME1 LIKE KNA1-NAME1,
          ORT01 LIKE KNA1-ORT01,
          END OF I_KNA1.
    DATA: BEGIN OF I_VBAK OCCURS 1,
          KUNNR LIKE VBAK-KUNNR,
          VBELN LIKE VBAK-VBELN,
          ERDAT LIKE VBAK-ERDAT,
          ERNAM LIKE VBAK-ERNAM,
          END OF I_VBAK.
    DATA: BEGIN OF I_VBAP OCCURS 1,
          VBELN LIKE VBAP-VBELN,
          POSNR LIKE VBAP-POSNR,
          MATNR LIKE VBAP-MATNR,
          CHARG LIKE VBAP-CHARG,
          END OF I_VBAP.
    DATA: BEGIN OF I_MARA,
          MATNR LIKE MARA-MATNR,
          MBRSH LIKE MARA-MBRSH,
          MTART LIKE MARA-MTART,
          MEINS LIKE MARA-MEINS,
          END OF I_MARA.
    DATA: BEGIN OF I_DEST OCCURS 1,
          KUNNR LIKE KNA1-KUNNR,
          LAND1 LIKE KNA1-LAND1,
          NAME1 LIKE KNA1-NAME1,
          ORT01 LIKE KNA1-ORT01,
          VBELN LIKE VBAK-VBELN,
          ERDAT LIKE VBAK-ERDAT,
          ERNAM LIKE VBAK-ERNAM,
          POSNR LIKE VBAP-POSNR,
          MATNR LIKE VBAP-MATNR,
          CHARG LIKE VBAP-CHARG,
          MBRSH LIKE MARA-MBRSH,
          MTART LIKE MARA-MTART,
          MEINS LIKE MARA-MEINS,
          END OF I_DEST.
    SELECT KKUNNR KLAND1 KNAME1 KORT01 VVBELN VERDAT VERNAM PPOSNR
    PMATNR PCHARG INTO TABLE I_DEST FROM KNA1 AS K INNER JOIN VBAK AS V ON
    KKUNNR = VKUNNR INNER JOIN VBAP AS P ON VVBELN = PVBELN INNER JOIN
    MARA AS M ON PMATNR = MMATNR.
    LOOP AT I_DEST.
    WRITE: / I_DEST-KUNNR, I_DEST-LAND1, I_DEST-NAME1, I_DEST-ORT01,
    I_DEST-VBELN, I_DEST-ERDAT, I_DEST-ERNAM, I_DEST-POSNR, I_DEST-MATNR,
    I_DEST-CHARG, I_DEST-MBRSH, I_DEST-MTART, I_DEST-MEINS.
    ENDLOOP.
    CHEERS.

  • How to get exact query of sql in oracle?

    Hi all,
    Hope doing well,
    sir i was using one query of sql that is here:
    Declare @nshiftmax datetime
    set @nshiftmax=convert(time,DATEADD(N,1439,0))
    print @nshiftmax
    so it is retreiving the result 1/1/1900 11:59 p.m
    and one more query is there
    Declare @nshiftmax datetime
    set @nshiftmax=convert(time,DATEADD(N,0,0))
    print @nshiftmax
    so it is retreiving the result 1/1/1900 12:00 a.m
    how to same result in oracle query.
    thanks in advance.

    952646 wrote:
    Hi all,
    Hope doing well,
    sir i was using one query of sql that is here:
    You mean you have these statements in SQL Server?
    Please remember that SQL is an access language for relational databases. It is used by all of the major rdbms products. "SQL Server" is the name of Microsoft's rdbms product. Do not let Microsoft's marketing flaks lull you into thinking SQL = SQL Server.
    Declare @nshiftmax datetime
    set @nshiftmax=convert(time,DATEADD(N,1439,0))
    print @nshiftmax
    so it is retreiving the result 1/1/1900 11:59 p.m
    and one more query is there
    Declare @nshiftmax datetime
    set @nshiftmax=convert(time,DATEADD(N,0,0))
    print @nshiftmax
    so it is retreiving the result 1/1/1900 12:00 a.m
    how to same result in oracle query.
    thanks in advance.

  • Help how to connecting Oracle SQL Developer 3.0  with Oracle Database 11g

    Hello,
    I'm new in oracle developer yesterday i setup in my laptop database 11g the last version (11.2.0.1.0), well i follow steps still i got succeed to install, and i got my local host URL and i test my user name and password work very well, my problem now is i try to connect database 11g using Oracle SQL Developer 3.0 (3.0.04.34) but always filed and with my little experience i don't know where the wrong. as i said i test database after finish install is work fine the my URL is https://Ahmed-HP:1158/em and i test my username and password that i already set before is enter normal in my local database, please i need help to know how i connect database with Oracle SQL Developer 3.0 (3.0.04.34).
    Thanks,

    885173 wrote:
    EdStevens, thanks for your quick answer, sorry for my explain was doesn't clear, i open oracle sql developer and choose new connection i set connection name system_orcl username:system password:*i set my password that i create when i setup database*
    -Now the link that i got after finish install database is https://Ahmed-HP:1158/em so i have question about this point Hostname and port if the link to access database is this https://Ahmed-HP:1158/em so this mean i typing at Hostname:localhost and port:1158 ?
    because the message when i test connection always is filed and I'm sure i typing username and password and SID:orcl as i set when install database.port 1158 is what the dbcontrol (Oracle Enterprise Manager) is listening on. OEM is NOT the database. As far as the database is concerned, OEM is "just another client".
    Actually, the database doesn't listen for requests on any port. There is another process, the "listener" that listens for requests to connect to the database. Typically, it listens on port 1521. You should have a tnsnames.ora file set up to resolve a connection request to the correct host. You can read more on this at http://edstevensdba.wordpress.com/2011/02/09/sqlnet_overview/

Maybe you are looking for

  • I want to set up an iPod for my dad... (Multiple Libraries Question)

    My dad has a early Shuffle (back when HP made 'em), and has grown tired of no screen and all. Being technologically deficient as he is, I was going to give him my old iPod Video for Father's Day (since I'm getting the iPhone, hopefully), and have it

  • SQL Reporting Services with Java EE

    I have developed a Java application for calling the SQL Reports. A couple of reports are made in the server. This SQL Reporting server is deployed and the client is made in the java using Werb services. Whenever a search is done from the Java applica

  • Mac OS 10.4 Tiger

    I was wondering if i could use my ipod touch on 10.4 tiger

  • Blocked Invoice & Parked Invoice

    Hi All Can someone explain to me what is the meaning of Blocked Invoice and Parked Invoice? Thanks John

  • Red Hat 9 - Oracle 9.2 - Not able to connect remote db

    I can tnsping remote dbs but I can't use sqlplus. I do not have control of the listener.ora and can't get a hold of it. But I have no problems connecting with windows with same tns names file that I have on linux. Also when I look in sqlnet.log I see