How to create user in workspace using command line with Internal APEX

Hi fellows,
I'm newbie with APEX and my i try doing something different. I need to build one application in Internal for create users in another workspaces. So, for do this, need use command line and PL/SQL code.
I know exists a CREATE_USER procedure. But, this procedure just create a user in Internal, not in workspace, like i want.
Its possible? Someone can help me?
Example of create_user procedure:
BEGIN
  APEX_UTIL.CREATE_USER(
     p_user_name => 'NEWUSER2',
     p_first_name => 'FRANK',
     p_last_name => 'SMITH',
     p_description => 'Description...',
     p_email_address => '[email protected]',
     p_web_password => 'password',
     p_developer_privs => 'ADMIN:CREATE:DATA_LOADER:EDIT:HELP:MONITOR:SQL',
     p_default_schema => 'MY_SCHEMA',
     p_allow_access_to_schemas => 'MY_SCHEMA2',
     p_change_password_on_first_use => 'N',
     p_attribute_01 => '123 456 7890');
END;
Thank you.

Did you try it like this?
DECLARE
   l_workspace_id      number;
BEGIN
    l_workspace_id := apex_util.find_security_group_id (p_workspace => 'MY_WORKSPACE_NAME');
    apex_util.set_security_group_id (p_security_group_id => l_workspace_id);
  APEX_UTIL.CREATE_USER(
     p_user_name => 'NEWUSER2',
     p_first_name => 'FRANK',
     p_last_name => 'SMITH',
     p_description => 'Description...',
     p_email_address => '[email protected]',
     p_web_password => 'password',
     p_developer_privs => 'ADMIN:CREATE:DATA_LOADER:EDIT:HELP:MONITOR:SQL',
     p_default_schema => 'MY_SCHEMA',
     p_allow_access_to_schemas => 'MY_SCHEMA2',
     p_change_password_on_first_use => 'N',
     p_attribute_01 => '123 456 7890');
END;

