Invoice date from and to  parameters

Hi
2 all
when i am working with these two parameters  if i give vendor id as null and giving invoice date and from date and to date then data is not getting
If i give three parameter then data is getting or else even i gave only  vendor id  even data is getting
my requirement is if i give only invoice from date and invoice to date  data should come...
can anybody give solution
AND aia.invoice_date BETWEEN nvl(:p_Invoice_from_date,aia.invoice_date) AND nvl(:p_invoice_to_date,aia.invoice_date)
and asu.vendor_id=:vendor_id;
regards
siva

Hai,
Use nvl like below
AND aia.invoice_date BETWEEN nvl(:p_Invoice_from_date,aia.invoice_date) AND nvl(:p_invoice_to_date,aia.invoice_date)
and asu.vendor_id=nvl(:vendor_id,asu.vendor_id);

Similar Messages

  • Problem in fetching invoice data from VBRK table.

    Hi guys,
              I am developing an ABAP program where I have to fetch the invoice data from VBRK and VBRP  based on the PO data or SO data in table LIPS. But I am not been able to link the two tables. Can anyone please suggest what are the PO and SO fields in VBRK or how to get the invoice data from VBRK and VBRP based on the Sales Order or Purchase Order number from LIPS. Thanks in advance.

    example:-
    VBRK &  VBRP
    select b~vbeln
             b~posnr
             a~fkdat
             a~spart
             a~kunag
             a~vkorg
             a~rfbsk
             a~fkart
             a~vtweg
             a~bzirk
             a~kurrf
             a~waerk
             a~knumv  
             b~fkimg    
             b~netwr 
             b~mwsbp 
             b~matnr
             b~arktx 
             b~prodh 
             b~vkgrp 
             b~ktgrm 
             b~aubel 
             b~matnr 
      into corresponding fields of table itab
      from vbrk as a inner join  vbrp as b
    on avbeln = bvbeln
      where a~kunrg in p_cust and
            a~fkdat in p_date and
            a~spart in p_dev and
            a~vkorg in p_vkorg and
            a~vtweg in p_vtweg and
            a~rfbsk in p_rfbsk and
            a~regio in p_regio and
            a~fkart in p_type and
            b~werks in s_werks and
            b~matnr in matnr.

  • FM or BAPI for reading invoice data from backend

    Hi Experts,
    We use SRM 4.0 and need to read invoice data from Back end (creation time and number).
    Which FM I can use?
    Thanks in advance
    Evgeniy Vazhev

    Hi,
    look at the below BAPI's
    BAPI_CUSTOMER_DISPLAY
    BAPI_CUSTOMER_GETDETAIL2
    Regards
    Sudheer

  • I wish to generate reports from the database an out put it but i need to enter a date from and to ina  html input box

    i wish to generate reports from the database an out put it
    but i need to enter a date from and to ina html input box
    in the input box a data of range will be input from a start
    to latest
    latest being the default as today's date.
    any help tips snipplets, concepts , turot=rails.
    thanks

    easycfm.com has tutorials for people who are brand new.
    If you don't know much about sql, I have heard good things
    about the book, Teach Yourself SQL in 10 Minutes by Ben
    Forta.

  • Calender using Date From and Date To

    Hi,
    I'm trying to build a calender based on a table that has a user_name, date_from, date_to and comments.
    Basically I want the calender to show all the dates betwwen the date from and date to. Is there any way of getting the calender to use those dates and all the days in between or will I have a to build a view that returns one row for each day between the start and end
    Whats the best way of doing this and does any one have an example
    Thanks in advance

    Andy,
    See my blog post here:
    http://deneskubicek.blogspot.com/2007/05/create-pseudo-tables.html
    and the corresponding example:
    http://htmldb.oracle.com/pls/otn/f?p=31517:83
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://htmldb.oracle.com/pls/otn/f?p=31517:1
    -------------------------------------------------------------------

  • How to view "date from" and "date to"

    Hi,
    I have loaded EMP data. In the mapping "date from" and "date to" are visible. But these fields are not seen when I display the EMP data.Can someone please tell me how to view these fields?
    Thanks,
    Williams

    I got your question . Please find my understandings .
    In the transformation Please check weather routine or formula is written which is stopping the dats
    to be updated to the target .
    I mean data is there in the source but if its not updating to target it seems some rules have been set up in the transformation . Please check .
    Assign marks is the best way to appreciate help

  • What is the purpose  of Date From and Date To In Oracle HRMS ?

    hi
    I have doubt on
    What is the purpose of Date From and Date To In Oracle HRMS?
    Thanks

    Where do you see these fields? Please give full details (eg, the navigation path).
    If you're referring to Effective Start Date and Effective End Date (effective_start_date, effective_end_date) these are two fields that appear on many HRMS entities. They're used to store dated history over time. For example:
    14-Jan-2009 to 19-Apr-2009 - Pam Stephens
    20-Apr-2009 to date - Pam Erickson
    In this example Pam got married on the 20th April 2009 and changed her surname from Stephens to Erickson. Here the history of changes are kept so that if we date-track to any time prior to the 20th April 2009 we'll see Pam Stephens and if we date-track on or after the 20th April 2009 we'll see Pam Erickson.
    Check out the following Oracle Support article for more information:
    How Date Track Works [ID 177733.1]

  • Info package ABAP Routine to populate date from and To filed

    Hello Experts,
    I have requirement to populate the From and To dates with the: T-1 to T (Current Date u2013 1 to Current Run Date aka Sy-Datum) at info package level.I have written a code for this but see that From filed is not getting populated but TO filed is filled with current date.Can someone please tell me wats wrongwith my code?It is a delta info pacakage.
    data: l_idx like sy-tabix.
    read table l_t_range with key
         fieldname = 'CPUDT'.
    l_idx = sy-tabix.
      l_t_range-sign = 'I'.
      l_t_range-option = 'BT'.
      l_t_range-low = sy-datum - 1.
      l_t_range-High = sy-datum.
    modify l_t_range index l_idx.
    p_subrc = 0.
    Thanks,

    Was able to tackle this using the following code.
    data: l_idx like sy-tabix.
    data: V_date type sy-datum.
    v_date = sy-datum - 1.
    read table l_t_range with key
         fieldname = 'CPUDT'.
    l_idx = sy-tabix.
      l_t_range-sign = 'I'.
      l_t_range-option = 'BT'.
      l_t_range-low = v_date.
       l_t_range-High = sy-datum.
    modify l_t_range index l_idx.
    p_subrc = 0.
    Thanks,
    I am closing this thread

  • Reporting on Master Data From and To

    Hello Experts,
    We are trying to report on the From and To dates of a time dependent infoobject 0FUND.  We have turned the infoobject on as a dataprovider but we dont see how you report on the two dates.  When we try adding 0DATETO to the attributes tab we get an error saying "attribute cannot be used with time-dependent attribute".  Next i tried mapping in a Z infobject but I could not get the object to populate with the Date To data.  What is the trick to getting these date fields in a query?
    Thanks,
    TMS

    Hi,
    Create Z objects for both dates. Create a Z object for master data objects "Fund".
    Add these two Z objects as attributes in master data Z object.
    Create as infoset with Orignal master data object and Z master data object.
    Use Infoset to create report.
    I hope it will work.
    Thanks,
    S

  • Date From and Date To Restriction

    Hi,
    I am loading data from R/3 into BW. I am bringing in Time Dependent Data.
    I want to write routine to bring the data only ones which are valid.
    I've written code as
    form compute_time_dependent_dates
      changing p_datefrom type d
               p_dateto   type d
               p_subrc like sy-subrc.
          Insert source code to current selection field
    $$ begin of routine - insert your code only below this line        -
              p_datefrom = 20040101.
              p_dateto   = sy-datum.
              p_subrc = 0.
    $$ end of routine - insert your code only before this line         -
    endform.
    But when i specify the values it brings in 0 records. And if do not specify it brings all the records.
    Any Idea???
    Thanks..
    Sachin K

    May be there is no records for that specified criteria?
    Nagesh.

  • Parsing the data from and xml type field

    Hi - I have registered a schema and inserted arecord into the table with the xml type column. Now I want to parse the data from the xmltype field into a relational table. I have been using the following select statement to accomplish this - and it does work if there is data in all the selected fields but when the filed is null then the whole select statement fails and brings back 'no rows returned'.If the value is null I want the select statment to return null. please give any ideas.
    SELECT version,frmd_transaction_date,extractValue(value(b), 'event_update/location')"location",
    extractValue(value(b), 'event_update/sending_system')"sending_system",
    extractValue(value(b), 'event_update/event_identifier')"event_identifier",
    extractValue(value(b), 'event_update/event_link')"event_link",
    extractValue(value(b), 'event_update/organization_code')"organization_code",
    nvl(extractValue(value(c), '/schedule/event_duration_minutes'),'000')"event_minutes"
    FROM fraamed_user.frmd_event_update , TABLE(xmlsequence(extract(xml_event_update, '/event_update')))b,
    TABLE(xmlsequence(extract(xml_event_update, '/event_update/schedule')))c

    ...then I guess you have to rewrite the query.
    Is schedule another xml sequence inside of event_update sequence ?
    If it is not you can try this :
    SELECT version,frmd_transaction_date,extractValue(value(b), '/event_update/location/text()')"location",
    extractValue(value(b), '/event_update/sending_system/text()')"sending_system",
    extractValue(value(b), '/event_update/event_identifier/text()')"event_identifier",
    extractValue(value(b), '/event_update/event_link/text()')"event_link",
    extractValue(value(b), '/event_update/organization_code/text()')"organization_code",
    extractValue(value(b), '/event_update/schedule/event_duration_minutes/text()')"event_minutes"
    FROM fraamed_user.frmd_event_update , TABLE(xmlsequence(extract(xml_event_update, '/event_update')))b
    ...if yes, did you try nvl function (I don't think this would be a solution of a problem):
    SELECT version,frmd_transaction_date,nvl(extractValue(value(b), '/event_update/location/text()')"location", 'NULL VALUE'),
    nvl(extractValue(value(b), '/event_update/sending_system/text()')"sending_system",'NULL VALUE'),
    nvl(extractValue(value(b), '/event_update/event_identifier/text()')"event_identifier",'NULL VALUE'),
    nvl(extractValue(value(b), '/event_update/event_link/text()')"event_link",'NULL VALUE'),
    nvl(extractValue(value(b), '/event_update/organization_code/text()')"organization_code",'NULL VALUE'),
    nvl(extractValue(value(c), '/schedule/event_duration_minutes/text()')"event_minutes",'NULL VALUE')
    FROM fraamed_user.frmd_event_update , TABLE(xmlsequence(extract(xml_event_update, '/event_update')))b,
    TABLE(xmlsequence(extract(xml_event_update, '/event_update/schedule')))c
    If none of this works post your xml schema.

  • Date (From  and To)

    Hi
    i am not able to get report inr particular duration
    i am trying in parameter (from and To) but it is not worling so
    Please tell me procedure how to put ( From and To ) format in excel reporter
    I have downloded some sample report also but i am trying not able to get just tell me the procedure.
    Thanks & Regards
    Amit

    Hi
              Here i am telling you step by step
                1 select paramete button on the botton
                2  select  New
                3       Name        Categary        Type            Atribute        Defuilt          Value       Prompt
                        FDate             literal            Date                                                                        From Date
                        Todate            literal            Date                                                                        To Date
               4    Transaction row and select parameter for Date
               5  Apply
    Please reply soon
    Thanks and Regards
    Amit

  • How to get invoice data(VBRK and VBRP)

    Hi, guru:
    Would like to ask one thing:
    customer system will pass ECC invoice id, and base on that do we have any SAP standard BAPI or function module which can get all the details for that invoice(header and items both).
    I tried BAPI_billingdoc_getdetail, however I can only get data for header(VARK)
    Thanks heaps!
    Eric

    is ECC a legal number maintained in the J*** transaction. then you can fetch if from there.

  • Date From and Date TO

    Hi All,
    I have created two parameters P_Date_From and P_Date_TO.
    I am using as below in SQL query to restrict data.
    Where Ordered_On_Date>=:P_Date_From and  Ordered_On_Date<=:P_Date_TO
    Its working fine if I supply the dates but erroring out when we run the report without giving any dates.
    Please suggest!!
    Regards
    MBVANAND

    You need to account for the null date values. Modify your "where" clause to this and try:
    Where Ordered_On_Date>= nvl(:P_Date_From, Ordered_On_Date)  and  Ordered_On_Date<=nvl(:P_Date_TO, Ordered_On_Date)
    Thanks,
    Bipuser

  • How to retreive data from and external program

    Hiii
    I have a Zreport which produce an ALV and also the VF02 transaction which produce a amartform.
    I will need to
    1:  From a new program extract from the Zreport the alv in sort of excel sheet and submit it by mail
    2.  From a new program extract the smartfroms found on VF02 and submit it by mail
    please advise how i can get access to those two external program

    Hi,
    1: When you have an output in ALV why don't you use an EXCEL-Layou in this Report?
    2: Print the smartform and send this as email from the spool (lot of examples in SDN, serach for this).
    Regards, Dieter

Maybe you are looking for

  • My iphone 4s cannot be turned on after updated to ios 7. can anyone tell me how to solve this

    my iphone cannot be turned on after a week i updated it to ios 7. I have tried many solution to turned it on but none of them works. Now it only appear the apple logo on my screen since 5 hours ago. Can anyone suggest me the best solution

  • Can I rotate a video 90*?

    I am using 10.4.11 operating system on my iMac and have Quicktime Pro. I took a video using my digital camera and turned the camera. The video plays fine but needs to rotate 90°. Is there a way to rotate the video 90°?

  • Wrong cancellation date seen in the order

    Hi, Today i.e 10th July 2011, Sunday evening at around 5.45 pm I called up the line cancellation number 0800 800 030 and requested that my landline be cancelled on 18th July. I was informed that generally two weeks notice is required and hence the li

  • Import picture never finish

    Hi, When Import a picture from a file, it imports the picture but never finish it. I Force Quit iPhoto, and the picture was imported.

  • Some devices won't connect to wifi network after resetting network settings to default

    Hi all, I had to restore to the default settings on my 4th generation Time Capsule today and now half of our devices will not connect to the wifi network.  The macbook pro (mid 2010 OS 10.9.4) that I used to reset the time capsule with and my iPhone