Weird select could cause blocked other session

Dear Gurus,
Could you give me some explanation why select query could blocked other update sessions, please find below
SID_BLOCKER BLOCKER WAITER
Session ID: 22339    in instance 1 is blocking   Session ID: 296 in instance 1
Session ID: 22339    in instance 1 is blocking   Session ID: 6673 in instance 1
Session ID: 22339    in instance 1 is blocking   Session ID: 26091 in instance 1
Elapsed: 00:00:01.77
12:21:45 SQL> @ssid
Elapsed: 00:00:00.00
enter value for sid: 22339
enter value for instance id: 1
   SID  SERIAL# SERVER_PID CLIENT_PID USERNAME    OSUSER     STATUS LOGON_TIME PROGRAM MACHINE          SYSDATE
EVENT WAIT_CLASS WAIT_TIME SECONDS_IN_WAIT STATE SQL_ID
22339    40705 18135 26767 XLAPPC      cmwl21     INACTIVE 15-SEP-2013 23:25:35 java@cbtcm cbtcmpap02 18-SEP-2013 12:21:53
pap02 (TNS
V1-V3)
SQL*Net message from client Idle 0            6649 WAITING
Elapsed: 00:00:00.08
     PIECE SQL_TEXT
         0 SELECT ch_objects.obj_id, ch_objects.obj_type, ch_objects.obj_ex
         1 ternal_id, ch_objects.obj_name, ch_objects.obj_desc, ch_arcs.arc
         2 _relation, TO_CHAR (ch_arcs.arc_valid_from, 'YYYYMMDDHH24MISS'),
3  TO_CHAR (ch_arcs.arc_valid_to, 'YYYYMMDDHH24MISS'), TO_CHAR (ch
         4 _objects.sys_update_date, 'YYYYMMDDHH24MISS') FROM ch_objects, c
         5 h_arcs WHERE ch_arcs.arc_child_id = :m_startObjID AND ch_arcs.ar
         6 c_relation IN (:relTypes0:relTypesInd0,:relTypes1:relTypesInd1,:
         7 relTypes2:relTypesInd2,:relTypes3:relTypesInd3,:relTypes4:relTyp
         8 esInd4,:relTypes5:relTypesInd5) AND ch_arcs.arc_father_id = ch_o
         9 bjects.obj_id AND TO_DATE (:m_effectiveTime, 'YYYYMMDDHH24MISS')
        10 BETWEEN ch_arcs.arc_valid_from AND ch_arcs.arc_valid_to
Elapsed: 00:00:00.71
12:21:54 SQL> @ssid
Elapsed: 00:00:00.00
enter value for sid: 6673
enter value for instance id: 1
   SID  SERIAL# SERVER_PID CLIENT_PID USERNAME    OSUSER     STATUS LOGON_TIME PROGRAM MACHINE          SYSDATE
EVENT WAIT_CLASS WAIT_TIME SECONDS_IN_WAIT STATE SQL_ID
  6673    51927 15196 19846 XLAPPC      cmwl61 ACTIVE   16-SEP-2013 18:25:53 java@cbtaa cbtaampap01      18-SEP-2013 12:22:08
mpap01 (TN
S V1-V3)
enq: TX - row lock contention Application 0            2681 WAITING a30z7fqk9sd1u
Elapsed: 00:00:00.03
     PIECE SQL_TEXT
         0 update ch_objects  set obj_name=:b0,sys_update_date=TO_DATE(:b1,
         1 'YYYYMMDDHH24MISS'),operator_id=:b2:b3,application_id=:b4:b5,dl_
         2 service_code='30' where obj_id=:b6
Elapsed: 00:00:00.69
12:22:09 SQL> @ssid
Elapsed: 00:00:00.00
enter value for sid: 6673
enter value for instance id: 1
   SID  SERIAL# SERVER_PID CLIENT_PID USERNAME    OSUSER     STATUS LOGON_TIME PROGRAM MACHINE          SYSDATE
EVENT WAIT_CLASS WAIT_TIME SECONDS_IN_WAIT STATE SQL_ID
  6673    51927 15196 19846 XLAPPC      cmwl61 ACTIVE   16-SEP-2013 18:25:53 java@cbtaa cbtaampap01      18-SEP-2013 12:22:21
mpap01 (TN
S V1-V3)
enq: TX - row lock contention Application 0            2695 WAITING a30z7fqk9sd1u
Elapsed: 00:00:00.03
     PIECE SQL_TEXT
         0 update ch_objects  set obj_name=:b0,sys_update_date=TO_DATE(:b1,
         1 'YYYYMMDDHH24MISS'),operator_id=:b2:b3,application_id=:b4:b5,dl_
         2 service_code='30' where obj_id=:b6
Elapsed: 00:00:00.63
12:22:22 SQL> @ssid
Elapsed: 00:00:00.00
enter value for sid: 26091
enter value for instance id: 1
   SID  SERIAL# SERVER_PID CLIENT_PID USERNAME    OSUSER     STATUS LOGON_TIME PROGRAM MACHINE          SYSDATE