Similar Messages

  • How to create users and groups using WLST Offline with Weblogic 8.1.4

    How to create users and groups using WLST Offline with Weblogic 8.1.4?
    Any ideas?

    Hi this is how i created a user using WLST Offline?
    cd('/Security/' + domainName)
    # Delete the default user name weblogic
    # incase you want to remove the defualt user weblogic
    delete('weblogic','User')
    # Creating a new user defined
    create(userName, 'User')
    # Setting the password of the user you created.
    cd ('/Security/' + domainName + '/User/' + userName)
    cmo.setPassword(password)
    Regards
    Makenzo

  • How to call a ODI Job using Command line?

    Hello All,
    Please help me on this..
    How to call an ODI Job using Command line?
    Thanks
    Ravikiran

    Generate a scenario of your package. Then go to <ODI_HOME>/oracledi/agent/bin in command prompt and invoke startscen command .
    startcmd.sh OdiStartScen -SCEN_NAME=scn_load_data -SCEN_VERSION=001 -CONTEXT=GLOBAL -AGENT_CODE=odiSchedAgent001
    Bhabani
    http://dwteam.in

  • How to install adobe flash player through command line with some script

    Hi Guys,
    Do you know how to install adobe flash player through command line with some script?
    Thanks,
    Galina

    Windows. I tried silent install  with "install_flash_player.exe /install" but it works only with one file that I downloaded from adobe.com - "install_flashplayer10_mssd_aih.exe". But it is possible to download this last file only one time, every next time it redirects me to download install_flash_player.exe file.

  • How can I create a NetBoot image using command line tools?

    Is it possible to create a NetBoot image entirely using command line tools?
    (That is, without using the SystemImageUtility)
    If so, are there reasonable instructions posted somewhere?
    I don't believe I can use SystemImageUtility with my current setup,
    but I would be happy to hear how I could:
    I have a set of Xserve clusternodes but without optical drives or video cards.
    One node acts as the head, running DHCP, DNS, OpenDirectory, Xgrid.
    They are wired to a gigabit switch.
    I have a PowerBook connected on the subnet which has ServerAdmin Tools installed.
    I don't think when I run SystemImageUtility on my PowerBook that I can successfully image one of the clusternodes disks over the network.
    I have tried to start one node in target(Firewire) mode, connect it via Firewire
    to the head node, and run hdiutil from the head node to make a complete disk image of the clusternode's drive.
    But a NetBoot image requires the whole nbi file, right?
    Could I then use copy this disk image to my PowerBook and use SystemImageUtility on my PowerBook to create a NetBoot image from it?
    I really have tried to read the PDFs, but I found the section on System Imaging in the Command Line Reference rather unhelpful.
    Thanks for anyones help.
    dmaus
      Mac OS X (10.4.4)  

    To create a NetBoot image, you could just put the cluster node in target mode and attach it to your PowerBook. Then use SIU to create the NetBoot image.
    If you're trying to create a backup image of the disk, use hdiutil, or put in in target mode and create the image with Disk Utility.

  • How to use command line with acrobat to extract page(s) from pdf file?

    I have adobe acrobat, and have a pdf file with over 500 pages. I need to extract small chunks of pages from it as seperate pdf files. I was hoping I could use command line interface to do this faster.
    Something like:
    acrobat src des start end
    so for example
    adobe file.pdf my_folder 3 5
    Is this possible? There are many chunks and I don't want to manually do it for every chunk. Command line would be much easier...
    Thanks

    I can't find any programs... sorry.
    Can you create one for me please.
    It should at least have these 5 arguments: (well the first one is not neccessary since were not using acrobat anymore...)
    [program] [src path/src file] [destination path/file name] [start page (inclusive)] [end page (inclusive)]
    for example:
    acrobat ./my_file.pdf ./my_folder/chunk1.pdf 3 5
    if start page == end page, then it only extracts that one page.
    So this way I can just stack these comands on a .bat file or something (maybe like 100 commands), then run the bat file, and it will create all the files.
    Thanks for doing this, it is appreciated.

  • How to purge data cache table using command line

    Hi:
    Is there a way to purge the data cache table using command line?
    thanks!

    Thanks, Mike.
    I'm thinking about the ldconsole provided with ALDSP.
    The ldconsole has a link for purging the cache. Is there anything I can leverage from there? Is it a JMX component that I can call?

  • How to create users in Weblogic using an API

    Hi All,
    I have a requirement where i need to add the users in security realm without using Weblogic Console.Is there any API or program which lets us to create the users and set it in realm.
    Please suggest!!
    Thanks.

    Hi,
    You can follow the blog written by Middleware magic team
    Creating Users And Groups
    http://middlewaremagic.com/weblogic/?p=4981
    Deleting Users And Groups
    http://middlewaremagic.com/weblogic/?p=5234
    Users List from Security Realm
    http://middlewaremagic.com/weblogic/?p=6678
    Hope this will be helpful
    Regards
    FAbian

  • How to create an alias from the command line

    Hi
    I would like to know how to create an alias (for a file, not a command) from the command line. I don't want to use the ln command, as an alias has more interesting features than soft/hard links... Is there an Apple specific tool to do this?
    Thanks
    -Jerome
      Mac OS X (10.4.10)  

    The only straightforward way that I am aware of for creating a "Finder" alias from the command line is using AppleScript via 'osascript'. Of course, it's not really a command line solution since the "Finder" has to be running. Anyway, something along the lines of:
    <pre style="overflow:auto; padding: 5px; width: 500px ; font-size: 10px; border:1">osascript -e 'tell application "Finder" to make alias file to POSIX file "/full/path/to/file" at POSIX file "/full/path/to/folder"'</pre>

  • How to create a listener service at command line?

    Hello,
    I want to create and configure a listener service in an installation script.
    lsnrctl does not support the creation of this service.
    netca or netmgr require user interactions.
    Is there an other tool to create the listener service or is it possible to use netca/netmgr with special options in a command line mode?

    Thank you very much - it works.
    When I execute the command
    "lsnrctl start"
    I get the error message
    "Failed to open service <OracleOraDb10g_home1TNSListener>, error 1060."
    but the service is created and is running.
    So the error message can be ignored.

  • How to Create User Defined Template in Back Office with Labels and Tags App

    Hello,
    Can anyone help me in creating a user defined template in Back Office with Labels and Tags Application. I'm currently using version 13.2.?
    Kindly help me out asap.
    Thanks,
    Monica.

    Hi Monica
    Third party software is available,from AccessVia, that can be used to create and update templates. Sample sample sqt can help you to understand the required inputs (batchID, templateID, departmentID, locale).
    Thanks
    Himanshu

  • How can I load PCL font using command line?

    We have a software that requires a signature font to be uploaded to the printer beforehand.  if the printer power cycles, the font is lost and paper is wasted.  This usually happens when a brown out occurs overnight.
    Our font vendor has a command line windows software that can upload the font to the printer.  It costs 100.00. 
    I'd really love to find a way to upload this file using linux.  The page is generated on linux so i could incorporate the command into that process.
    Anyone know of free software to do this on linux or windows?  or maybe programming documentation?

    i think i found the answer on another site
    http://mdn.morovia.com/kb/Download-Select-Remove-PCL-Fonts-10002.html
    Configuration 2: Network Printer Server
    When the printer is connected to a TCP/IP network directly, the best method is to send commands through lpr command. A TCP/IP device may be identified with a full qualified DNS name, or an IP address. In our test lab, we assigned our network printer a fixed IP address 192.168.1.22, and we use this address in the examples below. Inlpr manual page, it is also referred as Printer Name.
    Another name you will need is Queue Name. The queue names are names assigned to the “processors” in the print server. Many print servers and network printers hardcode their queue names. Some allow you to define your own queue. On HP JetDirect printer servers, the raw PCL queues are named as raw, raw1, raw2 and raw3. In this article we use rawas the queue name.
    Note thatlpr command only accepts 1 file at a time. However, the step1 and step2 commands must be sent in one stream, otherwise the printer discards them altogether. As a result, you will need to merge those three files into one first. On Windows, you can use copy command:
    copy /b C80D.txt +mrvcode39_4pitch.sfp +c5F.txt total.bin
    On Linux/Unix platforms, use cat command:
    cat c80D.txt mrvcode39_4pitch.sfp c5F.txt > total.bin
    Now we can send these files (Windows):
    lpr -S 192.168.1.22 -P raw -ol total.bin lpr -S 192.168.1.22 -P raw -ol data.txt
    You need to replace the IP address, the queue name and the file name with the appropriate ones in your environment.
    On Linux/UNIX platforms, things are more complicated. The configuration varies from platform to platform. Generally you need to set up the printer first. On RedHat Linux, this can be done using printtool. You assign a printer name (queue name) in the configuration, and you use this name in lpr command. Assume that the name is HPPrinter, the lpr command on RH Linux becomes:
    lpr -P HPPrinter -o raw total.bin lpr -P HPPrinter -o raw data.txt

  • How to create analytic privileges from sql command line in hana studio?

    I want to create a bunch of analytic privileges, activate them and assign it a roles. I was wondering if there is a method where I can create these analytical privileges directly from sql?

    Hi Krishna,
    Thanks for the reply.
    The use case is to create a bulk analytical privileges on the pre-existing analytical or calculation views and I'm failing to create it using the simple CREATE STRUCTURED PRIVILEGE.
    The security guide shows below mentioned as the syntax but I'm failing to create it through that:
    CREATE STRUCTURED PRIVILEGE AP_SALES_1 FOR SELECT ON TABLEOWNER.VIEW_SALES WHERE REGION IN ('DE','UK') OR PRODUCT = 'CAR';
    It gives me this error -
    SAP DBTech JDBC: [257] (at 44): sql syntax error: incorrect syntax near "FOR": line 1 col 44 (at pos 44)

  • How to create dynamic HTML page using PL/SQL code in APEX.

    hello,
    I am woking on one APEX application in which i want to create one dynamic HTML page on button press using PL/SQL code.
    Thanks

    It is possible to create HTML page with dynamic content. One way would be creating hidden field (e.g. P1_HTML on page 1) with dynamic HTML and on button click you redirect to page 2 and pass P1_HTML item value to item P2_HTML on page 2. On page you must have PL/SQL region. You can then render your dynamic HTML with code:
    htp.p(:P2_HTML);
    Don use APEX URL for passing HTML value. Problem and solution is described here: http://blog.trent-schafer.com/2011/04/03/dont-pass-string-parameters-in-the-url-in-apex-its-a-bad-idea/
    Edited by: MiroMas on 3.2.2012 3:20

  • How to register a DIP profile using command line

    Hi All,
    Am trying to register a profile in OID11.1.1.5 as shown below, but i face the below error message.
    I have set the JAVA_HOME, PATH, ORACLE_HOME, WL_HOME as suggested in document.
    Any pointers would be helpful
    [orasso@company bin]$ ./manageSyncProfiles -h cdceasso1.company.com -p 7005 -D weblogic -ENABLE
    Exception in thread "Main Thread" java.lang.NoClassDefFoundError: oracle/ldap/odip/wlst/ManageSyncProfiles
    Caused by: java.lang.ClassNotFoundException: oracle.ldap.odip.wlst.ManageSyncProfiles
    at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:305)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:246)
    Could not find the main class: oracle.ldap.odip.wlst.ManageSyncProfiles. Program will exit.
    [orasso@company bin]$

    Generate a scenario of your package. Then go to <ODI_HOME>/oracledi/agent/bin in command prompt and invoke startscen command .
    startcmd.sh OdiStartScen -SCEN_NAME=scn_load_data -SCEN_VERSION=001 -CONTEXT=GLOBAL -AGENT_CODE=odiSchedAgent001
    Bhabani
    http://dwteam.in

Maybe you are looking for