How to find the lock on a record??
Hi folks!!
Here is the gotcha!!
I am opening two sessions of the same applications with different users.
I am trying to access the same record in a table from both the sessions.
Once I tried to modify the data in one session the other session is getting hanged.
My motive is basically to throw/pop-up one box saying that the record is being modified by some other user.
My problem lies in how to track who (user) is modifying the record.
Plz help me out on this ASAP..
I would be really indebted..
Cheers...........PCZ
..and
My problem lies in how to track who (user) is modifying the record.
No that's not possible, because Oracle doesn't keep track of all the individual locks. Oracle doesn't have a lock manager.
There are two thing you can do
1) Examine the table locks, and if there is only one on the table you are working with, you have a chance that the session you find is the one you are looking for. But this is only true when the lock is held for quite some time.
2) When your session is waiting for a lock, there will be a record in v$lock. Use a third session to examine which session is holding the lock.
I hope do you solve
Similar Messages
-
How to find the LOCKED ROWS in a table?
Not locked objects, but for a table the locked rows.
Check below links :
http://www.jlcomp.demon.co.uk/faq/locked_rows.html
How to find the locked row.
who are waiting for same record?
HTH
Girish Sharma -
How to find the locked transaction?
Hi All,
Problem:
We are trying to VOID a cheque which was already accounted for some reason. We are unable to do that. The VOID option is there, but when we go to that option and give Check date and GL Date, system says it will void. On clicking OK in this screen, another message comes saying VOIDED..Requery to see changes... But when we requery we are unable to see the voided check. Still the check status is Negotiable.
Solution:
Usually happens when there is a database lock on that partucular check.
Some payment bacth of adjustment session had selected this particluar check but has not released it .
Pls ask ur dba to have it checked and if it is indeed locked , either try to release it or kill that session.
Now my query is how can I find out the locks via V$LOCK table.
Thanks
ShivankHi All,
I have found out the result of same.
We can find out the BLOCKING transactions from
SQL> select * from dba_locks where BLOCKING_OTHERS='BLOCKING';
Once you find out the blocking transactions you can check it with V$SESSION for the SID and SERIAL# i.e.
SQL> select * from V$SESSION where SID in (<SESSION_ID>);
Now you can release the locks by
SQL>ALTER SYSTEM KILL SESSION 'SID,SERIAL#';
Thanks
Shivank
Message was edited by:
anchorage.india -
How to find the user who created record on PA_TRANSACTION_INTERFACE_ALL ?
We are trying to develop a custom workflow to send Project WebADI transactions through workflow approval. My problem is, from the PA_TRANSACTION_INTERFACE_ALL table where the interface records are populated, I cant find the user responsibile. (Notification will be sent to the creator's manager)
What we planned for the design is:
Disable the import program being run from WebADI Screen. This ensures data stays in PA_TRANSACTION_INTERFACE_ALL and does not go to PA_EXPENDITURES_ALL Etc.
Looking at the data, send notifications. When the approval is given, run the import program to send the data to PA_EXPENDITURES_ALL Etc.
We were also going to remove the import program from the custom responsibilities so that users dont run it.
First, we had to disable the Import program being run from the WebADI screen. We did this by editing the integrator. Now when the data is imported into this table ,we can see many columns do not have data. CREATED_BY etc are populated only if the import program runs. But if it runs then already transactions have gone in and approval process is meaning less.
Only thing that looks like it could be useful is TXN_INTERFACE_ID but I cannot find another place where it will link to.
Could you help us find a way to find the creator of the data in PA_TRANSACTION_INTERFACE.Hi
I don't know the answer to your question, but thought of suggesting another approach.
Leave the original import program in the integrator of the WebAdi.
Develop a logic into Transaction Import Client Extension. There you can find the data that Oracle has already populated for the created by column, and you may trigger the notification submission for approval. Use the extension to alter the transaction status so it will not be actually interfaced, until you get the approval response.
Dina -
How to find the Locked User Account in OBIEE Admin Console
We have recently implemented OBIEE and we are in Learning mode. An user complained that his user account is locked, since he tried to login several times with wrong password. Apparently we unlocked his account successfully. Is there any way to find which user accounts are locked? This may be really helpful for
Thanks in advance.Looks like using wlst code can get the list
Check this
http://weblogic-wonders.com/weblogic/2010/11/12/userlockout-feature-of-weblogic-server/
If you customize above code with the below, can get the list of locked users on console
ul= connection.invoke(ulr, "isLockedOut", new Object[] { username },new String[] { "java.lang.String" }).toString();
System.out.println("Rezultat isUserLocked " + ul);
pls mark correct/helpful if helps
Edited by: veeravalli on Oct 18, 2012 11:51 AM -
How to find the number of transactions recorded in R/3
Hi guys,
I wanted to know the number of all the transactions recorded in R/3 in a time period.
Points for helping.
ThanksHi Prasun,
You can use tcode: STAT
Regards,
Ankit -
Finding the lock wait timeout in Oracle 11g
Want to know how to find the lock wait timeout set on Oracle 11g
Hi,
To find number of seconds a distributed transaction waits for a lock:
SELECT *
FROM v$parameter
WHERE NAME = 'distributed_lock_timeout';To find all parameter's related to lock you can use something like this:
SELECT *
FROM v$parameter
WHERE NAME like '%lock%';Thanks,
Shankar -
How to find the data flow in pipes
Hi All,
I am working on an existing created job which have the query that mapped to a input file from there it have a couple of Query transforms. After the second Query transform there are multiple Pipes with different query transform in which all of the querys are target to a error table and one pipe is target to a clean table.
I want to know how the data is flow into the clean table and error table. How to find the conditions saying which record needs to go into the clean table and which record needs to go into an error table.
ThanksNo such public document available from Oracle unless from Oracle Education.
for some specific operation you can check Process tab inside Oracle Application which shows the data flow as part for workflow process.
Regards
Prashant Pathak -
How to find the id of a session which holds the lock on record
Hi,
I need to find the session id of a user who holds a lock on the records that i need to update.
for example if a user 'A' is update a emp record where emp = 15 and is holding a lock on it. And now when user 'B' tries to get a lock on the same record either he has to wait indefinitely till 'A' releases the lock or he has to skip that record to get lock.
But how can user 'B' find that 'A' holds the lock on that record ?
Can any one please help me ?
Thanks in Advance
Kalyantry this:
---session A---------
test > conn hr/hr
Connected.
test > update employees set salary=100 where First_name='Shelley';
1 row updated.
-----session B--------
test > conn hr/hr
Connected.
test > set serveroutput on
test > DECLARE
2 CURSOR sal_cursor IS
3 SELECT *
4 FROM employees
5 WHERE First_name='Shelley'
6 FOR UPDATE OF salary NOWAIT;
7
8 e_emps_locked EXCEPTION;
9 PRAGMA EXCEPTION_INIT
10 (e_emps_locked, -54);
11 BEGIN
12 FOR emp_record IN sal_cursor
13 LOOP
14 UPDATE employees
15 SET salary = emp_record.salary * 1.10
16 WHERE CURRENT OF sal_cursor;
17 END LOOP;
18 EXCEPTION
19 WHEN e_emps_locked then
20 DBMS_OUTPUT.PUT_LINE ('Cannot update employees ' ||
21 'Shelley' || ' was locked by others. ');
22 END;
23 /
Cannot update employees Shelley was locked by others.
PL/SQL procedure successfully completed. -
How to find the number of records per months in cube
Hi,
how to find the number of records per months for my all cubes?
Can i use the ListCube transaction to find totl number f records per cube monthwise ?
JimmyHi,
Here is a program to generate no of records and list of ODS and Cubes in Active version.Schedule this program in background and create a cube to load this information and schedule to the data from the file generated by the program. Schedule this all per you requirement.
1.Copy the code into your Z<programname> from Se38.
2.change the FILENAME in CALL FUNCTION 'GUI_DOWNLOAD' in the program to the location from where you can pick the information to load data to cube(eg Application server).
3.Save program.
4.Schedule the program in background as required
5.Create cube with infoobjects to hold no of records and Infoprovider name
6.Load this cube based on event after the program job is done.
Hence you can report on this cube to see no of records in CUBE or ODS in your box.
Please find the code below.
Cheers,
Kavitha Kamesh.
types: begin of itabs ,
tabname type dd02l-tabname,
end of itabs.
data: itab type itabs occurs 0 with header line.
data: counter type i.
data: begin of itab1 occurs 0,
tabname type dd02l-tabname,
counter type i,
end of itab1.
DATA: ITABTABNAME TYPE STRING.
DATA: LENGTH TYPE I.
DATA: OBJECT(30).
data: str(6) type c.
select tabname from dd02l into table itab where ( tabname LIKE '/BIC/F%' or tabname LIKE '/BIC/A%00' )
and TABCLASS = 'TRANSP' and AS4LOCAL = 'A'.
loop at itab.
select count(*) from (itab-tabname) into counter.
str = itab-tabname.
if str = '/BIC/F'.
LENGTH = STRLEN( ITAB-TABNAME ).
SHIFT itab-tabname BY 6 PLACES LEFT.
ELSEIf str = '/BIC/A'.
SHIFT itab-tabname BY 6 PLACES LEFT.
LENGTH = STRLEN( ITAB-TABNAME ).
LENGTH = LENGTH - 2.
endif.
itab1-tabname = itab-tabname(LENGTH).
append itab1.
itab1-counter = counter.
clear itab-tabname.
clear: COUNTER.
endloop.
*********** itab1
loop at itab1.
write:/ itab1-tabname, itab1-counter.
endloop.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
* BIN_FILESIZE =
FILENAME = 'c:records.xls'
FILETYPE = 'ASC'
* APPEND = ' '
WRITE_FIELD_SEPARATOR = ','
* HEADER = '00'
* TRUNC_TRAILING_BLANKS = ' '
* WRITE_LF = 'X'
* COL_SELECT = ' '
* COL_SELECT_MASK = ' '
* DAT_MODE = ' '
* CONFIRM_OVERWRITE = ' '
* NO_AUTH_CHECK = ' '
* CODEPAGE = ' '
* IGNORE_CERR = ABAP_TRUE
* REPLACEMENT = '#'
* WRITE_BOM = ' '
* TRUNC_TRAILING_BLANKS_EOL = 'X'
* WK1_N_FORMAT = ' '
* WK1_N_SIZE = ' '
* WK1_T_FORMAT = ' '
* WK1_T_SIZE = ' '
* IMPORTING
* FILELENGTH =
TABLES
DATA_TAB = itab1
* FIELDNAMES =
* EXCEPTIONS
* FILE_WRITE_ERROR = 1
* NO_BATCH = 2
* GUI_REFUSE_FILETRANSFER = 3
* INVALID_TYPE = 4
* NO_AUTHORITY = 5
* UNKNOWN_ERROR = 6
* HEADER_NOT_ALLOWED = 7
* SEPARATOR_NOT_ALLOWED = 8
* FILESIZE_NOT_ALLOWED = 9
* HEADER_TOO_LONG = 10
* DP_ERROR_CREATE = 11
* DP_ERROR_SEND = 12
* DP_ERROR_WRITE = 13
* UNKNOWN_DP_ERROR = 14
* ACCESS_DENIED = 15
* DP_OUT_OF_MEMORY = 16
* DISK_FULL = 17
* DP_TIMEOUT = 18
* FILE_NOT_FOUND = 19
* DATAPROVIDER_EXCEPTION = 20
* CONTROL_FLUSH_ERROR = 21
* OTHERS = 22
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF. -
How to find the number of records in ods?
how to find the number of records in ods?
Pls suggest the solution apart going to the table of ods and seeing the number of records.
Is there any program or function module to see the number of records in ods?
For eg: SAP_INFOCUBE_DESIGNS is a program which gives the detail (number of records) of infocube.Hi,
I was looking at this and found the following tables that may be of help.
One of these tables will include a summary of the record count of all the tables in your system based on the last time each table had it's database statistics calculated:
DBSTATTADA
DBSTATTDB2
DBSTATTDB4
DBSTATTDB6
DBSTATTINF
DBSTATTMSS
DBSTATTORA
We run on an Oracle database so the table record counts can be taken from DBSTATTORA. Type in AZ in table selection field in SE16 to restrict the output to ODS (or DSO) tables only.
The record count is at the time indicated in the timestamp field. Obviously this is not real time but should not be too out of date - if it is you may be having performance issues and should get your DBA / Basis to run a full refresh of DB stats.
Hope this helps, alhtough not real time the table should give you a decent indication of the size of all your ODS objects (or any other table for that matter!) -
How to find out Locks on the database objects
how to find out Locks on the database objects
The following notes should be helpful:
Note: 200590.1 - bde_session_locks.sql - Locks for given Session ID
https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=200590.1
Note: 1039273.6 - SCRIPT: VIEWING LOCKS ON OBJECTS HELD BY SPECIFIC USER
https://metalink2.oracle.com/metalink/plsql/ml2_documents.showDocument?p_database_id=NOT&p_id=1039273.6
You can also search Metalink, there are many notes/scripts published there which would be also helpful. -
How to find the last update date time and user of record field peoplecode
how to find the last update date time record field peoplecode?
Thank you.One can check the last update date time using the following query
SELECT LASTUPDDTTM FROM PSPCMPROG WHERE OBJECTVALUE1 LIKE 'RECNAME' AND OBJECTVALUE2 LIKE 'FIELDNAME' -
Urgent!! how to find the recent committed record
how to find the recent commited record
if the records are inserted at the same time?Use ORDER BY(DateColumn)...
I don't have any other idea... -
How to find the records using contains with the word like this 'some text-some text'?
Hi,
How to find the records using the full text contains keyword and that column contains ‘some text-some text’
In the above some text can be anything.
Does anybody know please let me know.
Thanks,Hello,
You can try to create a Full Text Index on the table and use CONTAINS() to get the record which contains the specify words.
For example:
SELECT * FROM TABLE WHERE CONTAINS(column_name, 'some text')
Reference:
Full-Text Search (SQL Server)
Creating Full Text Catalog and Full Text Search
Regards,
Fanny Liu
Fanny Liu
TechNet Community Support
Maybe you are looking for
-
Artwork on iPod Nano (3rd Gen)
Hey everyone, I just got a new iPod nano and when I transfered songs from my computer over to my iPod only some of the artwork appears, does anyone know what the problem is? I even have changed the pictures to no avail.
-
Everytime I open Mozilla Firefox 5 Beta, a window pops up that says, "TypeError: Components.classes[cid_siterank] is undefined," with an "ok" button, after I click ok, it opens firefox, how do I stop this window from appearing everytime I open firefo
-
Combine standard task (ABAP method call) and additional UWL Action Handlers
Hi, i have defined a task with an asynchronous ABAP method call and a terminating event which i want to use "as is" in the universal worklist, that means that the standard action has to be the ABAP method call defined for the task. In addition to tha
-
About converting byte to send SMS in Javacard
Hello all, I'm try to send a location information out by put it in the unformat SMS. The location will return in 7 bytes; which including MCC and MNC (3 bytes), LAC (2 bytes), and cell id (2 bytes). Suppose it is 02 F8 00 | 00 14 | 00 79, it means MC
-
when background image rolls thru earth I can see earth in and out of circle mask. It is supposed to look like earth moving with circle mask. You are only supposed to see the earth in the circle.