EVENT WAIT_CLASS WAIT_TIME SECONDS_IN_WAIT STATE SQL_ID
26091    15759 57714 32378 XLAPPC cmwl11     ACTIVE   17-SEP-2013 14:08:58 java@cbtcm cbtcmpap01       18-SEP-2013 12:22:45
pap01 (TNS
V1-V3)
enq: TX - row lock contention Application 0            2051 WAITING a30z7fqk9sd1u
Elapsed: 00:00:00.04
    PIECE SQL_TEXT
         0 update ch_objects  set obj_name=:b0,sys_update_date=TO_DATE(:b1,
         1 'YYYYMMDDHH24MISS'),operator_id=:b2:b3,application_id=:b4:b5,dl_
         2 service_code='30' where obj_id=:b6
Elapsed: 00:00:03.89
Regards,

Session 22339 is only currently running a SELECT.  However, it might have, in the past, run an UPDATE or DELETE statement (against the rows that the other sessions want to update) without yet issuing a COMMIT (or ROLLBACK).  So the previous DML by this session makes it the "blocker" session.
Hemant K Chitale

Similar Messages

  • CKPT locks the system objects and blocks other sessions

    CKPT locks the system objects and blocks other sessions
    Oracle Version 10.2.0.4
    OS : HP UX 11.31 Itanium
    SQL> select * from v$lock where block=1;
    ADDR KADDR SID TY ID1 ID2 LMODE
    REQUEST CTIME BLOCK
    C0000009FCC2B348 C0000009FCC2B368 1100 RO 65559 1 2
    0 3877 1
    SQL> select program from v$session where sid=1100;
    PROGRAM
    oracle@ctqanhr1 (CKPT)
    As a workaround we flush the buffer cache with the below command
    SQL> alter system flush buffer_cache;
    however the issue reoccurs after some times.
    Edited by: 965132 on Dec 2, 2012 9:59 PM

    other reference:
    CKPT Questions
    The temporary workaround is to set "_db_fast_obj_truncate"=FALSE in that particular case.
    Regards,
    sgc
    Edited by: Samuel G. Cristobal on 03-dic-2012 8:48

  • LGWR blocking other session

    I encountered a new alert from datatbase, i got a SID that is blocking other sessions in the database. And the blocking session was nothing but LGWR process, and this seems to occured thrice in a day. please anyone help me to avoid this error.
    My database info
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bi
    PL/SQL Release 10.2.0.1.0 - Production
    CORE 10.2.0.1.0 Production
    TNS for Solaris: Version 10.2.0.1.0 - Production
    NLSRTL Version 10.2.0.1.0 - Production
    Jafar
    Thanks

    I suspect that the LGWR not able to keep pace with the commits. there might be case that your proceure making a huge inserts and while doing this it might commiting on every row inserts. In order to crosscheck for the same, you can check out the statspack report for logfile sync and logfile parellal write. You can also check with your alert.log for "can not allocate new log " massage. In order to rectify the problem, you can work with your developer to give a though on the issue I discussed above. you can also consider the below points to contributing factor.
    1. putting redologs on slow device
    2. putting redo on the same device as other files, you frequently access them.
    3. mounting the log devices in the buffered manner.
    4. putting redo on slow technology such as raid 5. (one must know that raid 5 is terrible with writes)
    hare krishna
    Alok

  • HT2509 Despite what this article states, Apple support told me not to try to remove any fonts as it could cause other possibly serious problems.  Is there a program which can be safely installed which will keep at the top of the font list those fonts whic

    An article in the New York Times yesterday told how to remove unwanted fonts from the Font Book.  I followed its instructions (the same as those on the webpage "support.apple.com/kb/ht2509") and was NOT successful in removing fonts.  Despite what the newspaper article and the web page stated, my attempts to remove fonts were unsuccessful.  I use perhaps 15-20 of the hundreds and hundreds of fonts, and deleting those I don't use would make choosing a font a lot faster.  I called support and was told not to try to remove any fonts which I myself had not added to the list(I have not added any) as doing so could cause significant problems elsewhere.  The support tech suggested that there might be independent software programs which would keep at the top of the list those fonts I have used, which sure would speed up the process of selecting a font.  Anyone know of such a program, or how to safely alter the font list Thanks.

    I just spoke again to tech support and this time an answer was provided that works!  Choose the font you want to use, drag it to the left, and a new "unnamed" folder will appear.  Continue to drag into that folder fonts you want to use.  You can click onto that folder to change its name.  Then when using font book merely click on that folder to open it and select the font wanted.  This tech rep also confirmed that you should NOT try to delete individual fonts as they are part of the basic operating system; he did confirm that the apple web page in parentheses above says otherwise, and will refer that to higher ups to see about removing or modifying that page.

  • Session 1648 is blocking 2 other sessions

    Hi,
    We are getting this Warning from the EM very frequently.
    How can I know Which user process is blocking which session?
    We are using 10.2.0.1.0 db in linux environment.
    Can you please provide me the query or quide me to get which process is blocking by which process?
    Thanks a lot in advance.
    Thanks
    Pathan

    >
    Can you please provide me the query or quide me to get which process is blocking by which process?There are two ways to do it,
    1) In the EM, in the performance tab,there is a link called Blocking Sessions. This would show you in the tree like structure that which session is bloking others and which are the blocked sessions. You can killl the blocking one from here itself.
    2) The same interface is given in CLI from ORacle supplied script under $OH/rdbms/admin/utlockt.sql. This would show the same results but in the sql prompt.
    2a) There are three views that you can use to create your own script,
    DBA_Blockers, DBA_waiters and V$locked_object ( already mentioned by last poster) .
    HTH
    Aman....

  • I previously used Indesign CS4. I now have recently purchased Indesign CC. I have a Mac Yosemite 10.10.3. When I print, I cannot select my paper stock, other than what is in the print dialogue box, i.e. art paper. In Indesign CS4, I could choose fine art

    previously used Indesign CS4. I now have recently purchased Indesign CC. I have a Mac Yosemite 10.10.3. When I print, I cannot select my paper stock, other than what is in the print dialogue box, i.e. art paper. In Indesign CS4, I could choose fine art paper etc. Where can I find this option in this new version?

    With Snow Leopard, the Printing of PDFs has changed. Try using the highlighted option

  • Issue with "read by other session" and a parallel MERGE query

    Hi everyone,
    we have run into an issue with a batch process updating a large table (12 million rows / a few GB, so it's not that large). The process is quite simple - load the 'increment' from a file into a working table (INCREMENT_TABLE) and apply it to the main table using a MERGE. The increment is rather small (usually less than 10k rows), but the MERGE runs for hours (literally) although the execution plan seems quite reasonable (can post it tomorrow, if needed).
    The first thing we've checked is AWR report, and we've noticed this:
    Top 5 Timed Foreground Events
    Event     Waits     Time(s)     Avg wait (ms)     % DB time     Wait Class
    DB CPU           10,086           43.82     
    read by other session     3,968,673     9,179     2     39.88     User I/O
    db file scattered read     1,058,889     2,307     2     10.02     User I/O
    db file sequential read     408,499     600     1     2.61     User I/O
    direct path read     132,430     459     3     1.99     User I/OSo obviously most of the time was consumed by "read by other session" wait event. There were no other queries running at the server, so in this case "other session" actually means "parallel processes" used to execute the same query. The main table (the one that's updated by the batch process) has "PARALLEL DEGREE 4" so Oracle spawns 4 processes.
    I'm not sure how to fix this. I've read a lot of details about "read by other session" but I'm not sure it's the root cause - in the end, when two processes read the same block, it's quite natural that only one does the physical I/O while the other waits. What really seems suspicious is the number of waits - 4 million waits means 4 million blocks, 8kB each. That's about 32GB - the table has about 4GB, and there are less than 10k rows updated. So 32 GB is a bit overkill (OK, there are indexes etc. but still, that's 8x the size of the table).
    So I'm thinking that the buffer cache is too small - one process reads the data into cache, then it's removed and read again. And again ...
    One of the recommendations I've read was to increase the PCTFREE, to eliminate 'hot blocks' - but wouldn't that make the problem even worse (more blocks to read and keep in the cache)? Or am I completely wrong?
    The database is 11gR2, the buffer cache is about 4GB. The storage is a SAN (but I don't think this is the bottleneck - according to the iostat results it performs much better in case of other batch jobs).

    OK, so a bit more details - we've managed to significantly decrease the estimated cost and runtime. All we had to do was a small change in the SQL - instead of
    MERGE /*+ parallel(D DEFAULT)*/ INTO T_NOTUNIFIED_CLIENT D /*+ append */
      USING (SELECT
          FROM TMP_SODW_BB) S
      ON (D.NCLIENT_KEY = S.NCLIENT_KEY AND D.CURRENT_RECORD = 'Y' AND S.DIFF_FLAG IN ('U', 'D'))
      ...(which is the query listed above) we have done this
    MERGE /*+ parallel(D DEFAULT)*/ INTO T_NOTUNIFIED_CLIENT D /*+ append */
      USING (SELECT
          FROM TMP_SODW_BB AND DIFF_FLAG IN ('U', 'D')) S
      ON (D.NCLIENT_KEY = S.NCLIENT_KEY AND D.CURRENT_RECORD = 'Y')
      ...i.e. we have moved the condition from the MERGE ON clause to the SELECT. And suddenly, the execution plan is this
    OPERATION                           OBJECT_NAME             OPTIONS             COST
    MERGE STATEMENT                                                                 239
      MERGE                             T_NOTUNIFIED_CLIENT
        PX COORDINATOR
          PX SEND                       :TQ10000                QC (RANDOM)         239
            VIEW
              NESTED LOOPS                                      OUTER               239
                PX BLOCK                                        ITERATOR
                  TABLE ACCESS          TMP_SODW_BB             FULL                2
                    Filter Predicates
                      OR
                        DIFF_FLAG='D'
                        DIFF_FLAG='U'
                  TABLE ACCESS          T_NOTUNIFIED_CLIENT       BY INDEX ROWID    3
                    INDEX               AK_UQ_NOTUNIF_T_NOTUNI    RANGE SCAN        2
                      Access Predicates
                        AND
                          D.NCLIENT_KEY(+)=NCLIENT_KEY
                          D.CURRENT_RECORD(+)='Y'
                      Filter Predicates
                        D.CURRENT_RECORD(+)='Y' Yes, I know the queries are not exactly the same - but we can fix that. The point is that the TMP_SODW_BB table contains 1639 rows in total, and 284 of them match the moved 'IN' condition. Even if we remove the condition altogether (i.e. 1639 rows have to be merged), the execution plan does not change (the cost increases to about 1300, which is proportional to the number of rows).
    But with the original IN condition (that turns into an OR combination of predicates) in the MERGE ON clausule, the cost suddenly skyrockets to 990.000 and it's damn slow. It seems like a problem with cost estimation, because once we remove one of the values (so there's only one value in the IN clausule), it works fine again. So I guess it's a planner/estimator issue ...

  • Massive Query blocking other Processes

    Hi 
    We are having a Sharepoint 2010 server and we have deployed a dot net custom application on it. Recently the application was working slow and the same was observed on out of box created lists using the out of box UI. 
    We found that it was originating from a SQL query which was blocking other processes. 
    Now this problem, occurs intermittently and goes away on its own in some time(~10 minutes). The query responsible is : 
    SELECT TOP(@NUMROWS) t1.[Type] AS c0, UserData.[ntext2], UserData.[datetime1], UserData.[nvarchar10], t6.[nvarchar5] AS c14c15, UserData.[float2], UserData.[int8], UserData.[tp_ItemOrder], UserData.[nvarchar1], t15.[nvarchar6] AS c36c34, UserData.[ntext1], UserData.[int7], UserData.[float1], UserData.[nvarchar19], UserData.[tp_ID], UserData.[nvarchar5], t5.[nvarchar4] AS c12c13, UserData.[bit1], t11.[nvarchar3] AS c24c25, UserData.[int11], t14.[nvarchar6] AS c30c34, t15.[tp_ID] AS c36c32, UserData.[tp_GUID], t1.[ProgId] AS c42, t1.[SortBehavior] AS c1, UserData.[tp_Author], UserData.[tp_Editor], UserData.[int1], UserData.[int6], UserData.[nvarchar13], UserData.[ntext5], UserData.[datetime4], UserData.[nvarchar18], UserData.[tp_ContentTypeId], t8.[nvarchar3] AS c18c19, UserData.[int10], t15.[tp_Created] AS c36c35, UserData.[tp_WorkflowVersion], t1.[LeafName] AS c37, UserData.[tp_Version], t1.[Id] AS c4, UserData.[nvarchar4], UserData.[nvarchar9], t14.[tp_ID] AS c30c32, t1.[TimeLastModified] AS c40, UserData.[tp_IsCurrentVersion], UserData.[tp_HasCopyDestinations], UserData.[tp_Level], t4.[nvarchar3] AS c10c11, UserData.[int5], t10.[nvarchar3] AS c22c23, UserData.[nvarchar12], UserData.[ntext4], UserData.[datetime3], UserData.[nvarchar17], t2.[nvarchar3] AS c6c7, UserData.[nvarchar20], UserData.[datetime8], UserData.[tp_HasAttachment], UserData.[tp_Modified], CASE WHEN DATALENGTH(t1.DirName) = 0 THEN t1.LeafName WHEN DATALENGTH(t1.LeafName) = 0 THEN t1.DirName ELSE t1.DirName + N'/' + t1.LeafName END AS c2, UserData.[nvarchar3], UserData.[nvarchar8], t7.[nvarchar3] AS c16c17, t13.[Status1] AS c28c29, t14.[tp_Created] AS c30c35, t15.[nvarchar4] AS c36c33, UserData.[tp_UIVersion], t1.[ItemChildCount] AS c43, UserData.[tp_CopySource], UserData.[nvarchar11], UserData.[ntext3], UserData.[datetime2], UserData.[nvarchar16], UserData.[tp_InstanceID], t3.[nvarchar3] AS c8c9, UserData.[int4], t9.[nvarchar3] AS c20c21, UserData.[int9], UserData.[float3], UserData.[datetime7], UserData.[tp_UIVersionString], t1.[TimeCreated] AS c38, t1.[ScopeId] AS c5, UserData.[nvarchar2], UserData.[nvarchar7], t14.[nvarchar4] AS c30c33, t15.[nvarchar1] AS c36c31, t1.[ClientId] AS c41, UserData.[int3], t12.[nvarchar3] AS c26c27, UserData.[datetime6], UserData.[tp_Created], UserData.[tp_ModerationStatus], UserData.[nvarchar6], UserData.[tp_WorkflowInstanceID], t1.[FolderChildCount] AS c44, t1.[MetaInfo] AS c3, UserData.[nvarchar14], t14.[nvarchar1] AS c30c31, UserData.[int2], UserData.[datetime5], t1.[DirName] AS c39 FROM AllUserData AS UserData WITH(INDEX=AllUserData_PK) INNER JOIN Docs AS t1 WITH(NOLOCK) ON (UserData.[tp_RowOrdinal] = 0) AND (t1.SiteId=UserData.tp_SiteId) AND (t1.SiteId = @SITEID) AND (t1.ParentId = UserData.tp_ParentId) AND (t1.Id = UserData.tp_DocId) AND ( (UserData.tp_Level = 1) ) AND (t1.Level = UserData.tp_Level) AND (t1.IsCurrentVersion = 1) AND (t1.Level = 1 OR t1.Level = 2) AND (UserData.[tp_ListID] =@LISTID) AND (UserData.[tp_CalculatedVersion] = 0 ) AND (UserData.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (UserData.[tp_DeleteTransactionId] = 0x ) LEFT OUTER LOOP JOIN AllUserData AS t2 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int1]=t2.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t2.[tp_RowOrdinal] = 0) AND ( (t2.tp_Level = 1) ) AND (t2.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t2.[tp_CalculatedVersion] = 0 ) AND (t2.[tp_DeleteTransactionId] = 0x ) AND (t2.tp_ListId = @L2) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t3 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int2]=t3.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t3.[tp_RowOrdinal] = 0) AND ( (t3.tp_Level = 1) ) AND (t3.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t3.[tp_CalculatedVersion] = 0 ) AND (t3.[tp_DeleteTransactionId] = 0x ) AND (t3.tp_ListId = @L4) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t4 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int3]=t4.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t4.[tp_RowOrdinal] = 0) AND ( (t4.tp_Level = 1) ) AND (t4.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t4.[tp_CalculatedVersion] = 0 ) AND (t4.[tp_DeleteTransactionId] = 0x ) AND (t4.tp_ListId = @L5) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t5 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int4]=t5.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t5.[tp_RowOrdinal] = 0) AND ( (t5.tp_Level = 1) ) AND (t5.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t5.[tp_CalculatedVersion] = 0 ) AND (t5.[tp_DeleteTransactionId] = 0x ) AND (t5.tp_ListId = @L5) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t6 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int5]=t6.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t6.[tp_RowOrdinal] = 0) AND ( (t6.tp_Level = 1) ) AND (t6.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t6.[tp_CalculatedVersion] = 0 ) AND (t6.[tp_DeleteTransactionId] = 0x ) AND (t6.tp_ListId = @L6) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t7 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int6]=t7.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t7.[tp_RowOrdinal] = 0) AND ( (t7.tp_Level = 1) ) AND (t7.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t7.[tp_CalculatedVersion] = 0 ) AND (t7.[tp_DeleteTransactionId] = 0x ) AND (t7.tp_ListId = @L7) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t8 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int7]=t8.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t8.[tp_RowOrdinal] = 0) AND ( (t8.tp_Level = 1) ) AND (t8.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t8.[tp_CalculatedVersion] = 0 ) AND (t8.[tp_DeleteTransactionId] = 0x ) AND (t8.tp_ListId = @L8) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t9 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int8]=t9.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t9.[tp_RowOrdinal] = 0) AND ( (t9.tp_Level = 1) ) AND (t9.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t9.[tp_CalculatedVersion] = 0 ) AND (t9.[tp_DeleteTransactionId] = 0x ) AND (t9.tp_ListId = @L9) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t10 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int9]=t10.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t10.[tp_RowOrdinal] = 0) AND ( (t10.tp_Level = 1) ) AND (t10.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t10.[tp_CalculatedVersion] = 0 ) AND (t10.[tp_DeleteTransactionId] = 0x ) AND (t10.tp_ListId = @L10) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t11 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int10]=t11.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t11.[tp_RowOrdinal] = 0) AND ( (t11.tp_Level = 1) ) AND (t11.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t11.[tp_CalculatedVersion] = 0 ) AND (t11.[tp_DeleteTransactionId] = 0x ) AND (t11.tp_ListId = @L11) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t12 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[int11]=t12.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t12.[tp_RowOrdinal] = 0) AND ( (t12.tp_Level = 1) ) AND (t12.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t12.[tp_CalculatedVersion] = 0 ) AND (t12.[tp_DeleteTransactionId] = 0x ) AND (t12.tp_ListId = @L12) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN Workflow AS t13 WITH(NOLOCK) ON ( CAST ( CAST (UserData.[nvarchar18]AS VARBINARY) AS UNIQUEIDENTIFIER)=t13.[ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t13.SiteId = @SITEID) AND (t13.WebId = @WEBID) AND (t13.ListId = UserData.tp_ListId) AND (t13.ItemId = UserData.tp_Id) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t14 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[tp_Author]=t14.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t14.[tp_RowOrdinal] = 0) AND ( (t14.tp_Level = 1) ) AND (t14.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t14.[tp_CalculatedVersion] = 0 ) AND (t14.[tp_DeleteTransactionId] = 0x ) AND (t14.tp_ListId = @L14) AND (UserData.tp_ListId = @L3) LEFT OUTER LOOP JOIN AllUserData AS t15 WITH(NOLOCK,INDEX=AllUserData_PK) ON (UserData.[tp_Editor]=t15.[tp_ID]) AND (UserData.[tp_RowOrdinal] = 0) AND (t15.[tp_RowOrdinal] = 0) AND ( (t15.tp_Level = 1) ) AND (t15.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (t15.[tp_CalculatedVersion] = 0 ) AND (t15.[tp_DeleteTransactionId] = 0x ) AND (t15.tp_ListId = @L14) AND (UserData.tp_ListId = @L3) WHERE (UserData.[tp_CalculatedVersion] = 0 ) AND (UserData.[tp_IsCurrentVersion] = CONVERT(bit,1) ) AND (UserData.[tp_DeleteTransactionId] = 0x ) AND (UserData.tp_ListID=@LISTID) AND ( (UserData.tp_Level = 1) ) AND (UserData.tp_SiteId=@SITEID) AND (UserData.tp_RowOrdinal=0) AND (t1.SiteId=@SITEID AND (t1.DirName=@DN OR t1.DirName LIKE @DNEL+N'/%') AND t1.SortBehavior=0) ORDER BY UserData.[tp_ID] ASC OPTION (FORCE ORDER, MAXDOP 1
    Any ideas what is causing this? Any background process or the custom code.
    Thanks
    Akshay

    This looks like a standard List query (could be any list).
    Make sure your List View Threshold is 5000 or less (this is set on the Web Application, primarily). Lists that are queried for >5000 rows will introduce a table locking read.
    Make sure your SQL Server is set to a Max Degree of Parallelism of 1, as well.
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • Select() does not block

    I cannot provide simple code for this yet. Nondeterministically,
    my calls to Selector.select() do not block. That is, they return
    immediately, and they return 0. There are no calls to
    Selector.wakeup() in the program, and I check that
    isInterrupted() == false from the thread that invokes select().
    The Javadoc states that these are the only two circumstances in
    which a return of 0 from select() should be possible.
    When this starts happening, it happens consistently ad infinitum,
    but it doesn't start happening in every execution.
    This happens with JDK 1.4.1-RC but NOT in JDK 1.4.0. I cannot
    easily roll back to JDK 1.4.0 because the OP_WRITE select()
    behavior has changed, and what I distribute must work with later
    versions of the JDK.
    I realize that, without a simple test case, it will be hard for anyone
    in this forum to diagnose this. I am hoping that, nevertheless,
    someone has some good speculation.
    I must say, I wish I had coded this in C++. This NIO seems to be
    rather shoddy so far.
    Thanks in advance,
    Juan Leon

    What platform are you using? I took a look and quickly found myself looking at a native method call in a platform-specific class. (sun.nio.ch.WindowsSelectorImpl$SubSelector.poll0(), specifically.) The provider (SelectorProvider.provider().getClass().getName()) might be helpful in diagnosing this. On my system (JDK 1.4.1_01, Win XP) it is: sun.nio.ch.WindowsSelectorProvider.
    With a little help from Jad and some hand editing of the formal arguments to poll0(), I get:
    private int poll() throws IOException {
        return poll0(pollWrapper.pollArrayAddress,
            Math.min(totalChannels, 1024), readFds, writeFds, exceptFds, timeout);
    private native int poll0(long address, int channels,
        int[] readFds, int[] writeFds, int[] exceptFds, long timeout);selectNow() pretty much just calls doSelect(0L) in a synchronized block, so I think hoping it will reset things is futile.
    WindowsSelectImpl.doSelect(long) looks like this:
        protected int doSelect(long l) throws IOException {
            if (channelArray == null)
                throw new ClosedSelectorException();
            timeout = l;
            processDeregisterQueue();
            if (interruptTriggered) {
                resetWakeupSocket();
                return 0;
            adjustThreadsCount();
            finishLock.reset();
            startLock.startThreads();
            try {
                begin();
                try {
                    subSelector.poll();
                } catch (IOException ioexception) {
                    finishLock.setException(ioexception);
                if (threads.size() > 0)
                    finishLock.waitForHelperThreads();
            } finally {
                end();
            resetWakeupSocket();
            finishLock.checkForException();
            processDeregisterQueue();
            return updateSelectedKeys();
        }As you can see, when all is said and done it calls the native method mentioned above to do all the work, which most likely calls your system's poll() (or possibly select()?), which may be where your problem actually lies. Another poster suggested it may choke on certain channels (closed w/ half-open socket) -- is it possible for you to remove them from the set before calling select? (I know you shouldn't have to, but....)
    By the way, updateSelectedKeys() iterates over the helper threads calling the subclass's processSelectedKeys() method, which in turn calls processFdSet() three times: once each for the readFds, writeFds, and exceptFds. This is what actually computes the return value, and the problem could be here, but isn't likely to be, since you say it isn't even blocking.
    Anyway, I've gone on long enough, and I'm sure you can use Jad (or some other decompiler) as well as I can. I'm certainly no nio expert (in fact, I haven't used Selector), and this is only what I found after a quick glance into the code.
    Whoa! While proofreading this, that "if (interruptTriggered)" block suddenly jumped out at me. If interruptTriggered is getting stuck on that could cause your problem. It's private volatile boolean and is false initially, then set in wakeup() and reset in resetWakeupSocket().
    Jad (v1.5.8e2) coughed while decompiling resetWakeupSocket(), but I think it's:
        private void resetWakeupSocket() {
            synchronized (interruptLock) {
                if (!interruptTriggered)
                    return;
            resetWakeupSocket0(wakeupSourceFd);
            interruptTriggered = false;
        }resetWakeupSocket0() is another native method. You'll get some insight into your problem from studying WindowsSelectorImpl (or whatever the implementation is on your platform), but you're going to find that you need to look at the several native methods being called to really determine what's going on.
    Good luck,
    David R. Conrad

  • Tables stored in memory but may be accessed from other sessions

    Dear Oracle experts,
    it may be a stupid question but I'm searching for the best possibility to create a kind of temporary table which may be accessed from other sessions.
    Could you provide some hints/ catchwords to speed up my recherches.
    Thank you very much,
    Daniel

    danielwetzler wrote:
    danielwetzler wrote:
    I fear that the caching is not suitable for my case because of the reasons decribed in my other postings...First of all I don't think that you need to worry about the effectiveness of the caching in your particular case. In addition Oracle is very clever at when to actually write the dirty blocks from the buffer cache to the disks, so if your amount of data written to the result table is fairly small and no other activity is going on your system it won't get written to disk immediately anyway but stay in memory until any of the conditions are met that trigger the database writer to flush the blocks to disk.
    But there are options you could consider if you want to avoid as much of the overhead as possible and to write the results of your calculation to the result table as fast as possible.
    You could use direct-path inserts (INSERT /*+ APPEND */) and set the result table to "NOLOGGING". This way no undo and minimum redo is generated.
    Note however that there are certain caveats and restrictions to consider when using such an approach, e.g. your result table won't be recoverable (which you say is OK), only one direct-path insert is allowed simultaneously (it blocks the table exclusively, no other DML possible until you commit/rollback the transaction), and the direct-path insert has some restrictions. If any of these apply that prevent the direct-path operation then it silently falls back to "conventional" insert mode which generates undo and redo. One of the more annoying restrictions is that you can't read from a table that has been written to in direct-path mode within the same transaction, you first have to commit the transaction, otherwise you get "ORA-12838: cannot read/modify an object after modifying it in parallel". This means by simply adding the APPEND hint you might break existing logic.
    Finally the direct-path insert never re-uses free space in blocks below the current high-water mark, which means if you perform a direct-path insert and afterwards delete rows from the table and repeat again a direct-path insert operation your segment will grow and the empty space in the already used blocks won't get re-used. Best way would be to truncate the table rather than deleting rows from it.
    There are workarounds available to overcome some of these direct-path insert limitations (exclusive lock, truncate instead of delete etc.), like using a partitioned table (if you have a suitable edition/license), because direct-path inserts can be restricted to partitions. In this case you can do simultaneous direct-path inserts if you use different partitions, but you need then some kind of logic that determines which partition to use.
    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/

  • What are changes between FP 10.0.42.34 and 10.0.45.2 that could cause AS2 code to run differently?

    Hi, I am trying to debug a large Flash reading literacy application which is written in AS2. Everything works in 10.0.42.34. When our school customers upgrade to 10.0.45.2 they get blocked from proceeding with training.
    The main movie has loaded an application to run a sequence of tutorial movieclips, driven by an xml input.
    The application waits for each background plus movie to load and the plays the movie.
    It then unloads the movie and background and proceeds to the next movie/background.
    I am running the debugger in CS4 in both FP 10.42.34 and FP 10.0.45.2, the two [UnloadSWF] trace outputs happens in both, but the next step is missed. I am delving into the code right now, but I hope that there may be a hint in the changes made.
    I see no errors or security sandbox issues in the trace output.
    Can someone tell me what main changes there are in FP 10.0.45.2 that could cause AS2 code to run differently?
    Currently we are going to tell our customers that they must downgrade Flash Player to keep their kids learning to read.
    Thanks,
    Sue W.

    All these bug reports are probably describing same problem:
    http://bugs.adobe.com/jira/browse/FP-3993
    http://bugs.adobe.com/jira/browse/FP-4137
    http://bugs.adobe.com/jira/browse/FP-4121
    Not yet any word from Adobe that this is considered a bug worth fixing.
    I would also like to add that the bug failing to load or run older AS1/2 swfs is present in both latest release version FP 10.0.45.2 and FP 10.1.51.95 (beta 3). So it does not look like it has been fixed with 10.1

  • Read by other session wait event

    I have some reports in my database that whenever executed by two or more session these reports suffers with read by other session wait event. Tables which are involving in that's query i moves them to other tablespace and then move back to original tablespace. Some how this could solves read by other session wait event. But after some days these problem occur again.
    How can i permanently solve this problem??
    My db is Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Prod
    Oracle Block size 4096
    Thanks

    Hi there,
    Searching for this wait eventin the docs gave this,
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14237/waitevents003.htm#sthref3159
    read by other session
    This event occurs when a session requests a buffer that is currently being read into the buffer cache by another session. Prior to release 10.1, waits for this event were grouped with the other reasons for waiting for buffers under the 'buffer busy wait' event
    Wait Time: Time waited for the buffer to be read by the other session (in microseconds)And a quick google search for the same gave these results in the top.
    http://www.confio.com/English/Tips/Read_By_Other_Session.php
    http://www.dbafan.com/blog/?p=132
    HTH
    Aman....

  • DBA commit other session's transaction?

    Hi, everyone,
    A quick question, can a DBA commit {color:#0000ff}other session's transaction{color}?
    If so, how?
    Thanks!
    Alex

    Transactions can be as long as what the user logic demands. There is no transactions that is too long or too large. Oracle doesn't break, slowdown, or underperform because of long or big transactions. If you look deep into how oracle handles transactions in the background, you'll see why.
    It's interesting you mentioned that. I hope you really looked deep into how oracle handles transactions so you can en-light us how long and large transaction not affecting performance.
    perhaps we should start with Oracle Concept shall we?
    http://download.oracle.com/docs/cd/B19306_01/server.102/b14220/transact.htm#CNCPT117
    In a nutshell long and large transaction has potential performance impact at least in these aspects.
    A transaction will generate undo information, until the transaction is committed, these undo segment can't be reused. As transaction grows the undo space held hostage grows. Potential performance impact No.1
    A transaction usually hold locks on rows you made changes. until your transaction is committed, no other user can update these rows and need to wait for the lock. Potential performance impact No.2
    The third one is situation like yours, when a session held long and big transaction dropped, Oracle need to rollback all the changes made to database. Some of these changes already been flushed to disk (especially since it's long and large transaction). In that case, Oracle will need to load all changed data blocks and apply undo information back.
    On the other hand, since you are seeking ways for DBA to commit the uncommit change you made recklessly, that means you could have committed the changes. There's certainly no user logic to hold these changes as one single transaction.

  • Weird Selection Problem - Mouse starts selecting everything  when going near line numbers

    In Dreamweaver CS6 Mac Code View, if I move the mouse near the line numbers it goes into some weird selection mode: It tries to select everything I move the mouse over.
    It doesn't happen all the time, but it happens frequently enough to be very annoying.
    How can I disable this?
    I have looked through the options and cannot find anything. I have also searched on Google.
    I have been using Dreamwaver's code view since Dreamweaver MX and have never come across this problem before.

    I am very sure that slim was done. It didn't start it as a daemon, I only let it respawn on runlevel 5 (in inittab). After I went in 3 and closed it, It didn't respawn. I looked at the display and I looked at ps -ef | grep slim and waited ;-)
    Anyways, seems like I was right: slim is simply not doing something.
    Now I have i my slim.conf:
    # Commands executed when starting and exiting a session.
    # They can be used for registering a X11 session with
    # sessreg. You can use the %user variable
    sessionstart_cmd /usr/bin/sessreg -a -l $DISPLAY %user
    sessionstop_cmd /usr/bin/sessreg -d -l $DISPLAY %user
    With who I have now:
    jonnyjd :0.0 2007-11-06 22:00
    The :0.0 made with -l $DISPLAY and seemed common. You can do anything you like I guess. -a stands for "add" and -d for "delete". Usually you have a -w and -u option also, but in Arch the wtmp and utmp are in the standard location, so we don't need them.
    The session*_cmd entries in slim.conf were inserted for exactly this purpose somewhere in the year 2005, referring to the bug-database of slim (http://developer.berlios.de/bugs/?group_id=2663)
    Okay, so I learned something new today
    EDIT:
    If you don't have xdm installed, than you shouldn't need the "-x" part. This is basically only needed when you have more than one x-display controlled by a login manager, which slim can't do anyways. So it would be a nice and clean: /usr/bin/sessreg -a -l $DISPLAY %user (edited the above .conf)
    Last edited by JonnyJD (2007-11-06 21:39:13)

  • How to view session parameters of other sessions?

    Hi
    I have a problem with an application that is related to character sets, codepages and NLS settings.
    As all my tests (with sqlplus) where successful I suppose the application is setting any NLS parameters that cause the problem. To further investigate the issue I'd like to see the session parameters of the session the application is using.
    I know NLS_SESSION_PARAMETERS has the information for my session, but how do I get the information for any other session?? Is this possible at all?
    best regards,
    Marcus

    So I have to do tracing? There is no view or table where I can quickly lookuo the info? That's a pity!
    Anyway, meanwhile I found out that the backend of the application has the ability to send custom SQLs to the server. So I just did a select on NLS_SESSION_PARAMETERS from there and voila there was a configuration issue...
    Ok, another question, maybe a dumb question, but I am missing NLS_CHARACTERSET in NLS_SESSION_PARAMETERS.
    NLS_CHARACTERSET is available in NLS_DATABASE_PARAMETERS and in V$NLS_PARAMETERS - but not in NLS_SESSION_PARAMETERS.
    Shouldn't it be possible to set the characterset within the session to adjust the output to the local client? If I set the NLS_LANG=language_territory.charset on the client, where does the charset go?

Maybe you are looking for