How to lock a user

Hi,
I have a workflow in which I want to lock a user.
I would appreciate if anyone could provide an example
as to how to do this.
Thanks,
John I

Thanks for the hint. I got it working with the following code:
<Activity id='9' name='Lock Lighthouse User'>
<Action id='0' application='com.waveset.provision.WorkflowServices'>
<Argument name='op' value='lock'/>
<Argument name='doLighthouse' value='true'/>
<Argument name='doResources' value='false'/>
<Argument name='accountId'>
<ref>WF_CASE_OWNER</ref>
</Argument>
</Action>
<Transition to='end'/>
<WorkflowEditor x='352' y='182'/>
</Activity>
Even though the IDM 6.0 SP1 documentation
talks about a lockOrUnlock workflow service,
(as you mention),
it appears that there is no such thing.
There is however an undocumented
'lock' workflow service which calls
a lockOrUnlock private java method.
This mirrors the correctly documented
enable and disable workflow services,
which also internally call a private java method
disableOrEnable.
More bad documentation I think.
Thanks for you help.
John I

Similar Messages

  • How to lock multiple user for a transcation code at same time is der any tc

    how to lock multiple user for a transcation code at same time is der any tc
    suppose i hav 15 user and i want to lock 10 user for mm02 who can i to it

    Basis can do a export and import transport, still if don't have connection between boxes.
    or
    check this
    http://www.sap-basis-abap.com/abap/copy-program-variants-from-one-to-another.htm

  • How to lock sap users in os level

    Dear consultants,
    how to lock the sap users in OS level.please tell me any one.

    Hi Pradeep,
    The table is usr02. The command is as below:
    update <schema>.usr02 set uflag=128;
    in case you need to mention any particular user to be locked, mention in the where clause.
    Before using this command, use the select statement to check the current status of the users.
    Regards,
    Meenu Hans

  • How to lock a user's account

    Hi there,
    In Solaris 9, how can I lock a user's account. By saying lock, I don't want to delete the account and any user's date under his home directory, I just want to inactivate it. I chceked the man page of useradd but I couldn't find it.
    Any related informationa is highly appreciated!

    Not sure if anything has changed from Solaris 8 to 9 but you should be able to use the passwd command. Use,
    $passwd -l username
    This will lock the account.
    To activate the account again use the passwd command like,
    passwd username
    Then specify the password.

  • How to lock a user with a report in batch?

    Hi experts,
    is it possible to lock a range of users with a report which runs in batch? I decide to modify the report EWULKUSR, because I can't run this report in batch. But maybe there is any other report?
    Any idea?
    Thanks and best regards
    Max

    Hi Sim,
    I mean, locking the user in the system.
    Thanks for your answer.
    Best regards,
    Max

  • How to lock a user by using random password?

    hello,
    i need to lock a user from a target system by pushing in random passwords for the accounts. i am successfully able to create an adapter that can generate a random string, but the place where i am stuck is that where to use it as i just need to lock the user and not delete it. if the corresponding manager approves the suspension then the account needs to be deleted else again the account needs to be enabled.
    Please help!
    Thanks!

    ok... sorry...
    so what i did is that i have created a resource that has to be provisioned to the user if the user is to be terminated, in which the manager will mention the user to be terminated and the reason.
    now OIM has to lock the user till the reason that has been given by the manager is deemed valid by the second level manager.
    so for that i have a approval and a process form and processes associsted with them. but the problem is that i need to lock the user using the "Entity Adapter" so i need to do so only in the "Data Object Manager" and thus the problem starts as i dont know where to map the adapter that generates the random password so as to lock the user.
    please, if you find anything confusing here, go thru the discussion in the whole of the thread.
    Thanks!

  • Lock a user for 10 min

    How to lock particular user from logging in for about 10 mins

    Hi
    ALTER USER user ACCOUNT LOCK;
    To create a job use 'dbms_job' package, 'submit' procedure:
    http://download-uk.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_job.htm#i1000807
    what -> 'ALTER USER user ACCOUNT UNLOCK;'
    next_date -> 'SYSDATE + 1/24/6' -- after 10 minutes
    hope this helps
    asp

  • How can I grant users the ability to pause/resume printing without a "print operators group" password.

    Greetings,
    We are running 10.8.5 on 30 machines in an active directory environment (graphics lab). The clients are experiencing a persistant error when pausing or resuming print jobs. Each time something is paused, it requires an administrator password to resume the job. Administrators are not always present so designers are locked out of all of the printers until we come in (or remote in) to authenticate.
    I spoke with Apple today and they said they would not support active directory accounts and that the account must be edited by the department that created the account because the restrictions come from the Active Directory account preferences.
    On the other hand, I ALSO read that I can edit this in the CUPS interface or modify it with the terminal command below, locally.
    dseditgroup -o edit -u admin_name -p -a user_name -t user _lpadmin
    "dseditgroup" adds the user_name to a group (in this case, _lpadmin).
    And admin_name is the name of your administrator's account.
    a) Must this be modified on the Active directory account or CAN I modify this on the local machine via CUPS or terminal?
    b) If so, how would I grant users the ability to resume printing without an admin password?
    c) If not, exactly what must be modified in the active Directory account to allow pause/resume without an admin password.
    I have seen a terminal command that adds users to the print operatiors group (Ipadmin) and I have seen some info on editing the CUPS interface, If i must edit the CUPS interface to allow this, can anyone point to detailed instructions on how to make this change.
    I also saw info on editing the CUPS interface but the suggestion lacked details as to how and how to return to default if it does not work.
    I also saw a post with these suggestions below but without detail as to how one would carry this out.
    /etc/cups/cupsd.conf
    # All administration operations require an administrator to authenticate...
    <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default CUPS-Get-Devices>
    AuthType Default
    *#Require user @SYSTEM*
    *Require valid-user*
    Order deny,allow
    </Limit>
    # All printer operations require a printer operator to authenticate...
    <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    *#Require user @AUTHKEY(system.print.operator) @admin @lpadmin*
    *Require valid-user*
    Order deny,allow
    </Limit>
    /etc/authorization
    +The system.print.operator key is new to Snow Leopard and seems to control resuming and pausing a printer queue among other things.+
    <key>system.print.admin</key>
    <dict>
    <key>allow-root</key>
    <true/>
    <key>class</key>
    <string>user</string>
    <key>group</key>
    <string>staff</string>
    <key>shared</key>
    <true/>
    </dict>
    <key>system.print.operator</key>
    <dict>
    <key>allow-root</key>
    <true/>
    <key>class</key>
    <string>user</string>
    <key>group</key>
    <string>staff</string>
    <key>shared</key>
    <true/>
    </dict>
    I have read all posts on this subject and I still am not clear on how to proceed, please assist.
    Thanks in advance,
    V

    Hello again.  For AD environments you can run the following command on each workstation:
    sudo dseditgroup -o edit -n /Local/Default -u localadmin -p -a "Domain Users" -t group _lpadmin
    This command assumes you are typing this interactively on the machine.  Obviously change localadmin to the Mac's local admin's name.  When running you will be prompted for password twice.  Once to elevate permissions (sudo) and once to validate you are localadmin.
    If you are using Apple Remote Desktop (or JAMF or other management suite), you can push this command out while embedding the localadmin's password. 
    sudo dseditgroup -o edit -n /Local/Default -u localadmin -P yourpass -a "Domain Users" -t group _lpadmin
    Please note, if your password uses special characters (/-\) this may fail over ARD.
    In Mavericks, AD groups are cached once they are referenced.  If you are dealing with a lot mobile users (laptops) you might want to replace Domain Users with everyone
    R-
    Apple Consultants Network
    Apple Professional Services
    Author "Mavericks Server – Foundation Services" :: Exclusively available in Apple's iBooks Store

  • How to set Current User in moss 2007 for Authentication....

    Hi Team,
    We have current running website where we have user id to login but now requirement is that user will login with his Email address. Email is stored in active directory, I'm able to login with fba authentication.  
    I'm able to retrieve the user id of current user using Email but
    I am NOT able to set that user id for current user for further authentication using Moss 2007.
    Please find the source code for login and authentication page:
    //---------------------------Login Page--------------------//
        public partial class Login : System.Web.UI.UserControl
            #region Decleration
            string LoginStatus = null;
            string UserCurrent = null;
           static SPUser siteuser;
           // private static string _randomNumbercheck;
            //private static bool IsLoggedin;      
            Random random;
            #endregion       
            #region Page Load
            protected void Page_Load(object sender, EventArgs e)
                this.hplchangepw.Visible = false;
                this.hplmytask.Visible = false;
                string desturl = SPContext.Current.Site.Url;
                if (!IsPostBack)
                    try
                        string str;
     SPWeb web = SPContext.Current.Web;
                             SPUser siteuser = web. .CurrentUser; 
                        //SPUser siteuser = spWeb.EnsureUser(username);
                        str = (siteuser == null ? "" : siteuser.ToString());
                        this.Login.TitleText = "";
                        this.Login.DestinationPageUrl = desturl;
                        //if (HttpContext.Current.Request.UrlReferrer != null)
                        //    if (this.Page.User.Identity.IsAuthenticated && ((Session["test1"].ToString() == _randomNumbercheck) || LoginControl.Class1.IsLoggedIn))
                         if (this.Page.User.Identity.IsAuthenticated)
                               // _randomNumbercheck = "";
                                this.hplregister.Visible = false;
                                this.hplforgetpassw.Visible = false;
                                this.hplchangepw.Visible = true;
                                this.hplmytask.Visible = true;
                                this.Login.Visible = false;
      if (str.StartsWith("fba_"))
                                    string name = str.Split(':').GetValue(1).ToString();
                                    LoginnameLbl.Text = "<b>" + name.ToString() + "</b>,<br><br>Haryana Urban Development Authority Welcomes
    You. <br><br><br><b><i>\"In The Service Of Masses\"</i></b>";
                                else
                                    string name = str.Split('\\').GetValue(1).ToString();
                                    LoginnameLbl.Text = "<b>" + name.ToString() + "</b>,<br><br>Haryana Urban Development Authority Welcomes
    You. <br><br><br><b><i>\"In The Service Of Masses\"</i></b>";
                            else
                                this.hplchangepw.Visible = false;
                                this.hplmytask.Visible = false;
                                this.Login.Visible = true;
                                LoginnameLbl.Text = "";
                                HttpContext.Current.Session.Clear();
                                HttpContext.Current.Session.Abandon();
                    catch (Exception ex)
                        //HttpContext.Current.Session.Clear();
                        //HttpContext.Current.Session.Abandon();
            #endregion
            #region Get Audit Informations
            public void GetUserInfo()
                try
                    string user = Login.UserName;
                    SPSecurity.RunWithElevatedPrivileges(new SPSecurity.CodeToRunElevated(delegate()
                        using (SPSite oSite = new SPSite(SPContext.Current.Site.ID))
                            using (SPWeb web1 = oSite.OpenWeb(SPContext.Current.Web.ID))
                                SPListItem item = null;
                                SPListItemCollection listItems = null;
                                web1.AllowUnsafeUpdates = true;
                                siteuser = web1.EnsureUser(Session["User"].ToString());// spWeb.EnsureUser(login);
                                listItems = web1.Lists["Audit_Trail"].Items;
                                item = listItems.Add();
                                item["User_ID"] = UserCurrent.ToString(); //Request.ServerVariables["AUTH_USER"];
                                string ip = Request.ServerVariables["HTTP_X_FORWARDED_FOR"];
                                if ((ip == null) || (ip == "") || (ip.ToLower() == "unknown"))
                                    ip = Request.ServerVariables["REMOTE_ADDR"];
                                item["IP_Address"] = ip;
                                item["Login_Date"] = System.DateTime.Now;
                                item["Login_Status"] = LoginStatus.ToString();
                                item.Update();
                                web1.AllowUnsafeUpdates = false;
                                web1.Dispose();
                                oSite.Dispose();
                catch (Exception ex)
            #endregion
            #region MD5Encryption
            private string MD5Encryption(string strToEncrypt)
                System.Text.UTF8Encoding ue = new System.Text.UTF8Encoding();
                byte[] bytes = ue.GetBytes(strToEncrypt);
                // encrypt bytes
                System.Security.Cryptography.MD5CryptoServiceProvider md5 = new System.Security.Cryptography.MD5CryptoServiceProvider();
                byte[] hashBytes = md5.ComputeHash(bytes);
                // Convert the encrypted bytes back to a string (base 16)
                string hashString = "";
                for (int i = 0; i < hashBytes.Length; i++)
                    hashString += Convert.ToString(hashBytes[i], 16).PadLeft(2, '0');
                return hashString.PadLeft(32, '0');
            #endregion
            #region Generate Random Code
            private string GenerateRandomCode()
                random = new Random();
                string s = "";
                for (int i = 0; i <= 6; i++)
                    s = string.Concat(s, this.random.Next(10).ToString());
               // _randomNumbercheck = s;
                return s;
            #endregion
            #region Generate Random String
            public string GenerateHashKey()
                StringBuilder myStr = new StringBuilder();
                myStr.Append(Request.Browser.Browser);
                myStr.Append(Request.Browser.Platform);
                myStr.Append(Request.Browser.MajorVersion);
                myStr.Append(Request.Browser.MinorVersion);
                myStr.Append(Request.LogonUserIdentity.User.Value);
                SHA1 sha = new SHA1CryptoServiceProvider();
                byte[] hashdata = sha.ComputeHash(Encoding.UTF8.GetBytes(myStr.ToString()));
                return Convert.ToBase64String(hashdata);
            #endregion
            #region Check User Authentication
            protected void Login_Authenticate(object sender, AuthenticateEventArgs e)
                Utility hu=new Utility();
                int CheckValue = 0;
                string user = Login.UserName;
                if(user.Contains("@"))
                    CheckValue=1;
                //Encrypted Password
                string HPassword = hash.Value;
                // Verify that the username/password pair is valid
                SqlConnection con = new SqlConnection();
                SqlCommand cmd = new SqlCommand();
                con.ConnectionString = System.Configuration.ConfigurationSettings.AppSettings["FBAPortalConnection"];
                if (con.State == ConnectionState.Closed)
                    con.Open();
                cmd.CommandType = CommandType.StoredProcedure;
                cmd.CommandText = "sp_Portal_ValidatePortalUser";
                cmd.Connection = con;
                cmd.Parameters.Add("@ID", SqlDbType.NVarChar, 256).Value = Login.UserName;
                cmd.Parameters.Add("@Password", SqlDbType.NVarChar, 300).Value = HPassword.ToString();
                cmd.Parameters.Add("@CheckVal", SqlDbType.Int).Value = CheckValue;
                cmd.Parameters.Add(new SqlParameter("@P_Return", SqlDbType.NVarChar, 256));
                cmd.Parameters["@P_Return"].Direction = ParameterDirection.Output;
                cmd.ExecuteNonQuery();
                string CurrentUserName = cmd.Parameters["@P_Return"].Value.ToString();
                cmd.Dispose();
                con.Close();
                //int x = hu.ValidatePortalUser(Login.UserName, HPassword.ToString(), CheckValue);
                if (CurrentUserName != "0")
                    Page.Session["User"] = CurrentUserName;
                    string UserName = Session["User"].ToString();
                    UserCurrent = UserName;
                    LoginStatus = "Successfull";
                    GetUserInfo();
                    e.Authenticated = true;
                    //Session["CustomAuthKey"] = MD5Encryption(Request.ServerVariables["Remote_Addr"] + Request.ServerVariables["Http_Cookie"] + Request.ServerVariables["Auth_User"]);
                    Session["CustomAuthKey"] = MD5Encryption(Request.ServerVariables["Remote_Addr"] + Request.ServerVariables["Http_Cookie"] + UserCurrent.ToString());
                    FormsAuthenticationTicket tkt;
                    String cookiestr;
                    HttpCookie ck;
                    tkt = new FormsAuthenticationTicket(1, UserName, DateTime.Now, DateTime.Now.AddMinutes(15), false, GenerateHashKey());
                    cookiestr = FormsAuthentication.Encrypt(tkt);
                    ck = new HttpCookie(FormsAuthentication.FormsCookieName, cookiestr);
                    ck.Path = FormsAuthentication.FormsCookiePath;
                    Response.Cookies.Add(ck);
                else
                    // Username/password are not valid...
                    Login.FailureText = "Invalid Username / password";
                    e.Authenticated = false;
            #endregion
            #region Login Error
            protected void Login_LoginError(object sender, EventArgs e)
                // Determine why the user could not login
                Login.FailureText = "Your login attempt was not successful. Please try again.";
                // Does there exist a User account for this user
                MembershipUser usrInfo = Membership.GetUser(Login.UserName);
                if (usrInfo != null)
                    // Is this user locked out?
                    if (usrInfo.IsLockedOut)
                        Login.FailureText = "Your account has been locked out because of too many invalid login attempts. Please contact the administrator to have your account unlocked.";
                    else if (!usrInfo.IsApproved)
                        Login.FailureText = "Your account has not yet been approved. You cannot login until an administrator has approved your account.";
                    else
                        Login.FailureText = "Invalid UserName / Password";
                        UserCurrent = usrInfo.UserName;
                        LoginStatus = "UnSucessfull";
                        GetUserInfo();
                else
                    Login.FailureText = "Invalid UserName / Password";
            #endregion
            #region Logged In
            protected void Login_LoggedIn(object sender, EventArgs e)
                string UserName = Session["User"].ToString();           
                LoginControl.Class1.IsLoggedIn = true;
                //If User Email is [email protected] it will be invalid. Prompt the user to update the email id. 
                LoginControl.Utility hu = new LoginControl.Utility();
                DataSet dsuser = hu.getUserDetails(UserName);
                string email;
                if (dsuser.Tables[0].Rows.Count > 0)
                    email = dsuser.Tables[0].Rows[0]["Email"].ToString();
                    if (email.Equals("[email protected]"))
                        Response.Redirect("/Pages/UserUpdates.aspx", true);
                    else
            #endregion
    //-------------------------------- Authentication code----------------------------//
      private void authenticateuser()
                try
                    if (SPContext.Current.Web.CurrentUser != null)
                        using (SPSite spSite = new SPSite(SPContext.Current.Site.Url))
                            using (SPWeb spWep = spSite.OpenWeb())
                                Utility hu = new Utility();
    _userid = spWep.CurrentUser.Name;
                                DataSet ds = new DataSet();
                                ds = hu.GetPlotid(_userid);
                                if (ds.Tables[0].Rows.Count > 0)
                                    _plotid = ds.Tables[0].Rows[0]["plotid"].ToString();
                                else
                                    if (!SPContext.Current.Web.UserIsSiteAdmin && !SPContext.Current.Web.UserIsWebAdmin)
                                        if (!SPContext.Current.Web.IsCurrentUserMemberOfGroup(SPContext.Current.Web.Groups["Allottee"].ID))
                                            SPUtility.HandleAccessDenied(new Exception("You do not have access to this page"));
                    else
                    { SPUtility.HandleAccessDenied(new Exception("Please login")); }
                catch (Exception ex)
                    //  lblMessage.Text = "Error:" + ex.Message;
                    ShowMessage("Following error has occured while executing the desried event :- " + ex.Message);
    Mohan Prakash

    1. Current work flow :-In web site the user have to register themselves in the web site and enters his details along with user id, password and email id. Once user
    is registered then he will login with his user id and password. The user id is picked from login control and that set in “SPWeb.CurrentUser” as user id and system uses "Membership.ValidateUser" method to Authenticate user for login. 
    2. New Requirement: we would like to facilitate the user to login with Email id as well as user id. 
    Problem: 
    We replaced "Membership.ValidateUser" method to our own method to Authenticate user with email id/user id and password. 
    When user is login with user id and password it is working successfully but in the case of email id and password –“the email id is picked from user control and set as
    "HttpContext.Current.User.Identity.Name" but we are not getting “SPWeb.CurrentUser” and it shows null value.” 
    We are able to get user id from database using email id of user. Please help us how we can set user id in "SPContext.Current.Web.CurrentUser".
    Mohan Prakash

  • Read-only mode. Object is currently locked by user: J2EE_ADMIN. hw 2 unlock

    Hi friends,
    <b>i am not able to edit my object in EP</b> , it says
    Read-only mode. Object is currently locked by user: J2EE_ADMIN.
    how do i unlock it ?
    i am on 04s SP9

    Hi Rohit,
       Navigate to
    system_admin -> Monitoring->
    Portal->object_locking->
    There you can view your locked pcd object.Just check it and Unlock.
    That should solve your problem.
    Hope this helps
    Regards
    Vineeth

  • How to lock wbs element

    Hi all,
    I would like to seek your help on how to lock wbs element in a report program. Is there any bapi or function module for that? The requirement is to lock the wbs element when the user process/run that particular WBS. If the user exit to the report program, then that is the time that the other user can be able to process the WBS.
    Please help. Thanks in advance.

    There is no BAPI or function module to lock on unlock a WBS element.Goto Tansaction CJ02,put in the WBS element and repsetive project.
    in CJ02, go to EDIT->STATUS->LOCK/UNLOCK.
    Hope this clarifies your query.
    Regards,
    teja

  • How to Lock a Mac at  A Certain time

    Hello,
    I would like to know how to lock my son's computer at a certain time. But when I go under parental controls, his account does not pop up. is it b/c he is the admin on the computer. Not sure on that one. Can someone please tell me how to lock out my son's account at a particular time?

    First you must remove him as an admin. Change his account to 'standard.' Under System Preferences > Users & Groups > Uncheck 'Allow This user to Administer the Computer' for your Son's account under his name. He must be logged out from his account. If you run into problems, see this thread:
    https://discussions.apple.com/thread/3783318?start=0&tstart=0
    Then, you may set up parental controls properly:
    Manage a user with parental controls

  • How to lock a client?

    Hi everybody,
            I want to lock a client for a period of time.  How can I do it?
    Thanks in advance
    venkatesh

    Hi Venkateswarlu,
    There is an alternative for what you want to do. Instead of locking the client, you could lock the users in that client, so they dont have access to the client for a period of time (until you unlock them again).
    Log in the client you want to restrict. Go to trx SU01. Choose in the menu Environment - Mass changes. In user selection section press button 'Address data' and enter. Select all the users you want to lock. You may not want to block sap*, or the admin user so you still have access to the system :). Select them and then press Transfer. Once all the selected users appear in the first screen, you can select all of them again and press the button to lock them. After this, users wont be able to login in that client anymore.
    I dont know exactly why you want to lock the client, but there is another option in trx STMS. Press button 'System overview' and choose the system you want to lock. Then press the lock button to lock the system.
    Good luck,

  • How to Lock a Transaction for Editing AND VERY minor tab cont. help

    Just two things I need to ask about
    <b>1. How to Lock a Transaction for Editing</b>
    I am currently using the fcode ENQUEUE_E_TABLE. The function works as once the transaction in opened, another cannot access it.
    However, I have two modes in my transction (Display and Edit). <u> What I need to do is If another user has already opened the transaction, the other user can still access the transaction but cannot access the edit mode.</u>
    <b> 2. VERY minor tab cont. help </b>
    I noticed in a table control is being used in a transction you can resize a colunm. <u> How do you disable this </b>?
    and <u> how do you resize the horizontal scroll bar </u> so that you can limit scrolling upto the point where there are field columns?
    Thanks for you help ppl and take care

    Hi chad,
    This link will help u know abty different types of locks that are available:
    http://help.sap.com/saphelp_erp2005/helpdata/en/7b/f9813712f7434be10000009b38f8cf/frameset.htm
    For resizing all u can go to the table settings and u can do it.
    Hope tis helps u,
    Regards,
    Nagarajan.

  • How to lock a row in a db2/400

    Hi all,
    Could someone show me how to lock a row in the database DB2/400
    The scenario:
    DB.beginTransaction
    User 1 gets a row with a column bill_number
    "select bill_number from numbers where pk = xxx for update"
    aux_bill_number = bill_number
    USER 1 updated this row
    "update numbers set bill_number = bill_number +1 where pk = xxx "
    USER 1, like final step, insert aux_bill_number in other table as primary key
    DB.commitTransaction
    While doing so,
    User 2 also gets a row with a bill_number. this user must take bill_number with value 2, but take the same value 1
    This it causes key duplicated in the destiny table.
    Please, help me.
    How I must lock the row not to allow to read until finishing the previous transaction?

    Hi all,
    Could someone show me how to lock a row in the
    database DB2/400Isn't SELECT FOR UPDATE standard?
    >
    The scenario:
    DB.beginTransaction
    er 1 gets a row with a column bill_number
    "select bill_number from numbers where pk =
    xxx for update"
    aux_bill_number = bill_number
    1 updated this row
    "update numbers set bill_number = bill_number
    +1 where pk = xxx "
    USER 1, like final step, insert aux_bill_number in
    other table as primary key
    DB.commitTransactionSounds like you're trying to do something that a JOIN would do better.
    While doing so,
    User 2 also gets a row with a bill_number. this user
    must take bill_number with value 2, but take the
    same value 1
    This it causes key duplicated in the destiny table.
    Please, help me.
    How I must lock the row not to allow to read until
    finishing the previous transaction?Setting the isolation level to SERIALIZABLE might help.
    %

Maybe you are looking for

  • Mp3 will not sync from iTunes desktop to iphone

    Hi All, I have some mp3 files (voice recordings purchased from Darren Hardy) that I imported into my iTunes Library just fine on my Mac OSX desktop. However, those files simply will not sync up with my iPhone like the other 1900-odd songs in my libra

  • Error VLD-1108 while validating the mapping in owb 11g

    Hi All, I am using owb 11.1.0.7.0. I am new to owb 11g. I am getting the following error while validating the mapping error: VLD-1108 . Operator requires more input or output connections in order to generate mapping code. I am using a function as ope

  • Spawning pages with page numbers "page 1 of 1"

    I'm using a calculation script to define "page 1 of 2" in a form. The script is as follows. //set the page number to number 1 this.pageNum = 1; //use the page of page format event.value = "Page " + (event.target.page+1)+" of " + (this.numPages); This

  • Hotspot spotty

    I have an iPhone 4 and a hotspot account.  But the hotspot service is "spotty."  That is, it sometimes works with my iPad, and sometimes does not.  Same thing with the Bluetooth and WiFi connections.  Sometimes they work, and more often they do not w

  • Payment advice (Invoice no. & FCN No.)

    Hi, At my client payers send ERA (instead of payment advice). In ERA they send us our invoice number as well their internally generated FCN no. (These no they use to keep track of our invoices in their system ). If we want to give them credit memo th