Use a Parameter or Formula in the Date() function

I am trying to filter a result set utilizing the Date() function.  I am trying to get all of the data between June 1st of a given year, and a parameterized date.  Here is the formula
{ReportStatic.rpsActualSaleDate} >= Date({@fPrevioustoLastYear}, 7, 1)
and {ReportStatic.rpsActualSaleDate} < DateAdd("yyyy", -2, {?pDateEnd})
and {ReportStatic.rpsSaleStatus} = 1
The value of fPrevioustoLastYear is '2008'
The report is returning 0 records.  I think it is because the Date() function isn't recognizing the formula (fPrevioustoLastYear) as a valid input.  However when I "Save and close" the formula editor doesn't find any problems with the formula.
What should I be doing differently?

If {@fPreviousToLastYear} is in fact 2008, I don't see an issue (with the possible exception that it should be a number, not a string; convert with CInt()).  Please post your formula for that field.
Also, I have to ask what the value of {?pDateEnd} is.  If it's like today, no records will fit the criteria because you'd be checking if the date was between 7/1/2008 and 3/29/2008 (you're subtracting 2 years from the parameter), which is a null set.
HTH,
Carl

Similar Messages

  • HT4796 after transfering data froAm my pc to mac using windows migration assist, where do the data go to on my mac please?

    after transfering data froAm my pc to mac using windows migration assist, where do the data go to on my mac please?

    Welcome to the Apple Support Communities
    By default, Migration Assistant creates a new user account where it puts all the transferred data. Just go to  > Log Out, and log in the new user that Migration Assistant has created, so you will be able to access to the transferred data.
    If you want to merge the data into the first user account, use the Shared folder (it's in /Users/Shared) to put the transferred files there, and then, on the first user, go to the Shared folder and put all the data in the folders you want

  • HT5446 If I buy a mac mini with a fusion drive and add windows using boot camp, can I make the SSD function be dedicated to the windows partition?

    If I buy a mac mini with a fusion drive and add windows using boot camp, can I make the SSD function be dedicated to the windows partition?

    Additional information from Linc's post. Basically, only one additional partition can be added to a Fusion Drive and it resides on the HDD.
    Do computers that come with a Fusion Drive support Boot Camp?
    Yes. Use the Boot Camp Assistant to create a Windows partition and install Boot Camp. The Windows partition will exist on the hard disk drive, not the Flash drive, and is not part of Fusion Drive Logical Volume Group. 3TB Fusion Drive configurations need to update to OS X Mountain Lion v10.8.3 or later to install Windows 8. See iMac (27-inch, Late 2012): Boot Camp alert with 3T hard drive for more information.

  • HT201335 when using apple tv with my ipad, the mirroring function does not work, screen goes black, what is the issue?

    when using apple tv with my ipad, the mirroring function does not work, screen goes black, what is the issue?  My son's Ipad(same as kind as mine) works ok with the apple tv but mine does not.  Any suggestions?

    Hello Nina Izurin,
    While written for the iPhone, the troubleshooting below can help resolve issues with your iPad's camera, as well.
    Camera isn't functioning or has undesired image quality
    If the screen shows a closed lens or black image, force quit the Camera app.
    If you do not see the Camera app on the Home screen, try searching for it in Spotlight. If the camera does not show up in the search, check to make sure that Restrictions are not turned on by tappingSettings > General > Restrictions.
    Ensure the camera lens is clean and free from any obstructions. Use a microfiber polishing cloth to clean the lens.
    Cases can interfere with the camera and the flash. Try gently cleaning the lens with a clean dry cloth or removing the case if you see image or color-quality issues with photos.
    Try turning iPhone off and then back on.
    Tap to focus the camera on the subject. The image may pulse or briefly go in and out of focus as it adjusts.
    Try to remain steady while focusing:
    Still images: Remain steady while taking the picture. If you move too far in any direction, the camera automatically refocuses to the center.
    Note: If you take a picture with iPhone turned sideways, it is automatically saved in landscape orientation.
    Video: Adjust focus before you begin recording. You can also tap to readjust focus while recording. Exiting the Camera application while recording will stop recording and will save the video to the Camera Roll.
    Note: Video-recording features are not available on original iPhone or iPhone 3G.
    If your iPhone has a front and rear camera, try switching between them to verify if the issue persists on both.
    My issue is still not resolved. What do I do next?
    Contact Apple Support.
    iPhone: Hardware troubleshooting
    http://support.apple.com/kb/TS2802
    Cheers,
    Allen

  • Writing the file using Write to SGL and reading the data using Read from SGL

    Hello Sir, I have a problem using the Write to SGL VI. When I am trying to write the captured data using DAQ board to a SGL file, I am unable to store the data as desired. There might be some problem with the VI which I am using to write the data to SGL file. I am not able to figure out the minor problem I am facing.  I am attaching a zip file which contains five files.
    1)      Acquire_Current_Binary_Exp.vi -> This is the VI which I used to store my data using Write to SGL file.
    2)      Retrive_BINARY_Data.vi -> This is the VI which I used to Read from SGL file and plot it
    3)      Binary_Capture -> This is the captured data using (1) which can be plotted using (2) and what I observed is the plot is different and also the time scare is not as expected.
    4)      Unexpected_Graph.png is the unexpected graph when I am using Write to SGL and Read from SGL to store and retrieve the data.
    5)      Expected_Graph.png -> This is the expected data format I supposed to get. I have obtained this plot when I have used write to LVM and read from LVM file to store and retrieve the data.
    I tried a lot modifying the sub VI’s but it doesn’t work for me. What I think is I am doing some mistake while I am writing the data to SGL and Reading the data from SGL. Also, I don’t know the reason why my graph is not like (5) rather I am getting something like its in (4). Its totally different. You can also observe the difference between the time scale of (4) and (5).
    Attachments:
    Krishna_Files.zip ‏552 KB

    The binary data file has no time axis information, it is pure y data. Only the LVM file contains information about t(0) and dt. Since you throw away this information before saving to the binary file, it cannot be retrieved.
    Did you try wiring a 2 as suggested?
    (see also http://forums.ni.com/ni/board/message?board.id=BreakPoint&message.id=925 )
    Message Edited by altenbach on 07-29-2005 11:35 PM
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    Retrive_BINARY_DataMOD2.vi ‏1982 KB

  • Can you record sound using a USB 6211 and convert the data to a .wav (or other sound) file?

    Hello,
    I am trying to build a system that will use a USB 6211 to record sounds from multiple electret microphones and then save the data as a .wav file or other sound file.  I have already built my mics and hooked the mics up to the USB 6211; the DAQ device seems to do an adequate job recording the signal - I've recorded from 3 mics at a time at 11,025 Hz, although I don't know how good the signals are since I can't save them for playback after the fact, and they aren't going through my sound card. Ultimately, I would like to save the data as a multichannel audio file which I could then open in a program such as Audacity for further editing and analysis. Since Audacity can import a variety of sound files, my file format doesn't need to be .wav if another format would work better.
    Any advice would be appreciated.
    Thanks, Eric

    If you are sampling all three simultaneously, your highest frequency recordable will be (11,025/2)/3, so about 1800Hz and that will pretty coarse (traditionally digital sound recording is at 44Ks/s at the low end). As to converting to a .wav, there are functions on the "Graphics and Sound" palette for saving waveforms to a .wav file.
    Putnam
    Certified LabVIEW Developer
    Senior Test Engineer
    Currently using LV 6.1-LabVIEW 2012, RT8.5
    LabVIEW Champion

  • Problem  inserting date using the date function

    Hi there,
    I am getting this error The value
    "#CREATEODBCDATE(StartDate)#" could not be converted to a date. I
    used different methods including the Now() function but getting
    always the converted to a date error. The database fields are set
    to datetime format with length of 8 bits. The database is sql
    server database and the date format I use is
    =dateformat(now(),"mm-dd-yyyy")&timeformat(now(),"hh:mm:ss ".
    The actual time format the datbase us is the same format except
    there is AM or PM after the time, is this one of the reasons?
    Thanks for your help.

    In my SQL Server inserts I insert a date like the the NOW()
    function
    as
    insert into table (col1, date1) values ('texthere', GETDATE()
    your issue may be that the insert, update, or delete needs to
    be an SQL
    command, not
    a coldfusion one Coldfusion's now() --> SQL Server's
    getdate()
    For Updates or deletes, where I want to match a date, I let
    CF do a bit of
    the work inside the
    sql statement....
    update table set datefield = <cfqueryparam
    cfsqltype="cf_sql_date"
    value='#meetdate#'>
    (where '#meetdate#' is the form date or date that I want to
    update. CF then
    verifies it is a proper date structure before attemptint to
    save to the SQL
    SErver datetime field :)
    HTH,
    DixieGAl
    (although I
    "hannash" <[email protected]> wrote in message
    news:e98p4j$brc$[email protected]..
    | Hi there,
    |
    | I am getting this error The value
    "#CREATEODBCDATE(StartDate)#" could not
    be
    | converted to a date. I used different methods including the
    Now()
    function but
    | getting always the converted to a date error. The database
    fields are set
    to
    | datetime format with length of 8 bits. The database is sql
    server database
    and
    | the date format I use is
    |
    =dateformat(now(),"mm-dd-yyyy")&timeformat(now(),"hh:mm:ss ".
    The actual
    time
    | format the datbase us is the same format except there is AM
    or PM after
    the
    | time, is this one of the reasons?
    |
    | Thanks for your help.
    |

  • With out using submit button how to retrive the data

              at in the combo box if I selects one name automatically that person details to
              be retrive from the database and placed at in the other text boxes.
              

              Hi,
              You can do it in two ways:
              1. You can implement this in having java script function for that radiobutton
              on select and then make a call to server, submitting the form data to fetch the
              same from database. But in this case, the page will be refreshed.
              2. you can have a javascript function and using the same you can open a new window
              and then make a call to servlet to fetch the data and to submit to the text field
              in the form.
              Regards
              Srinivas.K
              "chiru" <[email protected]> wrote:
              >
              >at in the combo box if I selects one name automatically that person details
              >to
              >be retrive from the database and placed at in the other text boxes.
              

  • Can't use jHeadStart10.1.2 to refresh the data?

    I set "JSP" in view type of jHeadStart10.1.2(Developer version 10.1.2).
    It couldn't refresh data in the jsp page when I updated the data in the database.
    And two different ViewObject(jsp page) using the same EntityObject had the same problem.
    It was mean when I updated one of them, the other couldn't refresh at the same time.
    But the same problem didn't occur in jHeadStart9.0.5.1.
    Did anything need to set up?
    Thanks for your help.
    HorngDar

    HorngDar,
    I think that what you are running into is the 'caching' of data in ADF BC. By default, ADF will query all iterators in the UIModel needed to show the page, but once an iterator is queried, it will not be queried again unless you write specific code in your DataAction to do so. So if the data in your database can change through other means than the ADF application itself, you should include code to always query the iterator yourself.
    The best place to do that is in the prepareModel() method:
    protected void prepareModel(DataActionContext daContext) throws Exception
    super.prepareModel(daContext);
    // Force executeQuery on an iterator
    JUIteratorBinding ib = getBindingUtils().findIterBinding(daContext.getBindingContainer(), "<youriteratorname>");
    if (ib != null)
    ib.getRowSetIterator().getRowSet().executeQuery();
    else
    log.error("Iterator not found, check the name");
    This is just an example, which assumes there is only one iterator for which changes on the database may occur. You could write more generic code to query all the IteratorBindings in the current UIModel, but of course there are performance impacts so I would suggest to do this as little as possible.
    Hope this helps,
    Peter Ebell
    JHeadstart Team

  • Find the date functions

    hello,how can i find the weeks pass the date what i input,if have any functions?
    for example,i creat one PO on 2006.8.7,next time,i will judge the PO was pass 4 weeks.

    Hi,
    DATA: weeknum1 LIKE  SCAL-WEEK,
          weeknum2 LIKE  SCAL-WEEK,
          week_diff type i.
    CALL FUNCTION 'DATE_GET_WEEK'
      EXPORTING
        date               = '20060907'
    IMPORTING
       WEEK               = weeknum1
    EXCEPTIONS
       DATE_INVALID       = 1
       OTHERS             = 2.
    CALL FUNCTION 'DATE_GET_WEEK'
      EXPORTING
        date               = '20060807'
    IMPORTING
       WEEK               = weeknum2
    EXCEPTIONS
       DATE_INVALID       = 1
       OTHERS             = 2.
    week_diff = weeknum1 - weeknum2.
    write : 'No of weeks pass ' , week_diff.
    Rgds,
    Shakuntala

  • How to use a variable multiple times in the data flow

    DECLARE
    @StartTime datetime,
    @EndTime datetime
    SET @StartTime = (SELECT MAX(AvailDateTime) FROM dbo.Fact)
    SET @EndTime = (SELECT MAX(AvailDateTime) FROM dbo.Product);
    --DATEADD(day, 1, @StartTime);
    --PRINT @StartTime
    --PRINT @EndTime;
    WITH
    dates AS (
    SELECT DATEADD(Minute,5,@StartTime) AS [date]
    WHERE DATEADD(Minute,5,@StartTime) <= @EndTime
    UNION ALL
    SELECT DATEADD(minute, 5 ,t.date) AS [date]
    FROM dates t
    WHERE DATEADD(minute, 5, t.date) <= @EndTime
    I have the above sql, in this I'm using the 2 variables and calling @Starttime Variable couple of time. How should I build the SSIS package based on this query? how can I call the same variable in different place? how will SSIS take it?
    Thanks

    Since you have the variables set in code you just can place this code into the SQL code section of say an OLEDB source
    like there
    or

  • How to use case and decode to extract the data

    Hello PL/SQL Gurus,
    I am using Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production version
    I have a table in following format -
    drop table TT2;
    create table TT2(College, Class,gender,status,fees) as select
    'IITB','MBA','M','P',255600 from dual union all select
    'IITK','MTech','M','P',300000 from dual union all select
    'IITD','MBA','F','P',450000 from dual union all select
    'IITKH','MBA','F','P',350000 from dual union all select
    'IITC','MTech','F','P',420000 from dual union all select
    'IITB','MTech','M','P',185000 from dual union all select
    'IITC','MTech','M','P',235000 from dual union all select
    'IITD','MBA','F','F',175000 from dual union all select
    'IITM','MBA','M','F',257000 from dual union all select     
    'IITKH','MTech','F','P',335000 from dual union all select
    'IITD','MBA','F','P',540335 from dual union all select
    'IITC','MBA','F','F',125089 from dual union all select
    'IITD','MTech','M','P',290756 from dual union all select
    'IITM','MBA','M','P',200000 from dual union all select     
    'IITKH','MBA','F','F',534990 from dual union all select
    'IITD','MBA','F','P',221000 from dual ;some of the extraction conditions are as following -
    CASE CONDITION
    College in 'IITB' and status='P'- 'WestRegion Passed'
    College in 'IITC' and status='P'- 'SouthRegion Passed'
    College in 'IITD' and 'IITK' and status='P' and Gender='F' - 'NothRegion Female Passed'
    College not in 'IITK' and status='F' - 'Ex Kanpur Failed'
    Expected output -
    Region Statnding     Fees
    WestRegion Passed     440460
    SouthRegion Passed     655000
    NothRegion Female Passed     1386335
    Ex Kanpur Failed     1092079SQL Used
    I am using the following query which only make sure of case but this is not how i want the output , if i try to use the case within decode then how to work on this -
    SELECT (CASE WHEN College in ('IITB') and status='P' then sum(fees) else 0 end) WP,
    (case when College in ('IITC') and status='P' then sum(fees) else 0 end) SP,
    (case when College in ('IITD','IITK') and gender='F' and status='P' then sum(fees) else 0 end) NFP,
    (case when College in ('IITK') and status='F' then sum(fees) else 0 end) ExKF
    FROM
    TT2
    GROUP BY College, Class,gender,status

    user555994 wrote:
    Thank you so much jeneesh i am really thankful to you ...vov.
    one more query in case if any of the selection don't have the output data , then values will be displayed like -One way..
    with t as
    --"Add all your descriptions
    (select 'WestRegion Passed' region_standing from dual union all
    select 'SouthRegion Passed' region_standing from dual union all
    select 'NothRegion Female Passed' region_standing from dual union all
    select 'Ex Kanpur Failed' region_standing from dual)
    select region_standing,sum(fees) fees
            from (
            (SELECT CASE WHEN College in ('IITB') and status='P'
                                then 'WestRegion Passed'
                        when College in ('IITC') and status='P'
                                then 'SouthRegion Passed'  
                        when College in ('IITD','IITK') and gender='F' and status='P'
                                then 'NothRegion Female Passed'
                        when College in ('IITK') and status='F'
                                then 'Ex Kanpur Failed'
                        else 'Others' end region_standing,
                        sum(fees) fees
            FROM TT2
            GROUP BY  CASE WHEN College in ('IITB') and status='P'
                                then 'WestRegion Passed'
                        when College in ('IITC') and status='P'
                                then 'SouthRegion Passed'  
                        when College in ('IITD','IITK') and gender='F' and status='P'
                                then 'NothRegion Female Passed'
                        when College in ('IITK') and status='F'
                                then 'Ex Kanpur Failed'
                        else 'Others' end
            union all
            select region_standing,0
            from t
    group by   region_standing;
    REGION_STANDING              FEES
    Others                     2567835
    NothRegion Female Passed   1211335
    WestRegion Passed           440600
    Ex Kanpur Failed                 0
    SouthRegion Passed          655000
    {code}
    Edited by: jeneesh on Nov 5, 2012 5:07 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • BAPI commit without using Wait? need to get the data for created order

    I am using BAPI to create or change sales order and by using 'BAPI_TRANSACTION_COMMIT' updating the database.
    Immediately after that there is some requirement to fetch VBAP with the created order number, but there is no data found.
    If i use call function 'BAPI_TRANSACTION_COMMIT'
                 exporting
                   wait          =  'X'.
    then i am able to fetch data from VBAP, but its impacting the performance. Is there any alternative way to get data without fetching or without using wait.
    Can i use ABAP memory or SAP memory to get the details?
    Please help...........

    Hi Tapas379,
    Yes technically you can:
    set data before commit
    DATA memory_id(20) TYPE c.
      CONCATENATE 'VBAP_01_' sy-uname INTO memory_id.
      DELETE FROM DATABASE indx(as) ID memory_id.
      EXPORT vbap_tab = vbap_tab "<-input
        TO DATABASE indx(as)
        CLIENT sy-mandt
        ID memory_id.
    Get data from anywhere after setting it.
      data memory_id(20) type c.
      concatenate 'VBAP_01_' sy-uname into memory_id.
      import vbap_tab = vbap_tab " ->output
        from database indx(as)
        client sy-mandt
        id memory_id.
      delete from database indx(as) id memory_id.
    Thanks,
    Duy

  • How to use a km service to show the data of collaboration rooms.

    I follow the method in documents:
    import com.sapportals.portal.prt.runtime.PortalRuntime;
    IRooms roomsAPI = (IRooms) PortalRuntime.getRuntimeResources().getService(IRooms.PORTAL_SERVICE_ID);
    and cast Exception come out,  means can not transfer to IRooms
    And I alse wonder why PortalRuntime.getRuntimeResources().getService(IRooms.PORTAL_SERVICE_ID)'s return type is IService, but IRooms is not extends from IService ,how can casting succesussful......

    I follow the method in documents:
    import com.sapportals.portal.prt.runtime.PortalRuntime;
    IRooms roomsAPI = (IRooms) PortalRuntime.getRuntimeResources().getService(IRooms.PORTAL_SERVICE_ID);
    and cast Exception come out,  means can not transfer to IRooms
    And I alse wonder why PortalRuntime.getRuntimeResources().getService(IRooms.PORTAL_SERVICE_ID)'s return type is IService, but IRooms is not extends from IService ,how can casting succesussful......

  • Bought an Apple TV and the remote affects my Mac book pro when in use is it possible to disable the remote function ion the MacBook Pro

    When browsing on the Apple TV menu the remote affects my MacBook Pro and changes it to video mode even if not connected with the Apple TV

    Welcome to the Apple Support Communities
    In that case, just disable the IR port of the MacBook Pro > http://support.apple.com/kb/PH7234
    If you are using OS X Mountain Lion, you have to go to System Preferences > Security & Privacy > Advanced

Maybe you are looking for