Select list need to pass a value to collect information based on a value on another page

i have a product-detail.php page that is then sent to a cart.php i have a number of tables that are all joined and show in the statement below. the results are displayed on the detail page
$var1_rsProduct = "-1";
if (isset($_GET['productID'])) {
  $var1_rsProduct = $_GET['productID'];
mysql_select_db($database_beau, $beau);
$query_rsProduct = sprintf("SELECT * FROM beauAW13_Cat, beauAW13_products, beauAW13_Stock, beauAW13_SizeList WHERE beauAW13_products.catID = beauAW13_Cat.catID AND beauAW13_products.ProductID = beauAW13_Stock.ProductID AND beauAW13_Stock.SizeID = beauAW13_SizeList.SizeID AND beauAW13_products.ProductID = %s AND beauAW13_Stock.Stock != 0 ", GetSQLValueString($var1_rsProduct, "int"));
$rsProduct = mysql_query($query_rsProduct, $beau) or die(mysql_error());
$row_rsProduct = mysql_fetch_assoc($rsProduct);
$totalRows_rsProduct = mysql_num_rows($rsProduct);
i have a select list that needs to show the sizes.this is shown below
<select name="select" id="select">
                <?php
do { 
?>
                <option value="<?php echo $row_rsProduct['StockID']; ?>"><?php echo $row_rsProduct['Size']?></option>
                <?php
} while ($row_rsProduct = mysql_fetch_assoc($rsProduct));
  $rows = mysql_num_rows($rsProduct);
  if($rows > 0) {
      mysql_data_seek($rsProduct, 0);
            $row_rsProduct = mysql_fetch_assoc($rsProduct);
?>
              </select>
it is currently passing the value of <?php echo $row_rsProduct['StockID']; ?>
which is ok as this is a totally unique number so on the cart page i need to get all the size information from that stockID
here is an example:-
i have used a stockID of 355
on the cart.php the stockID is echoed out as 355 and the size is echoed out as 355 which is what i would expect.
the stock table looks like this
StockID | ProductID | SizeID  |  Stock
  355   |    582    |   14    |    5
so
ProductID is blue jumper
Stock id is unique number
SizeID = 14 = once size
Stock = 5 in stock
so i need to in the cart say
355 = 14 = one size
i can then echoe out the correct size as one size and not 355
i really hope someone can help
thanks

Thanks for everyone advise. I managed to get it working
I sent the stockID on;y to the cart page, made a new variable based on the stockID the made a query and got all the information based on the new stockID variable
<?php
$newStockID = $XCart_StockID = ${$XCName}["contents"][0][$XCart__i];
mysql_select_db($database_beau, $beau);
$query_rsSize = "SELECT * FROM beauAW13_SizeList, beauAW13_Stock WHERE beauAW13_Stock.SizeID = beauAW13_SizeList.SizeID AND beauAW13_Stock.StockID = '$newStockID'";
$rsSize = mysql_query($query_rsSize, $beau) or die(mysql_error());
$row_rsSize = mysql_fetch_assoc($rsSize);
$totalRows_rsSize = mysql_num_rows($rsSize);
                          ?>
select list
<option value="<?php echo $row_rsProduct['StockID']; ?>"><?php echo $row_rsProduct['Size']?></option>

Similar Messages

  • Passing multiple values to another page via a sql report

    Having trouble passing multiple values to another page via a popup SQL report
    I have two fields one called "descr" and another called "Met"
    when I use the code below all works fine and the value of "descr" is passed
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE:'
    || descr
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    But when I want to pass another value, all goes bonkers and instead of the value of the field being passed the literal text is passed.
    can someone look at my code below and see what may be wrong
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE,P950_CODE:'
    || descr, Met
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    I appeciate your help looking into this
    FYI (Here is the entire SQL for reference)
    With t
    as
    (SELECT
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_CPT &gt; :P940_METRIC_1_WCS_CPT1 then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_CPT,'FML999G999G999G999G990D00')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_CPT,'FML999G999G999G999G990D00')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_CPT,'FML999G999G999G999G990D00')||'&lt;/span&gt;' end "WCSCPT",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_TOI_PER_FTE &lt; :P940_METRIC_2_WCS_TOI_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_TOI_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_TOI_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_TOI_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSTOIPERFTE",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_SIO_PER_FTE &lt; :P940_METRIC_3_WCS_SIO_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_SIO_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_SIO_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_SIO_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSSIOPERFTE",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_TC_PER_FTE &lt; :P940_METRIC_4_WCS_TC_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_TC_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_TC_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_TC_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSTCPERFTE",
    CASE WHEN KEY = 2 then
    CASE WHEN WCS_ADSL_PER_FTE &lt; :P940_METRIC_5_WCS_DSL_PER_FTE then
    '&lt;span style="color:Red; "&gt;'||TO_CHAR(WCS_ADSL_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' else
    '&lt;span style="color:#399304; "&gt;'||TO_CHAR(WCS_ADSL_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end
    else '&lt;span style="color:#180c8b;"&gt;'||TO_CHAR(WCS_ADSL_PER_FTE,'999G999G999G999G990')||'&lt;/span&gt;' end "WCSADSLPERFTE",
    CASE WHEN KEY = 2 THEN
    TO_CHAR(MONTH,'MON-YY')
    else
    'METRICS'
    end "MONTH"
    FROM (
    SELECT DISTINCT
    ROW_NUMBER() OVER (ORDER BY KEY DESC) AS ROW_NUM, KEY, WCS_CPT, WCS_TOI_PER_FTE, WCS_SIO_PER_FTE, WCS_TC_PER_FTE, WCS_ADSL_PER_FTE, MONTH
    from TW_M_KEYMETRICS
    WHERE TO_DATE(UPPER(MONTH),'DD/MON/YY') &gt;= TO_DATE(UPPER(:P940_START_OF_THIS_FIN_YEAR),'DD/MON/YY')
    ORDER BY KEY ASC, ROW_NUM, MONTH)
    WHERE ROW_NUM &lt;= :P940_MONTHS_SINCE_FIN_START)
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_METRIC_TYPE,P950_METRIC_VALUE:descr,MET'
    || ''
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    , max(Met) METRICS, max(Jul) Jul08, max(Aug) Aug08, max(Sep) Sep08, max(Oct) Oct08, max(Nov) Nov08, max(Dec)Dec08, max(Jan) Jan08, max(Feb) Feb08, max(Mar) Mar08, max(Apr) Apr08, max(May) May08, max(Jun) Jun08
    from (
    Select 'Cost Per Transaction' descr,
    decode (MONTH, 'METRICS', WCSCPT) MET,
    decode (MONTH, 'JUL-08', WCSCPT) Jul,
    decode (MONTH, 'AUG-08', WCSCPT) Aug,
    decode (MONTH, 'SEP-08', WCSCPT) Sep,
    decode (MONTH, 'OCT-08', WCSCPT) Oct,
    decode (MONTH, 'NOV-08', WCSCPT) Nov,
    decode (MONTH, 'DEC-08', WCSCPT) Dec,
    decode (MONTH, 'JAN-08', WCSCPT) Jan,
    decode (MONTH, 'FEB-08', WCSCPT) Feb,
    decode (MONTH, 'MAR-08', WCSCPT) Mar,
    decode (MONTH, 'APR-08', WCSCPT) Apr,
    decode (MONTH, 'MAY-08', WCSCPT) May,
    decode (MONTH, 'JUN-08', WCSCPT) Jun
    from t
    union all
    Select 'Total Orders Issued Per FTE' descr,
    decode (MONTH, 'METRICS', WCSTOIPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSTOIPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSTOIPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSTOIPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSTOIPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSTOIPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSTOIPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSTOIPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSTOIPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSTOIPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSTOIPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSTOIPERFTE) May,
    decode (MONTH, 'JUN-08', WCSTOIPERFTE) Jun
    from t
    union all
    Select 'SIOs Per Billing FTE' descr,
    decode (MONTH, 'METRICS', WCSSIOPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSSIOPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSSIOPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSSIOPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSSIOPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSSIOPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSSIOPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSSIOPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSSIOPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSSIOPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSSIOPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSSIOPERFTE) May,
    decode (MONTH, 'JUN-08', WCSSIOPERFTE) Jun
    from t
    union all
    Select 'Total Calls Answered per FTE' descr,
    decode (MONTH, 'METRICS', WCSTCPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSTCPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSTCPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSTCPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSTCPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSTCPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSTCPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSTCPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSTCPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSTCPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSTCPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSTCPERFTE) May,
    decode (MONTH, 'JUN-08', WCSTCPERFTE) Jun
    from t
    union all
    Select 'ADSL Orders per FTE' descr,
    decode (MONTH, 'METRICS', WCSADSLPERFTE) MET,
    decode (MONTH, 'JUL-08', WCSADSLPERFTE) Jul,
    decode (MONTH, 'AUG-08', WCSADSLPERFTE) Aug,
    decode (MONTH, 'SEP-08', WCSADSLPERFTE) Sep,
    decode (MONTH, 'OCT-08', WCSADSLPERFTE) Oct,
    decode (MONTH, 'NOV-08', WCSADSLPERFTE) Nov,
    decode (MONTH, 'DEC-08', WCSADSLPERFTE) Dec,
    decode (MONTH, 'JAN-08', WCSADSLPERFTE) Jan,
    decode (MONTH, 'FEB-08', WCSADSLPERFTE) Feb,
    decode (MONTH, 'MAR-08', WCSADSLPERFTE) Mar,
    decode (MONTH, 'APR-08', WCSADSLPERFTE) Apr,
    decode (MONTH, 'MAY-08', WCSADSLPERFTE) May,
    decode (MONTH, 'JUN-08', WCSADSLPERFTE) Jun
    from t
    GROUP by descr
    Frank

    Borg Species 5618 wrote:
    Having trouble passing multiple values to another page via a popup SQL report
    But when I want to pass another value, all goes bonkers and instead of the value of the field being passed the literal text is passed.
    can someone look at my code below and see what may be wrong
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE,P950_CODE:'
    || descr, Met
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    Hi Frank,
    You should close this parameters with single quotation. Try this -
    Select '&lt;a href="javascript:popUp2('''
    || 'f?p=&APP_ID.:950:&SESSION.::&DEBUG.::'
    || 'P950_TYPE,P950_CODE:'
    *|| 'descr, Met'*
    || ''', 790, 460);"style="color:darkred; font-weight: bold;font-size: 90%"&gt;'
    || descr
    || '&lt;/a&gt;' "Note"
    Hope this helps.
    Regards,
    M Tajuddin
    http://tajuddin.whitepagesbd.com

  • Passing multiple values to another page

    I am somewhat new to Coldfusion 9 in a IIS platform through Dreamweaver CS4 and could use some direction.  I am working on a form where someone has submited a request for approval.  The user has requested a bulk approval button for all users that fall under certain filter conditions to do a mass approve ( setting the value to 1).  I have not been able to either pass the values to the current approval method or approve them on the existing page.  Below is the coding for the page as I have it.
    After the filter has applied I need to get the values of the #qRecords.VR_Machine_Participant_Activity_Login_ID# and have them all approve as apposed to doing them individually which they are doing now.  I have looked at several methods, but they are not meeting my needs.  Some information cut for space but left the form action.
    <form name="form1" method="post">
        <table width="996" border="1">
         <tr class="ReportColumnHeadingSmall">
          <td width="150">Approval Needed</td>
          <td width="100">Approved</td>
                            <td width="180">Business Unit</td>                    
         </tr>
         <tr class="data0Small">
          <td>
           <select name="cboApprovalRequired" class="smallFont">
            <!---<option value="All">All</option>--->
                     <option value="1"
             <cfif isDefined("vApprovalRequired")>
              <cfif vApprovalRequired eq 1>
                selected
              </cfif>
             </cfif>
            >True</option>
                     <option value="0"
             <cfif isDefined("vApprovalRequired")>
              <cfif vApprovalRequired eq 0>
                selected
              </cfif>
             </cfif>
            >False</option>
           </select>
          </td>
          <td>
           <select name="cboApproved" class="smallFont">
            <!---<option value="All">All</option>--->
                     <option value="1"
             <cfif isDefined("vApproved")>
              <cfif vApproved eq 1>
                selected
              </cfif>
             </cfif>
            >True</option>
                     <option value="0"
             <cfif isDefined("vApproved")>
              <cfif vApproved eq 0>
                selected
              </cfif>
             </cfif>
            >False</option>
           </select>
          </td>
                              <!--- Drop down showing the current available units to choose from --->
                             <td>
                       <select name="cbo_BusUnit" id="cbo_BusUnit">
                            <cfoutput query="qBusUnit">
                             <option value="#qBusUnit.BusinessUnit#"
                            <cfif (isDefined("vBusUnit") AND vBusUnit is qBusUnit.BusinessUnit)>selected                               </cfif>>#qBusUnit.BusinessUnit#</option>
                              </cfoutput>
                            </select>
                          </td>
    <!--- This is where I'd like to mark the items for approval. --->
                            <td><input type="submit" name="Submit" value="Apply Filter">
                            </td>                       
          <td width="450" align="right">
            This will approve all records displayed on the current page.
                              <input name="bVr_id" type="button" value="Approve">
      <cfoutput query="qRecords"><a href=   "vr_participantactivityapproval.cfm?participant=#qRecords.VR_Machine_Participant_Activity _Login_ID#">
        <img src="../Images/switch_user.gif" alt="Approve" width="16" height="16" border="0"></a>
        </cfoutput>
    </td>
         </tr>
         <tr class="ReportColumnHeadingSmall">
                         <td colspan="3" height="20"></td>
                        </tr>
        </table>
    <table width="996" border="1">
    <tr class="ReportColumnHeadingSmall">
        <td></td>
        <td>Machine or<br>Activity Type</td>
        <td>Activity</td>
        <td>Comments</td>
        <td>Oper.<br>ID</td>
        <td>Name</td>
        <td>Approved</td>
        <td>Login Status</td>
        <td>Login Date Time</td>
        <td>Minutes</td>
    </tr>
    <cfoutput query="qRecords">
    <tr class="data#Int(qRecords.CurrentRow MOD 2)#Small">
    <td>
                        <!--- Current method of approving them individually. --->    
    <a href="vr_participantactivityapproval.cfm?participant=#qRecords.VR_Machine_Participant_Act ivity_Login_ID#"><img src="../Images/switch_user.gif" alt="Approve" width="16" height="16" border="0"></a>
      </td>
      <td class="SmallFont">#qRecords.ActivityType#</td>
    <td class="SmallFont">#qRecords.Activity#</td>
        <td class="SmallFont">#qRecords.Value_Nvarchar#</td>
    <td class="SmallFont">#qRecords.VR_Department_Number#</td>
    <td class="SmallFont">#qRecords.FullName#</td>
    <td class="SmallFont"><cfif #qRecords.Approved# IS 0>False<cfelse>True</cfif></td>
        <td class="SmallFont">#qRecords.Login_Status#</td>
        <td class="SmallFont">#DateFormat(qRecords.Login_Date, 'ddd mm/dd/yyyy')# #TimeFormat(qRecords.Login_Date, 'H:mm')#</td>
        <td class="SmallFont">#qRecords.TotalTime#</td>
    </tr>
    </cfoutput>
    </table>
        </form>

    I suggest displaying all the potential approvees as checked checkboxes.  The user can then uncheck as many as he wants.

  • Passing the values to another page.

    Hi all,
    In the first column of the report is radio buttons
    After selecting the radio button of a row and pressing the button view, has to go the next page where i can view the full details of the row.
    How i should pass the values of the selected row in the view button.
    In other words
    How to refer the report items when pressing a button.
    For eg:
    If i say in URL Target like.....
    javascript:redirect('f?p=&APP_ID.:3:&SESSION.:DISPLAY:NO::P3_ACC_NO:' +#id#+)
    if i put #id# the value is not appearing..
    Could any one please guide me ?
    Thanks in advance
    bye
    Srikavi

    Hello,
    >> only if it is the primary key as you mentioned it is appearing.but, if i put an non-pk column it is not appearing.
    I’m not sure what you mean by that. The onclick event will always set your hidden item according the any database column. In my example it’s ‘empno’, but I don’t see any reason to use any other column in the row. Anyway, the reason to use PK as the passes parameter is that with the PK you can retrieve the entire record on your next page, and use any column you need from the record.
    If I misunderstood you’ please be more descriptive about the problem.
    Regards,
    Arie.

  • Javascript: to pass values to another page

    hi all,
    i hav an interactive report. if i clik on a particular row, that row values must be passed to an another page (via javascript)
    i found this forum https://forums.oracle.com/thread/2467579 in which they hav used it for sending mail.
    but i wanted to pass those values to another page throug javascript bz, i hav installed a plugin nd wrking from it under right clik.
    ma  javascript function  is,
    function func(action,el, pos)
       window.location ="http://apex.oracle.com/pls/apex/f?p=71510:2:&SESSION.:::2:P2_X,P2_X2:'+ $(el).children('td[headers="EMPNO"]').text() +  ',' + $(el).children('td[headers="ENAME"]').text()";
    here i hav redirected it to the 2nd page and in the 2nd page i hav used 2 items to get these values.
    $(el).children('td[headers="EMPNO"]').text() +        ------->  this is to fetch the empno of that particular row and similarly for the name.
    but if i click on the right clik button , no action is happening... 
    but its working fine, if i use the function as,
    function func(action,el, pos)
       window.location ="http://apex.oracle.com/pls/apex/f?p=71510:2:&SESSION.";
    so somewhere is going wrong in passing the values in URL i suppose....
    and i hav used al d above things in
    http://apex.oracle.com/pls/apex/f?p=71510:1 (username: test / paswrd: pex14gm)
    pls help me out.....
    thanks in advance

    Try like this.
    function func(action,el, pos){
        var empNum = $(el).children('td[headers="EMPNO"]').text();
        var eName  = $(el).children('td[headers="ENAME"]').text();
        window.location ='http://apex.oracle.com/pls/apex/f?p=71510:2:&SESSION.:::2:P2_X,P2_X2:'+empNum+','+eName;
    It looks simple and neat.
    If you still didn't get post me workspace details.

  • Passing column values to another tab if check box selected in that row

    Hi
    I have the following requirement.
    I have a table that gets populated by a web service. Have added one more field to it which is a check box. Th requirement is that I need to pass the values of column (say id) from each row which has it's check box selected, as input parameters to a web service in another tab.
    example: table has fileds id, name, address,checkbox. If there are 5 rows and the user select 1 and 2 then I need the ids of 1 and 2 to be passed to another tab.
    Is this possible  ........
    Thanks

    Hi
    I just don't want to make multiple selection but pass the values of a column from the selected rows to another tab to be used as input parameters to a web service.
    I want to know how to pass the values(of one filed) of the selected rows across tabs/switches.
    Thanks

  • I have SSRS parametarized report in that one data set have repeated values with query parameter . but while am mapping that query parameter to report parameter i need to pass distinct values. How can i resolve this

    I have SSRS parametarized report in that one data set have repeated values with query parameter . but while am mapping that query
    parameter to report parameter i need to pass distinct values. How can i resolve this

    Hi nancharaiah,
    If I understand correctly, you want to pass distinct values to report parameter. In Reporting Service, there are only three methods for parameter's Available Values:
    None
    Specify values
    Get values from a query
    If we utilize the third option that get values from a dataset query, then the all available values are from the returns of the dataset. So if we want to pass distinct values from a dataset, we need to make the dataset returns distinct values. The following
    sample is for your reference:
    Select distinct field_name  from table_name
    If you have any other questions, please feel free to ask.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

  • Need to pass the value from UI

    Hi!!
    I am using jdeveloper 11.1.1.5
    I had dragged and dropped Three Input Text Boxes in my UI
    I need to pass the values from the UI to my AMImpl Methods
    i.e. In my AMImpl Methods
    vo2.setNamedWhereClauseParam("year",[af:ImputTextBox1]);
    vo2.setNamedWhereClauseParam("period",[af:ImputTextBox2]);
    vo2.setNamedWhereClauseParam("bu",[af:InputTextBox3]);
    vo2.executeQuery();

    The links given by Vinoth and jabr is very usefull for me!!
    Still i m receiving an while i clicked the button
    Cannot convert MEL of type class java.lang.String to class oracle.adf.view.rich.component.rich.input.RichInputText
    Cannot convert 201011 of type class java.lang.String to class oracle.adf.view.rich.component.rich.input.RichInputText
    Cannot convert 5 of type class java.lang.String to class oracle.adf.view.rich.component.rich.input.RichInputTextEdited by: wilhelm wundt on Dec 18, 2011 10:00 PM

  • 2 Select lists do not change the value

    Hi all,
    I am having a situation. I have 2 select lists . The second one is dependent of the first one. Data are retrieved perfectly.
    These select lists are done in page 0 and they are used in the referenced page. Apexlib is used in the page 0
    When I change the item of the second list, the returned value used in a report, is ok. It takes the correct one.
    If I change the item of the fist select list, the returned value of the second select list does not change(the displayed value are correct). the report is run (after changing the first select list) but the wrong returned value of the second list is taken.
    The correct value of the second one is taken only if page is submited or we change the option.
    it seems that it keeps the last value of the second list according to the previous selection.
    Both select list is without submit.
    How can I make a "refresh" of the returned values of the second select list (the records are ok) after changing the first one?
    Thanks in advance
    Raf

    Hi Rafael,
    is ApexLib integrated correct? Did you check against http://apexlib.oracleapex.info/howto_integrate_manual_steps.html ?
    Or did you try and install the ApexLib Feature Demonstration Application and see if it works there?
    brgds,
    Peter
    Blog: http://www.oracle-and-apex.com
    ApexLib: http://apexlib.oracleapex.info
    Work: http://www.click-click.at

  • How can I pass a value into a page fragment?

    How can I pass a value into a page fragment?
    I am implementing four search screens. And the only thing different about them will be their backing bean.
    So I’d like to do something like have four pages, each which retrieves its appropriate backing bean, sets that bean to a variable, and then includes a page fragment which contains the generic search page code (which will make use of that variable).
    The code in the four pages would be something like this:
    <?xml version='1.0' encoding='windows-1252'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0"
    xmlns:c="http://java.sun.com/jsp/jstl/core">
    <jsp:directive.page contentType="text/html;charset=windows-1252"/>
    <c:set var="searchPageBackingBean"
    value="#{pageFlowScope.employeeSearchPageBean}"
    scope="page"/>
    <jsp:include page="./SearchPageBody.jsff"/>
    </jsp:root>
    At this point, what I’m seeing is that the fragment page, SearchPageBody.jsff, has no visibility of the searchPageBackingBean variable, either referencing it as #{pageFlowScope.searchPageBackingBean} or just #{searchPageBackingBean}

    The following will work, assuming you are needing to access a managed bean:
    Put this in the parent page:
    <c:set var="nameOfSearchPageBackingBean"
    value="employeeSearchPageBean"
    scope="request"/>
    Put this in the child, SearchPageBody.jsff:
    <c:set var="searchPageBean"
    value="#{pageFlowScope[nameOfSearchPageBackingBean]}"
    scope="page"/>

  • Passing the values between two pages

    hi all,
    I am trying to pass the value from one page to another page. by referring the Link
    http://www.youtube.com/watch?v=4eyzBiIf5MM&feature=related
    I have created the code based on the demo. it is deployed without any issues. but when i press the hyperlink from the first page it is not moving to the second page.
    Regards
    C.Karukkuvel

    Hi john,
    My Requirement is to create a ADF page based on the Human Task with the Default payload. In that page when the user presses the empid link field, It will show all the information related to the employee id in a separate page.
    so ,
    1. i have created the View Object based on the Query with where clause
    2. Create a bind variable for the where clause
    3.Created s new page for displaying the employee details
    4.drag and drop the both the pages (employee details, default page created by human task) into the adfcconfig file.
    5.drag and drop the Execute with params into the adfcconfig file
    6.wire it from human task page --> execute with params--> Employee details page
    7.change the employee field in that human task page to a link field.
    8.drag and drop the set property listener to that employee field.
    Testing
    Enter the input values for the Web service, logging to the BPM worklist, double click that task .it is showing the details when I press the employee id it is not navigating to the employee details page.
    Thanks in advance
    C.Karukkuvel

  • How to retrieve a page item value in another page?

    Hi,
    how to retrieve a page item value in another page?
    say P55_COURSES_TO_EVALUATE is my page item name and it is a select list.Based on the value selected,in the next page i shd show details related to the selected value and for this i need P55_COURSES_TO_EVALUATE value in the next page.How Do I get it?When I try to retrieve the values it simply returns nothing.
    Any pointers would be really helpful.
    Thanks in advance.

    Hi,
    Could you please tell how you try use it ?
    If you set value to item P55_COURSES_TO_EVALUATE and submit page, value is saved to session state.
    Then you can use that item in any page like
    :P55_COURSES_TO_EVALUATEYou can not access page value in javascript/jQuery from other pages like
    $v('P55_COURSES_TO_EVALUATE')
    document.getElementbyID('P55_COURSES_TO_EVALUATE')
    $(#P55_COURSES_TO_EVALUATE)Because item is not in other pages. In javascript from other pages you can use
    var a = '&P55_COURSES_TO_EVALUATE.';Regards,
    Jari

  • Dynamic select list with more than one value?

    I am creating a simple CRUD component for our company's Joomla site. This component allows our users to create discount bundles for our cart according to shopper group and products.  I've been using Dreamweaver to author the administrator forms and have run into a bit of a problem.  All of my forms work properly, but I need to be able to collect two values from each chosen multi-select listing. 
    Right now, when a user chooses an item under 'products', the site pushes back product_id, one of the variables I need.  I would also like product_parent_id to return with each result as well.  I need to be able to insert product_parent_id after the user has chosen their desired products.  product_parent_id is located in the same table as product_id.
    In the end, I need those two values to be pushed to another table, essentially creating a new entry for each product in the bundle.  Referenced by ID and parent ID.
    Pasted below is the administrator form code.  Any suggestions would be wonderful.
    Thanks!
    <?php require_once('Connections/SQLTest.php'); ?>
    <?php
    if (!function_exists("GetSQLValueString")) {
    function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
      if (PHP_VERSION < 6) {
        $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
      $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
      switch ($theType) {
        case "text":
          $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
          break;   
        case "long":
        case "int":
          $theValue = ($theValue != "") ? intval($theValue) : "NULL";
          break;
        case "double":
          $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
          break;
        case "date":
          $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
          break;
        case "defined":
          $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
          break;
      return $theValue;
    $editFormAction = $_SERVER['PHP_SELF'];
    if (isset($_SERVER['QUERY_STRING'])) {
      $editFormAction .= "?" . htmlentities($_SERVER['QUERY_STRING']);
    if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
      $insertSQL = sprintf("INSERT INTO jos_vm_related_products (product_id, related_product_id) VALUES (%s, %s)",
                           GetSQLValueString($_POST['products'], "int"),
                           GetSQLValueString($_POST['products'], "int"));
      mysql_select_db($database_SQLTest, $SQLTest);
      $Result1 = mysql_query($insertSQL, $SQLTest) or die(mysql_error());
    if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
      $insertSQL = sprintf("INSERT INTO jos_vm_relations (discount_type, discount, shopper_group_id) VALUES (%s, %s, %s)",
                           GetSQLValueString($_POST['amount_off_total'], "text"),
                           GetSQLValueString($_POST['dollar_amount'], "int"),
                           GetSQLValueString($_POST['shoper_group'], "int"));
      mysql_select_db($database_SQLTest, $SQLTest);
      $Result1 = mysql_query($insertSQL, $SQLTest) or die(mysql_error());
    if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) {
      $insertSQL = sprintf("INSERT INTO jos_vm_relations_messages (discount_message) VALUES (%s)",
                           GetSQLValueString($_POST['discount_message'], "text"));
      mysql_select_db($database_SQLTest, $SQLTest);
      $Result1 = mysql_query($insertSQL, $SQLTest) or die(mysql_error());
    $maxRows_Products = 10;
    $pageNum_Products = 0;
    if (isset($_GET['pageNum_Products'])) {
      $pageNum_Products = $_GET['pageNum_Products'];
    $startRow_Products = $pageNum_Products * $maxRows_Products;
    mysql_select_db($database_SQLTest, $SQLTest);
    $query_Products = "SELECT * FROM jos_vm_product";
    $query_limit_Products = sprintf("%s LIMIT %d, %d", $query_Products, $startRow_Products, $maxRows_Products);
    $Products = mysql_query($query_limit_Products, $SQLTest) or die(mysql_error());
    $row_Products = mysql_fetch_assoc($Products);
    if (isset($_GET['totalRows_Products'])) {
      $totalRows_Products = $_GET['totalRows_Products'];
    } else {
      $all_Products = mysql_query($query_Products);
      $totalRows_Products = mysql_num_rows($all_Products);
    $totalPages_Products = ceil($totalRows_Products/$maxRows_Products)-1;
    mysql_select_db($database_SQLTest, $SQLTest);
    $query_shopper_group = "SELECT * FROM jos_vm_shopper_group";
    $shopper_group = mysql_query($query_shopper_group, $SQLTest) or die(mysql_error());
    $row_shopper_group = mysql_fetch_assoc($shopper_group);
    $totalRows_shopper_group = mysql_num_rows($shopper_group);
    ?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>
    </head>
    <body>
    <form id="form1" name="form1" method="POST" action="<?php echo $editFormAction; ?>">
      <p>
        <label for="products"></label>
      Choose the product(s) you would like to add to your new discount bundle.</p>
      <p>
        <select name="products" size="1" multiple="MULTIPLE" id="products">
          <option value=""></option>
          <?php
    do { 
    ?>
          <option value="<?php echo $row_Products['product_id']?>"><?php echo $row_Products['product_name']?></option>
          <?php
    } while ($row_Products = mysql_fetch_assoc($Products));
      $rows = mysql_num_rows($Products);
      if($rows > 0) {
          mysql_data_seek($Products, 0);
      $row_Products = mysql_fetch_assoc($Products);
    ?>
        </select>
      </p>
    <p>
      <input type="hidden" name="hiddenField" id="hiddenField" />
      </p>
      <p>Choose the subscriber group that you would like this discount to apply to.</p>
      <p>
        <select name="shoper_group">
          <?php
    do { 
    ?>
          <option value="<?php echo $row_shopper_group['shopper_group_id']?>"><?php echo $row_shopper_group['shopper_group_name']?></option>
          <?php
    } while ($row_shopper_group = mysql_fetch_assoc($shopper_group));
      $rows = mysql_num_rows($shopper_group);
      if($rows > 0) {
          mysql_data_seek($shopper_group, 0);
      $row_shopper_group = mysql_fetch_assoc($shopper_group);
    ?>
        </select>
      </p>
      <p>Please enter the dollar amount that you would like to adjust.
        <label for="dollar_amount"><br />
        </label>
        <input type="text" name="dollar_amount" id="dollar_amount" />
      </p>
      <p>
        <input name="amount_off_total" type="hidden" id="amount_off_total" value="amount_off_total" />
      </p>
      <p>Enter any message you would like the shopper to view during shopping and checkout when this discount is applied.</p>
      <p>
        <label for="discount_message"></label>
        <textarea name="discount_message" id="discount_message" cols="45" rows="5"></textarea>
      </p>
      <p>
        <input type="hidden" name="MM_insert" value="form1" />
      </p>
      <p>
        <input type="submit" name="submit" id="submit" value="Submit" />
      </p>
    </form>
    <br />
    </body>
    </html>
    <?php
    mysql_free_result($Products);
    mysql_free_result($shopper_group);
    ?>

    Thanks guys for you reply , [Cor Ligthert] I post this in Visual basic section, I appreciate your solution [dbasnett],
    Thanks for that idea of attribute <Flags> [Blackwood] ,
    Dictionary will not work in IF Statement as I want it , also ParamArray tbl() , thanks guys.
    Here is the code
    Module myModule
    <Flags()>
    Enum Table As Integer
    Table1 = 2
    Table2 = 4
    Table3 = 8
    Table4 = 16
    Table5 = 32
    End Enum
    Public Sub MySub(ByVal Table As Table)
    If (Table And Table.Table1) = Table.Table1 Then
    MsgBox((Table And Table.Table1))
    End If
    If (Table And Table.Table2) = Table.Table2 Then
    MsgBox((Table And Table.Table2))
    End If
    If (Table And Table.Table3) = Table.Table3 Then
    MsgBox((Table And Table.Table3))
    End If
    If (Table And Table.Table4) = Table.Table4 Then
    MsgBox((Table And Table.Table4))
    End If
    If (Table And Table.Table5) = Table.Table5 Then
    MsgBox((Table And Table.Table5))
    End If
    End Sub
    End Module
    Class Myclass
    Private sub CallTables()
    MySub(Table.Table1 Or Table.Table2)
    MySub(Table.Table2 Or Table.Table3 Or Table.Table4)
    MySub(Table.Table1 Or Table.Table4 Or Table.Table5)
    MySub(Table.Table1 Or Table.Table2 Or Table.Table4 Or Table.Table5)
    MySub(Table.Table1 Or Table.Table2 Or Table.Table3 Or Table.Table4 Or Table.Table5)
    end sub
    end Class

  • Select list not setting a return value

    I have defined a select list based on a named LOV. With the default values for the SOURCE section I do not seem to be getting a value returned, as indicated in the following debug output:
    0.05: parse query
    0.05: binding: ":P1_SALESMANAGER_SHOW"="P1_SALESMANAGER_SHOW" value=""
    0.05: print column headings
    0.05: rows loop: 15 row(s)
    no data found
    If I change the Source Type to SQL Query and enter the query in Source Value or Expression I get the behaviour I would expect that the value returned is always the first row returned by the query, no matter which one I pick from the list.
    What do I need to set so it behaves correctly?
    Thanks
    Andy

    How do I generate all the page item attributes to send you? What do you mean by "see the page" - do you want me to submit the generated HTML source?
    In the meantime, I have dropped the select list item and am now re-creating it as follows:
    - Click the Item Create icon
    - Choose Select List
    - For Select List Control Type, accept the default of Select List and click Next.
    - Item name = P1_SALESMANAGER_SHOW and click Next
    - Choose a named LOV, enter null value / text and click Next
    - Accept default item attributes and click Next, then Create Item
    This is exactly in accordance with the instructions for the example page in Chapter 2 of the 2-day Tutorial.
    Run the page, exactly the same result. Clicking Debug shows that P1_SALESMANAGER_SHOW .value is set to null, even though I have picked one of the displayed values.
    I need to do a proof-of-technology demo of HTMLDB to my managers this week so would really appreciate your advice to get this going.
    Thanks,
    Andy

  • Select List with Submit Not pulling % values

    Hello All,
    I have a tabular form in app and displays data based on choice selected in 'select list with submit' from Item, it works fine for values chosen, when i choose '%' I want to display all the records existing in the tabular form but instead it says 'No Data Found'. How do i solve this ? Kindly advice and help.
    ex:
    Tabular form query-
    select a, b
    from table
    where a like :ITEM
    Item:
    Type: select list with submit
    Named LOV:
    select a d, a r
    from lookup_table order by 1
    Appreciate your response.
    Thanks and Regards,
    Senana

    Hello,
    You need to check what value is returned by select list when you select '%' in the select..
    there is a field display null value as where you can enter '%' and return value of null you can enter 0
    and then modify your tabular form query to
    select a , b from table where a like :ITEM OR :ITEM = 0
    Regards,
    Shijesh

Maybe you are looking for