Passing date criteria in url parameter

Hi,
I want to filter a recordset by a given date.
Create the recordset, if I use a runtime value of #27/11/06#
all the records for that date are returned.
However, when I try to pass the same information through an
URL Parameter it doesn't work.
Is there a problem with passing this info in that way?
Thanks, Mark.

No, should be absoloutely fine. The prob is most likely to do
with your SQL
statement.
As a test, don't display any records. At the top of your
page, try
outputting the completed SQL statement onto the page to see
what it looks
like. The problem being you may need to add the # symbols
manually. Should
look something like
"SELECT * FROM TableName WHERE DateField = #" &
URLParameter & "#"
HTH,
Piers

Similar Messages

  • How can I pass empty value in URL Parameter

    Hi,
    I am passing different URL parameters to one page, to filter
    the recordset on that page. How can I pass an empty value in the
    URL parameter so that the recordset in unfiltered?
    The URL parameter is based on one field of the database:
    ContentType. So, the link would be to
    default.asp?ContentType=Event
    and then all records that have the ContentType field in the
    DB as Event are displayed. Is it possible to use this system to
    pass an empty parameter so that all records are displayed?
    Thanks
    Ian

    ?ContentType=All
    <% if (ContentType == "All")
    Build recordset w/o filtering
    ASP is rusty, but those are the basics.
    "iandobie" <[email protected]> wrote in
    message
    news:e8im80$q7m$[email protected]..
    > Hi,
    > I am passing different URL parameters to one page, to
    filter the recordset
    > on
    > that page. How can I pass an empty value in the URL
    parameter so that the
    > recordset in unfiltered?
    > The URL parameter is based on one field of the database:
    ContentType. So,
    > the
    > link would be to
    > default.asp?ContentType=Event
    > and then all records that have the ContentType field in
    the DB as Event
    > are
    > displayed. Is it possible to use this system to pass an
    empty parameter so
    > that
    > all records are displayed?
    > Thanks
    > Ian
    >

  • Problem passing Session variable as URL parameter?

    Hi,
    I am trying to create a multiple page entry form using
    coldfusion session. But I am having some problem when passing the
    session variable to url parameter. For test purpose I have created
    the following code:
    <cfif Not IsDefined("SESSION.AE")>
    <!--- If structure undefined, create/initialize it
    --->
    <cfset SESSION.AE = StructNew()>
    <!--- Represent current form srep; start at one --->
    <cfset SESSION.AE.StepNum = 1>
    </cfif>
    <cfif IsDefined("Form.GoBack")>
    <cfset SESSION.AE.StepNum = #url.StepNum# - 1>
    <cfelseif IsDefined("Form.Next")>
    <cfset SESSION.AE.StepNum = #url.StepNum# + 1>
    </cfif>
    <html>
    <head>
    <title>Untitled Document</title>
    <meta http-equiv="Content-Type" content="text/html;
    charset=iso-8859-1">
    </head>
    <body>
    <form method="post"
    action="/AE/try.cfm?StepNum=#SESSION.AE.StepNum#">
    <input type="submit" name="GoBack" value="Back">
    <input type="submit" name="Next" value="Next">
    </form>
    </body>
    </html>
    When run it I get the following error:
    The value "" cannot be converted to a number
    The error occurred in C:\CFusionMX\wwwroot\AE\try.cfm: line
    11
    9 : <cfset SESSION.AE.StepNum = #url.StepNum# - 1>
    10 : <cfelseif IsDefined("Form.Next")>
    11 : <cfset SESSION.AE.StepNum = #url.StepNum# + 1>
    12 : <!---<cfset SESSION.AE.StepNum = #url.StepNum# +
    1>--->
    13 : </cfif>
    I couldn't figure out where is the problem. Any help is
    really appreciated.
    Thanks in advance.

    You are mixing up your gets and posts aren't you?
    You have your form method set to post which creates form
    variables not
    url variables. So when you try to use the url variable to set
    your
    session it does not exist.
    Change your SESSION.AE.StepNum = #url.StepNum# to
    Session.AE.StepNum =
    form.StepNum, note there is no need for the #'s.
    OR
    change your form method="post" to form method="get"
    Nagelia wrote:
    > Hi,
    >
    > I am trying to create a multiple page entry form using
    coldfusion session. But
    > I am having some problem when passing the session
    counter to url parameter. For
    > test purpose I have created the following code:
    >
    > <cfif Not IsDefined("SESSION.AE")>
    > <!--- If structure undefined, create/initialize it
    --->
    > <cfset SESSION.AE = StructNew()>
    > <!--- Represent current form srep; start at one
    --->
    > <cfset SESSION.AE.StepNum = 1>
    > </cfif>
    > <cfif IsDefined("Form.GoBack")>
    > <cfset SESSION.AE.StepNum = #url.StepNum# - 1>
    > <cfelseif IsDefined("Form.Next")>
    > <cfset SESSION.AE.StepNum = #url.StepNum# + 1>
    > </cfif>
    >
    > <html>
    > <head>
    > <title>Untitled Document</title>
    > <meta http-equiv="Content-Type" content="text/html;
    charset=iso-8859-1">
    > </head>
    > <body>
    > <form method="post"
    action="/AE/try.cfm?StepNum=#SESSION.AE.StepNum#">
    > <input type="submit" name="GoBack" value="Back">
    > <input type="submit" name="Next" value="Next">
    > </form>
    > </body>
    > </html>
    >
    > When run it I get the following error:
    >
    > The value "" cannot be converted to a number
    >
    >
    > The error occurred in C:\CFusionMX\wwwroot\AE\try.cfm:
    line 11
    >
    > 9 : <cfset SESSION.AE.StepNum = #url.StepNum# - 1>
    > 10 : <cfelseif IsDefined("Form.Next")>
    > 11 : <cfset SESSION.AE.StepNum = #url.StepNum# +
    1>
    > 12 : <!---<cfset SESSION.AE.StepNum =
    #url.StepNum# + 1>--->
    > 13 : </cfif>
    >
    > I couldn't figure out where is the problem. Any help is
    really appreciated.
    >
    > Thanks in advance.
    >
    >
    >
    >

  • Passing file location as URL parameter for xml query

    Hi all,
    A quick question regarding using a parameter to set the source URL in an XML query template.
    When assigning the URL, the static text works perfectly eg:
    //<servername>/<folder>/samplefile.xml . The xml is returned as required.
    However, we wish to call this from a BLS txn and set the source URL dynamically.
    To test this we assigned //<servername>/<folder>/samplefile.xml to Parameter no 1 and insert [Param.1] in the source URL field. No luck.
    Any suggestions?
    Cheers
    Mark

    Mark,
    In BLS, the double slashes (escaping the single /) are only necessary if you are building the full http url string in the link editor.
    If your XMLQuery template is something like http://localhost/Folder/Subfolder/[Param.1] then put in a default param value in the query template and make sure the query test works.  Then configure (or reconfigure) this in your BLS transaction and generate the sample results.  All you should have to do in BLS then is to assign your Transaction or Local property to the Param.1 link in your XMLQuery action block.  All of the dynamic replacement and subsequent xml file retrieval should then be done by the XMLQuery itself.
    If you can keep the majority of the URL in the XMLQuery itself and then just dynamically pass it the Param.1 piece it will be very easy to test and configure (also use localhost if the file lives on the xMII web server), but if you have to build the string external in BLS I would recommend using a combination of the expression editor and a Local property.  If the Local string property contains the base of http://localhost/Folder/Subfolder/ (no quotes or character escaping needed for the default value of a string property) then just assign something like the following to your Param.1 property of the XMLQuery:  Local.URLBase & "filename.xml" (a simple evaluate will confirm your efforts).
    Regards,
    Jeremy

  • Passing Hidden varable in URL

    Hi,
    I am trying to pass hidden variable as URL parameter.
    Please could someone correct me what is wrong here as I always get null value though there is a value in folderId:
    <input type=hidden id="folderId" value='<c:out value="${bean.folderId}"/>'/>
    //passing hidden variable in URL:
    <form method="POST" name="frmWorkFlow" id="frmWorkFlow" action="../../jsp/actions/workFlow.do?folderId=${folderId}">Thanks

    Which do you want to do?
    As a hidden field on the page and submit the form (which will then pass it as a parameter)
    Or building it up on the URL - where you don't need the hidden field at all.
    Personally I prefer using a hidden field.
    A form only submits the input fields nested within it.
    Solution: Put your <input type="hidden"> between the <form> </form> tags.
    Oh, and the reason its not working right now is that ${folderId} is null where ${bean.folderId} probably isn't.
    EL variables can not access the hidden field values directly - they're for use on the client end only.

  • Pass data parameter from URL to Forms

    Hi
    Is it possible to pass a data parameter from asp to Forms?.
    In my asp I have a url to call a form (eg. http://servername:port/forms90/f90servlet/form=testform.fmx). In my testform.fmx I accept 'account no' as a parameter for querying the records. Since I am calling this form from asp, I already have the account no in my asp. I would like to pass this account no to the form automatically.
    Is it possible to pass this data parameter from url to forms?.
    If possible, what changes to be made in the form. Please help.
    sreekumar

    Create a parameter in your form, there's a node for it in the Navigator window. Imagine it is called myParam.
    Pass it on the URL like this:
    http://host/forms90/f90servlet?config=myApp&otherParams=myParam=somevalue
    Regards,
    Robin Zimmermann
    Forms Product Management

  • How to pass a form value  as a url parameter??

    I have following form and I want to pass the selected value of the drop down choice in as one of the parameter in the URL. How can I do that ??
    something like proposalid that I have done in the url, I want to pass the selected value of the variable doc_id, when I click the Link button
    <form name = "link" method="POST" enctype="multipart/form-data" action="<%= request.getScheme() %>://<%= request.getServerName() %>/webAppCore/common/add_doc.jsp">
    <table>
         <tr> <td class="tableContent"> Doc Identifier: </td>
    <td class="tableContent"> <SELECT name="doc_id">
    <%
         Vector v = iddata.getDocumentIdList(tabName);
         //out.println(v);
         if (v != null && v.size() > 0) {
              for (int i = 0; i < v.size(); i++) {
              Hashtable hash = (Hashtable) v.elementAt(i);
    %>
    <OPTION selected name="id " value="<%=(String)hash.get("DOCUMENT_ID")%>"> <%=(String)hash.get("DOCUMENT_NAME")%></OPTION>
    <% } } else {%>
         <OPTION selected name="id " value="test"> No DocIDs</OPTION>
    <%}%>
    <tr> <td colspan = "2">
         <table border="1" width="200">
              <tr> <td> <input type="text" name="link_file" size="30" value=""/></td><td> <INPUT TYPE=button VALUE="Link..." onClick="window.open('<%= request.getScheme() %>://<%= request.getServerName() %>/webAppCore/common/link.jsp?proposalid=<%=proposalID>','mywindow','toolbar=no,location=no,directories=yes,status=yes,menubar=no,scrollbars=yes,resizable=yes,width=400,height=300,left=20,top=20');"></td> </tr>
              <tr> <td colspan = "2">
                   To Create Links: <br>
                   * Select Doc Identifier
                   * Click on Link...to select file within eFile. <br>
                   * Click Add to create the Link <br>
              </td> </tr>
         </table>
         </tr>

    if - in your form declaration - you change your method to GET from POST, it will append the form data onto the URL string instead of putting it in the request header. For instance, if you have a form with an input called THE_INPUT, and you submit to a servlet (or script of some kind or whatever) when the value of that text box is "foo", the URL will be:
    http://www.yourdomain.com/yourservlet?THE_INPUT=foo
    But, if you use the POST method, the URL will just be:
    http://www.yourdomain.com/yourservlet
    Is that what you meant?

  • How to pass mysql query id through url parameter to a detail page

    Hi there,
    I am a newbie to JSP and I am trying to pass a url parameter to a detail page so that it will query a mysql data query to show the details of that query. How can I write the query on the details page so that it will display the query results on the page. eg select * From data Where = "passed_url parameter_ value". Please i need urgent help on this please.

    <Acknowledged>
    which should be strongly cautioned against even for "newbies".
    </Acknowledged>
    Right, but the code you posted will "work" in a very harmful wayNot always, I used normal Statements last year and I had no problems.
    Even with pretty capible code brakers trying to cause $h!t with my application.
    Just check for invalid datatypes, and for SQL Injections remove stuff like ' or replace with `
    But yes PStat... are the better way.

  • Problem in passing Modified date through Go url

    Hi All
    I am trying to pass parameters through url to report.
    Its working fine and passing row id of the record but when i try to pass modified date also, it takes me to no result view where i can see that value has been passed to report but the results are not filtered, instead no result view.
    While passing date in url as parameter do we have extra consideration?
    Anybody has faced smilar kind of scenario.

    I am getting the following error when trying to pass modified date for oppty.
    Error getting drill information: SELECT Opportunity.Name saw_0, Opportunity."Opportunity ID" saw_1, Opportunity."Sales Type" saw_2, Opportunity.Priority saw_3, Opportunity."Last Modified" saw_4 FROM "Opportunity Lists" WHERE (Opportunity."Opportunity ID" = 'AAPA-6EEC9X') AND (Opportunity."Last Modified" = timestamp '0000-00-00 00:00:00')
    Error Details
    Error Codes: YQCO4T56:OPR4ONWY:U9IM8TAC:OI2DL65P
    Odbc driver returned an error (SQLExecDirectW).
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 46048] Datetime Month value 0 from 0000-00-01 is out of range. (HY000)
    SQL Issued: {call NQSGetLevelDrillability('SELECT Opportunity.Name saw_0, Opportunity."Opportunity ID" saw_1, Opportunity."Sales Type" saw_2, Opportunity.Priority saw_3, Opportunity."Last Modified" saw_4 FROM "Opportunity Lists" WHERE (Opportunity."Opportunity ID" = ''AAPA-6EEC9X'') AND (Opportunity."Last Modified" = timestamp ''0000-00-00 00:00:00'')')                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • How to auto login and pass data (parameter) to ApEx at the same time

    Does anybody know how to automatically login to apex (e.g. from JSP page) and pass a parameter value at the same time? I can use wwv_flow_custom_auth_std to login, I can even choose a page but I cannot pass any data (at least I do not know how). If I use f?p URL syntax I can pass data but there is no way to pass login/password information.
    Any idea? Thanks Jaros

    Jaros -
    You could copy your login page and make the new page "public". On the new page, add a process before the login process that sets the value of application item FSP_AFTER_LOGIN_URL to the report page URL (with the arguments), e.g.,   :FSP_AFTER_LOGIN_URL := 'f?p=&APP_ID.:100:&SESSION.::NO::P100_X,P100_Y:&RPT_VALUE1.,&RPT_VALUE2.';Create application-level items RPT_VALUE1 and RPT_VALUE2 in the application.
    From your external page, POST to this new "login" page, passing values for the username, password, rpt_value1, and rpt_value2 items.
    Let us know if it works.
    Scott

  • How to pass dates as parameters in GO URL?

    Hi,
    Can we pass date values as parameters in GO URL?
    I have a date column in my source report that I would like to pass as filter parameter to target reports via GO URL. Could you please let me know the correct syntax if this is possible?

    How can i convert the CHAr to date in the target?? I am using the below syntax and it is receiving a value of 20-JUL-2011.
    '<a href="http://sunt2000-10.wfs.com:9704/analytics/saw.dll?GO&path=/shared/WFS%20Financials/WFS%20Business%20Aviation/WFS%20Business%20Aviation%20Retail%20Volume&Action=Navigate&P0=1&P1=eq&P2="WFS%20Day%20Date"."Calendar%20Date"&P3=' || CAST("WFS Day Date"."Calendar Date" AS CHAR)  || ' ">QTY(USG)</a>'
    I need to convert this as a DATE when navigating to a different page to pass as a parameter.

  • How to pass url parameter string to a query

    I need urgent help please, to pass a mysql query string from a master page to another details jsp page using a url parameter. The master page's url parameter looks like this;
    <a href="Details.jsp?jobs=<c:out value="${row.actions_id}"/>"><c:out value="${row.action_title}"/></a>How can I query the mysql database using the url query string to get the query details.
    Please help me out with detailed example please.

    You can get the parameter value using HttpServletRequest#getParameter():String jobs = request.getParameter("jobs");You can interact with databases using the JDBC API. This is a different topic. If you aren't familiar with it yet, then learn it. There is a very good JDBC tutorial here at Sun.com: [http://java.sun.com/docs/books/tutorial/jdbc/index.html]. Once you're familiar with that, create a DAO class which does the all the database interaction tasks. Create a method which takes the jobs value as parameter and let it return result(s) accordingly. You may find this article useful either: [http://balusc.blogspot.com/2008/07/dao-tutorial-data-layer.html].

  • How to pass date parameter from one page to other in BSP application

    Hello gurus,
    In my BSP application i have taken an input field and made its type "date" and its value also of type date and have set showhelp .
    Now once a particular date is given as an input i want to pass its value to next page. And in next page i have to fire a query based on the date entered in previous page...
    Now my prb is that my date value is not getting passed to the next page.
    I have used
    navigation->set_parameter( name = 'BEGDA' value = BEGDA ).
    to pass date parameter.....still parameter is not getting passed.
    plz help me with this.....
    thankx.....

    Hi Eddy,
    By truncation i mean the entire date becomes 10 char including the ' . ' eg(06.12.2006).
    so with begda being 8chars it takes my date as 06.12.200
    as a result my query is not getting executed.
    now i have tried to use a FM  'CONVERT_DATE_TO_INTERN_FORMAT'.
    in my 1st page but still in 2nd page its giving me following error.
    <b>The data that was read could not be written to the specified target field during a SELECT access. Either the conversion is not supported for the type of the target field, or the target field is too short to accept the value, or the data is not in the appropriateformat for the target field.
    </b>
    Regards
    Swati

  • How to passing multiple values for a parameter of discoverer(url parameters

    Hi All,
    I am trying to pass multiple values for a parameter of disco report. I am trying to include my url for discoverer viewer report. the values has the following
    'jeff,mark'
    'sfophiee,angela'
    Thanks and Regards
    Venkat

    Hello Venkat,
    I know there are some problems with 10.1.2.0.2, maybe if you haven't done yet you can try with 10.1.2.2, assuming this version should be working for multiple parameter values :
    OracleAS Discoverer 10.1.2.2 is installed with the following patch :
    Patch 4960210 PLACEHOLDER BUG FOR AS/DS 10G R2 PATCH SET 2 10.1.2.2
    So, once installed you can try adding your parameter as param_<parameter_name>='sfophiee,angela'
    Hope this helps, otherwise feel free to log a Service Request to Support.
    Best Regards,
    Gianluca

  • Passing data and command in url of the page

    Hi,
    I have a developed a page which has material as input field on first page
    now on press of button on that page ,it feteches the data related to that material in the input processing of that page and display output on other page.
    now i want to display out directly ,supressing the first page.
    so is there a way where i can pass data + command (button press) in the url of that page so it will execute on i/p processing of this page directly and displays the o/p on other page.
    for eg...  ?matnr=x.....(what to write for button click so it executes on i/p processing directly)
    Remember my code for fetching the data is on the first page in input processing,so i need to call this page itself.

    Hi Sushi,
    I wouldn't do it quite the way you are - I would only build one page.
    Make MATNR an auto page attribute. Then in <i>onInitialization</i> you can test
    if MATNR is not initial.
    and then fetch the data.
    In the layout you can either display the input field, call it MATNR, and any error messages from the fetch data code or if the data was fetched okay display the results.
    Now you can call the page with <i>?matnr=X</i> and it will work.
    Cheers
    Graham Robbo

Maybe you are looking for