Materialized view process running constantly /* MV_REFRESH (DEL) */

Hello,
3 days ago I created this Materialized view:
CREATE MATERIALIZED VIEW src_mv
nologging
compress
partition by range (dato)
partition src_mv_pre2005 values less than (to_date('2005-01-01','yyyy-mm-dd'))
, partition src_mv_2005 values less than (to_date('2006-01-01','yyyy-mm-dd'))
, partition src_mv_2006 values less than (to_date('2007-01-01','yyyy-mm-dd'))
, partition src_mv_2007 values less than (to_date('2008-01-01','yyyy-mm-dd'))
, partition src_mv_2008 values less than (to_date('2009-01-01','yyyy-mm-dd'))
, partition src_mv_2009 values less than (to_date('2010-01-01','yyyy-mm-dd'))
, partition src_mv_2010 values less than (to_date('2011-01-01','yyyy-mm-dd'))
, partition src_mv_2011 values less than (to_date('2012-01-01','yyyy-mm-dd'))
, partition src_mv_2012 values less than (to_date('2013-01-01','yyyy-mm-dd'))
, partition src_mv_2013 values less than (to_date('2014-01-01','yyyy-mm-dd'))
REFRESH on demand
start with sysdate next trunc(sysdate)+1+3.75/24
with primary key
ENABLE QUERY REWRITE
AS
SELECT srcid
, a
, dato
, group
, COUNT(*) tx
, SUM(amount) sumtx
FROM b btx
JOIN groups g USING(gid)
join c on (srcid=cid and ctype='W')
GROUP BY srcid
, a
, dato
, group;
Table b has more than 330 millions rows and table c has about 3 millions rows. However the creation of the MV itself tok about an hour.
After the MV was created I tried to create an index on dato but I got:
ORA-00054: resource busy and acquire with NOWAIT specified
When I checked the active sessions, I see this:
/* MV_REFRESH (DEL) */ delete from "X"." SRC_MV"
So, now I am not able to create any index, drop the MV or even kill the session that is running the /* MV_REFRESH (DEL) */.
Why is this DELETE statement running, when I said REFRESH on demand? Is this running since the MV was created?
On the other hand, the database is shutdown/startup everyday at 8pm/10pm, and there has not been any problem with this shutdown/startup, so I can't understand why this Delete statement is still running.
The MV has now a compilation error status, why is not possible to drop it then?
Can anybody help me?
Thanks in advance,
Alida

When I try to kill the session I get this:
Error starting at line 1 in command:
alter system kill session '261,1408'
Error report:
SQL Error: ORA-00031: session marked for kill
00031. 00000 - "session marked for kill"
*Cause:    The session specified in an ALTER SYSTEM KILL SESSION command
cannot be killed immediately (because it is rolling back or blocked
on a network operation), but it has been marked for kill. This
means it will be killed as soon as possible after its current
uninterruptable operation is done.
*Action:   No action is required for the session to be killed, but further
executions of the ALTER SYSTEM KILL SESSION command on this session
may cause the session to be killed sooner.
Every time I run the command to kill the session and apears again the next day :\
Thanks,
Alida

