Run a search on a user table

Hello,
I'd like to know if it's possible to search a user table in SAP or Oracle where users and his/her department are displayed.
Eg: I have a long list (300) of users and I just want to know in which department they are working.
SAP system release = 4.7 R3
Oracle = 9.2.0.8
Thanks a lot
Bert

This really isn't the best place to post such a message.  You might want to try the ABAP forum.  I'm sure somewhere there has written a report like this in the past.  The main User Master tables are USR* (ie USR01).  However to get department, you might have to combine your search with HR tables as well.  There is a department field within the Address Master linked to the User Master (ADDR3) that might be used instead of the HR records (since not everyone utilizes SAP HR).  You can look at transaction SU01 to via a user master and see if this is the data you want.

Similar Messages

  • I canu00B4t do a formatted search in a user table

    Hye, I'm trying to do a formatted search over a user table using and I get the error -2006, why?
    I use "report generator" and my selecc is :
    SELECT T0.U_grupo, T0.U_CODE
    FROM T0
    WHERE T0.U_grupo ='[%0]' FOR BROWSE
    If I do the same with standar table ( e.j OITM),  all is right:
    SELECT T0.ItemCode, T0.ItemName
    FROM OITM T0
    WHERE T0.PrchseItem ='[%0]' FOR BROWSE
    unless, with user tables no, whyyyy?
    thank´

    I have seen this, though I don't have an official answer, I have my own theories.  SBO matches up the variable with the previous field name and looks up the description for that field.  The description for user fields is not stored in the same place as standard fields.
    In a previous thread, named "SQL Syntax in SBO" (number 7144) another user showed a way to do dummy selects with the variables to get the names of standard fields.  Then the variables can be used for the real work.
    That is awkward, and it limits you to the descriptions of standard fields.
    Bruce

  • How do I create new user table in program and then access it?

    I am writing an application where I check for the existence of user objects when the add on starts and run the setup if the objects do not exist. I can create the user tables and fields but after the setup completes these objects still are not visible.
    If the user objects exist when the add on is first run everything is detected correctly.
    When a user object is added in SAP the user is eventually prompted to restart so I suspect something needs to happen prior to the add on being able to use the new fields.
    Does the add on need to wait for the DI Server to perform some action? Do I need to just quit the add on's class and rerun it, disconnect and reconnect to the company, or get a new Application and/or company object?
    What I want to do is figure out a way for the add on to automatically run the configuration if the user tables and fields do not exist yet and then kick off the regular add on code. I haven't seen anyone else's code so I don't know what is recommended or required here.
    Thanks for any assistance!

    I found that the add on can validate the existance of the user fields if I disconnect from the company object, set the SAPbouiCOM.Application and SAPbobsCOM.Company objects to null, set the new application, context, and company objects, and reconnect once more.
    HOWEVER...
    I still have to wait for the client to be restarted manually before I can run any of the form I added to the menu.
    So, I'd still like to know what the best practice is here. Should I just exit after setting up the tables and tell the user to restart SAP?

  • Run search on user table to find which users belong to which department

    Hello,
    I'd like to know if it's possible to search a user table in SAP or Oracle where users and his/her department are displayed.
    The user's department is of course defined in SU01 but in stead of of entering user per user in SU01, I want to find the table where I can run a search.
    Eg: I have a long list (300) of users and I just want to know in which department they are working.
    SAP system release = 4.7 R3
    Oracle = 9.2.0.8
    Thanks a lot
    Bert

    Perfect ! I was trying to find it and this answered it perfectly ! Thanks

  • Formatted search on User Table

    Hi..,
          I need to set formatted search for user table which is @DCNR . My Requirement is that i need to  Pick CST NO from BP Master  . In my user screen i had taken CARDCODE value using CFL which is binded to the field U_ven in the table @DCNR.Using this CARDCODE value i need to pick CSTNO from BP master to the user screen which is binded to the table (@DCNR).My Query is as follows but it is not working,
    SELECT crd7.taxid1 from crd7 inner join @dcnr on crd7.cardcode  = @dcnr.u_ven where crd7.cardcode = $[@dcnr.u_ven]
    U_VEN field contains card code value.
    Do i need to follow some other terms in order to write formatted search on user table.
    Hope some one would help to fix this problem.
    thank u,
    -Ashok Krishnan

    Dear Mr Krishnan,
    As a starting poing I would suggest reading these documents regarding UDF and Formatted search:
    https://websmp108.sap-ag.de/~form/sapnet?_FRAME=CONTAINER&_HIER_KEY=701100035871000437965&_OBJECT=011000358700004463532006E&_SCENARIO=01100035870000000183&
    https://websmp108.sap-ag.de/~form/sapnet?_FRAME=CONTAINER&_HIER_KEY=701100035871000437965&_OBJECT=011000358700003625432006E&_SCENARIO=01100035870000000183&
    let us know if they were usefull.
    Kind Regards,
    Marcella Rivi
    SAP Business One Forums Team
    Edited by: Paul Finneran on Aug 14, 2008 1:15 PM

  • Using VPD in combination with a user table?

    I'm very new with VPD's. In fact, I don't know a thing about it yet (I know the philosophy behind it and the principle, but not the practical implementation). My question: Are VPD's always based on database-users? Our applications have a user-table now, where the access rights to applications are stored. Once a user is present in that table and has the necessary rights, he can login to the application. So we don't have an actual database-user for each "real-life" user, just an entry in a table.
    Is it possible to use the system of VPD's (and maybe Oracle Label Security) with users stored in a table, instead of actual database users?

    TomVD wrote:
    My question: Are VPD's always based on database-users? No, they are not. You could for example put VPD policies on tables that restrict access after a certain time of the day (not caring which user attempts to access the data, using only SYSDATE and a given cut off access time).
    TomVD wrote:
    Is it possible to use the system of VPD's (and maybe Oracle Label Security) with users stored in a table, instead of actual database users?Yes you can.
    VPD allows you to construct a predicate as you would like based on your requirements (you are basically appending a WHERE clause in to every query based on the logic you dictate on the objects and accesses you determine necessary).
    Typically if you're running through a connection pool (as it sounds like you are) you would use an application context to set a specific value (the logging in user) and then validate that against your Users table in whatever fashion tickles your fancy
    [Some Tutorials|http://www.google.ca/#hl=en&source=hp&q=oracle+vpd+tutorial&btnG=Google+Search&meta=&aq=0&oq=oracle+vpd+&fp=8e6c6930b7d53e73] may also be helpful
    and of course .. [The Documentation|http://download.oracle.com/docs/cd/E11882_01/network.112/e10574/vpd.htm]

  • TSQL for capture and insert to a user table when blcoking is happening on a SQL server

    Hi,
    I am searching for a TSQL which will capture the blocking script to a table with execution plan and all other necessaryu details. I tried with below script but its not giving the text for blocked statement
    I t will be nice if i get RequestingText and  BlockingTest
    SELECT @@servername as Instancename,getdate() as [date],session_id,start_time,status,command,database_id,blocking_session_id,
    wait_type,wait_time,last_wait_type,ST.TEXT AS SQL,
    wait_resource,open_transaction_count,cpu_time,total_elapsed_time,reads,writes,logical_reads,text_size from sys.dm_exec_requests SR
    CROSS APPLY SYS.DM_EXEC_SQL_TEXT(SR.SQL_HANDLE) AS ST 
    where blocking_session_id >0
    I tried the below link also, this this script also got blocked
    http://blog.sqlauthority.com/2010/10/06/sql-server-quickest-way-to-identify-blocking-query-and-resolution-dirty-solution/

    But when you run select * from sys.sysprocesses where blocked >0 
    i can see blocking
    and it will be nice if I get RequestingText and BlockingTest
    in the user table
    You can get the requesting text for the spid that is blocked, plus all the other information you get from sys.sysprocesses by
    select SUBSTRING(st1.text, (p.stmt_start/2)+1,
    ((CASE p.stmt_end
    WHEN -1 THEN DATALENGTH(st1.text)
    ELSE p.stmt_end
    END - p.stmt_start)/2) + 1) AS RequestingText,
    p.*
    from sys.sysprocesses p
    CROSS APPLY sys.dm_exec_sql_text(p.sql_handle) AS st1
    where p.blocked <> 0;
    But you will not bee able to get the command that caused the lock that is causing the blocking.  SQL does not keep that information.  For a lock, it only keeps the spid that owns it, what is locked, and the kind of lock.  It does not keep
    the command that caused the lock.  And while you can, at least sometimes get the last command the blocking spid has issued, but that may well not be the command that caused the lock.  The command that caused the lock might be anything the blocking
    spid ran since it entered transaction state.  And since that could be the last command or many, many commands ago, you won't be able to get that information with a query into the system tables and/or views.
    Tom

  • User tables belonging to the dbo schema were found in the database...

    Hi
    I´m running SAP on windows server 2003 R2 x64 sql 2005.
    I have installed a sandbox system based on NW 7.01 SR1 ECC 6.0. It´s only abap.
    After that I wanted to make a system copy of our production system to the the sandbox. So my sql colleague took a full backup of the production database and restored it into the sandbox.
    Now I´m trying to run the system copy installation sapinst - SAP ERP 6.0 EHP4 Ready (Support Release 1) - Sotware life Cycle Options - System Copy - MS SQL Server - Target System Installation - Central System - Based on AS ABAP - Central System...
    I choose custom and say it´s a Homogeneus System Copy (MS SQL Servver-specific)
    After that I choose "Use existing database" but the it say:
    *User tables belonging to the dbo schema were found in the database ES0. SOLUTION: You can only install an SAP system in a database with no user objects belonging to the system schema dbo. If there already is an SAP system in the database (MCOD), or you install a Java Add-In, you might have to convert the existing system to its own schema, or contact your SAP support.*
    I have searched the forums and can´t find anything I can use. I found someone wrote that I should change the control.xml file under sapinst directory:
    Proceed as follows:
    1. Stop SAPinst.
    2. Open the file control.xml in the sapinst log directory and look for the following lines:
    AllowNew: mig ? ?false? : ?true?,
    AllowDboObjects: mig ? ?true? : ?false?,
    3. Change these lines to
    AllowNew: ins ? ?true? : ?false?,
    AllowDboObjects: ins ? ?false? : ?true?,
    4. Save the control.xml, restart SAPinst and choose ?Continue old installation?.
    but it is not helping.
    Please advise me.
    If this is the wrong forum please tell which one is correct.
    Best regards
    Thomas
    Edited by: Thomas Aastrøm on Feb 23, 2012 3:49 PM

    Hi again
    Phase 11 is ok now. We changed the database owner to sap SIDadm.
    But now it fails at phase 12 (Move MS SQL Server objects from one schema to another)
    An error occurred while processing option SAP ERP 6.0 EHP4 Ready - Support Release 1 > Software Life-Cycle Options > System Copy > MS SQL Server > Target System Installation > Central System > Based on AS ABAP > Central System. You can now:
    Choose Retry to repeat the current step.
    Choose View Log to get more information about the error.
    Stop the option and continue with it later.
    Log files are written to C:\Program Files/sapinst_instdir/ERPEhP4/LM/COPY/MSS/SYSTEM/CENTRAL/AS-ABAP/.
    sapinst.log:
    INFO 2012-02-24 13:18:55.427
    Execute step MoveSchema of component |NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|1|0|NW_CreateDBandLoad|ind|ind|ind|ind|10|0|NW_CreateDB|ind|ind|ind|ind|0|0|NW_MSS_DB|ind|ind|ind|ind|2|0|MssSysCopy|ind|ind|ind|ind|10|0|MssSchemaMove|ind|ind|ind|ind|2|0
    ERROR 2012-02-24 13:18:56.349
    FCO-00011  The step MoveSchema with step key |NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|1|0|NW_CreateDBandLoad|ind|ind|ind|ind|10|0|NW_CreateDB|ind|ind|ind|ind|0|0|NW_MSS_DB|ind|ind|ind|ind|2|0|MssSysCopy|ind|ind|ind|ind|10|0|MssSchemaMove|ind|ind|ind|ind|2|0|MoveSchema was executed with status ERROR .
    ERROR 2012-02-24 13:18:56.146
    MDB-05053  Errors when executing sql command: [Microsoft][ODBC SQL Server Driver][SQL Server]Object 'ep0.AFKO' does not exist or is not a valid object for this operation.
    <p> SOLUTION: If this message is displayed as a warning, you can ignore it. If this is an error, contact SAP support.</p>
    INFO 2012-02-24 13:19:02.583
    An error occured and the user decided to retry the current step: "|NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|1|0|NW_CreateDBandLoad|ind|ind|ind|ind|10|0|NW_CreateDB|ind|ind|ind|ind|0|0|NW_MSS_DB|ind|ind|ind|ind|2|0|MssSysCopy|ind|ind|ind|ind|10|0|MssSchemaMove|ind|ind|ind|ind|2|0|MoveSchema".
    ERROR 2012-02-24 13:19:02.770
    FCO-00011  The step MoveSchema with step key |NW_ABAP_OneHost|ind|ind|ind|ind|0|0|NW_Onehost_System|ind|ind|ind|ind|1|0|NW_CreateDBandLoad|ind|ind|ind|ind|10|0|NW_CreateDB|ind|ind|ind|ind|0|0|NW_MSS_DB|ind|ind|ind|ind|2|0|MssSysCopy|ind|ind|ind|ind|10|0|MssSchemaMove|ind|ind|ind|ind|2|0|MoveSchema was executed with status ERROR .
    What to do?
    Best Regards
    Thomas

  • Creating a User Table via DI API

    Hi all,
    I'm using
    SAP Business One 2004A (6.70.185) SP: 00 PL: 07
    and corresponding SAP Business One DI API 2004
    I want to create a user table.
    I try to create it this way:
    I have two functions
    First function to create the table
    Private Function AP_AddOn_CreateTable() As Boolean
       AP_AddOn_CreateTable = True
       Dim oUDT As SAPbobsCOM.UserTablesMD
       Dim sErrMsg As String
       Dim iErrCode As Integer
       Dim iReturn As Integer
       oUDT = oDIComp.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserTables)
       oUDT.TableName = "AP_tbItemCalc"
       oUDT.TableDescription = "ItemCalculation"
       iReturn = oUDT.Add
       If iReturn <> 0 Then
          oDIComp.GetLastError(iErrCode, sErrMsg)
          Message…
          AP_AddOn_CreateTable = False
       End If
       oUDT = Nothing
    End Function
    This works fine
    Then I call a second function to create the user fields
    Private Function AP_AddOn_CreateFields() As Boolean
       AP_AddOn_CreateFields = False
       Dim oUDF As SAPbobsCOM.UserFieldsMD
       Dim sErrMsg As String
       Dim iErrCode As Integer
       Dim iReturn As Integer
       oUDF = oDIComp.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oUserFields)
       oUDF.TableName = "@AP_tbItemCalc"
       'Field1
       oUDF.Name = "ItemCode"
       oUDF.Description = "ItemCode"
       oUDF.Type = SAPbobsCOM.BoFieldTypes.db_Alpha
       oUDF.Size = 20
       iReturn = oUDF.Add()
       If iReturn <> 0 Then
          oDIComp.GetLastError(iErrCode, sErrMsg)
          Message…
          Exit Function
       End If
       'Field2
       oUDF.Name = "ItemName"
       oUDF.Description = "ItemName"
       oUDF.Type = SAPbobsCOM.BoFieldTypes.db_Alpha
       oUDF.Size = 100
       iReturn = oUDF.Add()
       If iReturn <> 0 Then
          oDIComp.GetLastError(iErrCode, sErrMsg)
          Message
          Exit Function
       End If
          next fields …
       AP_AddOn_CreateFields = True
    End Function
    The second function returns on adding the first field, an error, errCode -1120, errMsg ‚Ref count for this object is higher than 0’
    If i close the application after creating the table and then restart the application only executing the second function it works.
    I also tried the example as provided in ‚MetaDataOperations’ and it shows the same behaviour.
    Besides, I’m the only user on the system and no other application is running.
    Kind regards,
    Eduard

    Hi,
    See Add  userfield to usertable 1120 Error  SOLUTION
    HTH
    Ribeiro Santos

  • User Table Key set up in User defined field management

    Dear  Expert,
    what is use of User Table Key set up in User defined field management in SAP B1.
    Thanks.
    Sridharan.R
    Edited by: Sridharan.R on Oct 4, 2011 8:26 AM

    Hi,
    Once a UDF is created and a value is entered in it, the same cannot be retrieved in any of the layouts and reports unless a Key is generated for that UDF. By assigning a Key to that UDF, the same UDF can be used in Crystal Reports or any other Reporting tool to extract its values from SAP. These reporting tools searches the Uniqueness of the UDF Values with this Keys only.
    For eg.: When you develop a report and select a table from which you need the fields to be shown in the layout. In that, the only fields whose keys are generated are only available to use in the report.
    Hope its clear to you.
    Regards,
    Papil

  • User Table

    Hi there,
    I created a user table with 16 fields, if I run a query like "SELECT * FROM myTable" I can see all the column and the data inserted, when I use "Tools-User Tables" and then I select myTable I see only 14 fields and is not matter of resize.
    How come?
    Roberto

    When ur table is being shown with the columns please click the Form Settings on the tool bar and make sure all the cols are Visible and Active.
    Hope it helps,
    Regards,
    Vasu Natari.

  • How to write select query for all the user tables in database

    Can any one tell me how to select the columns from all the user tables in a database
    Here I had 3columns as input...
    1.phone no
    2.memberid
    3.sub no.
    I have to select call time,record,agn from all the tables in a database...all database tables have the same column names but some may have additional columns..
    Eg: select call time, record,agn from ah_t_table where phone no= 6186759765,memberid=j34563298
    Query has to execute not only for this table but for all user tables in the database..all tables will start with ah_t
    I am trying for this query since 30days...
    Help me please....any kind of help is appreciated.....

    Hi,
    user13113704 wrote:
    ... i need to include the symbol (') for the numbers(values) to get selected..
    eg: phone no= '6284056879'To include a single-quote in a string literal, use 2 or them in a row, as shown below.
    Starting in Oracle 10, you can also use Q-notation:
    http://download.oracle.com/docs/cd/E11882_01/server.112/e17118/sql_elements003.htm#i42617
    ...and also can you tell me how to execute the output of this script. What front end are you using? If it's SQL*Plus, then you can SPOOL the query to a file, and then execute that file, like this:
    -- Suppress SQL*Plus features that interfere with raw output
    SET     FEEDBACK     OFF
    SET     PAGESIZE     0
    -- Run preliminary query to generate main query
    SPOOL     c:\my_sql_dir\all_ah_t.sql
    SELECT       'select call time, record, agn from '
    ||       owner
    ||       '.'
    ||       table_name
    ||       ' where phone_no = ''6186759765'' and memberid = j34563298'
    ||       CASE
               WHEN ROW_NUMBER () OVER ( ORDER BY  owner          DESC
                              ,        table_name      DESC
                              ) = 1
               THEN  ';'
               ELSE  ' UNION ALL'
           END     AS txt
    FROM       all_tables
    WHERE       SUBSTR (table_name, 1, 4)     = 'AH_T'
    ORDER BY  owner
    ,       table_name
    SPOOL     OFF
    -- Restore SQL*Plus features that interfere with raw output (if desired)
    SET     FEEDBACK     ON
    SET     PAGESIZE     50
    -- Run main query:
    @c:\my_sql_dir\all_ah_t.sql
    so that i form a temporary view for this script as a table(or store the result in a temp table) and my problem will be solved..Sorry, I don't understand. What is a "temporary view"?

  • List user tables in oracle 9i database

    Hi,
    Im new bi to oracle database...,
    Will anyone provide me the command to list the user tables in oracle 9i database.??.
    im using linux redhat 4.0... and oracle 9i database....
    thanks,
    vasanth....

    user12864080 wrote:
    Hi,
    Im new bi to oracle database...,
    Will anyone provide me the command to list the user tables in oracle 9i database.??.
    im using linux redhat 4.0... and oracle 9i database....
    thanks,
    vasanth....
    SELECT ... FROM USER_TABLES;=================================================
    Learning how to look things up in the documentation is time well spent investing in your career. To that end, you should drop everything else you are doing and do the following:
    Go to tahiti.oracle.com.
    Drill down to your product and version.
    <b><i><u>BOOKMARK THIS LOCATION</u></i></b>
    Spend a few minutes just getting familiar with what is available here. Take special note of the "books" and "search" tabs. Under the "books" tab you will find the complete documentation library.
    Spend a few minutes just getting familiar with what <b><i><u>kind</u></i></b> of documentation is available there by simply browsing the titles under the "Books" tab.
    Open the Reference Manual and spend a few minutes looking through the table of contents to get familiar with what <b><i><u>kind</u></i></b> of information is available there.
    Do the same with the SQL Reference Manual.
    Do the same with the Utilities manual.
    You don't have to read the above in depth. They are <b><i><u>reference</b></i></u> manuals. Just get familiar with <b><i><u>what</b></i></u> is there to <b><i><u>be</b></i></u> referenced. Ninety percent of the questions asked on this forum can be answered in less than 5 minutes by simply searching one of the above manuals.
    Then set yourself a plan to dig deeper.
    - Read a chapter a day from the Concepts Manual.
    - Take a look in your alert log. One of the first things listed at startup is the initialization parms with non-default values. Read up on each one of them in the Reference Manual.
    - Take a look at your listener.ora, tnsnames.ora, and sqlnet.ora files. Go to the Network Administrators manual and read up on everything you see in those files.
    - When you have finished reading the Concepts Manual, do it again.
    Give a man a fish and he eats for a day. Teach a man to fish and he eats for a lifetime.
    =================================

  • How to catch events on user tables forms?

    Hi all,
    Is there any way to catch the events on user defined tables' form which opens from Tools-User Tables? The form Id we get is not unique so we can't initialize the form with that ID or put it in  an If  loop for pval.formUId.
    any clues?
    Thanks in advance.....

    Hi Binita,
    The UDT form should have a form type in the format:
    110xxx
    where xxx is the value in the TblNum field in the OUTB table (eg 110015 if the TblNum field is 15).
    Therefore, you can query the OUTB table for your UDT name and get the correct TblNum value and then calculate the correct form type for your table. If you want to filter events then you'll need to run this query as your addon starts and dynamically add the correct event types and filters to your addon.
    Kind Regards,
    Owen

  • User Tables form

    Hi,
    Is it possible to Add combo box in the existing field on User table form through UI API? I want to add combo box in UDT for selecting Item code.
    thanks in advance
    Denis

    Hi Denis,
    The first approach I would try is a formatted search fired when Shift+F2 is clicked. Cheap and easy.
    In a user defined form, you could use datasources to get this. But in the default form I don´t think you could do it using datasources. Perhaps I´m wrong.
    If you are in 2005, you could try the ChooseFromList object to get what you need. More elegant, but more work.
    Hope helps,
    Ibai Peñ

Maybe you are looking for

  • Getting rgb values from BufferedImage

    BufferedImage.getRGB(int x, int y) returns the colour of an image pixel as an integer. My problem is that i need the seperate red/blue/green components of this. Does anyone know how I can get these? Thanks.

  • LMS 2.6 and ACS 4.2 compatible with Windows 2008 R2 Active Directory?

    Hi, We are planning to upgrade CORP Domain from Windows 2003 Active Directory Schema to Windows 2008 R2 Active Directory Schema. I wanted to know if the following applications which are installed on windows (domain member servers) are compatible with

  • Material autorization in requisition order

    Hi, I want to restrict autorization to use a material in a requisition order. What I have to do to make the user authorized or not creating a purchase order for this material..? Thanks for your reply.. Rgards,

  • Maverick 10.9.5 Software Update not being listed for clients

    I have Software Update and Caching enabled on an OSX 10.9.5 machine. It has downloaded the 10.9.5 update, but when I run software update on our client computers, the update isn't being shown. I'm feeling like none of the updates are being shown, not

  • Help with updates ASAP!

    I recently bought Photoshop Lightroom 5 and I am trying to install on my MAC desktop. I am not really good with MACs so I don't know anything about the updates and what not. It is saying I need 10.7.0 How do I get this so I am able to download my pho