Date Issue very urgent

Hi Experts, I am having SY-DATUM. Based on SY-DATUM i required next month first date and after three month end date of the month.

This is how you can get the first day of next month as the start date and three months later date as end date.
DATA: v_start_date LIKE sy-datum,
      v_end_date   LIKE sy-datum.
*-- This will be the last day of the current month
CALL FUNCTION 'BKK_GET_MONTH_LASTDAY'
  EXPORTING
    i_date = sy-datum
  IMPORTING
    e_date = v_start_date.
*-- This will be the first day of the next month
v_start_date = v_start_date + 1.
CALL FUNCTION 'BKK_ADD_MONTH_TO_DATE'
  EXPORTING
    months  = 3
    olddate = v_start_date
  IMPORTING
    newdate = v_end_date.
WRITE:/ v_start_date, v_end_date.

Similar Messages

  • CATS Issue VERY Urgent..

    HI ALL,
    BiW  PROD is placing CATS data for 2007 in to week 52 2006.  Can advise why?
    Please advise what would be the error.
    Cheers,
    Sri

    Hi All,
    We have a problem for 0CALWEEK in CATS.
    FOR  0CALQUARTER
    20061 means 1st quarter
    20062 means 2ND quarter
    20063 means 3RD quarter
    20064 means 4TH quarter
    FOR 0calweeK:
    20061 means 1st WEEK
    20062 means 2ND WEEK
    20063 means 3RD WEEK
    20064 means 4TH WEEK
    0CALWEEK is giving problem  IN CUBE.
    It  shows wrongly.
    0CALQUARTER      0CAL WEEk
    2007 1             2006 52 ( 52 week)
    2007 1                          2006 52
    <b>0CAL WEEk          should show 2007 1     instead of 2006 52.</b>
    It should show :
    0CALQUARTER      0CAL WEEk
    2007 1             2007 1 (ist week in 2007)
    2007 1                         2007 1
    we have a routine on 0CAL_week
    =====
    PROGRAM UPDATE_ROUTINE.
    $$ begin of global - insert your declaration only below this line  -
    TABLES: ...
    DATA:   ...
    data:   employee_md like /bi0/memployee,
            employee_wa like /bi0/memployee,
            person_md   like /bi0/mperson,
            PERSON_WA   LIKE /BI0/MPERSON.
    DATA:   G_RECORD_NO LIKE SY-TABIX.
    INCLUDE RS_BCT_HR_UPDATE_RULES_GENERAL.
    INCLUDE RS_BCT_HR_PAPA_UPDATE_RULES.
    $$ end of global - insert your declaration only before this line   -
    FORM compute_characteristics
      TABLES   MONITOR STRUCTURE RSMONITOR "user defined monitoring
      USING    COMM_STRUCTURE LIKE /BIC/CS0CATS_IS_1
               RECORD_NO LIKE SY-TABIX
               RECORD_ALL LIKE SY-TABIX
               SOURCE_SYSTEM LIKE RSUPDSIMULH-LOGSYS
      CHANGING RESULT LIKE /BIC/VZCATST-CALWEEK
               RETURNCODE LIKE SY-SUBRC
               ABORT LIKE SY-SUBRC. "set ABORT <> 0 to cancel update
    $$ begin of routine - insert your code only below this line        -
    fill the internal table "MONITOR", to make monitor entries
    data: w_date type d.
    data: w_date_check type d.
    data: w_numberofdays type p decimals 2.
    data: w_numberofweeks type i.
    data: w_dayofweek type p.
    data: w_first_day_of_sap_calendar type d value '19790101'.
    data: check type i.
    data: w_year(4) type c.
    data: w_weekno(2) type c.
    w_date_check = COMM_STRUCTURE-CALDAY.
    w_date = w_date_check.
    w_date+04(04) = '0101'. " beginning of the year
    do.
    w_dayofweek = ( ( w_date - w_first_day_of_sap_calendar ) mod 7 ) + 1.
    if w_dayofweek = 7. " First sunday(7) of the Current year
    exit.
    endif.
    add 01 to w_date+07(01).
    enddo.
    w_numberofdays = ( w_date_check - w_date ) + 1.
    w_numberofweeks = ceil( w_numberofdays / 7 ).
    w_year = w_date_check+0(4).
      if w_numberofweeks = 53.
        w_numberofweeks = 1.
        w_year = w_date_check+0(4) + 1.
      endif.
      if w_numberofweeks = 0.
        w_numberofweeks = 52.
        w_year = w_date_check+0(4) - 1.
      endif.
    w_weekno = w_numberofweeks.
    call function 'CONVERSION_EXIT_ALPHA_INPUT'
         exporting
              input   = w_weekno
        importing
             output  = w_weekno.
    concatenate w_year w_weekno into RESULT.
    result value of the routine
    RESULT = .
    if the returncode is not equal zero, the result will not be updated
      RETURNCODE = 0.
    if abort is not equal zero, the update process will be canceled
      ABORT = 0.
    $$ end of routine - insert your code only before this line         -
    ENDFORM.
    ========
    This is giving problem from 2007 year only.
    We need to check with FI or HR teams , Is there any configuration settings in R/3 side for 0Calweek?
    This is production ISSUE. Help me on very Urgent BASIS!!
    Thanks & Regards,
    Sri.

  • Query Issue(Very Urgent)

    Hi,
         I have issue with select statement to pull the records from two tables. Here I have two tables one is with Billing Document Items and Service Order Operations.
    I have service order as unique field in both tables, When I execute select statement with one service order I got 10 records like
    S Ord Oper                           Billing Document Items
    Oper    Repair Code                 Item    Oper    Repair Code
    10        AD01                           1         10        AD01
    20        AD01                           2         20        AD01  
    30        OT01                           3         10        AD01
    40        RE01                           4         20        AD01
    50        RP01                           5         20        AD01
                                                   6        20         AD01
                                                    7        30         OT01
                                                    8        40         RE01  
                                                    9        50         RP01
                                                   10      50         RP01
                 This are the records with same Service order number, and my select statement giving data like
    O/P
    Service Order =  60001212
    OPER    ITEM    REPAIR TYPE
    10         1           AD01
    20         1           AD01
    10         2           AD01
    20         2           AD01
    10         3           AD01
    20         3           AD01
    10         4           AD01
    20         4           AD01
    10         5           AD01
    20         5           AD01
    10         6           AD01
    20         6           AD01
    30         7           OT01
    40         8           RE01
    50         9           RP01
    50         10         RP01
    But I need output like this
    Item  Oper                   Rep Code
    1      10                      AD01
    2      20                      AD01
    3      10                      AD01
    4      20                      AD01
    5      20                      AD01
    6      20                      AD01
    7      30                      AD01
    8      40                      RE01
    9      50                      RP01
    10    50                      RP01
             Please give me the select statement which gives the above output. I need very urgent please....
    Thanks
    Robbie

    hi robert,
    The ouput u want is just a little away from the one u r actually getting. it is the two fields OPER and ITEM interchangeably..
    U just have to use GROUP BY ITEM..........if u want the desired output with ITEM as first field.
    <group-by-clause> &#8594; GROUP BY [<column-ref>,*]<column-ref>
    if it helps please reward points.
    thanks

  • Hi Experts ,how to copy database schema without data ? very urgent...*****

    Hi experts,
    How to copying database without Data.
    Its very urgent..pls help out me......
    Thanks
    Vijay

    Use Transfer database objects task or script the objects out using generate scripts wizard from SSMS and apply them in the new server
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • Attachment issue --very urgent help  required

    Hello friends,
    1)i have create page and deatal page . requirement is that we have to load required attachments in table region, if not loading required attachments exception will raise. this validation is working fine in create page.
    2)same in detail page i loaded required attachments also excepiton is raising.
    waht would be cause. i am very new to ADF technology.
    very urgent to fix this issue. any one help me out.
    Thanks,
    vamshi.
    Edited by: Krishna Vamshi on Jul 1, 2010 6:14 PM

    Kirshna,
    Unfortunately your question is very unclear.
    Let me say that if you are asking about OA Framework, you should ask on the OA Framework forum, not here.
    also excepiton is raising.It will help if you say what the exception is.
    John

  • Encrypting and Decrypting Data(Its Very Urgent, Please Help.)

    Hi,
    Can anyone tell me some idea in the below mentioned details.
    Iam creating a Function for Encrypting and Decrypting Data Values using
    DBMS_OBFUSCATION_TOOLKIT with UTL_RAW.CAST_TO_RAW by using
    Key Value as normal.
    But the problem, is it possible to have the key value more than 8.
    Its showing me error when i give the key value less than 8 or more than 8.
    Can u tell me why it happens, is that the limit of the key value or is any other way to do that.
    Its Very Urgent, Please Help.
    Thanks,
    Murali.V

    Is this what you're looking for?
    Usage Notes
    If the input data or key given to the DES3DECRYPT procedure is empty, then the procedure raises the error ORA-28231 "Invalid input to Obfuscation toolkit."
    If the input data given to the DES3DECRYPT procedure is not a multiple of 8 bytes, the procedure raises the error ORA-28232 "Invalid input size for Obfuscation toolkit." ORA-28233 is NOT applicable for the DES3DECRYPT function.
    If the key length is missing or is less than 8 bytes, then the procedure raises the error ORA-28234 "Key length too short." Note that if larger keys are used, extra bytes are ignored. So a 9-byte key will not generate an exception.
    C.

  • Insert in oracle database issue (very urgent)

    Hello
    I am new to this forum and also new to oracle .... I am woking in a C# 3.5 desktop application
    I am Leasing data from socket (1 message per 10 millisecond) and save in queue<T> and then i have a background thread which dequeu the data and perform some calculation and create “insert sql query “ on run time NO STORE PROCEDURE just simple insert query
    For example
    insert into Product values(0,computer , 125.35);
    I pass that insert query to my datalayer which create oracle connection and insert in to a data base. see the code below
    using System.Data.OracleClient
    class db
    OracleConnection conns = null
    public static void conn(string dbalias, string userid, string password){
    try
    string connString = @"server =" + dbalias + ";uid =" + userid + ";password =" + password + ";";
    conns = new OracleConnection(connString);
    conns.Open();
    catch (OracleException e){
    Console.WriteLine("Error: " + e);}}
    public static void ExecuteCommand(string sqlquery)
    try
    OracleCommand cmd = new OracleCommand(sqlquery,conns);
    cmd.ExecuteNonQuery();
    NOW the problem is that inseration in oracle database is very slow please tell me how to solve this issue

    using System.Data.OracleClient ????
    This is the ODP.NET forum.
    using Oracle.DataAccess.Client;
    and reference something like: C:\Oracle\product\11.1.0\client_1\ODP.NET\bin\2.x\Oracle.DataAccess.dll
    Assuming your "insert thread" is simply waiting on the next queue entry, why don't you just turn pooling off, open the connection and keep that one connection open?
    I am fairly certain the speed issue has nothing to do w/the insert statement vs. stored procedure.
    r,
    dennis

  • Reporting issue (very urgent)

    Sr.No     Flt.NO     ORI- DES     Total Flts     TS OFF     FC     KC     TS Util      FC
    1     IT101     BOM-BLR        20     2,680     400     2,280     2,165     230
    2     IT103     BOM-BLR        20     3,216     480     2,736     2,322     245
    5     IT111     BOM-BLR        24     3,216     480     2,736     2,396     159
    Result           BOM-BLR        64     9,200     1,360     7,800     6,900     615
    6     IT102     BLR-BOM        20     2,680     400     2,280     2,222     140
    9     IT110     BLR-BOM        20      3,216     480     2,736     2,543     257
    10     IT112     BLR-BOM        24     3,216     480     2,736     2,257     168
    Result          BLR-BOM        64     9,200     1,360     7,800     7,100     530
    Overall Result    BOM-BLR-BOM       128     18,400     2,720     15,600          
    Hi all,
              I have the above issue like am working on BI7 reporting and i want a monthly report and the report should be like above.The user want to see the result of each segment in the next row.And after two result rows,  one over all result of the two.
    When I put a filter in the report then i can see the subresult of single segment but am not able to see the rest of the Segments.It is just showing the filtered segment with the subresult. I want to see all the segments with the subresult and overall result rows.
    Can it possible in the report if it is then Plz tell me how to do that.Its urgent
    Ensuring points
    Thanking

    I guess ORI-DES is a characteristic. if yes then, Ori-des should come before Flt. NO. and in properties->display, result rows should be 'Always display' to get desire result

  • Approval issue very urgent

    Hi Experts,
    I knew to WF
    We get the approval issue . In Ebuy of China, we have the approval workflow as go to the highest approver if the approval limit is over the default approver manager. That is User A have mgr B with limit 40,000 and mgr B have mgr C with limit 80,000. If raise a Shopping cart to 50,000, the shopping cart will go to Mgr C. User A need to add the mgr B as the first approver. But after all mgrs are added, and ordered, and back to Check status, the first 2 mgrs are disappeared. can u help on this issue?
    Thanks & Regards
    Vijay

    Hi Nazeer,
    The value of Tan(45) is beng wrongly calculated by ABAP because internally the data type for all the Trignometric functions are represented as Floating point numbers.
    Please refer to this:
    The results of the following functions have the data type f:
    &#61599;     Trigonometric functions: cos, acos, sin, asin, tan, atan
    &#61599;     Hyperbolic functions: tanh, sinh, cosh
    &#61599;     Exponential functions (base e): exp
    &#61599;     Natural logarithms (base e): log
    &#61599;     Logarithms (base 10): log10
    &#61599;     Square root: sqrt
    In case you have any further clarifications,do let me know.
    Regards,
    Puneet Jhari.

  • Modal dialog issue - very urgent

    Hi everyone,
    i'm working with indesign application under asp.net. I'm using Interop.InDesign.dll. I'm able to open Indesign, but when i try to change UserInteractionLevel, then application returns error "Cannot handle the request because a modal dialog or alert is active." I can't see what modal dialog is opened because, i can't see Indesign window. It is runing in asp.net context.
    When i'm opening manually Indesign then none of the modal dialogs is active.
    My code:
    Type indAppType = Type.GetTypeFromProgID("InDesign.Application");
    objInDesign = (InDesign.Application)Activator.CreateInstance(indAppType, true);
    objInDesign.ScriptPreferences.UserInteractionLevel = idUserInteractionLevels.idNeverInteract;
    Do you have any solutuion for it ?
    Thanks.
    Regards

    I have similar issues.
    Initially this was caused by the splash dialog that appears the first time a user launches InDesign.  Logging in with the credientals used to launch InDesign, and checking the "Dont show again" checkbox cleared it up for me.
    Later, I ran into the problem again when InDesign was trying to recover some autosaved files.
    This was cleared up by deleting the recovered file information from the accounts AppData folder.
    I'm now getting this error again, but so far I dont know why. I have no Idea what modal dialog InDesign is trying to display.  How can I tell?
    I've got to say, I'm very disapointed with this behavior.
    If a programmer sets ScriptPreferences.UserInteractionLevel to InDesign.idUserInteractionLevels.idNeverInteract;  this should inform InDesign that its launch is part of an automated process; there is no user available to press anything, and there is likely not a desktop to display anything.
    It is far more important for InDesign to respect the ScriptPreferences.UserInteractionLevel than to try and recover documents or display a welcome dialog.
    But since we are stuck with this exception, I have the following questions:
    Is there a way to programmatically dismiss the splash "Welcome" dialog via script command?
    Is there a way to programmatically respond to the dialog that is displayed when InDesign has recovered documents?
    Is there a way to programmatically determine what modal dialog is causing the exception? (app.Dialogs is empty)
    Thanks!

  • 2 Company Codes - Same Report --- Issue Very Urgent

    Hello Guys,
    I have following questions w.r.to BI implementation.
    We have 40 SAP BI reports developed for our company.
    Now we have moved to other New implementation for the same company but in other country. ( Germany - Company Code - DE / France - Company Code - FR ).
    Both Implementation : EN Language.
    We have 2 different Dev clients(ECC) for diff country implementations.But when we move to QAS they (ECC) will be integrating the data into one client,
    we are using only one BI client for both implementations.
    I Just have few questions ...
    I need to Load all the master data for 2nd implementation all over again.
    Firstly we have all the process chains and DTP and Transformations in place from !st implementation.
    1.Can we use those same PC to load master data for our second implmentation with different ECC client.
    2. How can we differentiate which master data belongs to which implementation when we integrate into one ECC client from BI system point of View.
    3. Also they (2nd implementation) want to use the above BI reports developed from 1st implementations, with their data specific to thier company.
    How can we handle above issues.
    Also could you suggest the points to keep in mind when displaying the same report but with different data based on company code.
    thanks,
    Shekar.

    Hi Shekar,
    1.Can we use those same PC to load master data for our second implmentation with different ECC client.
    --> If source system and client is same you can use same process chains, or neet to create new one to include new infopackage for new source and client.
    2. How can we differentiate which master data belongs to which implementation when we integrate into one ECC client from BI system point of View.
    --> If same data(material and customer) maintained differently in different systems(ex: same technical name but description is different)... then its better to make master data objects compounding with source system to differentiate data.
    http://help.sap.com/saphelp_nw04/helpdata/en/80/1a6399e07211d2acb80000e829fbfe/frameset.htm
    3. Also they (2nd implementation) want to use the above BI reports developed from 1st implementations, with their data specific to thier company.
    --> Create authorization variable on company and use..
    How can we handle above issues.
    Also could you suggest the points to keep in mind when displaying the same report but with different data based on company code.
    --> Create authorization variable on company and use..

  • How do I reclaim the unused space after a huge data delete- very urgent

    Hello all,
    How do I reclaim the unused space after a huge data delete?
    alter table "ODB"."BLOB_TABLE" shrink space; This couldn't execute with ora 10662 error. Could you please help

    'Shrink space' has requirements:
    shrink_clause
    The shrink clause lets you manually shrink space in a table, index-organized table or its overflow segment, index, partition, subpartition, LOB segment, materialized view, or materialized view log. This clause is valid only for segments in tablespaces with automatic segment management. By default, Oracle Database compacts the segment, adjusts the high water mark, and releases the recuperated space immediately.
    Compacting the segment requires row movement. Therefore, you must enable row movement for the object you want to shrink before specifying this clause. Further, if your application has any rowid-based triggers, you should disable them before issuing this clause.
    Werner

  • Calculate stock of material on a particular date ..very urgent (have points

    Hi all,
    My requirement is to calulate stock of a material on a particular date..
    See.
    I need a function mudule that will accept..
    matnr, date, werks....n give me stock as output..
    Please help me reg. this..
    Have ur points...

    hai pradeep,
    As there is no function module as u said but u can create the function moudule as per ur requimrent in SE37. Just you need the tables from where you want the stock and from which you are giving matnr, date and werks.
    Take the import paramters as matnr, date and werks and export parameter as stock. In source code write the select qurey depending up on the input. i think u know how to write the qurey depending up on the tables from where you want the stock .
    hope this will help you.
    <b>reward if useful</b>
    regards,
    sunil kairam.

  • Vendor Classification Issue very urgent

    Hi Guys
        I have to show the report with Geo Characteristics in my Vendor Master . When I see the attributes I can see 0POSTCD_GIS . Which is Geo relavant. I have also 0LONGITUDE and  0LATITUDE etc....Now when Load Master Data for vendor I found no data for Geo relavant chars. What should I do.
    I came to knew that SAPBWKEY needs to be activated and Demo content needs to be activated.But I dont understand what exactly needs to be done.I need few simple steps one by one....Please let me know what are these shape files and how I can get Geo Data....Please advice..ask me if you need further details regarding the process Iam following

    Hi Nazeer,
    The value of Tan(45) is beng wrongly calculated by ABAP because internally the data type for all the Trignometric functions are represented as Floating point numbers.
    Please refer to this:
    The results of the following functions have the data type f:
    &#61599;     Trigonometric functions: cos, acos, sin, asin, tan, atan
    &#61599;     Hyperbolic functions: tanh, sinh, cosh
    &#61599;     Exponential functions (base e): exp
    &#61599;     Natural logarithms (base e): log
    &#61599;     Logarithms (base 10): log10
    &#61599;     Square root: sqrt
    In case you have any further clarifications,do let me know.
    Regards,
    Puneet Jhari.

  • Authorisation issue(very urgent)

    Hii all,
    My client has asked to create a new user-id and to give a few authorisation of reports to it.Could anyone help me regarding this ASAP.
    Till now I have identified the required reports & the data targets connected to it.Just help me to proceed further.
    Thanks buddies.

    Hi,
       These transaction code willbe helpful SU01,PFCG. Once you have created a role through PFGC , then goto Authorization tab of the role and need to carry out the following.
    Role Name
      |
    >Manually  Basis : Administration
    >Manually  Authorization Role check
    >Manually  Authorization :Role Check
    >Activity   < 03, 22 >
    > Role Name  < ur role name>
    < > are value to be specified
      And also on the menu tab please create a folder , here you can save your BEX Query as Workbooks. when you assign this role to the new User-ID , on the SAP Easy access page the user will be able to access these queries/ Workbook.
    Hope this help.
    cheers,
    Balaji

Maybe you are looking for

  • Having a hellish time with a RAID 5 Array

    Seems that after a hiccup and a freeze that required a hard restart things have been going downhill. Nothing but a gray screen after the restart and then had to start from an external drive. Raid utility showed 2 of the 3 drives in the raid set as ro

  • Widgets in Muse

    After dragging horizontal widgets into my master page, changing color and font, and placing them, how can I lock them into a spot on the page?  They keep showing up outside the actual page, hanging over to the left.

  • Exception from HRESULT: 0x80131904 and Violation of PRIMARY KEY constraint 'AllUserDataJunctions_PK' on item.update

    HI, We have done following changes to Production environment. 1. Migrated Application from 2007 to 2010 2. Done User Domain Migration user MoveSP-User commmand 3. Then we Run following command to block users from another domain. Set-SPSite -Identity

  • Dbms_crypto pacage

    i tried to call dbms_crypto package from forms, i call the package by a function in the database i have created, i always got the error 00904 , all the rights are given on the function and the crypto package i use database 11 g and forms 10 g i tried

  • JMC Frequently Asked Questions

    Java Mission Control is a tools suite for monitoring, managing and profiling Java applications running in production. It is free for development! This forum is mainly for the Java Mission Control Client. If you have questions about the JVM parts (for