Pass query result as parameter to javascript

Hello,
I'm a beginner with javascript, so (maybe) sorry for this
question.
Is it possible to use a query result as parameter in a
javascript function
for example like this?
<cfquery name="select_data">
select name from user_table
</cfquery>
<script language="javascript">
function(#select_data.name#)
</script>
Background is: I have to validate an input field with some
values which are saved in a database table.
This values can be dynamic , so I don't want to put this
values into the cfm-file.
Any ideas?
Claudia

Each column in a cf query is effectively a 1D array. You can
use the toscript function to send this array to js.

Similar Messages

  • How to pass query result to HTML table?

    Hi,
      i want to get the query result in HTMl table instead of Display Grid. how to do it? i searched in help, it suggests use icommand to do this. but i dont know how to pass the select query result to HTML table.. please help me.
    -senthil

    Hi Senthil,
    You can create an icommand query. You can then use the icommand retrieval methods to capture and manipulate the query data.
    (http://help.sap.com/saphelp_xmii115/helpdata/en/Applet_Reference_Details/iCom
    mand_Reference.htm)
    Basically what we did was, use the getColumnCount() and getRowCount() methods, once you have these two numbers you can set two for loops and use String getValue(int ColID, int RowID) , within the for loops you can generate the inner html content and write the values either in a html table or html form (which is what we did). This seems to work well, I'm still playing around with it and may post this approach on sdn by end of this week.
    Mahwish

  • How to pass query result from pop-up?

    Hi!
    First of all, sorry for my english, I hope you could
    understand me :-)
    I'm newbie in Flex, just started. I wrote main application
    with button
    "Login", and when I click on it I generate pop-up window witn
    my
    custom component "LoginForm". In this form I check in my
    MySQL
    database using PHP if the username and the password are
    correct.
    To this point it works.
    Now, I would like to pass the result (the query return full
    name of
    the users if it is correct) to the variable declared in main
    application:
    var person:Staff = new Staff();
    Staff is my class defined in separate file Staff.as with
    public
    variable full_name:String and public method
    setFullName(name:String);
    How to do that?
    Best regards,
    Mariusz

    There are several ways. One way is to use events. This
    example shows several *other* ways.
    http://www.cflex.net/showFileDetails.cfm?ObjectID=558
    Tracy

  • Retrieve Query Results in Javascript

    Hi,
    I've created a SQL query template with Param.1.  I've created and iCommand for it.  I've also created an Applet consisting of the SQL Query and iCommand template.
    I am trying to retrieve query results after setting the parameter.  I am getting errors (undefined of course) when using the getValue() method. 
    1. var commandObject = document.AppName.queryobject;
    2. commandObject.setParam(1, var1).  var1 = 'Training'
    3  applet refresh
    4.  var var2 = commandObject.getValue(1,1) ==> crashes. 
    5.  alert (var2);
    This seems pretty straight forward.  Any ideas?
    Thanks

    kelly
    Just missing one javascript code <b>iCommand.executeCommand();</b>
    1. document.AppName.getqueryobject().setParam(1, var1) ;
    2. document.AppName.executeCommand();
    3. var var2 = document.AppName.getValueByName(String ColName, 1);
    5. alert (var2);
    Regards
    Som

  • Pass the result of a SQL Query as table_name  for another SQL Query

    Hi All,
    How to pass the result of a SQL Query as parameter to another SQL Query
    Eg: I am doing the steps below.
    1) select distinct table_name as TAB1 from all_tab_cols where table_name like 'T_%' and column_name like '%XYZ'
    2) I want to pass the table_name from step 1 above as parameter to another query "select * from TAB1"
    Thanks

    Naveen B wrote:
    Hi All,
    How to pass the result of a SQL Query as parameter to another SQL Query
    Eg: I am doing the steps below.
    1) select distinct table_name as TAB1 from all_tab_cols where table_name like 'T_%' and column_name like '%XYZ'
    2) I want to pass the table_name from step 1 above as parameter to another query "select * from TAB1"
    ThanksYou should craete PL/SQL code with cursor which will accept a parameter and call that cursor inside the first one
    But if the first sql returns only one row, you can do it with simple sql code
    select * from (select distinct table_name as TAB1 from all_tab_cols where table_name like 'T_%' and column_name like '%XYZ')- - - - - - - - - - - - - - - - - - - - -
    Kamran Agayev A. (10g OCP)
    http://kamranagayev.wordpress.com
    [Step by Step install Oracle on Linux and Automate the installation using Shell Script |http://kamranagayev.wordpress.com/2009/05/01/step-by-step-installing-oracle-database-10g-release-2-on-linux-centos-and-automate-the-installation-using-linux-shell-script/]

  • Pass parameter value to another parameter.... User query in user parameter

    Hello everyone, any help would be greatly appreciated.
    Problem:
    My report currently has 5 user parameters (3 Number, 2 Characters). I have an after parameter trigger that evaluates all the parameters to see which one has any value and then creates the “where clause”. Below is an example of two of the 5 parameters.
    The function works fine, I just cut out all the other stuff for this issue.
    function AfterPForm return boolean is
    IF :P_JOB_ID is not null then
         :P_WHERE_CLAUSE := 'where Job_num = :P_JOB_ID';
    ELSIF :P_QUES_DESC is not null then
    :P_WHERE_CLAUSE := 'where DESCRIPTION like :P_QUES_DESC’;
    ELSE :P_WHERE_CLAUSE := ‘where JOB_NUM = 0';
    The “P_WHERE_CLAUSE” is used as follows in a query.
    Select job_num
    from PROMOTION
    &P_W_CLAUSE
    Issue:
    The query result can be anywhere from 1 to 50 job_num’s. I need to show the end user running this report the values (job_num) in a drop down list. They in turn will select one job_num which will be used to run the report. I tried putting the Select job_num from PROMOTION &P_W_CLAUSE in a User Parameter but that does not work. I get an error. I feel that I am approaching this the wrong way. Because in the end I would end up with two queries, one for the Select statement containing the P_W_CLAUSE and another with the final report. This issue is sort of like cascading prompt where the values from one (or more) parameters are used in the select of another user parameter which in turn the value selected will be used in the final report. Also this report will be used somewhere between 50 - 75 times per day so storing the values in a temp table might not work.

    Sorry,
    as I know depending parameters like you want are not possible in Reports. You can use one reports as parameter-report-only to use a second as your original report, but this is not perfect. Or use a tool like Application Express (which is able to have depending fields) in front of reports to build your parameter forms.
    Regards
    Rainer

  • How to pass a result of SQL query to shell script variable

    Hi all,
    I am trying to pass the result of a simple SQL query that only returns a single row into the shell script variable ( This particular SQL is being executed from inside the same shell script).
    I want to use this value of the variable again in the same shell scirpt by opening another SQL plus session.
    I just want to have some values before hand so that I dont have to do multiple joins in the actual SQL to process data.

    Here an example :
    SQL> select empno,ename,deptno from emp;
         EMPNO ENAME          DEPTNO
          7369 SMITH              20
          7499 ALLEN              30
          7521 WARD               30
          7566 JONES              20
          7654 MARTIN             30
          7698 BLAKE              30
          7782 CLARK              10
          7788 SCOTT              20
          7839 KING               10
          7844 TURNER             30
          7876 ADAMS              20
          7900 JAMES              30
          7902 FORD               20
          7934 MILLER             10
    14 rows selected.
    SQL> select * from dept;
        DEPTNO DNAME          LOC
            10 ACCOUNTING     NEW YORK
            20 RESEARCH       DALLAS
            30 SALES          CHICAGO
            40 OPERATIONS     BOSTON
    SQL> exit
    Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    $ cat my_shell.sh
    ### First query #####
    ENAME_DEPTNO=`sqlplus -s scott/tiger << EOF
    set pages 0
    select ename,deptno from emp where empno=$1;
    exit
    EOF`
    ENAME=`echo $ENAME_DEPTNO | awk '{print $1}'`
    DEPTNO=`echo $ENAME_DEPTNO | awk '{print $2}'`
    echo "Ename         = "$ENAME
    echo "Dept          = "$DEPTNO
    ### Second query #####
    DNAME_LOC=`sqlplus -s scott/tiger << EOF
    set pages 0
    select dname,loc from dept where deptno=$DEPTNO;
    exit
    EOF`
    DNAME=`echo $DNAME_LOC | awk '{print $1}'`
    LOC=`echo $DNAME_LOC | awk '{print $2}'`
    echo "Dept Name     = "$DNAME
    echo "Dept Location = "$LOC
    $ ./my_shell.sh 7902
    Ename         = FORD
    Dept          = 20
    Dept Name     = RESEARCH
    Dept Location = DALLAS
    $                                                                           

  • Passing java parameter to javascript function in oa framework

    hi all,
    can anybody tell how to pass parameter to javascript function from java for example
    OAMessageTextInputBean txtbean = (OAMessageTextInputBean)webBean.findChildRecursive("BuyerPrice");
    String row = "rowid";
    txtbean.setOnKeyUp("javascript:checkNumber("+row+")");
    checknumber is javascript function defined .

    Hi,
    go through http://forum.java.sun.com/thread.jspa?threadID=174157&messageID=539357
    if ur requirement is just to pass a string to a JS function.
    Thanks

  • How to pass a result set as an output parameter

    I have a function that will be used as a web service. It invokes a stored procedure - ideally I'd like to pass the result set from the SP out as a result set to the client consuming the web service. Is this do-able or am I in dreamland?

    What you typically do is iterate thru the RS, turning each row of data into a business object and adding all the business objects to a list or some other collection. Then close the result set. Return that collection of business objects to the client.

  • Entity Attribute Existence Check - Query Result Parameter not possible ?

    I already read the section of the ADF BC Developer Guide (9.6.2 Implementing an Efficient Existence Check).
    That works and maybe is the best solution, however I am working with a group of Forms Developers which are much more comfortable with writing SQL statements.
    Natural thing for them in this case was to define a declarative compare validator with the following Query Result:
    select PROD_ID from Products where PROD_ID=:ProdId
    where :ProdId is ServiceRequest.ProdId
    Is this possible with ADF BC ?
    Other possibility is to define a List Validator with the following Query Result:
    select PROD_ID from Products
    but this is not performant.
    I know the programmatic approach is always possible, but to make migration easier for Forms developers into the ADF BC world, the declarative SQL option should be available.
    Thanks,
    Claudio.

    This isn't possible out of the box in 10.1.3 since we don't support a mechanism to set the values of the bind variables. In 10.1.3, you would need to build a custom validation rule class (explained in section 26.9 "Implementing Custom Validation Rules") to make this declarative for others on your team.
    I wouldn't recommend the list validator in 10.1.3 for anything but the most trivial uses. This is because it's current implementation retrieves all rows from the query, then does the attribute comparison in memory.
    Among many, many other enhancements, we are greatly enhancing declarative business logic features of ADF Business Components for our 11g/Fusion release (the next major release), where this will be super-easy.

  • XML query results in HTML form parameter

    Hi,
    I would like insert records from a query result (raw XML) into HTML form tags, using the XSL stylesheet. Here is the code I am trying to use, but obviously it is not working.
    <INPUT TYPE="hidden" NAME="te_hb_strdEntryId"
    VALUE="<xsl:value-of select="ID"/>">
    Are there any other options to put a result of a query in a hidden tag, using XSL?
    Any help will be appriciated.

    <INPUT TYPE="hidden" NAME="te_hb_strdEntryId"
    VALUE="<xsl:value-of select="ID"/>">
    The correct syntax would be:
    <INPUT TYPE="hidden" NAME="xxx">
    <xsl:attribute name="VALUE">
    <xsl:value-of select="ID"/>
    </xsl:attribute>
    however, there is a shortcut syntax
    when you are using XPath expressions
    in literal attribute values:
    XSLT attribute value templates. They are
    XPath expressions inside curly braces.
    So, you can achieve your desired result
    with the shorter form:
    <INPUT TYPE="hidden" NAME="xxx" VALUE="{ID}">
    as well.

  • How to pass more than one parameter

    Hello,
    This is my code.
    How to pass more than one parameter:
    SELECT:responsibility_name responsibility_name,
    LPAD(' ', 6*(LEVEL-1))
      || menu_entry.entry_sequence sequence ,
      LPAD(' ', 6*(LEVEL-1))
      || menu.user_menu_name SubMenu_Description ,
      LPAD(' ', 6*(LEVEL-1))
      || func.user_function_name Function_Description ,
      LPAD(' ', 6*(LEVEL-1))
      || menu_entry.prompt prompt
      ,menu.menu_id ,
      func.function_id
      --menu_entry.grant_flag Grant_Flag ,
      --DECODE( menu_entry.sub_menu_id , NULL, 'FUNCTION' , DECODE( menu_entry.function_id , NULL, 'SUBMENU' , 'BOTH') ) Type
    FROM fnd_menu_entries_vl menu_entry ,
      fnd_menus_tl menu ,
      fnd_form_functions_tl func
    WHERE menu_entry.sub_menu_id    = menu.menu_id(+)
    AND menu_entry.function_id      = func.function_id(+)
    AND MENU.LANGUAGE(+) = 'US'
    AND FUNC.LANGUAGE(+) = 'US'
    --AND func.user_function_name LIKE '%Primary Care Providers%'
    AND grant_flag                  = 'Y'
      START WITH menu_entry.menu_id =
      (SELECT menu2.menu_id
      FROM fnd_menus_tl menu2,apps.fnd_responsibility_vl resp
      WHERE menu2.menu_id=resp.menu_id
      and resp.responsibility_name= :responsibility_name
      --and menu2.user_menu_name = ('ATCO HR INQ USER'
      AND LANGUAGE = 'US'
      CONNECT BY MENU_ENTRY.MENU_ID = PRIOR MENU_ENTRY.SUB_MENU_ID
       and menu_entry.function_id not in (select func.function_id
                                       from --fnd_form_functions_vl fnc,
                                       apps.fnd_resp_functions exc,
                                       apps.fnd_responsibility_vl res
                                      where func.function_id = exc.action_id
                                      and res.responsibility_name =:responsibility_name
                                      and res.responsibility_id=exc.responsibility_id)
      and menu_entry.sub_menu_id  not in (select menu.menu_id
                                       from --fnd_menus_vl imn,
                                       apps.fnd_resp_functions exc,
                                       apps.fnd_responsibility_vl res
                                       where menu.menu_id = exc.action_id
                                       and res.responsibility_name =:responsibility_name
                                      and res.responsibility_id=exc.responsibility_id)
    ORDER SIBLINGS BY menu_entry.entry_sequence;
    Thank you for your help
    Shuishenming

    Hi, Ming,
    One way is to put the "parameters" in a table, and join to that table in your query.  If you make it a Global Temporary Table, then multiple sessions can run the query at the same time, and each can be seeing different responsibilities.
    I hope this answers your question.
    If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for all the tables involved, and the results you want from that data.  Since this problem involves parameters, you should give a couple of different sets of parameters, and the results you want from the same sample data for each set.
    Explain, using specific examples, how you get those results from that data.
    Always say what version of Oracle you're using (e.g. 11.2.0.2.0).
    See the forum FAQ: https://forums.oracle.com/message/9362002

  • Stepping through a query result set, replacing one string with another.

    I want to write a function that replaces the occurance of a string with another different string.  I need it to be a CF fuction that is callable from another CF function.  I want to "hand" this function an SQL statement (a string) like this:   (Please note, don't bother commenting that "there are eaiser ways to write this SQL..., I've made this simple example to get to the point where I need help.  I have to use a "sub_optimal" SQL syntax just to demonstrate the situation)
    Here is the string I want to pass to the function:
    SELECT
      [VERYLONGTABLENAME].FIRST_NAME,
      [VERYLONGTABLENAME].LAST_NAME,
      [VERYLONGTABLENAME].ADDRESSS
    FROM
      LONGTABLENAME [VERYLONGTABLENAME]
    Here is the contents of the ABRV table:
    TBL_NM,  ABRV    <!--- Header row--->
    VERYLONGTABLENAME, VLTN
    SOMEWHATLONGTALBENAME, SLTN
    MYTABLENAME, MTN
    ATABLENAME, ATN
    The function will return the original string, but with the abreviations in place of the long table names, example:
    SELECT
      VLTN.FIRST_NAME,
      VLTN.LAST_NAME,
      VLTN.ADDRESSS
    FROM
      LONGTABLENAME VLTN
    Notice that only the table names surrounded by brackets and that match a value in the ABRV table have been replaced.  The LONGTABLENAME immediately following the FROM is left as is.
    Now, here is my dum amatuer attempt at writing said function:  Please look at the comment lines for where I need help.
          <cffunction name="AbrvTblNms" output="false" access="remote" returntype="string" >
            <cfargument name="txt" type="string" required="true" />
            <cfset var qAbrvs="">  <!--- variable to hold the query results --->
            <cfset var output_str="#txt#">  <!--- I'm creating a local variable so I can manipulate the data handed in by the TXT parameter.  Is this necessary or can I just use the txt parameter? --->
            <cfquery name="qAbrvs" datasource="cfBAA_odbc" result="rsltAbrvs">
                SELECT TBL_NM, ABRV FROM BAA_TBL_ABRV ORDER BY 1
            </cfquery>
         <!--- I'm assuming that at this point the query has run and there are records in the result set --->
        <cfloop index="idx_str" list="#qAbrvs#">      <!--- Is this correct?  I think not. --->
        <cfset output_str = Replace(output_str, "#idx_str#", )  <!--- Is this correct?  I think not. --->
        </cfloop>               <!--- What am I looping on?  What is the index? How do I do the string replacement? --->
            <!--- The chunck below is a parital listing from my Delphi Object Pascal function that does the same thing
                   I need to know how to write this part in CF9
          while not Eof do
            begin
              s := StringReplace(s, '[' +FieldByName('TBL_NM').AsString + ']', FieldByName('ABRV').AsString, [rfReplaceAll]);
              Next;
            end;
            --->
        <cfreturn output_txt>
        </cffunction>
    I'm mainly struggling with syntax here.  I know what I want to happen, I know how to make it happen in another programming language, just not CF9.  Thanks for any help you can provide.

    RedOctober57 wrote:...
    Thanks for any help you can provide.
    One:
    <cfset var output_str="#txt#">  <!--- I'm creating a local
    variable so I can manipulate the data handed in by the TXT parameter.
    Is this necessary or can I just use the txt parameter? --->
    No you do not need to create a local variable that is a copy of the arguments variable as the arguments scope is already local to the function, but you do not properly reference the arguments scope, so you leave yourself open to using a 'txt' variable in another scope.  Thus the better practice would be to reference "arguments.txt" where you need to.
    Two:
    I know what I want to happen, I know how to make it happen in another programming language, just not CF9.
    Then a better start would be to descirbe what you want to happen and give a simple example in the other programming language.  Most of us are muti-lingual and can parse out clear and clean code in just about any syntax.
    Three:
    <cfloop index="idx_str" list="#qAbrvs#">      <!--- Is this correct?  I think not. --->
    I think you want to be looping over your "qAbrvs" record set returned by your earlier query, maybe.
    <cfloop query="qAbrvs">
    Four:
    <cfset output_str = Replace(output_str, "#idx_str#", )  <!--- Is this correct?  I think not. --->
    Continuing on that assumption I would guess you want to replace each instance of the long string with the short string form that record set.
    <cfset output_str = Replace(output_str,qAbrs.TBLNM,qAbrs.ABRV,"ALL")>
    Five:
    </cfloop>               <!--- What am I looping on?  What is the index? How do I do the string replacement? --->
    If this is true, then you are looping over the record set of tablenames and abreviations that you want to replace in the string.

  • Converting Query results into HTML email

    Hi,
    I am using oracle 11g. I' m using the following procedure to send out html emails from a static query in the procedure and it works fine. I wanted to make it dynamic and pass the sql query as a parameter to procedure and build the html tags based on the query. Any thoughts?
    CREATE OR REPLACE PROCEDURE html_sql_results
    is
        v_rows clob;
        v_header clob;
        cursor v_cursor is
        select SR_NO,STATE,DUE_DT,PROCESS_DT,STATUS,DAY_NO,SEQ_NO
        from T_TABLE;
        BEGIN
        v_header := '<table border=1>
                  <tr style=''background:#8DB3E2''>
                  <td><p><b>SR_NO</b></p></td>
                  <td><p><b>STATE</b></p></td>
                  <td><p><b>DUE_DT</b></p></td>
                  <td><p><b>PROCESS_DT</b></p></td>
                  <td><p><b>STATUS</b></p></td>
                  <td><p><b>DAY_NO</b></p></td>
                  <td><p><b>SEQ_NO</b></p></td>
                  </tr>';
        v_rows := Null;
        FOR i in v_cursor
        LOOP
        v_rows  := v_rows ||
                '<tr>
                <td> <p>' || I.SR_NO||'</p></td>
                <td> <p>' || I.STATE||'</p></td>
                <td> <p>' || I.DUE_DT ||'</p></td>
                <td> <p>' || I.PROCESS_DT ||'</p></td>
                <td> <p>' || I.STATUS||'</p></td>
                <td> <p>' || I.DAY_NO ||'</p></td>
                <td> <p>' || I.SEQ_NO||'</p></td>
                </tr> ';
        END LOOP;
        if v_rows is not null then
        v_rows:= v_header ||v_rows ||' </table> ' ;
        dbms_output.put_line(v_rows); 
        email_results(v_rows);
        end if ;
        end ;
    /

    A possible way :
    SQL> var result clob
    SQL> DECLARE
      2
      3    ctx  dbms_xmlgen.ctxHandle;
      4    qry  varchar2(2000) := 'SELECT * FROM hr.employees WHERE department_id = :1';
      5
      6    xsl  xmltype := xmltype('<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
      7   <xsl:output method="html"/>
      8   <xsl:template match="/ROWSET">
      9    <table border="1">
    10     <tr style="background:#8DB3E2">
    11      <xsl:for-each select="ROW[1]/*">
    12       <td><p><b><xsl:value-of select="name()"/></b></p></td>
    13      </xsl:for-each>
    14      <xsl:apply-templates/>
    15     </tr>
    16    </table>
    17   </xsl:template>
    18   <xsl:template match="ROW">
    19    <tr><xsl:apply-templates/></tr>
    20   </xsl:template>
    21   <xsl:template match="ROW/*">
    22    <td><p><b><xsl:value-of select="."/></b></p></td>
    23   </xsl:template>
    24  </xsl:stylesheet>');
    25
    26    res  clob;
    27
    28  BEGIN
    29
    30    ctx := dbms_xmlgen.newContext(qry);
    31    dbms_xmlgen.setBindValue(ctx, '1', 90);
    32    dbms_xmlgen.setNullHandling(ctx, dbms_xmlgen.EMPTY_TAG);
    33    dbms_xmlgen.setXSLT(ctx, xsl);
    34
    35    :result := dbms_xmlgen.getXML(ctx);
    36    dbms_xmlgen.closeContext(ctx);
    37
    38    --dbms_output.put_line(res);
    39
    40  END;
    41  /
    PL/SQL procedure successfully completed.
    SQL> print result
    RESULT
    <table border="1"><tr style="background:#8DB3E2"><td><p><b>EMPLOYEE_ID</b></p></
    td><td><p><b>FIRST_NAME</b></p></td><td><p><b>LAST_NAME</b></p></td><td><p><b>EM
    AIL</b></p></td><td><p><b>PHONE_NUMBER</b></p></td><td><p><b>HIRE_DATE</b></p></
    td><td><p><b>JOB_ID</b></p></td><td><p><b>SALARY</b></p></td><td><p><b>COMMISSIO
    N_PCT</b></p></td><td><p><b>MANAGER_ID</b></p></td><td><p><b>DEPARTMENT_ID</b></
    p></td><tr><td><p><b>100</b></p></td><td><p><b>Steven</b></p></td><td><p><b>King
    </b></p></td><td><p><b>SKING</b></p></td><td><p><b>515.123.4567</b></p></td><td>
    <p><b>17/06/03</b></p></td><td><p><b>AD_PRES</b></p></td><td><p><b>24000</b></p>
    </td><td><p><b></b></p></td><td><p><b></b></p></td><td><p><b>90</b></p></td></tr
    <tr><td><p><b>101</b></p></td><td><p><b>Neena</b></p></td><td><p><b>Kochhar</b></p></td><td><p><b>NKOCHHAR</b></p></td><td><p><b>515.123.4568</b></p></td><td><
    p><b>21/09/05</b></p></td><td><p><b>AD_VP</b></p></td><td><p><b>17000</b></p></t
    d><td><p><b></b></p></td><td><p><b>100</b></p></td><td><p><b>90</b></p></td></tr
    <tr><td><p><b>102</b></p></td><td><p><b>Lex</b></p></td><td><p><b>De Haan</b></p></td><td><p><b>LDEHAAN</b></p></td><td><p><b>515.123.4569</b></p></td><td><p><
    b>13/01/01</b></p></td><td><p><b>AD_VP</b></p></td><td><p><b>17000</b></p></td><
    td><p><b></b></p></td><td><p><b>100</b></p></td><td><p><b>90</b></p></td></tr></
    tr></table>Typically, XSLT stylesheets may be stored in the database too, so that you can modify and use different presentation templates without touching the code.

  • How to pass a combo box parameter on reporting services?

    How to pass a combo box parameter on reporting services?
    For example, a report has a parameter which is a combo box, its items came from a database query.
    Looks like the combo box didn't got populated and greyed out if I didn't pass the parameter.

    Hi LAScorpion,
    In Reporting Services, if we want to pass a combo box parameter (means signal-parameter) from one report (main report) to another report (subreport), we can enable an action with “Go to report” or “Go to URL” option to achieve the requirement. For more details,
    please see:
    Method1: Go to report
    Right-click a report item to open the properties dialog in subreport, click Action in the left pane.
    Enable Go to report action, then select the main report name in the drop-down list.
    Add a parameter as below:
    Select ID (a parameter name from main report) in the drop-down list of Name, and select [ID] (a field name from subreport) in the drop-down list of Value.
    Method2: Go to URL
    Right-click a report item to open the properties dialog in subreport, click Action in the left pane.
    Enable Go to URL action, the URL below is for your reference:
    ="javascript:void(window.open('http://server_name/ReportServer/Pages/ReportViewer.aspx?%2ffolder_name%2fmain_report_name&rs:Command=Render&parameter_name="& Parameters!parameter_name.Value &"'))"
    Besides, if the parameter’s values are based on other parameters, then the combo-box got greyed out when we haven’t select values in preceding parameters. For more details, please see:
    Cascading Parameters
    If there are any misunderstanding, please elaborate the issue for further investigation.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

Maybe you are looking for