Function privileges

what privileges do i need to grant to a user so that they can create a function in their schema?
Never mind didnt realize that create procedure granted that privilege.
Message was edited by:
user457357

Grant execute on <function_name> to <user/role_name>;

Similar Messages

  • Demonstrating PL/SQL Functions Using SQL Developer

    Good afternoon,
    I'm starting to write some PL/SQL functions to replace some of the SQL that I use most frequently.  A couple of very simple examples would be:
    create or replace function func_test (p_1 number) return number
    is
    x number;
    y number;
    begin
    x :=1;
    y :=2;
    return p_1 * x * y;
    end func_test;
    create or replace function func_test2 (p_1 varchar2) return varchar2
    is
    return_val varchar2(10);
    begin
    select p_1 into return_val from dual;
    return return_val;
    end func_test2;
    However, at my workplace I haven't been granted create function privileges yet until I can demonstrate some examples, which is understandable.
    For the time being, without these privileges, is there a way I can build/test functions in principle locally using SQL Developer without the need to write the functions to our database? I.e. can I demonstrate the above in SQL Developer, but without wrapping in create or replace syntax?
    I hope this isn't too vague.
    Using Oracle 11gR2 (not logged in to workplace database at the moment for specific version no.)
    SQL Developer 3.4
    Thanks,
    TP

    sb92075 02-Nov-2013 19:12 (in response to TinyPenguin)
    populating test DB with data is a solvable problem.
    You don't need client data to test code (functions).
    You only need sample test data; which generally is less than a few dozen records per table.
    Absolutely, of course. Our client database is pretty messy though, and includes data prior to the implementation of more recent business rules that I need to take account of. Useful perspective though, thanks.
    rp0428 02-Nov-2013 19:14 (in response to TinyPenguin)
    Sure, but then I wouldn't have access to all the data in our client database to test functions under various circumstances.
    Huh? Why not? It's your database so what keeps you from creating a database link to your client database where all the data is?
    Also, I suppose it's not good practice to constantly write/replace/drop functions to/from a database when developing them? Better to test the function in principle and then write to the database?
    Huh? Why not? What you think a dev database is for if not for development?
    Based on your two posts so far in this thread it's understandable why they don't want to give you privileges yet. Those sample 'functions' you posted are NOT a good use for functions.
    In sql developer you can just create and save the queries you use most often. There is no need to create functions for that.
    But if you do need an anonymous function now and then just create one using sql*plus syntax:
    Our IT department are pretty sensitive about how they allow access, even to the dev environment. As you've identified, I'm not naturally a programmer so the option to play around with the data to develop some representative examples about how we can simplify and devolve SQL reporting to more members of staff is useful to me. I just wrote those two function quickly for the purpose of posting some sample data, which I thought would be helpful. Thanks for illustrating how to return their output using an anonymous block.
    FrankKulash 02-Nov-2013 19:13 (in response to TinyPenguin)
    Hi,
    The obvious solution is to get the privileges.  If your employer really wants you to do something, they need to give you the necessary privileges to do it.  It's silly for them to tell you to do something, but refuse to let you do it.
    Failing that, you can install Oracle on your own machine, as suggested above.  It's free and legitimate if you're only using it for learning and developing.  Oracle Express Edition is very easy to install.
    As a last resort, you can write functions and procedures that are local to an anonymous block, like this:
    Thanks Frank. Yeah I'm going to speak with our DBA next week about privileges. I've got XE/SQL Developer installed on my own computer - I wrote those sample functions using them - I just wasn't sure how to call/return anonymous blocks as both you and rp identified to develop at work as an interim solution.
    Thanks a lot All,
    TP.

  • Trusted code for importData function

    Hi,
        I want to call xfa.host.importData with file path. I understand that this can be called with copying .js file under user's ApplicationData/Adobe/Javascript folder. I tried to add following code in JS to make it a trusted code, but I get exception in Javascript Debugger.
    Code in JS file kept in Javascript folder
    function importXML()
          xfa.host.importData("3dPdfReport_1_data.xml");
    myFunc = app.trustedFunction( function ()
          // privileged and/or non-privileged code here
          app.beginPriv();
          importXML();
          app.endPriv();
          // privileged and/or non-privileged code here
    I called myFunc in docReady event. But I get following exception.
    xfa is not defined
    3:XFA:form1[0]:#subform[0]:ListBox1[0]:docReady
    If I call xfa.host.importData(""); in docReady event then it works fine by showing file dialog to choose the XML file to import. Please let me know if I'm missing something here.
    Thanks
    raghuvan

    Private Sub Duplicate(ByVal FormUID As String, ByVal strDocNum As String)
            objRecord = objSBOAPI.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset)
            strQuery = "SELECT * FROM [@Tablename] WHERE DocEntry = '" & strDocNum & "'"
            objRecord.DoQuery(strQuery)
            If objRecord.RecordCount > 0 Then
                strQuery = "UPDATE [@Tablename] SET Status = 'C' Where DocEntry = '" & strDocNum & "'"
                objRecord = objSBOAPI.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset)
                objRecord.DoQuery(strQuery)
                strDocNum = ""
            End If
        End Sub
    With Regards
    Micheal

  • Versioning of BPMN Process Models and Change Management

    Hi all,
    Can any of you please provide insight on how can we do the following change management activities?
    1. Version Control of BPMN Models synchronized with the change management activities
    2. In the Help documentation, two roles called Improvement Manager and Modeler were mentioned. How do we define their roles in the Administration? In User Management I see only one function privilege "Change Management" and both Improvement Manager and Modeller will have this privilege. Than how they are distinguished in their roles?
    3. Does it also support a work flow and notification mechanism?
    Thanks in anticipation.
    Best regards,
    Raja Mohan

    Hi,
    I'd just like to add some quick points that you need to consider:
    Implicit version control is not supported in the current release (10.1.3.4) but it will be supported in Release 11 (upcoming release). There are some workarounds/alternatives like attributes (Status, Since/on, Released on, Released by, Release) and external version control system combined with the XML import/export functionality (Re: Control Version
    The Change Management can be used to describe upcoming modeling tasks within the Business Process Architect. This implicates changes from IT, adding new objects, adjustments of models or control flow, etc... Especially it is suitable to document suggestions for future model improvements.
    "Does it also support a work flow and notification mechanism?"I think this might be a governance topic that has to be created on your own.
    Hope it helps,
    Danilo

  • Create New NON SA user with Priviledges

    Hi all,
    I want to create new non sa user login with openrowset function privileges for read/write operation on excel sheet file.
    So please can nay one give me example or script to create non sa user login with above privileges.
    Thanks in advanced.

    Thanks to all for reply.
    I give ADMINISTER BULK OPERATIONS permission to user I also create linked server with required credentials but does not work. With sa
    credentials it work.
    I execute following statement
    select * from openrowset('Microsoft.ACE.OLEDB.12.0',
    Excel 12.0;HDR=Yes;Database ='C:SAMPLES\Northwind.xls';select * from [sheet1$])
    when I execute above statement it gives me error.
    please reply.
    Hi AK9841,
    Please review the detailed answer in your another thread,
    https://social.technet.microsoft.com/Forums/en-US/59710c1d-6bfe-42dc-ac80-643b9ae7f8f0/create-new-non-sa-user?forum=transactsql
    Thanks,
    Lydia Zhang

  • What problem may arise if we remove "system" account from ACL on files & folders

    hi friends
    as wee see, in the ACL of all files & folders ,the account called "system" exist & usually has full permission.
    what is the usage or benefit of this here ?  if we remove system from here, which problems may occur? if possible please give me some examples. 
    thanks in advance

    Hi,
    We have an old article for explaining this question:
    How the System account is used in Windows
    http://support.microsoft.com/kb/120929/en-us
    The system account and the administrator account (Administrators group) have the same file privileges, but they have different functions. The system account is used by the operating system and by services that run under Windows.
    There are many services and processes within Windows that need the capability to log on internally (for example during a Windows installation).
    The system account was designed for that purpose; it is an internal account, does not show up in User Manager, cannot be added to any groups, and cannot have user rights assigned to it. On the other hand, the system account does show up on
    an NTFS volume in File Manager in the Permissions portion of the Security menu. By default, the system account is granted full control to all files on an NTFS volume. Here the system account has the same functional privileges as the administrator account.
    NOTE: Granting either account Administrators group file permissions does not implicitly give permission to the system account. The system account's permissions can be removed from a file but it is not recommended.
    On shared folders if there is no system file stored inside, you can remove SYSTEM account from NTFS permission.
    If you have any feedback on our support, please send to [email protected]
    hi shaon
    nice. thank you very much
    best regards

  • Error in reconcilation Function - Job "Reconcile roles and privileges"

    SAP NW 7.0 SP2 Patch 3
    Roles contain Privileges
    Help file says: "If you are using roles and privileges, you will need to perform a reconciliation of the roles/privileges assigned to the users in the identity store after the roles are modified. "
    Job imported as described.
    When I let the job run on the ID-Store, for each entry, the following error message occurs:
    runFunctionsInString($FUNCTION.reconcile( MSKEY )$$) got exception
    org.mozilla.javascript.NotAFunctionException: reconcile( MSKEY )
    ...where MSKEY is, of course, the MSKEY of the entry.
    If I let run the job with the Windows-Dispatcher and as a VB-script, it produces no error; however, in the output file, there are a lot of Messages like
    "!ERROR: Invalid use of Null"
    Only some entries (of Type MX_PERSON) show the "Priviliege added: (...)" output. But the job does not add the Privileges assigend to the role, as it should.
    So, I would suggest that one redefines the SQL-Query of the Job so that it runs only on MX_PERSONS. But then, still, in my case, it does nothing.
    Has anyone better experiences with the Job?
    Edited by: Thomas P. Felder on Sep 25, 2008 10:32 AM

    The job when imported by default uses java runtime engine but the script is written in vbscript syntax so you have to change the engine or the script syntax.
    When you did your select statement did you use SELECT DISTINCT.  That will also cause errors.  I do not narrow the entry type to MX_PERSON.
    I'm installing the patch now;  I will see if I get any errors.

  • Providing execute privileges to function in a package.

    Hi All,
    I want to provide execute privilege to a function in a package to other schema.
    Owner wedb
    Package MASTER
    function in a a package is convert_function
    GRANT EXECUTE ON wedb.MASTER.convert_function to HRDB;I got the blow error.
    ORA-00905: missing keyword
    Please help me .
    Thanks.

    user9077483 wrote:
    Hi All,
    I want to provide execute privilege to a function in a package to other schema.
    Owner wedb
    Package MASTER
    function in a a package is convert_function
    GRANT EXECUTE ON wedb.MASTER.convert_function to HRDB;I got the blow error.
    ORA-00905: missing keyword
    Please help me .
    Thanks.You cant grant access to a portion (In your case a function) of a package. You need to grant access to the entire package.

  • Privilege need to create functional index

    Greeting gurus?
    What privilege I needed for create functional index
    I am writing a definer righted procedure to create index however when creating functional index, it gives me ora-0131 insufficent but unique, bitmap and reverse index works
    and I granted create any index and create any indextype already. what else is missing ?

    CREATE INDEX
    To create a function-based index, in addition to the prerequisites for creating a conventional index, if the index is based on user-defined functions, then those functions must be marked DETERMINISTIC. Also, you must have the EXECUTE object privilege on any user-defined function(s) used in the function-based index if those functions are owned by another user.

  • Error 1297 A privilege that the service requires to function properly does not exist in the service account configuration

    When I try to start Windows installer in Services.msc, it gives me this error Error 1297 A privilege that the service requires to function properly does not exist in the service account configuration. How do I fix this? I am running Windows 7 ultimate.

    Hi,
    Based on the error code, we can use the Services Microsoft Management Console (MMC) snap-in (services.msc) and the Local Security Settings MMC snap-in (secpol.msc) to view
    the service configuration and the account configuration for Windows Installer service.
    Besides, the following two threads focus on the similar issue and can be referred to as reference.
    Error 1297: "ERROR_INCOMPATIBLE_SERVICE_PRIVILEGE 1297” FTP service in Windows 7 computer
    http://social.technet.microsoft.com/Forums/windows/en-US/52329b48-1ba9-4cab-a6b2-efd8db173625/error-1297-errorincompatibleserviceprivilege-1297-ftp-service-in-windows-7-computer?forum=w7itpronetworking
    Service fails to start, error 1297 and 7000
    http://social.technet.microsoft.com/Forums/windowsserver/en-US/419ba006-4413-4036-8c49-252b08593131/service-fails-to-start-error-1297-and-7000?forum=winserverDS
    Hope it helps.
    Best regards,
    Frank Shen

  • How to grant privilege for a specific function?

    Hello all,
    I wonder if exists a privilege, that i could grant to a user, just to run a specific function.
    I searched in dba_sys_privs something about it but, returned nothing.
    13:38:10 brunos@fastora1> select * from dba_sys_privs where privilege like '%FUNCTION%';
    GRANTEE PRIVILEGE ADMIN_OPTION
    Do you guys have any idea for my issue ?
    Thanks in advance.

    BSalesRashid wrote:
    Hello all,
    I wonder if exists a privilege, that i could grant to a user, just to run a specific function.
    I searched in dba_sys_privs something about it but, returned nothing.
    13:38:10 brunos@fastora1> select * from dba_sys_privs where privilege like '%FUNCTION%';
    GRANTEE PRIVILEGE ADMIN_OPTION
    Do you guys have any idea for my issue ?
    Thanks in advance.GRANT EXECUTE ON SPECIFIC_FUNCTION TO NEWBIE_USER;

  • Report.save() "security restricted" even if in privileged function??

    It may be that I am missing something, but even if I put the save() method of the in a privileged application-level function, I get the "Security settings prevent access to this property or method" error message. Must this be considered a bug?
    In another context, the saveAs() Doc object method works properly.
    I am testing in Acrobat Pro 9 on Mac.
    Any useful hint is highly appreciated.
    Max Wyss.

    First, I thought that there is not really any connection between this statement and the problem described.
    However, at a second thought, it is.
    The connection is that the error message provided by Acrobat is COMPLETELY, AND TOTALLY WRONG!!!!
    In both cases, the correct error message should be something like "filespec invalid"!
    Besides making the "security guys" look "good", those misleading error messages are of no use. Acrobat is a development tool, and as such, error messages MUST be as precise as possible.
    Max Wyss.

  • Privileges granted to roles sometimes are not effective(not functioning)?

    Hello,
    I have experienced where roles where granted and privileges granted to the roles. The roles are they granted to certain users. But when these users try to perform dml/ddl, they get insufficient priviledges even though these users were granted the roles which do contain the correct priviledges. Why are some priviledges not functioning when they are granted to the roles? To resolve, direct grants were granted to the users. But why aren't they working through the roles? Thank you.

    Hi watson2000 ,
    can you send the scripts...what you have performed.
    Since, I did not faced any problem with granting privliges and roles.
    If you provide some information on that (little more) whjat you have done so that we can help you out..
    Thanks
    Pavan Kumar N

  • Granting Privileges on Functions

    Hi,
    I have created two functions and am using them in a SQL statement. I would like to run the statement in apps mode, however the functions have been created under another account. I get this error message when running the statement in apps mode:
    ORA-00904: "FUNC_GET_PO": invalid identifier
    00904. 00000 - "%s: invalid identifier"
    *Cause:   
    *Action:
    Error at Line: 12 Column: 86
    I can run the SQL under the user account:
    SELECT cck.concatenated_segments AS "Segment" ,
    cc.code_combination_id AS "CCID",
    jeh.je_header_id AS "Header ID",
    jel.je_line_num AS "Line Number",
    NVL ( src . user_je_source_name , '**********' ) AS "Source" ,
    NVL ( cat . user_je_category_name , '**********' ) AS "Category" ,
    jel . period_name AS "Period Name" ,
    i.gl_date AS "GL Date",
    s.vendor_name AS "Vendor Name",
    s.segment1 as "Supplier No",
    eul_fin_us.func_get_po(i.invoice_id, cc.code_combination_id) "PO No",
    eul_fin_us.func_get_po_requester(i.invoice_id, cc.code_combination_id, func_get_po(i.invoice_id, cc.code_combination_id)) "PO Requester",
    i.invoice_num AS "Transaction Number",
    i.invoice_date AS "Invoice Date",
    jel . description AS "Description" ,
    jel.accounted_dr AS "Debit" ,
    jel.accounted_cr AS "Credit" ,
    NVL(jel.accounted_dr, 0) - NVL(jel.accounted_cr, 0) AS "Net Amount"
    FROM apps.gl_code_combinations cc ,
    apps.gl_code_combinations_kfv cck,
    apps.gl_je_lines jel ,
    apps.gl_je_headers jeh ,
    apps.gl_je_batches jeb ,
    apps.gl_je_categories cat ,
    apps.gl_je_sources src,
    apps.gl_import_references r,
    apps.xla_ae_lines al,
    apps.xla_ae_headers ah,
    apps.xla_events e,
    xla.xla_transaction_entities te,
    apps.ap_invoices_all i,
    apps.ap_suppliers s
    WHERE ( cc.CHART_OF_ACCOUNTS_ID = 50328
    AND jeh.LEDGER_ID IN
    (SELECT acc.ledger_id
    FROM apps.gl_access_set_ledgers acc
    WHERE acc.access_set_id = 1000
    AND jel.code_combination_id = cc.code_combination_id
    AND cck.code_combination_id = cc.code_combination_id
    AND jel.status
    || '' = 'P'
    AND ( jel.accounted_dr != 0
    OR jel.accounted_cr != 0 )
    AND jeh.je_header_id = jel.je_header_id
    AND jeh.actual_flag = 'A'
    AND 1 = 1
    AND jeh.currency_code != 'STAT'
    AND jeb.je_batch_id = jeh.je_batch_id
    AND jeb.average_journal_flag = 'N'
    AND src.je_source_name = jeh.je_source
    AND cat.je_category_name = jeh.je_category
    AND r.je_header_id(+) = jel.je_header_id
    and r.je_line_num(+) = jel.je_line_num)
    and ( :period_name = jel.period_name
    AND al.gl_sl_link_id(+) = r.gl_sl_link_id
    AND al.ae_header_id = ah.ae_header_id(+)
    AND al.application_id = ah.application_id(+)
    AND ah.application_id = e.application_id(+)
    AND ah.event_id = e.event_id(+)
    AND e.application_id = te.application_id(+)
    AND e.entity_id = te.entity_id(+)
    AND NVL(te.source_id_int_1,-99) = i.invoice_id(+)
    AND i.vendor_id = s.vendor_id(+) )
    AND ( jel.ledger_id = 2041)
    ORDER BY src.user_je_source_name ,
    cat.user_je_category_name ,
    jeb.name ,
    jeh.name ,
    cck.concatenated_segments ,
    jel.je_line_num
    Please note EUL_FIN_US is the user account, I have granted execute priviliges on both functions to user APPS but still no luck. Can anybody help?
    Thanks

    Hi,
    one of the schema prefix is missing, (in the func_get_po_requester function call), use this version:
    SELECT cck.concatenated_segments AS "Segment" ,
    cc.code_combination_id AS "CCID",
    jeh.je_header_id AS "Header ID",
    jel.je_line_num AS "Line Number",
    NVL ( src . user_je_source_name , '**********' ) AS "Source" ,
    NVL ( cat . user_je_category_name , '**********' ) AS "Category" ,
    jel . period_name AS "Period Name" ,
    i.gl_date AS "GL Date",
    s.vendor_name AS "Vendor Name",
    s.segment1 as "Supplier No",
    eul_fin_us.func_get_po(i.invoice_id, cc.code_combination_id) "PO No",
    eul_fin_us.func_get_po_requester(i.invoice_id, cc.code_combination_id, eul_fin_us.func_get_po(i.invoice_id, cc.code_combination_id)) "PO Requester",
    i.invoice_num AS "Transaction Number",
    i.invoice_date AS "Invoice Date",
    jel . description AS "Description" ,
    jel.accounted_dr AS "Debit" ,
    jel.accounted_cr AS "Credit" ,
    NVL(jel.accounted_dr, 0) - NVL(jel.accounted_cr, 0) AS "Net Amount"
    FROM apps.gl_code_combinations cc ,
    apps.gl_code_combinations_kfv cck,
    apps.gl_je_lines jel ,
    apps.gl_je_headers jeh ,
    apps.gl_je_batches jeb ,
    apps.gl_je_categories cat ,
    apps.gl_je_sources src,
    apps.gl_import_references r,
    apps.xla_ae_lines al,
    apps.xla_ae_headers ah,
    apps.xla_events e,
    xla.xla_transaction_entities te,
    apps.ap_invoices_all i,
    apps.ap_suppliers s
    WHERE ( cc.CHART_OF_ACCOUNTS_ID = 50328
    AND jeh.LEDGER_ID IN
    (SELECT acc.ledger_id
    FROM apps.gl_access_set_ledgers acc
    WHERE acc.access_set_id = 1000
    AND jel.code_combination_id = cc.code_combination_id
    AND cck.code_combination_id = cc.code_combination_id
    AND jel.status
    || '' = 'P'
    AND ( jel.accounted_dr != 0
    OR jel.accounted_cr != 0 )
    AND jeh.je_header_id = jel.je_header_id
    AND jeh.actual_flag = 'A'
    AND 1 = 1
    AND jeh.currency_code != 'STAT'
    AND jeb.je_batch_id = jeh.je_batch_id
    AND jeb.average_journal_flag = 'N'
    AND src.je_source_name = jeh.je_source
    AND cat.je_category_name = jeh.je_category
    AND r.je_header_id(+) = jel.je_header_id
    and r.je_line_num(+) = jel.je_line_num)
    and ( :period_name = jel.period_name
    AND al.gl_sl_link_id(+) = r.gl_sl_link_id
    AND al.ae_header_id = ah.ae_header_id(+)
    AND al.application_id = ah.application_id(+)
    AND ah.application_id = e.application_id(+)
    AND ah.event_id = e.event_id(+)
    AND e.application_id = te.application_id(+)
    AND e.entity_id = te.entity_id(+)
    AND NVL(te.source_id_int_1,-99) = i.invoice_id(+)
    AND i.vendor_id = s.vendor_id(+) )
    AND ( jel.ledger_id = 2041)
    ORDER BY src.user_je_source_name ,
    cat.user_je_category_name ,
    jeb.name ,
    jeh.name ,
    cck.concatenated_segments ,
    jel.je_line_numEdited by: user11268895 on Aug 20, 2010 3:53 PM

  • Event ID 7000 Diagnostic Service Host failed to start. Privilege in service requiring to function doesn't exist in service account configuration.

    I have Windows 7 Home Premium. I get this error when I try to start the Windows Search service. All of the solutions that I've seen talk about changing Security Settings | Local Policies | User Rights Assignment. However, from what I can determine in Home
    Premium there is no way to access those settings or anything to do with group policies. Does anyone have any other ideas?
    Thanks,

    Hi T_Meyer,
    Thanks for feedback.
    Actually, I am waiting for OP come back. In my first reply, I  confirm the question first, because the
     User Rights Assignment setting would be reflected to the registry data.
    I know the current Home Premium does not contain the Group Policy Editor, but we need know if this is the real cause for this issue.
    Back to the answer:
    To edit the user rights, alternatively, we can use ntrights tool, although this is no longer supported after Windows XP, but we can still use it:
    http://support.microsoft.com/kb/266280
    set the SeSystemProfilePrivilege for NT Service\WdiServiceHost
    we can get it from this download link:
    http://www.microsoft.com/en-in/download/details.aspx?id=17657
    Alex Zhao
    TechNet Community Support

Maybe you are looking for

  • New computer, how can I move all my music from my old computer?

    I have just bought a new computer, but all of my music in iTunes for my iPod is on my old computer. How can I transfer my music to the new computer?

  • Analyze: PL/SQL function body returning an SQL query

    I need to obtain the final SQL returned by the PL/SQL function. I will be using this final SQL in a procedure. Please provide some advise on how to obtain the SQL. I have already looked in the DBMS_SQL package but I am not sure if that is the right p

  • I Can't Get it to compile anything.

    Hi, I can't get it to compile. I'm using Windowsxp Pro and the New beta version of Java jsdk1.4.0-beta3. I set path and my classpath but when I go to compile it gives me this message "error: cannot read: BigDebt.java 1error" Can anyone help me I have

  • Where did the change color option go it was in elements 10

    In older versions of photoshop elements you could go to enhance and then at the bottom of that list you could "change color" what happened to that option?  I LOVED it and used it all the time when colors did not come out correctly.

  • Licensing model for OES2?

    Hello, We have an unlimited user license for Novell.The Tree has multiple Netware servers , all of our servers are Netware 6.5 SP7. We are planning to deploy the OES 2 (OES2 SP3 + Suse Linux Enterprise Server 10 SP4) on new server in an existing Nove