Similar Messages

  • Materialized View to run only once in a year...

    Hi everybody...
    I want to create a materialized view which will run only once in a year and specifically some minutes after 00:00 a.m. on new year's day,
    so i created the following:
    CREATE MATERIALIZED VIEW <mv_name>
    BUILD IMMEDIATE
    REFRESH START WITH TO_DATE('01/01/2007 00:15:00','DD/MM/RRRR HH24:MI:SS')
    NEXT SYSDATE+366
    I have two notes:
    1) how to declare the refresh to be done the first new year's day after the day it'll be created , i mean not static date (01/01/2007)
    2)some years are leap and some are not , so in order to run every new year's day how should i transform the above..????
    3)is there any view which displays the next run of a materialized view..???
    the view DBA_MV_REFRESH_TIMES displays the last refresh of mv's...
    I use Oracle 10.2.0.1 on XP ...
    Thanks , a lot
    Simon

    1).
    use the expression that evaluates to next january first.
    SQL> select sysdate, add_months(trunc(sysdate, 'yyyy'), 12) from dual ;
    SYSDATE     ADD_MONTHS(
    19-JUN-2006 01-JAN-2007
    1 row selected.
    SQL>2). for this also use the same expression that will evaluate to the january first of the year after that.

  • After 10.6.3 upgrade: "translate" process running constantly

    Just upgraded to 10.6.3 Since the upgrade a process called "translate" is running in in Activity monitor constantly. It's taking a pretty constant 99% CPU (out of 400% total on my 4-core).
    I don't remember seeing that process before and it surely should not be sitting there eating up CPU.
    As I write, it's been doing this for 8 or 9 hours.
    Regards,
    Peter G.

    Have had the same problem with the translate process. My system got so bogged down and screwed up while I tried to correct this (with several calls to Apple Support) that I did a full system restore via Time Machine to 3/20/2010. The restore took 12.5 hrs due in large part to 10K+ photos on my hard drive, but after the restore, everything worked fine (no translate process running) until I got the auto-upgrade notice and upgraded to Snow Leopard 10.6.3 (plus several other Apple apps)--again the translate process now runs at 99-100%. The only solution I can see until Apple fixes this is quit the process using the Activity Monitor via the CPU Usage screen. The positive point in all of this is that Time Machine works as advertised. I had tried to reinstall the OS from the installation disk, but the installation failed x3.

  • How to find out which materialized views are running on the DB?

    So I have a long list of MVs stored on the DB.
    Is there a script to find out which MVs are being refreshed right now?
    Help!
    Thanks

    Hi ,
    You can use the following data dictionary view to get information on when Mview was last refreshed--
    SQL> desc DBA_MVIEWS
    Name                                                  Null?    Type
    OWNER                                                 NOT NULL VARCHAR2(30)
    MVIEW_NAME                                            NOT NULL VARCHAR2(30)
    CONTAINER_NAME                                        NOT NULL VARCHAR2(30)
    QUERY                                                          LONG
    QUERY_LEN                                                      NUMBER(38)
    UPDATABLE                                                      VARCHAR2(1)
    UPDATE_LOG                                                     VARCHAR2(30)
    MASTER_ROLLBACK_SEG                                            VARCHAR2(30)
    MASTER_LINK                                                    VARCHAR2(128)
    REWRITE_ENABLED                                                VARCHAR2(1)
    REWRITE_CAPABILITY                                             VARCHAR2(9)
    REFRESH_MODE                                                   VARCHAR2(6)
    REFRESH_METHOD                                                 VARCHAR2(8)
    BUILD_MODE                                                     VARCHAR2(9)
    FAST_REFRESHABLE                                               VARCHAR2(18)
    LAST_REFRESH_TYPE                                              VARCHAR2(8)
    LAST_REFRESH_DATE                                              DATE
    STALENESS                                                      VARCHAR2(19)
    AFTER_FAST_REFRESH                                             VARCHAR2(19)
    UNKNOWN_PREBUILT                                               VARCHAR2(1)
    UNKNOWN_PLSQL_FUNC                                             VARCHAR2(1)
    UNKNOWN_EXTERNAL_TABLE                                         VARCHAR2(1)
    UNKNOWN_CONSIDER_FRESH                                         VARCHAR2(1)
    UNKNOWN_IMPORT                                                 VARCHAR2(1)
    UNKNOWN_TRUSTED_FD                                             VARCHAR2(1)
    COMPILE_STATE                                                  VARCHAR2(19)
    USE_NO_INDEX                                                   VARCHAR2(1)
    STALE_SINCE                                                    DATE
    SQL>

  • ORA-23401: materialized view ""SYS"".""MV_OPTIONS"" does not exist

    Oracle 11gR1
    Linux Red Hat 6.3
    I have never seem this object SYS.MV_OPTIONS before much less know why it would be missing. Any ideas?
    I can no longer refresh my materialized views.

    Process worked fine until the addition on new MVs.
    What causes error?
    Running SP that calls DBMS_MVIEW.refresh. Here is the error in more detail...
    "ORA-23401: materialized view ""SYS"".""MV_OPTIONS"" does not exist
    ORA-06512: at ""SYS.DBMS_SNAPSHOT"", line 2545
    ORA-06512: at ""SYS.DBMS_SNAPSHOT"", line 2751
    ORA-06512: at ""SYS.DBMS_SNAPSHOT"", line 2720
    What has been changed?
    Added new materialized views to my instance that need periodic refreshing.
    Note: Running the block below works fine ....
    begin
    DBMS_MVIEW.refresh('MV_MINE');
    end;
    I suspect something in the process that calls this function is the issue (of course). But I still wonder what the object SYS.MV_OPTIONS is/does?

  • Recieving ORA-01722 invalid number error while creating a materialized view

    Hi,
    I am receiving a ORA-01722 invalid number error while creating a materialized view. when run the select statement of the view i don't get any error, but when i use the same select statement to create a materialized view i receive this error. Could any please help in resolving this error. Here is the code i am using to create a materialized view.
    CREATE MATERIALIZED VIEW MV_EBS_CH_CLOSED
    REFRESH FORCE ON DEMAND
    AS
    SELECT DISTINCT kr.request_id, org.org_unit_name,
    ebs_ch_ticket_type (kr.request_id) ticket_type,
    DECODE
    (kr.status_code,
    'CLOSED_SUCCESS', kr.last_update_date,
    'IN_PROGRESS', (SELECT MAX (start_time)
    FROM ebs_ch_datastore ecd1
    WHERE kr.request_id = ecd1.request_id
    AND workflow_step_name =
    'Final BA Review and Deployment Exit Criteria')
    ) closed_date,
    substr(krhd.visible_parameter12,1,10) siebel_start_date,
    kr.creation_date itg_start_date
    FROM kcrt_requests kr,
    kcrt_request_types krt,
    kcrt_req_header_details krhd, kcrt_request_details krd1,
    (SELECT koum.user_id user_id,
    DECODE (koup.org_unit_name,
    'IT Implementations', 'CHS - Service Management BA',
    koup.org_unit_name
    ) org_unit_name
    FROM krsc_org_unit_members koum, krsc_org_units koup
    WHERE 1 = 1
    AND 'Y' = koup.enabled_flag
    AND koum.org_unit_id = koup.org_unit_id
    AND EXISTS (
    SELECT 'X'
    FROM krsc_org_units kouc
    WHERE koup.org_unit_id = kouc.org_unit_id
    START WITH kouc.parent_org_unit_id =
    ANY (SELECT org_unit_id
    FROM krsc_org_units krsc_org_units1
    WHERE 'Clearinghouse' =
    org_unit_name)
    CONNECT BY kouc.parent_org_unit_id =
    PRIOR kouc.org_unit_id)
    UNION
    SELECT kou.manager_id user_id,
    DECODE
    (kou.org_unit_name,
    'IT Implementations', 'CHS - Service Management BA',
    kou.org_unit_name
    ) org_unit_name
    FROM krsc_org_units kou
    WHERE 'Y' = kou.enabled_flag
    START WITH kou.parent_org_unit_id =
    (SELECT org_unit_id
    FROM krsc_org_units krsc_org_units2
    WHERE 'Clearinghouse' = org_unit_name)
    CONNECT BY kou.parent_org_unit_id = PRIOR kou.org_unit_id) org
    WHERE krt.request_type_id = kr.request_type_id
    AND krt.request_type_name IN ('Bug Fix', 'IT Enhancement')
    and kr.REQUEST_ID = krd1.request_id
    and krd1.batch_number = 1
    AND kr.request_id = krhd.request_id
    AND org.user_id in (krd1.parameter4, krd1.parameter5, krd1.parameter7)
    AND ( 'CLOSED_SUCCESS' = kr.status_code
    OR 'IN_PROGRESS' = kr.status_code
    AND kr.request_id IN (
    SELECT request_id
    FROM (SELECT DISTINCT request_id,
    MAX
    (start_time)
    closed_date
    FROM ebs_ch_datastore
    WHERE 'Final BA Review and Deployment Exit Criteria' =
    workflow_step_name
    GROUP BY request_id))
    Thanks,
    Shaik Mohiuddin

    This error occurs when you try to create a materialized view , but if you run the sql the results are perfectly fine. Well it happend to me also and to fix this I made sure all the coulmns have the same data type which are used in joins or in where clause.
    use
    where
    to_number(col1)=to_number(col2) and to_number(col3)=to_number(col4)
    hope this helps..

  • Updatable materialized view- error with CREATE_SNAPSHOT_REPGROUP

    I'm trying to create an updatable materialized view from the replication administrators account (REPADMIN). I use the assistant and in the third step (after creating the replication group and the materialized view), when the materialized view is going to be added to the group, I got this error:
    ERROR in line 1:
    ORA-01403: No data found
    ORA-06512: in "SYS.DBMS_REPCAT_SNA_UTL", line 5927
    ORA-06512: in "SYS.DBMS_REPCAT_SNA", line 82
    ORA-06512: in "SYS.DBMS_REPCAT", line 1332
    ORA-06512: in "SYS.DBMS_REPCAT", line 1307
    ORA-06512: in line 2
    I have also tried to use the command file that the assistant generates (I add below), and the error is triggered within the CREATE_SNAPSHOT_REPOBJECT procedure.
    Has anybody any idea to resolve the problem?
    Thanks in advance
    BEGIN
    DBMS_REPCAT.CREATE_SNAPSHOT_REPGROUP(
    gname => '"MYGROUP"',
    master => 'DB.DOMAIN.COM',
    propagation_mode => 'ASYNCHRONOUS');
    END;
    CREATE SNAPSHOT "MYUSER"."MYTABLE"
    REFRESH COMPLETE WITH ROWID
    FOR UPDATE
    AS SELECT "COD", "NAME" FROM
    "MYUSER"."MYTABLE"@DB.DOMAIN.COM c
    BEGIN
    DBMS_REFRESH.ADD(
    name => '"MYUSER"."REF3"',
    list => '"MYUSER"."MYTABLE"',
    lax => TRUE);
    END;
    BEGIN
    DBMS_REPCAT.CREATE_SNAPSHOT_REPOBJECT(
    gname => '"MYGROUP"',
    sname => '"MYUSER"',
    oname => '"MYTABLE"',
    type => 'SNAPSHOT',
    min_communication => FALSE);
    END;

    Hello,
    These days I have had some problems with my forum-account and I haven't been able to connect and reply.
    Regarding to your doubt, the name of refresh group was correct, and as I see, the problem can't be related to the refresh group.
    While the problem with my account was resolved, I created two new databases (*) and the problem within the materialized view process is disappeared. I suppose that my first original databases were degraded, but I don't know where.
    (*) of course, I could do that because I use Oracle in an academy institution, not for production, thank God
    Anyway, for now I will give up here. Thanks for your help.
    Regards,

  • Materialized view job

    hI,
    i need to create a job for materialized views to run them midnight,
    Could you help me advise pls
    CREATE MATERIALIZED VIEW MV_EMP
    BUILD IMMEDIATE
    USING INDEX
    REFRESH FORCE ON DEMAND START WITH sysdate+0 NEXT SYSDATE + 10/1440
    AS SELECT * FROM EMP;
    Thanks

    You can add the group of materialised together into a refresh group and then create a single job to refresh this refresh group.
    One approach could be to have a refresh group per schema and a single refresh job for that group per schema. You can also create your own PL/SQL logic to determine what to refresh and then schedule that code as a job.
    Lots of flexibility - you need to decide on which technique to use to meet your specific requirements.

  • Materialized view being ignored

    Hi all
    Running Oracle 10.2.0.3 on Solaris 9.
    I'm not sure how much info to provide at this stage but i'm having a problem with a materialized view.
    The database contains tens of thousands of digitized books and an application to help manage all the data. Now, if I refresh the materialized view and run a full browse of all publications I get a response back in about 15 seconds. But then, within minutes this drops to a number of minutes. Again, as soon as I fresh the mat view it speeds up again.
    Now, I know I have provided very little information here but I guess I'm wondering if the problem is something fundamental that other people may have come across/overcome.
    If anyone can help shed light on this I would be very grateful.
    Please let me know any other information that you require.
    Many thanks
    Farren Minns

    user4662649 wrote:
    Running Oracle 10.2.0.3 on Solaris 9.
    The database contains tens of thousands of digitized books and an application to help manage all the data. Now, if I refresh the materialized view and run a full browse of all publications I get a response back in about 15 seconds. But then, within minutes this drops to a number of minutes. Again, as soon as I fresh the mat view it speeds up again.Farren,
    one possible explanation is that by refreshing the materialized view you cache the data in your database and/or file system/SAN cache, so that immediately after the refresh only few physical I/Os are required. Once other activities have been performed that also use a significant part of your available cache, more physical I/O is required, so the overall response time increases. Without further details however this is just a speculation.
    If you run your statement e.g. with AUTOTRACE enabled in SQL*Plus you could try if you can see a difference in the number of physical reads performed between a quick and slow execution. However this doesn't cover any caching performed outside the database buffers (e.g. file system cache), so tells you only half the truth.
    If you trace your statement using extended SQL trace (including wait events) you could get more details, e.g. you could tell from the average wait times for the I/O requests whether they were served from an underlying cache or more likely real physical I/O.
    Does your data contain LOB objects if you say "digitized" books, do you use one of Oracle's extensions to maintain that information (Oracle Text, Multimedia etc.)?
    Regards,
    Randolf
    Oracle related stuff blog:
    http://oracle-randolf.blogspot.com/
    SQLTools++ for Oracle (Open source Oracle GUI for Windows):
    http://www.sqltools-plusplus.org:7676/
    http://sourceforge.net/projects/sqlt-pp/

  • Materialized View Refresh; Process Flow

    I was wondering if anyone has used process flow to refresh materialized view;
    I am trying to use a process flow for this i.e. run something similiar to below
    EXECUTE dbms_refresh.refresh('"ODW_SRC"."MV_SERVICE_DAILY_AUDIT"');
    I am trying to avoid using DB scheduler because I want to make sure process flow doesn't clash with update of materialized view causing possible conflict of longer than expected job run time goes into refresh window.
    I am assuming I could use a transformation and build it out; but I was wondering if there is an easier way in just executing this one line ... any idea's
    Thank you in advance for your help

    Sorry, I think the OWB term is post mapping process, its actually an operator in an OWB mapping where you can add a procedure call for example. The procedure can do pretty much what it wants.
    Cheers
    David

  • In FCP x backup process is constantly running in background even though its done which results into slow working of FCP x. any idea to resolve the issue. I am using 10.1.3 and facing the problem ever since i have updated my FCP x to 10.1.3

    in FCP x backup process is constantly running in background even though its done which results into slow working of FCP x. any idea to resolve the issue? I am using 10.1.3 and facing the problem ever since i have updated my FCP x to 10.1.3

    Go into preferences and under playback turn off background render. That helped speed things for me when working with large files.

  • Refreshing Materialized view from APEX process is causing errors

    Hi,
    I have created a materialized view, and am attempting to create a process in APEX to refresh the mview on a button click.
    I have been reading the documentation on Materialized Views and think I am more confused now than when I started.
    Do I need to add my mview to a refresh group to enable me to use the DBMS_REFRESH.REFRESH command from an APEX process?
    I have had a few attempts at getting it working, but to no avail yet.
    Any help would be appreciated.
    Cheers, Greg

    Snowman wrote:
    Hi,
    I have created a materialized view, and am attempting to create a process in APEX to refresh the mview on a button click.
    I have been reading the documentation on Materialized Views and think I am more confused now than when I started.
    Do I need to add my mview to a refresh group to enable me to use the DBMS_REFRESH.REFRESH command from an APEX process?What error are you getting?

  • Process "bird" taking up to 140% of CPU and running constantly

    Mac OS X 10.10.1 Yosemite/iMac mid-2011
    My iMac is really slow to start-up, to run, and to have applications run. I have 32 GB memory, 113 GB hard disk capacity and it has never been slower in its life. There is a process called "bird" that is running almost constantly whenever I run Activity Monitor and it is taking up to 140% of CPU time. What is "bird"? Why is it running constantly and eating up so much CPU time? Why is my iMac so slow running Mac OS X 10.10.1 Yosemite?
    Other issues on my iMac include: Software Update is supposed to be updating and installing updates automatically and it is not. When I log in, I see a blank white screen with an apple logo and a progress bar below. It takes forever for the progress bar to get 1/4 of the way across, then the screen flashes and the progress bar finishes the remaining 3/4 really fast. And then once logged in, it takes forever for my dock icons to appear, and my iMac hard drive is chattering like crazy even though nothing is running yet. Whenever I launch Safari I get a progress bar in the address field that goes 1/3 of the way across and frequently hangs. And then just nothing. All of these issues never happened before Mac OS X 10.10.1 Yosemite. Is anyone else experiencing issues like this? How did you solve them?

    Once it’s enabled iCloud Drive starts working automatically, syncing data between your devices in the background (slowing your iMac down). Unlike the first version of iCloud, iCloud Drive can be be accessed in the Finder like other folders. You can store any type of file in iCloud Drive provided it is less than 15 gigabytes in size. When it’s enabled, it will show up in the side column of a Finder window. iCloud Drive is not as advanced and widely accessible and supported as Dropbox, but it’s  useful if you work and share documents between your iOS and Mac devices. The service should improve further.

  • Materialized View to be run every 1 minute through dbms_scheduler

    Hi,
    I have a materialized view on 1 database which has its select statement going across a database link to numerous tables on another database.
    The materialized view creates fine and when refreshed using dbms_snapshot refreshes without error.
    My requirement is to automate this refresh for every minute. I have created a job through dbms_scheduler for the refresh to happen every minute but it fails with the error message
    ORA-12008: error in materialized view refresh path
    I have ctreated another materialized view on the database which does not go across a dblink and scheduled this though dbms_scheduler for every minute, this works fine.........
    So it appears my issue is the selecting from tables across a dblink.
    Does any one have any experience of this area, how to resolve this issue or maybe an alternative solution than dbms_scheduler?
    Thanks in advance.
    Mark.

    How is your database link defined?
    Is it using a fixed user? i.e create database link .... identified by xxxxx
    I think it needs to be to be used in a scheduled job.
    Carl

  • The data of my materialized view....in the while

    Hello
    We have problems with materialized views
    We have one wich re-build each a short period of time
    ¿Can i avoid the data to dissapear in the time process of refresh?
    Is so annoing to our clients to see that "from time to time" the data just dissapear for one period of time -the time while the materialized view is refreshing-
    Thank you in advance
    Bruno. Madrid. Spain

    > Is so annoing to our clients to see that "from time to time" the data just dissapear for
    one period of time -the time while the materialized view is refreshing-
    Have a similar problem. And dealing with large data volumes that makes the DELETE of the MV a very undesirable feature. Not as much a the resource footprint required, but the time it takes to do this - and the very tight processing windows that exist.
    The solution is a self-rolled and very likely not ideal for most - but it works well enough for us in production.
    No MV. Create a partition table. Create a staging table. Do a manual "full refresh" of the staging table (TRUNCATE and direct path INSERT). Follow this by a partition exchange with the partition table (no validation and including indexes). The result is that the data is replaced in the partitioned table within a second - no long running and expensive DELETE. End-users not effected by having a truncate pulling the data from beneath their reports.

Maybe you are looking for

  • Object reference not set to an instance of an object error with Import data

    Hi Experts, We are using BPC 7.5M with SQL Server 2008 in Multiserver environment, I am getting an error "Object reference not set to an instance of an object." while running Import data package, earlier we use to get this error sometime(once in a mo

  • Need help with publishing as animated .gif

    I'm having trouble publishing my project as an animated .gif.  My project, which consists of two different animated movie clips, plays just fine when test it (Shift + Enter).  But, when I go to publish it, the animations don't show up.  The settings

  • "Normal" Mac OS on an XServe

    I have recently obtained a DP 2.3GHz G5 XServe. Before it gets used as a server (if ever), I wish to generally play around with it, try things out, etc., while learning. As part of this whole process, I would like to try running it as a normal comput

  • Correlation set based on correlation from raised ADF event payload

    Hi, In a BPEL process, how can we include a Correlation set based on correlation from raised ADF event payload ? Thanks

  • Keyboard and time

    After reinstalling Arch, with Xorg7, etc, I can't change the keyboard layout and the time... (I'm using Xfce4) these are the steps I've tried... - pacman -S xf86-input-keyboard - nano /root/xorg.conf.new    ...   adding-  Option   "XkbLayout"  "uk" -