Passing sylesheet name as a parameter to xsql file

The way that I can have
<page xmlns:xsql="urn:oracle-xsql" connection="{@conn}">
where conn is the connection!
Could I have someting like
<?xml-stylesheet type="text/xsl" href="{@style}" >
where style would be the style sheet that the user chooses in the URL

Eric,
You can pass the stylesheet in the query string of the XSQL request, like in
http://akeu.coucou/page.xsql?xsl=alternatestylesheet.xsl
This would overwrite the stylesheet set in the XSQL Script.
- Olivier

Similar Messages

  • Pass table name as a parameter to function

    Is there a way to pass table name as a parameter to functions? Then update the table in the function.
    Thanks a lot.
    Jiaxin

    Hi, Harm,
    Thank you very much for your suggestion and example. But to get my program work, i need to realise code like follows:
    CREATE OR REPLACE FUNCTION delstu_func(stuno char) RETURN NUMBER AS
    BEGIN
    EXECUTE IMMEDIATE 'DELETE FROM student s' ||
    'WHERE' || 's.student_number' || '=' || stuno;
    LOOP
    DBMS_OUTPUT.PUT_LINE('record deleted');
    END LOOP;
    END;
    SELECT delstu_func('s11') FROM STUDENT;
    The intention is to check if such a function can perform operations such as update, delete and insert on occurence of certain values. When executing the above statement, the system returns an error message:
    ERROR at line 1:
    ORA-00933: SQL command not properly ended
    ORA-06512: at "SCMJD1.DELSTU_FUNC", line 3
    Could you tell me where is wrong?
    Jiaxin

  • Script to stop running SQL Agent job without passing job name as a parameter

    Looking for script to stop running job and don’t want to pass job name as a parameter, any job which is in running state I want that to be stop/disable.
    I have script to disable all jobs however if any jobs are in running state my requirement is to stop that job immediately and gets disable.
    Rahul

    Try the below scripts and then apply script to disable all jobs.
    execute xp_cmdshell 'net stop sqlserveragent'
    execute xp_cmdshell 'net start sqlserveragent'
    Regards, RSingh

  • Pass Bean Name as a parameter?

    Hi,
    Is it possible to pass the bean name as a parameter to the method? In that case, we can pass the bean name as a String to the calling method?
    Thanks
    Aishu

    You can use f:param, f:attribute or f:setPropertyActionListener to pass "parameters" to the method.
    Also see [http://balusc.blogspot.com/2006/06/communication-in-jsf.html].

  • Pass column-name as a parameter to reports

    Hello,
    the code below calls a report. But now I want to sort the rows in the report. For example I have a text-item in my form-modul. If I type a column-name and press the button then the rows should be sorted in the report. Is it possible tp pass column-names as parameter to reports?
    DECLARE
    repid REPORT_OBJECT;
    v_rep VARCHAR2(100);
    rep_status VARCHAR2(20);
    BEGIN
    repid := find_report_object('STATIONSTOPOLOGIE');
    SET_REPORT_OBJECT_PROPERTY(repid,REPORT_EXECUTION_MODE,RUNTIME);
    SET_REPORT_OBJECT_PROPERTY(repid,REPORT_COMM_MODE,SYNCHRONOUS);
    SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESTYPE,CACHE);
    SET_REPORT_OBJECT_PROPERTY(repid,REPORT_DESFORMAT,'html');
    SET_REPORT_OBJECT_PROPERTY(repid,REPORT_SERVER,'rep_oracle-dev');
    -- SET_REPORT_OBJECT_PROPERTY(repid,REPORT_OTHER,'paramform=no pdeptno='||:dept.deptno);
    v_rep := RUN_REPORT_OBJECT(repid);
    rep_status := REPORT_OBJECT_STATUS(v_rep);
    WHILE rep_status in ('RUNNING','OPENING_REPORT','ENQUEUED')
    LOOP
    rep_status := report_object_status(v_rep);
    END LOOP;
    IF rep_status = 'FINISHED' THEN
    WEB.SHOW_DOCUMENT('http://oracle-dev:8888/reports/rwservlet/getjobid'||
    substr(v_rep,instr(v_rep,'_',-1)+1)||'?'||'server=rep_oracle-dev','_blank');
    ELSE
    message('Error when running report');
    END IF;
    END;

    Hi,
    the work has been done in reports. You can use a lexical parameter in reports to add a condition for sorting to the query like:
    select .. from .. where ... &p_order.
    Then add another parameter to the report (for example p_param). Fill p_param via your interface in forms (SET_REPORT_OBJECT_PROPERTY(repid,REPORT_OTHER, ....) with the column name. Then build a report trigger like:
    if :p_param is null
    then
    :p_order:= null;
    else
    :p_order:= 'order by '||:p_param;
    end if;
    But have a look, that p_param can only get correct values.
    Rainer

  • How to pass printer name as a parameter to Bursting control file

    We are on 11.5.10.2 using XML Publisher 5.6.3. We ahve a requirement, where we need to print our invoices to different printers.
    How do we pass the printer name as a parameter to Bursting control file. Can the bursting control file be created to use the printer parameter.
    If it can, can you please provide some examples.
    - Vasu -

    Hi.
    I have created Formula column and it is coming in xml data.
    Like this way
    <CP_TAX_NO>CZ27813941</CP_TAX_NO>
    <CP_CUST_TAX_REG>CZ680527617</CP_CUST_TAX_REG>
    <CF_PRINTER_NAME>ABC_hp4250</CF_PRINTER_NAME>
    <C_REQ_ID>12310217</C_REQ_ID>
    </ISOPTWSHRDPAK>
    But while i passed it bursting directory, it is not printing, if i hardcode over there then it is printing.
    Bursting file code
    <xapi:delivery>
         <xapi:print id="printer1" printer="ipp://localhost:631/printers/${CF_PRINTER_NAME}" copies="1" />
    </xapi:delivery>
    In bursting program file It is display like :
    [1]printer-uri:ipp://localhost:631/printers/null
    If i pass hardcode value instead of cf_printer_name then it is working fine
    [1]printer-uri:ipp://localhost:631/printers/ABC_hp4250
    Pls suggest what to do?

  • How to pass sicf name as a parameter frm webdynpro

    Hi All,
    I have created a properties file in which i hv provided the following path: servername:port n path to open the SAP R/3 easy access but i want to pass sicf name so it directly opens it in portal.   Please provide me some assistance. Thankyou.
    Regards,
    Jaspreet Kaur
    Edited by: Jaspreet Kaur on Dec 29, 2008 11:56 AM

    Hi Jaspreet,
    You can create an IAC iview with your service.
    Hope this helps,
    Ivá

  • Passing table name as a parameter

    Hi:
    I have a question regarding passing part of a table name to crystal. I have table getting created everyday and the dynamic part being Table_<date in yymmdd format>, for e.g. - Table_20140225 for table created on 02/25/2014
    I have written query like "select * form Table_{@DT}". This used to work in Crystal 11.5.8.826. but recently we upgraded to 12.2.0.290. In this version of Crystal it is not working and giving me error "com.crystaldecisions.sdk.occa.report.lib.ReportSDKServerException: Missing parameter values.---- Error code:-2147217394 Error code name:missingParameterValueError".
    Can you please suggest to get around this problem. Running a stored procedure with REFCURSOR is not an option.
    i tried another solution, where i just wrote a stored procedure to do a insert into a table handling the dynamic table in stored procedure. but to my surprise, the stored procedure doesn't execute all the time.
    Any help on this is much appreciated...

    Please see if SP 6 helps. You are on SP 2 at this time.
    https://share.sap.com/a:328ro3/MyAttachments/521c18ac-d7fd-4a58-a2dc-9d40d1951975/
    - Ludek
    Senior Support Engineer AGS Product Support, Global Support Center Canada
    Follow us on Twitter

  • Can I pass function name as a parameter to constructor?

    Hi!
    I want to create a class that extends JButton and executes some function, when released. The function for each button is different. I mean, can I write, for example:
    public class MyButton extends JButton
    public MyButton(...functionName...)
    addMouseListener(new MouseAdapter()
         public void mouseReleased(MouseEvent e)
         ...execute functionName...;
    MyButton testButton = new MyButton(printTest);
    void printTest()
    System.out.println("The button executes OK");
    (This code will not work, of cause).
    If you understood me, please answer if there is any way to pass function as a parameter ?
    Thank you in advance.

    Using reflection would work, but there is a more straightforward way. Here's what I do when I want to pass a method to be called by another object: First I declare an interface named Callback:public interface Callback
      public void run();
    }Then your class would look like this:public class MyButton extends JButton {
      private Callback doit;
      public MyButton(Callback whatToDo) {
        doit = whatToDo;
        addMouseListener(new MouseAdapter() {
          public void mouseReleased(MouseEvent e) {
            whatToDo.run();
    }and the code that creates a MyButton might look like this:Callback callMe = new Callback() {
      public void run() {
        System.exit(0);
    MyButton closeButton = new MyButton(callMe);
    closeButton.setText("Close");If you like, you can adapt this pattern to use variations of Callback that have parameters or return values.

  • Passing TABLE NAME as parameter is possible or not?

    I want develop a small/simple report like this
    TABLE NAME :
    WHERE :
    ORDER BY :
    QUERY ROWS
    In the above model i want to pass all the three (TABLE NAME,WHERE and ORDER BY) as a parameter.
    My doubt, is that possible to pass TABLE NAME as a parameter? If so!
    When i enter any TABLE NAME it has to fetch me out the records of that table (Based on WHERE condition and ORDER BY).
    Is that possible to do?
    Need some help!
    Edited by: Muthukumar Seshadri on Aug 10, 2012 6:19 PM

    Yes, it is possible with lexical parameters. Look in the help for examples:
    SELECT Clause
    SELECT &P_ENAME NAME, &P_EMPNO ENO, &P_JOB ROLE  FROM EMP
    P_ENAME, P_EMPNO, and P_JOB can be used to change the columns selected at runtime.  For example, you could enter DEPTNO as the value for P_EMPNO on the Runtime Parameter Form. 
    Note that in this case, you should use aliases for your columns.  Otherwise, if you change the columns selected at runtime, the column names in the SELECT list will not match the Report Builder columns and the report will not run.
    FROM Clause
    SELECT ORDID, TOTAL FROM &ATABLE
    ATABLE can be used to change the table from which columns are selected at runtime.  For example, you could enter ORD for ATABLE at runtime. 
    If you dynamically change the table name in this way, you may also want to use lexical references for the SELECT clause (look at the previous example) in case the column names differ between tables.
    WHERE Clause
    SELECT ORDID, TOTAL FROM ORD WHERE &CUST
    ORDER BY Clause
    SELECT ORDID, SHIPDATE, ORDERDATE, TOTAL  FROM ORD ORDER BY &SORT You have to be really careful with this approach. Dynamic SQL may cause serious performance problems.
    Edited by: InoL on Aug 10, 2012 10:06 AM

  • Parameter to script files

    i wish to pass a parameter to .sql file. Please help me urgently...................
    i have a query that calculates on the basis of invoice number. I have a script file that has the query which displays the output in formatted pattern.
    Now i wish to pass invoice number as the parameter to .sql file but i donot know how to do this. please help

    See sections 2 and 9 of http://otn.oracle.com/support/tech/sql_plus/htdocs/sub_var.html
    -- CJ

  • Xml string passed as parameter to xsql

    I am trying to pass xml string as parameter to xsql.But having problems with the < and > .I tried to escape
    those chars but but i am not getting desired output.Could you please suggest how to pass the xml string .
    <xsql:include-xsql href="order.xsql?neworder='{@neworder}'
    i trying to pass neworder parameter as xml string which contains data to update 2-3 table .

    u can't post a parameter valued by a xml string,because of the xml string must be
    has xml element with attributes. as follows:
    <row num="1">
    the "=" will make the web container got error
    when parsing http request parameters's name and value pair.
    solution:
    1. use "post" method submit your parameter
    2. use microsoft xml http compoment post your param as a parameter
    of it's "send" method, and set the request contentType header "text/xml"
    in xsql file:
    <xsql:set-page-param name="param1" xpath="/parameters/neworder"/>
    try it :->

  • Pass table name as parameter in prepared Statement

    Can I pass table name as parameter in prepared Statement
    for example
    select * from ? where name =?
    when i use setString method for passing parameters this method append single colon before and after of this parameter but table name should be send with out colon as SQL Spec.
    I have another way to make sql query in programing but i have a case where i have limitation of that thing so please tell me is it possible with prepared Statment SetXXx methods or not ?
    Thanks
    Haroon Idrees.

    haroonob wrote:
    I know ? is use for data only my question is this way to pass table name as parameterI assume you mean "how can I do it?" As I have already answered "is this the way?" with no.
    Well, I would say (ugly as it is) String concatenation, or stored procedures.

  • Passing field name in function as parameter

    Hi
    I want to pass the fields name as in parameter in function and then return the value of that field.
    thanks
    pramod patel

    CREATE OR REPLACE FUNCTION demo
    (i_in IN number)
    RETURN NUMBER
    IS
    BEGIN
    RETURN i_in*2;
    END demo;
    Hope that helps ... also, remember you can't use precision and scale (in the case of NUMBER), or length (in the case of VARCHAR2) for the parameters but you can ANCHOR (%TYPE or %ROWTYPE)
    Good luck!

  • Passing a column name as a parameter

    Good afternoon,
    I was wondering if any of you ever encountered the following situation and found a method to get around it...
    I recently created a pivot table using the SQL Query (PL/SQL function body returning SQL query) option.
    The table consisted of the following information:
    - Date range, Object Type and count.
    The final table looks something like this (pardon the lack of fancy markup, hopefully it will get the point across):
    Date        Object A    Object B    Object D    Object G
    01-apr-09   10           16         50          43
    02-apr-09   1            15         77          35
    03-apr-09   19           0          14          17
    04-apr-09   15           7          70          20
    05-apr-09   7            6          65          50And it goes on like that.
    I had to create the code dynamically because I don't know what Objects I will get in any given date range (for example: I could have something for Object C and nothing for Object D in the month of March). I had a cursor loop through the object types before creating the SQL query that builds the table above.
    The table is now working fine. What I'm trying to do now is do a little bit of drilling down in data.
    Since everything is dynamically built, I can't give actual column names in my report. Is there any way that, when I click on, for example, the "10" on April 1st in Object A that the column header "Object A" gets passed? #COL02# only passes the value "10" which isn't what I want, and I tried the other variations such as :COL02 and &COL02. without much luck.
    If you could shed some light on this problem, that would be greatly appreciated!
    Thank you for your time.
    Ivan

    Hi,
    You can achieve passing column name as parameter with the help of jquery.
    Below is the sample code
    <script src="http://www.google.com/jsapi"></script>
    <script type="text/javascript"> 
       google.load("jquery", "1.2.6"); 
    </script>
    <script type="text/javascript">
        //<![CDATA[
        $(document).ready( function() {
            $('.t20data').each( function(i) {
                $td =$(this);
                colHeader = $(this).attr("headers");
                $td.html('<a href="f?p=' + &APP_ID. + ':3' + ':' + &APP_SESSION. + '::NO:3:P3_COLUMN_HEADER,P3_COLUMN_VALUE:' + colHeader +',' +$td.text()+ '">' + $td.html() + '</a>');
        });                                  //]]>
    </script>Note - U need to change t20data , :p3_column_header , :p3_column_value to match you application.
    No need to add link individually by going into column attributes
    [E X A M P L E |http://apex.oracle.com/pls/otn/f?p=62171:2]
    Regards,
    Shijesh

Maybe you are looking for

  • Error while testing web dynpro application

    Hi all, I am trying to test a webdynpro application, following error is being generated. The problem is, that I when I try to create a View for a Web Dynpro, the layout window reports the following error message: ERROR The requested URL could not be

  • TM with 2 external drives.

    I have a client I am installing 10.5 for, and I was wondering if its possible to backup to 2 different external drives alternately. What they want is to back up to Drive 1 one day and Drive 2 the next, and keep alternating like that. Both the drives

  • Views are not being updated

    Hello All, I am a newbie to oracle dB. I have an old VB6 application code that used to "talk" with Oracle dB (version 10g). The 2 machines used to be connected using the Microsoft ODBC for Oracle driver ("Provider=MSDASQL.1"). It used to run fine and

  • Root file system 100%

    Hi, We are facing a proble in which our root file system is 100% because of a lot of directories being created in the /proc directory. These directories are created with numbers as their names. Please give some advice

  • Synchronisation doesn't work with itunes. Comment : synchro will continue when PC will be available

    Synchro has been working until lasr monday  now it doesn't work (ipad and iphone). The iphone / ipad doesn't appear in itunes but i have the windows feedback On my ipad, in the general menu, option synchro wifi itunes, i read the synchro will continu