Update & select query when tablespace in backup mode

Hi,
I have a query related to the DML statement when tablespace is in backup mode. Suppose when put the tablespace in begin backup mode then during the time one user run an update statement against this tablespace and commit the transaction and other user run the select query on the same data then which image the user will get and from where the data will be taken to display.
steps:
alter tablespace users begin backup;
update emp set sal=4000 where empno=101;
commit;
select * from emp where empno=101;
Now what result user will get and from where the data will fetch.
Thanks,
Gulshan

Hi,
alter tablespace users begin backup;
update emp set sal=4000 where empno=101;
commit;
select * from emp where empno=101;AFAIK, the database would work normally and you will not find the difference from transactions perspective. If you check from Oracle architecture and process, fuzzy bit will be setted at up and additional redo vectors would be saved up in the online redo logs - due to which size of redo would higher when compared to normal transactions. Secondly, you must be worried about the backup - which might not be consistent. So better opt for RMAN instead of User managed Backups.
- Pavan Kumar N

Similar Messages

  • Tablespace begin backup mode,

    Whether redo-logfiles get created during tablespace  begin backup mode.? is that really possible?

    a9362c69-5635-4bf2-a548-4a13a7cba11b wrote:
    Whether redo-logfiles get created during tablespace  begin backup mode.? is that really possible?
    Database Concepts
    Continuing to flood the forum with documentation questions -- especially after repeated warnings -- will continue to result in nothing more than links to the documentation you should be reading.  

  • What happen when Database in Backup Mode?

    Hi,
    What happen when we kept database in backup mode, Means using command 'Alter database Begin Backup';
    Thanks...
    Asit

    jgarry wrote:
    EdStevens wrote:
    jgarry wrote:
    What do you think of the snapshot backup on page 22 of [url http://en.community.dell.com/techcenter/storage/w/wiki/2638.oracle-11g-backup-and-recovery-using-rman-and-equallogic-snapshots-by-sis.aspx]this paper? (No sarcasm, I'm curious about these snap solutions in general. Though I am really down on Dell for what turned out to be a brain-damaged laptop I got for my wife.)
    Well, you can't really make a judgement about a company's enterprise products based on an experience with their consumer products.What if it came from what they call a business products catalog? They intermingle laptops with servers.
    Don't know, in general. I do know that for Dell there is a distinct difference between their decidedly consumer laptops (Inspiron) and their "business" Lattitude series. I know that at my last job we had a lot of rock solid HP equipment (servers and SAN) - vs. an HP laptop I had that was trouble from Day One. I'm sure there is a point in desktops and laptops the line can get blurred, but in the case of the OP, he was no where near that fuzzy line.
    >
    >>
    Perhaps I can find time to read the white paper over the weekend ....

  • How to improve performance of select query when primary key is not referred

    Hi,
    There is a select query where we are unable to refrence primary key of the tables:
    Since, the the below code is refrensing to vgbel and vgpos fields instead of vbeln and posnr..... the performance is very  slow.
    select vbeln posnr into (wa-vbeln1, wa-posnr1)             
           from lips                                            
           where ( pstyv ne 'ZBAT'    
               and pstyv ne 'ZNLN' )  
               and vgbel = i_vbap-vbeln                         
               and vgpos = i_vbap-posnr.                        
    endselect.                                                 
    Please le t me know if you have some tips..

    hi,
    I hope you are using the select statement inside a loop ...endloop get that outside to improve the performance ..
    if not i_vbap[] is initial.
    select vbeln posnr into table it_lips
    from lips
    for all entries in  i_vbap
    where ( pstyv ne 'ZBAT'
    and pstyv ne 'ZNLN' )
    and vgbel = i_vbap-vbeln
    and vgpos = i_vbap-posnr.
    endif.

  • Problem with select query when it returns a NULL value

    Hi all,
    I have a d/b table called QMEL and i picked VBELN from that table. Now if the VBELN value in that table is NULL i have to wtite an if condition.
    Can i say it like this
    IF VBELN = ' '.
    write: enter into the if condition.
    ELSE.
    write: enter into the else condition.
    ENDIF.
    or should is say some thing else? my objective is ..i should execute some statments if VBELN has no value and i should execute some othet statements if VBELN has a value.
    Kindly help..as even though i put above condition..it deosnot work
    Regards,
    Jessica Sam

    hi
    check this
    if u r using selection optins  use this code
    IF NOT s_material[] IS INITIAL.
        SELECT material                             
        FROM marc
               INTO  l_material
             WHERE material IN s_material.                     
        ENDSELECT.
        IF sy-subrc NE 0 AND l_material IS INITIAL.
          MESSAGE e302 WITH space.
        ENDIF.
      ENDIF.
    if u r using parameter then
    IF NOT P_material IS INITIAL.
        SELECT material                             
        FROM marc
               INTO  l_material
             WHERE material EQ P_material.                     
        ENDSELECT.
        IF sy-subrc NE 0 AND l_material IS INITIAL.
          MESSAGE e302 WITH space.
        ENDIF.
      ENDIF.
    ~linganna
    Edited by: katigiri linganna on Apr 8, 2009 5:58 AM

  • What exactly happens when datafile is put in backup mode ?

    Dear Friend,
    i want to know what exactly happens when a datafile is put in backup mode ?
    that is what happens between Begin Backup ........................... end backup
    with regards.

    When u start hot backup via 'alter tablespace begin backup', the tablespace headers are marked as such. The dirty data buffers that belong to the database files are written out to the files and the datafiles are check pointed. The headers are updated with SCN @ the time the backup commences. It is the data file headers that were not updated until the 'alter tablespace end backup' is issued.
    The database files still continue to be read and updated. Recovery will commence from the scn written at the commencement of the backup and it is the changes written to the redo\archive logs during the backup that are rolled forward during recovery
    Cheers,
    Bin

  • PIT recovery until time when database was in backup mode

    Hello,
    Is it possible to recover database until some point/time which is within "time window" when database tablespaces were still in online backup mode?
    I was basicaly replicatying database from source to target DB by putting DB to online backup mode, then copy all datafiles, after copy of datafiles was finished I started applying redologs generated on source DB afterwards. After I applied tens of redologs with "recover database until cancel using backup controlfile" and then typed "CANCEL" after 10-20 redologs applied I still got an error that opening DB would get an error due to inconsistent datafile. When I ended backup mode on source DB and applied few of redologs after ending backup mode on source DB datafiles were consistent.....
    Thx a lot for answer in advance.

    Hello Hemant K Chitale ,
    thats clear. I probably did not express it clearly, so I will describe it once again:
    Teoreticall scenario 1:
    I put 'source" database to backup mode and start copy datafiles to "target" db. When copy of all datafiles is succesfully finished (lets say it 5:00AM), I don't issue "end backup" on source DB but I keep tablespaces in backup mode until 7:00AM. On target DB I will start recovery and apply redologs from source system.
    Question 1:Is it possible to recover database until time 6:00AM? At this time all datafiles were already succesfully copied, BUT source db was still in backup mode. Or will I be able to get target DB to consistent state only after 7:00AM (end backup issuied on source DB) and not in window 5:00AM-7:00AM?
    Teoreticall scenario 2 (small correction comparing to scenario1):
    I will put source DB to begin backup mode at 5:00AM on 20.february and let it in this state until 7:00AM on 20.february. On target DB I will restore backup from source DB performed day before (or few days before does not matter) that means on 19.february and start to apply redologs generated after this backup.
    Question 2: Will I be able to recover DB until 6:00AM on 20.february and open database after recovery until this time? Or wont I be able to recover and open DB witin window 20.february 5:00AM-7:00AM (source db in backup mode)
    Bear in mind this is just teoreticly (don't ask me why would you do it and why you don't do it this way etc...). I just want to understand how it really works ;)
    Thx a lot!

  • Update only one select query field

    hello
    how i can update select query result field in original table.
    update table1 set field_1 from(select field_1 from table 1,table2,table3,table4 where table1.field_1=table1.field_1 and table2.field_2=table3.field_2 and table4.field_3=table1.field_4)
    like that.is it possible!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!can u please help me to rewrite query/
    select query returns result like that from different tables
    lets example field_1 field_2 field_3 field_4
    TIGER 1 V A
    TIGER 2 F B
    TIGER 3 R C
    I need to update 'TIGER' instead of 'LION' in original table.
    THANKS

    Maybe something like
    update table1
       set beast = (select animal
                      from <table_list>
                     where <predicates>
    where beast = 'LION'when your query returns a single row
    or when multiple rows are returned
    update (select t1.beast,t2.animal
              from (select beast,
                           <join_columns_list>
                      from table1
                     where beast = 'LION'
                   ) t1,
                   (select animal,
                           <join_columns_list>
                      from <table_list>
                     where <predicates>
                   ) t2
             where t1.<join_columns_list> = t2.<join_columns_list>
       set beast = animalRegards
    Etbin

  • RMAN and Begin backup mode

    Hi guys I have a couple of questiopns...
    I want to know whether data is written to datafiles by DBWR when the datafile is in begin backup mode.
    What is the difference in archive log creation during normal operation of a database and operation of a database during RMAN backup?

    user13087302 wrote:
    Normally, Oracle should write only changes into redolog files. But if tablespace is in backup mode, then entire block will be put into redolog as soon as this change it is 1st change occured on that block after enabling backup mode. That is why, we face massive redo log generation if the tablespace is in backup mode. So, logically you should be able to recover to the last SCN you have in hands.What do you mean by last SCN.Is it the SCN before puttting the tablespace in backup mode?Does that mean data present in other files will also be lost even though they are written in datafiles..Pls, look:
    SQL> create tablespace myts1 datafile 'C:\app\oracle\oradata\testdb\myts1.dbf' size 10m;
    Tablespace created.
    SQL> create tablespace myts2 datafile 'C:\app\oracle\oradata\testdb\myts2.dbf' size 10m;
    Tablespace created.
    SQL> create table myt1 tablespace myts1 as select * from dba_objects where rownum<10001;
    Table created.
    SQL> create table myt2 tablespace myts2 as select * from dba_objects where rownum<10001;
    Table created.
    SQL> alter tablespace myts1 begin backup;
    Tablespace altered.
    SQL> create table myt1_1 tablespace myts1 as select * from dba_objects where rownum<10001;
    Table created.
    SQL> create table myt2_1 tablespace myts2 as select * from dba_objects where rownum<10001;
    Table created.
    SQL> create table myt1_3 tablespace myts1 as select * from dba_objects where rownum<10001;
    Table created.Backup database:
    C:\Documents and Settings\Administrator>rman target /
    Recovery Manager: Release 11.2.0.1.0 - Production on Wed Nov 3 15:46:55 2010
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    connected to target database: TESTDB (DBID=2517263760)
    RMAN> backup database;
    Starting backup at 03-NOV-10
    using target database control file instead of recovery catalog
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=44 device type=DISK
    channel ORA_DISK_1: starting full datafile backup set
    channel ORA_DISK_1: specifying datafile(s) in backup set
    input datafile file number=00001 name=C:\APP\ORACLE\ORADATA\TESTDB\SYSTEM01.DBF
    input datafile file number=00002 name=C:\APP\ORACLE\ORADATA\TESTDB\SYSAUX01.DBF
    input datafile file number=00003 name=C:\APP\ORACLE\ORADATA\TESTDB\UNDOTBS01.DBF
    input datafile file number=00005 name=C:\APP\ORACLE\ORADATA\TESTDB\EXAMPLE01.DBF
    input datafile file number=00006 name=C:\APP\ORACLE\ORADATA\TESTDB\MYTS1.DBF
    input datafile file number=00007 name=C:\APP\ORACLE\ORADATA\TESTDB\MYTS2.DBF
    input datafile file number=00004 name=C:\APP\ORACLE\ORADATA\TESTDB\USERS01.DBF
    channel ORA_DISK_1: starting piece 1 at 03-NOV-10
    channel ORA_DISK_1: finished piece 1 at 03-NOV-10
    piece handle=C:\APP\ORACLE\FLASH_RECOVERY_AREA\PRIM_DB\BACKUPSET\2010_11_03\O1_MF_NNNDF_TAG20101103T154701_6F2LXQ5C_.BKP tag=TAG20101103T154701 comment=NONE
    channel ORA_DISK_1: backup set complete, elapsed time: 00:01:35
    channel ORA_DISK_1: starting full datafile backup set
    channel ORA_DISK_1: specifying datafile(s) in backup set
    including current control file in backup set
    including current SPFILE in backup set
    channel ORA_DISK_1: starting piece 1 at 03-NOV-10
    channel ORA_DISK_1: finished piece 1 at 03-NOV-10
    piece handle=C:\APP\ORACLE\FLASH_RECOVERY_AREA\PRIM_DB\BACKUPSET\2010_11_03\O1_MF_NCSNF_TAG20101103T154701_6F2M0PJ3_.BKP tag=TAG20101103T154701 comment=NONE
    channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01
    Finished backup at 03-NOV-10
    Recovery Manager complete.
    SQL> select current_scn from v$database;
    CURRENT_SCN
        1466019
    SQL> drop table myt1_3 purge;
    Table dropped.So, we dropped table MYT1_3 and now trying incomplete recovery.
    SQL> shutdown abort;
    ORACLE instance shut down.
    SQL> startup mount;
    ORACLE instance started.
    Total System Global Area  431038464 bytes
    Fixed Size                  1375088 bytes
    Variable Size             322962576 bytes
    Database Buffers          100663296 bytes
    Redo Buffers                6037504 bytes
    Database mounted. C:\Documents and Settings\Administrator>rman target /
    Recovery Manager: Release 11.2.0.1.0 - Production on Wed Nov 3 15:51:51 2010
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    connected to target database: TESTDB (DBID=2517263760, not open)
    RMAN> run
    2> {
    3> set until scn 1466019;
    4> restore database;
    5> recover database;
    6> sql 'alter database open resetlogs';
    7> }
    executing command: SET until clause
    Starting restore at 03-NOV-10
    using target database control file instead of recovery catalog
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=20 device type=DISK
    channel ORA_DISK_1: starting datafile backup set restore
    channel ORA_DISK_1: specifying datafile(s) to restore from backup set
    channel ORA_DISK_1: restoring datafile 00001 to C:\APP\ORACLE\ORADATA\TESTDB\SYS
    TEM01.DBF
    channel ORA_DISK_1: restoring datafile 00002 to C:\APP\ORACLE\ORADATA\TESTDB\SYSAUX01.DBF
    channel ORA_DISK_1: restoring datafile 00003 to C:\APP\ORACLE\ORADATA\TESTDB\UNDOTBS01.DBF
    channel ORA_DISK_1: restoring datafile 00004 to C:\APP\ORACLE\ORADATA\TESTDB\USERS01.DBF
    channel ORA_DISK_1: restoring datafile 00005 to C:\APP\ORACLE\ORADATA\TESTDB\EXAMPLE01.DBF
    channel ORA_DISK_1: restoring datafile 00006 to C:\APP\ORACLE\ORADATA\TESTDB\MYTS1.DBF
    channel ORA_DISK_1: restoring datafile 00007 to C:\APP\ORACLE\ORADATA\TESTDB\MYTS2.DBF
    channel ORA_DISK_1: reading from backup piece C:\APP\ORACLE\FLASH_RECOVERY_AREA\
    PRIM_DB\BACKUPSET\2010_11_03\O1_MF_NNNDF_TAG20101103T154701_6F2LXQ5C_.BKP
    channel ORA_DISK_1: piece handle=C:\APP\ORACLE\FLASH_RECOVERY_AREA\PRIM_DB\BACKUPSET\2010_11_03\O1_MF_NNNDF_TAG20101103T154701_6F2LXQ5C_.BKP tag=TAG20101103T154701
    channel ORA_DISK_1: restored backup piece 1
    channel ORA_DISK_1: restore complete, elapsed time: 00:01:45
    Finished restore at 03-NOV-10
    Starting recover at 03-NOV-10
    using channel ORA_DISK_1
    starting media recovery
    media recovery complete, elapsed time: 00:00:03
    Finished recover at 03-NOV-10
    sql statement: alter database open resetlogs
    RMAN>Now, check tables:
    SQL> select count(*) from myt1;
      COUNT(*)
         10000
    SQL> select count(*) from myt2;
       COUNT(*)
         10000
    SQL> select count(*) from myt1_3;
      COUNT(*)
         10000
    SQL> select count(*) from myt2_1;
      COUNT(*)
         10000So, it does not matter what is the status of any tablespace: in backup mode or not. Incomplete recovery uses archivelogs + redologs.

  • DB Taken out of Backup Mode During User-Managed Backup

    I was taking a user-managed backup and the DB was accidentally taken out of backup mode in the middle of the backup. The backup continued and backed up all the datafiles, but many of the datafiles were backed up after backup mode was turned off. Can I restore the DB using this backup? What are my options?

    The backup might be usable and it might not. When you put a tablespace (actually all data files in the tablespace) into backup mode, Oracle continues to perform writes to those data files. However, when first modifying a block in a data file after it has been put in backup mode, Oracle will put a before image of that entire block in the redo log (instead of just the row changes). After this first data block change is written to the redo log, further changes to this data block are written as just normal. Oracle does this initial write of the whole block to prevent fractured blocks during recovery. You see, when the OS copies the files for backup, it copies in chunks that might, or might not, fall on a data block boundary. A data block may be updated on disk between two OS file copy chunks. Thus when the file is restored it is possible that part of a data block will have new data and another part have old. This is a fractured block. When applying undo, Oracle first lays down a full block, which will cure a possible fractured block, and then apply redo as normal to complete the recovery operation.
    This is why it is important to make sure that your hot backup set includes all redo generated between the time you put the tablespaces in backup mode and the time you took them out of backup mode.

  • Backup Mode

    Gurus,
    I have a script to put all tablespaces in backup mode (oracle 9i). This script used to take less than a minute to execute. Now, it is taking more than one hour for the same tablespaces.
    Any idea what can decrease the performance of
    alter tablespace xxx begin backup;
    Please help

    OK, you have 381 datafiles, but I made the wrong question (mea culpa), the relevant info is actually the number of tablespaces. When you execute "begin backup" the whole buffer cache is scanned, independently of the number of dirty buffers, so if the buffer cache is large and you have a lot of tablespaces, the time it takes to process all of them will be high. The workaround is to use RMAN for backups, it doesn't issue "begin backup". I've to remark that hitting this "bug" is just a possibility among others.
    Enrique

  • How can i use param in my select query ( see code)

    Hi ,
    I need to use the param instead of hardcoding the value in the select query , when i did that it is working .
    I think the limit of args is only till the end of main and my select query is in a method called Load() .
    How can i use the param in my select query .
    public static void main(String[] args){
    name = args[0];
    class= args[1];
    new Load();
    }//end of main
    public Load()
              try {
                   Class.forName(JDBC_DRIVER);
                   connection = DriverManager.getConnection(DATABASE_URL,"username","pw");
                   statement = connection.createStatement();
                   //First Query : pin and ticket number
                   ResultSet resultSet = statement.executeQuery("SELECT pin , ticketnumber from airport ,year where "+                                                                      "year.year_name= Here i need to use the param (instead of hardcoding) and year.class_year= Here too i need to use param");
    }// end of method Load()Edited by: 1sai on Sep 24, 2008 7:34 AM
    Edited by: 1sai on Sep 24, 2008 7:35 AM

    Might I suggest you change the structure of your program to the following:
    public class Load {
      private Connection conn;
      private PreparedStatement statement;
      public Load(String sql) {
        init(sql);
      protected void init(String sql) throws Exception {
        Class.forName(JDBC_DRIVER);
        conn = DriverManager.getConnection(DATABASE_URL, "username", "pw");
        statement = conn.prepareStatement(sql);
      public ResultSet execute(String p1, String p2) throws Exception {
        statement.setString(1, p1);
        statement.setString(2, p2);
        return statement.executeQuery();
      public void close() throws Exception {
        if (statement != null)
          statement.close();
        statement = null;
        if (conn != null)
          conn.close();
        conn = null;
      public static void main(String[] args) throws Exception {
        String sql = args[0];
        String param1 = args[1];
        String param2 = args[2];
        Load load = new Load(sql);
        ResultSet rs = load.execute(param1, param2);
        while (rs.next())
          System.out.println(rs.get(0));
        rs.close();
        load.close();
    }This allows you to use the same "Load" object for multiple queries with different parameters.
    I do not recommend you actually use the code above in any sort of production application. You should really take a look at Spring Framework along with an ORM tool like Hibernate or Ibatis to simplify your DAO layer.
    Hope this helps,
    David

  • Tablespace or Datafile in Backup mode

    Hi,
    Can anyone explain me what happen at the background when a tablespace or a datafile is in backup mode.
    Thanks in advance
    Regards
    Aruna
    Edited by: user11144654 on May 8, 2009 3:10 AM

    The tablespace is checkpointed, the checkpoint SCN marker in the datafile headers cease to increment with checkpoints, and full images of changed DB blocks are written to the redologs.
    Those three actions are all that is required to guarantee consistency once the file is restored and recovery is applied. By freezing the checkpoint SCN in the file headers, any subsequent recovery on that backup copy of the file will know that it must commence at that SCN. Having an old SCN in the file header tells recovery that the file is an old one, and that it should look for the redolog file containing that SCN, and apply recovery starting there. Note that checkpoints to datafiles in hot backup mode are not suppressed during the backup, only the incrementing of the main checkpoint SCN flag. A “hot backup checkpoint” SCN marker in the file header continues to increment as periodic or incremental checkpoints progress normally.
    There is a confusing side effect of having the checkpoint SCN artificially frozen at an SCN earlier than the true checkpointed SCN of the datafile. In the event of a system crash or a ‘shutdown abort’ during hot backup of a tablespace, the automatic crash recovery routine at startup will think that the files for that tablespace are quite out of date, and will actually suggest the application of old archived redologs in order to bring them back into sync with the rest of the database. It is unnecessary, in this case, to heed Oracle’s suggestion. With the database started up in mount mode, simply check v$backup and v$datafile to determine which datafiles were in backup mode at the time the database crashed. For each file in backup mode, issue an ‘alter database datafile '<file name>' end backup;’ This action will update the checkpoint SCN in the file headers to be the same as the hot backup checkpoint SCN (which is a true representation of the last SCN to which the datafile is truly checkpointed. Once this action is taken, it allows normal crash recovery to proceed during the ‘alter database open;’ command.
    By initially checkpointing the datafiles that comprise the tablespace and logging full block images to redo, Oracle guarantees that any blocks changed in the datafile while in hot backup mode will also be available in the redologs in case they are ever used for a recovery.
    It is well understood by much of the Oracle user community that during hot backup mode, a greater volume of redo is generated for changes to the tablespace being backed up than when the tablespace is not in backup mode. This is the result of the logging of full images of changed blocks in these tablespaces to the redologs. Normally, Oracle logs an entry in the redologs for every change in the database, but it does not log the whole image of the database block. By logging full images of changed DB blocks to the redologs during backup mode, Oracle eliminates the possibility of the backup containing irresolvable split blocks. To understand this reasoning, you must first understand what a split block is.
    Typically, Oracle database blocks are a multiple of O/S blocks.  For instance, most Unix filesystems have a default block size of 512 bytes, while Oracle’s default block size is 2k. This means that the filesystem stores data in 512 byte chunks, while Oracle performs reads and writes in 2k chunks, or multiples thereof. While backing up a datafile, your backup script makes a copy of the datafile from the filesystem, using O/S utilities such as copy, dd, cpio, or OCOPY.  As it is making this copy, it is reading in O/S-block sized increments. If the database writer happens to be writing a DB block into the datafile at the same time that your script is reading that block’s constituent O/S blocks, your backup copy of the DB block could contain some O/S blocks from before the database performed the write, and some from after. This would be a split block.
    By logging the full block image of the changed block to the redologs, it guarantees that in the event of a recovery, any split blocks that might be in the backup copy of the datafile will be resolved by overlaying them with the full legitimate image of the block from the redologs. Upon completion of a recovery, any blocks that got copied in a split state into the backup will have been resolved through application of full block images from the redologs.

  • How SCN sync after the tablespace is put back to END Backup mode

    When we put the tablespace in begin backup mode, the scn get forzen and it will not be further updated, until it is put back to end backup.
    Question is : If at the time of being backup , say the snc forzed at 45. Before we put back the tablespace to end back up , we had genrerated 10 SCN. Then the current scn is 55. If we put the tablespace in end backup , does the datafile will start with scn 56 ( by maintaint it previous scn at 45)
    Or after we put back the tsp in end back up , does the datafile will be updated from 46 to 55 , before it is updated with scn 56.
    In the above example i am considering by db has one datafile only.
    Thanks
    Naveen

    Are you implying that the "Checkpoint number" is a different series of numbers --
    seperate from SCNs ?
    Are you implying that when a checkpoint occurs it is this "Checkpoint number"
    that is incremented and written to the datafile headers ?
    There really is no such thing as a "Checkpoint number".
    If you look at the definitions of V$DATABASE , V$DATAFILE and V$DATAFILE_HEADER, you would see that a Checkpoint increments the SCN.
    A header can have multiple entries -- a Checkpoint SCN (called CHECKPOINT_CHANGE#) , ArchiveLog SCN (called ARCHIVELOG_CHANGE#),
    the Current SCN (called CURRENT_SCN), SCN of last Unrecoverable (Nologging)
    (called UNRECOVERABLE_CHANGE#) etc etc. They are all derived from SCNs
    only.
    The SCN is used as the single point of reference. Thus, we can compare
    CHECKPOINT_CHANGE# with CURRENT_SCN with UNRECOVERABLE_CHANGE# etc.

  • Using case when statement in the select query to create physical table

    Hello,
    I have a requirement where in I have to execute a case when statement with a session variable while creating a physical table using a select query. let me explain with an example.
    I have a physical table based on a select table with one column.
    SELECT 'VALUEOF(NQ_SESSION.NAME_PARAMETER)' AS NAME_PARAMETER FROM DUAL. Let me call this table as the NAME_PARAMETER table.
    I also have a customer table.
    In my dashboard that has two pages, Page 1 contains a table with the customer table with column navigation to my second dashboard page.
    In my second dashboard page I created a dashboard report based on NAME_PARAMETER table and a prompt based on customer table that sets the NAME_ PARAMETER request variable.
    EXECUTION
    When i click on a particular customer, the prompt sets the variable NAME_PARAMETER and the NAME_PARAMETER table shows the appropriate customer.
    everything works as expected. YE!!
    Now i created another table called NAME_PARAMETER1 with a little modification to the earlier table. the query is as follows.
    SELECT CASE WHEN 'VALUEOF(NQ_SESSION.NAME_PARAMETER)'='Customer 1' THEN 'TEST_MART1' ELSE TEST_MART2' END AS NAME_PARAMETER
    FROM DUAL
    Now I pull in this table into the second dashboard page along with the NAME_PARAMETER table report.
    surprisingly, NAME_PARAMETER table report executes as is, but the other report based on the NAME_PARAMETER1 table fails with the following error.
    Error Codes: OPR4ONWY:U9IM8TAC:OI2DL65P
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 16001] ODBC error state: S1000 code: 1756 message: [Oracle][ODBC][Ora]ORA-01756: quoted string not properly terminated. [nQSError: 16014] SQL statement preparation failed. (HY000)
    SQL Issued: SET VARIABLE NAME_PARAMETER='Novartis';SELECT NAME_PARAMETER.NAME_PARAMETER saw_0 FROM POC_ONE_DOT_TWO ORDER BY saw_0
    If anyone has any explanation to this error and how we can achieve the same, please help.
    Thanks.

    Hello,
    Updates :) sorry.. the error was a stupid one.. I resolved and I got stuck at my next step.
    I am creating a physical table using a select query. But I am trying to obtain the name of the table dynamically.
    Here is what I am trying to do. the select query of the physical table is as follows.
    SELECT CUSTOMER_ID AS CUSTOMER_ID, CUSTOMER_NAME AS CUSTOMER_NAME FROM 'VALUEOF(NQ_SESSION.SCHEMA_NAME)'.CUSTOMER.
    The idea behind this is to obtain the data from the same table from different schemas dynamically based on what a session variable. Please let me know if there is a way to achieve this, if not please let me know if this can be achieved in any other method in OBIEE.
    Thanks.

Maybe you are looking for

  • SQL REPORTING SERVICES 2008 R2

    I HAVE THIS QUERY: SELECT     DIMENSIONS.DESCRIPTION, HOS_SALEHST.CUSTOMERCLASS, MONTH (HOS_SALEHST.INVOICEDATE) as MONTH, YEAR (HOS_SALEHST.INVOICEDATE) as YEAR, HOS_SALEHST.ITEMCLASS, SUM(HOS_SALEHST.QUANTITY) AS QUANTITY, SUM(HOS_SALEHST.NETSALESA

  • How to send string data through socket!

    Is there any method to send string data over socket. and if client send string data to server, How to get that data in server? Comments please!

  • "Invalid Serial Number" alert when registering Time Capsule

    Hi, Today I tried to register a few Apple products through my Express Lane account. I succeeded in registering an iMac, an iPhone 4 and a MacBook, but when I tried to register my Time Capsule I get the following error: "We're sorry, but that is not a

  • Can I plug my Ethernet laser to the AE?

    I have a Lexmark 332N on my network and would like to move it and make it wireless. Can I plug it to the Ethernet port of the Airport Express and then plug my Epson R800 inkjet to the USB port? I already have an Airport Etreme. thanks Andre PowerBook

  • Sorry Ignore it... duplicate question

    Hi In BI, one of my field was off of the data type in flat file, so got error while loading flat file to PSA, so whole file failed to load. Do you have some idea how to cleansing the data for data type before loading to PSA or what do we do generally