How to get current logged-in user name in data access driver or in universe

In universe, to get the current log in user is via @Variable('BOUSER').
Right now, I need to be able to get the user name in the data access driver. I am writing a customized data access driver because we need to patch some where clause on the the query generated by the universe based on the logged-in user info. I only think of using end_sql parameter or adding an universe level filter to patch the @Variable('BOUSER') to the query, which would not work if user want to use customized query.
Can anyone tell me how to get currentBO user name from connection server ? or how @Variable('BOUSER') is translated into the logged-in user name in the universe?

I do not know your EJB Service. But you should pass the credentials of the current logged on portal user to your service. That's not by default I think.
I had a similar problem with CAF developed webservices. I had to turn on permission checks in my web service and passed the credentials via logon ticket.
Regards, Bernd

Similar Messages

  • How to get/capture log-on user name on PC (work station)

    Hi,
    Colud anyone give me how to get/capture log-on user name on my PC (work station)?
    I need to get the infomation by using a function module.
    Kind regards,
    Hisao

    Hi,
    TH_USER_INFO shows me terminal ID, IP address and other information. howerver it does't show me log-on user name of OS.
    Kind regards,
    Hisao

  • OIM11gr2 - How to get currently logged in user details using oim api

    Hi All,
    I have a requirement to retrieve currently logged in users profile in the process adapter.
    I have tried with getSelfProfile in tcUserOperation and also ContextManager.getOIMUser API's however, in both the cases i am getting xelsysadm details only.
    Also as know request details in Process task mapping doesnot work for OIM11g onwards (its returning column not found exception )
    DOes any one has idea how to achieve this.
    PS. - i am using platform to retrieve API's.
    Thanks & Regards
    Swati Pandey

    You can get the logged in user name using the below java code:
    ADFContext adfCtx = ADFContext.getCurrent();
    SecurityContext secCntx = adfCtx.getSecurityContext();
    String user = secCntx.getUserPrincipal().getName();
    HTH

  • How to get Current Log in BO user name in data access driver

    In universe, to get the current log in user is via @Variable('BOUSER').
    Right now, I need to be able to get the user name in the data access driver. I am writing a customized data access driver because we need to patch some where clause on the the query generated by the universe based on the logged-in user info. I only think of using end_sql parameter or adding an universe level filter to patch the @Variable('BOUSER') to the query, which would not work if user want to use customized query.
    Can anyone tell me how to get currentBO user name from connection server ? or how @Variable('BOUSER') is translated into the logged-in user name in the universe?

    Shweta,
    The link you provided was the Auditor guide for BO 6.x, I'm not sure it that is going to help Karen or not.
    Karen,
    There is function called connection
    (usage:  =connection([Query Name]), where [Query Name]
    denotes the name of the tab for the query under Edit Query)
    Here is some of the output from connection:
    4;ODBC18;MS SQL Server 2000166; VERSION=7; USER=xxxxx;
    PASSWORD=; DBTYPE=Relational; DATABASE=xxx_xxxx;
    ODBC_USER=xxxxxx; ODBC_PASSWORD=; BO_DSN=xxxx_xxxx;
    BO_DRV_CONNECT_MODE=0; 224; VERSION=6; Name=xxxxx; Shared=4;
    LoginTimeout=600; Timeout=600; Pool Time=60; Array Fetch Size=10;
    Array Bind Size=5; RecommendedLenTransfert=1000; Password_Encryption=x;
    AliasTable=; MeasureDimension=; Hint=; ConnectInit=; ArrayFetch=1;
    I'm not sure if this info helps out either, being that connection provides info on a post-processing basis and it sounds like you need to get out ahead of the SQL generation.  The @variable('bouser') would seem like the place to be, however, in allowing custom SQL to take place you loose the bouser due to an individual could customize the SQL to the point that it gets unwantingly yanked out.  The end_sql might be your answer...
    Thanks,
    John

  • How to get Current Logged in user in Java

    Hi All ,
    I have written a code in to get the current logged in user in the portal in an EJB service.  I have used the code
    *IUser user= UMFactory.getAuthenticator().getLoggedInUser();*. But surprisingly the userId which it returns is always is Guest. Can you please help on this issue.
    Thanks & Regards,
    Rohit

    I do not know your EJB Service. But you should pass the credentials of the current logged on portal user to your service. That's not by default I think.
    I had a similar problem with CAF developed webservices. I had to turn on permission checks in my web service and passed the credentials via logon ticket.
    Regards, Bernd

  • How to get currently logged in user on 'Bill of Material' Form in Add-Mode

    Dear All,
                    I am using a UDF on 'Bill of Material' Form in SAP. This UDF is named as Current_User. I want in this UDF the user name that is currently logged in to SAP. I am able to get user name at form load event. But when 'Bill of Material' Form comes in ADD Mode, the user name doesn't display. What can I do for this problem.? Here is my code:
    public override void Handle_SBO_ItemEvent(string FormUID, ref SAPbouiCOM.ItemEvent pVal, out bool BubbleEvent)
                BubbleEvent = true;                 
                try
                    if ((mst_FormUIDModal != null))
                        if (FormUID != mst_FormUIDModal)
                            bool dbo_FormFound = false;
                            foreach (SAPbouiCOM.Form dsa_Form in this.SBO_Application.Forms)
                                if (dsa_Form.UniqueID == mst_FormUIDModal)
                                    if (FormUID != mst_FormUIDModal)
                                        if (this.SBO_Application.Forms.Item(mst_FormUIDModal).Selected == false)
                                            this.SBO_Application.Forms.Item(mst_FormUIDModal).Select();
                                        BubbleEvent = false;
                                        return;
                                    dbo_FormFound = true;
                            if (!dbo_FormFound)
                                this.mst_FormUIDModal = null;
                    if (pVal.BeforeAction == false)
                        switch (pVal.EventType)
                            case BoEventTypes.et_FORM_LOAD:
                                    if (pVal.FormType == -672)
                                        Program.Curr_User = SBO_Company.UserName;
                                        doc_form = this.SBO_Application.Forms.GetForm(pVal.FormType.ToString(), pVal.FormTypeCount);
                                        ((SAPbouiCOM.EditText)doc_form.Items.Item("U_User").Specific).Value = Program.Curr_User;
                                } break;

    Hi,
    You need not to write any sdk code for this task. You just create a user query as mentioned above and save it with some name.
    Then Open the Bill Of Material Screen, just click in the required field, then click alt + shift + f2 to assign a Formatted Serach.
    Then Select 3 rd Option       "Search in Existing User-Defined Values According to Saved Query"
    Then Click on the button "Open Saved Query"
    It will open the Query Manager. Select the Saved Query.
    Enable the Option "Auto Refresh When Field Changes"
    In the Drop Down list, select the Value "Parent Item"
    Then Select the Option Refresh Regularly or Display Saved Values.
    This will automatically put the user code if the parent item is selected.
    You an achieve this by without SDK Code.
    PS:
    There is a change in the Above Query:
    Select USER_CODE from ousr where userid = $[USER]
    Edited by: Manikandan K on Dec 22, 2011 2:00 PM

  • How to get current logged in user's star rating in SharePoint 2013

    Hi,
    Currently,  I am developing a custom web part to show star rating for documents, everything is done.
    However,when user hover on the star I want a tooltip message("Your current rating is 1..."), similar to what we have 
    in libraries(or what the sharepoint by default provides in libraries) . So can I get the user specific rating depending upon 
    the logged in user using code(.net or CSOM anything will work)

    using the below code you can get the rated by user along with the rating , it's easier to just notify the user that her already rated the document 
    var acontext = new SP.ClientContext.get_current();
    var lists=acontext.get_web().get_lists();
    var l =lists.getByTitle("Documents"); //your document libraty
    var aitem=l.getItemById(27);//Item id
    acontext.load(aitem, "RatedBy", "ID", "Ratings");
    acontext.executeQueryAsync(function(){
    var RatedBy= aitem.get_item('RatedBy');
    if (!SP.ScriptHelpers.isNullOrUndefined(ratings)) {
    for (var i = 0; i < RatedBy.length; i++) {
    var user = RatedBy[i];
    if (user.get_lookupId() == _spPageContextInfo.userId) {
    //show that you already rate it
    break;
    },function(s,e){alert(e.get_message());});
    another way is to use CAML query to check if the current user id is within the RatedBy multi user field
    Hope that helps|Amr Fouad|MCTS,MCPD sharePoint 2010

  • How to get the logged in user to accept remote management

    Hi,
    It possible to have the currently logged in user to accept or reject a Remote Desktop connection?
    The reason is that the remote administrator taking control should not be able to see the currently logged in user without him knowing it. I know about the "being observed" icon but that's not enough.
    I want the remote administrator to be able to work freely when no users are logged in but if a user is logged in, I want some kind of request/validation-or-rejection mechanism before the remote desktop administrator can take control of the mac.
    Is that possible?
    Ludo

    ARD supports both modes that you desire... The problem, as I recall, is that these are "all or nothing" switches you get one way, or the other, but you can't have it both ways.
    The controls for these options lie behind the "Computer Settings..." button in the Sharing Prefs panel.
    "Anyone may request permission to control the screen"
    and
    "VNC viewers may control the screen with password:"

  • Get current logged in user in sharepoint 2013 hover display template

    Hi,
    Can somebody tell me how the current logged in username can be retreived in hover display template to be used in search result.
    i tried using rest api but that is very difficult to get as it is to be done using ajax call and if we do getting a return value asynchronous is difficult.
    Please help

    Hello,
    You might use the function used in the Visual Studio SharePoint App template:
    var context = SP.ClientContext.get_current();
    var user = context.get_web().get_currentUser();
    $(document).ready(function () {
    getUserName();
    function getUserName() {
    context.load(user);
    context.executeQueryAsync(onGetUserNameSuccess, onGetUserNameFail);
    function onGetUserNameSuccess() {
    $('#message').text('Hello ' + user.get_title());
    function onGetUserNameFail(sender, args) {
    alert('Failed to get user name. Error:' + args.get_message());

  • Command in JSP to get current logged in user.

    Hello Experts,
    We have a web page written in JSP.
    Once we call to this web page. I want to fetch username of the person who has logged in currently to system.
    is there is any single word command to get this ?
    Thanks In Advance..
    Avinash Shrivastava

    avinash101 wrote:
    Hi BalusC,
    First of all Thanks for your reply, but this JSP page will be saved in Server and user will access this site from client machine.
    Please suggest how to go in this scenario.
    Thanks Again,
    AvinashJSP runs at the server machine. It would only return the user name of the server machine. All what the client got is the HTML output produced by JSP, it doesn't get any line of JSP/Java code. You need to run Java at the client machine. A signed applet and web start app can do that.

  • How to show current logged in user image in Master Page

    Hi,
    I am trying to show logged in user image next to his name, following this article 
    http://erikswenson.blogspot.in/2011/04/display-user-profile-picture-next-to.html
    I am trying to do this in SharePoint 2013, so i put Reference
    in .Master file & Control in . html file
    Picture is not visible and when i tried to find whether the control has been loaded or not, the control also hasn't been loaded.
    Please tell me, how could i do this?

    This is not that hard to do, simply go into your masterpage (Design Manager) and copy and paste this on the top of the page:
    <%@ Register tagprefix="SPSWC" namespace="Microsoft.SharePoint.Portal.WebControls" assembly="Microsoft.SharePoint.Portal, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
    Once that is done, you can now add this:
    <SPSWC:ProfilePropertyLoader runat="server" />
    <SPSWC:ProfilePropertyImage PropertyName="PictureUrl" ResizeToFit="115" ShowPlaceholder="true" id="PictureUrlImage" runat="server"/>
    To the location where you want the image to be shown. If you have a custom HTML page that you built out, just add it the same way. Let me know if you have any questions.
    -G

  • How to get the CLIENT OS USER NAME using Apex

    Dear All,
    I know there are many other posts (some of them are very old) discuss about this issue. But unfortunately most of the posts endup with NO PROPER ANSWER. But still I believe that tehre has to be some way to do this. So this is my requirement.
    I am using custom authentication module and I want to get the CLIENT MACHINE OS USER NAME for that. But I do not want to do any authentication against the client user domain.
    How can I get this?
    * There are some other way to get this using VB Scripts. But thats not a real solution for this due to followings
    01. User has to manually allow to run VB scripts. So if user dissable that then we canot get the required info
    02. Its working only with specific browsers(Mainly in IE and also we can get that thing work after installing plugins to Firefox.). So this is also depends with the bvrowser and plugings.
    What I want to do is to get this info using a common way which is not depends with the browser or any thirdparty plugins.
    Thanks,
    Alex

    Its good that you did some searching in the forums before you posted the question.
    Most modern browsers would consider what you require as a security/privacy issue and prevents such information from being transmitted available(easily). IE might let you pull out this using a VB script or activex control. Browser specific addons/extension could work but they need some kind of installation to start with. Java could be a way to do it with all browsers, but the end user still has to grant access before it can do any such thing.
    Lets say you were able to pull out such information from an end user, what would be next, get his mail id from outlook ? , access his browsing history, steal credit card information or read cookies?
    Add to that , what if the end user accesses it using any other OS(linux,macintosh or even a smartphone) ? what about windows vista and windows 7 OS's , are you going to write code to handle all those cases too ?
    Here's a blog posting which explains using NTLM authentication with Apex(it still needs configuration from the end user)
    What I want to do is to get this info using a common way which is not depends with the browser or any thirdparty plugins.I guess if this is the question, then the answer would have to be no. I don't think you will be able to find a method that passes this information from the client side without any modification/configuration at their side

  • How to get the system property - user.name from a client system

    Hi All,
    I have an application which would enable active users from the domain of the company. I want to get the name of the client from the system. I tried to run it on the local machine from Jdeveloper, it returned me the correct user name. But when the application is deployed on the Oracle Application server, and i hit the URL of the application, it returns the server URL.
    I understand that the JSP works on the server side here but help me out to get a solution. I want to read the user name from the client side.
    Thanks in advance!
    Akhil

    Akhil,
    I hope this will never work. Think about your requirement for a second....
    This would mean an application is able to see my user credentials without my knowledge. It's bad enough the know my IP if I'm not using TOR.
    To get your requirement to work you have to redefine it a bit. The user have to log in to your application. The application holds the name together with an ID of the session to know the user in further requests.
    Thats a basic security theme, described in the dos [Adding Security to a Fusion Web Application|http://download.oracle.com/docs/cd/E12839_01/web.1111/b31974/adding_security.htm] .
    Timo

  • Get current logged portal  user information

    Hi,
    I need to get information about current user logged to the portal from a J2EE application. I developed an Enterprise application project with a java servlet and I integrated it into the portal as an URL iView.
    This in the code of servlet:
    import com.sap.security.api.*;
    IUserFactory userFactory= UMFactory.getUserFactory();
         IUser user= UMFactory.getAuthenticator().getLoggedInUser();
         out.println(user.getUniqueID().toString());
         out.println(user.getDisplayName().toString());
         out.println(user.getName().toString());
         out.println(user.getUniqueName().toString());
    When I run my application I have this output:
    USER.PRIVATE_DATASOURCE.un:Guest Guest, Guest Guest
    But I access with another user, it's not Guest.
    How can I solve this problem???THANKS

    Hi,
    Please try checking with following code
    ISearchResult rst = UMFactory.getUserFactory().getUniqueIDs();
                      IUserFactory usf = UMFactory.getUserFactory();
                      IUser iuser = null;
                      IUserListElement userElement = null;
                      int i = 0;
                      while (rst.hasNext()) {
                      iuser =  UMFactory.getUserFactory().getUser(rst.next().toString());
                      String email = iuser.getEmail();
                       String fname = iuser.getFirstName();
                        String lname = iuser.getLastName();
    let me know if there are any issues.
    regards
    Anil

  • Get current logged in user's Apple ID

    Hi,
    I'm trying to implement a rating feature on an app I'm developing, but it's giving me a problem wich is that every user of the app can rate something one and only one time, wich means I can't use his/her IP nor MAC Address, I need something global like the user's e-mail associoated with apple's account, Apple ID or wathever it is that distinguishes users in the App Store. So, is there a way of getting this information in AIR or native language (so I can create an ANE)? Just a simple method that returns the user's ID is what I need.
    Thanks in advance.

    Ok, after some ersearch I found an extension by MilkmanGames called RateBox, here are some links:
    http://www.milkmangames.com/blog/tools/#ratebox (for the extension)
    http://www.adobe.com/devnet/air/articles/ratebox-ane-ios-android.html (for a tutorial)
    Can anyone confirm if this works for rating in-app purchases? I don't wanna buy this without knowing if it'll really work for what I want.

Maybe you are looking for

  • Transfer of material from R/3 to APO, Problem in Integration model

    Hi I have created Integration model for Transferring material from R/3 to APO. While  activating the model, it is giving error  with status as i..e. SYSFAIL On clicking the status, I am getting the following message "Logical system R3CON does not ass

  • Mail doesn't send mail :(

    I am having major issues with mail recently. No matter what account i use (IMAP, POP3) it won't send mail (ie won't connect the smtp). Anyone else have this issue? (It downloads the mail).

  • Import/export of PDF files via iPad USB port - Apple please!

    I am writing here in the hope that some Apple representatives will read it. I am a scientist working for a large pharmaceutical corporation. In my work I read and annotate a lot of publications. Since forever I have been doing this by printing out pu

  • Java.lang.ClassCastException in Console

    Hi, I'm using Weblogic Server 8.1 SP3. When trying to access some screens in the Management console, I get a java.lang.ClassCastException : ####<Nov 28, 2005 10:01:17 AM CET> <Debug> <Management> <midgard> <prddmfaup_admin> <ExecuteThread: '9' for qu

  • I Used To Use Windows?

    I have only switched to Mac recently. The MBP is my first Mac. I never understood the hype until now. I used to anticipate new Windows operating systems, like Vista would really excite me in the past. Now it doesn't phase me as Windows seems to be tr