Default date and year

Hi Guru's,
Can you please give your suggestions for following requirement..
On selection screen for parameter_period...
( which is in format ---   mm-dd-yyyy)
I want default value for
mm-dd  as ( 01-01)..
and yyyy  as current year ..
For eg ::if execte the program today ,on selection screen in parameter_period field it should dispaly 01-01-2008..
Your suggestions will be rewarded..
Thanks
Parnith,..

Hi Parnith,
You can give sy-datum as default value to this parameter.
And then in the Initialization event change the first four digits to 0101.
date+0(4) = 0101.
Hope it helps.
Regards
Hemant Khemani

Similar Messages

  • Month to Date and Year to Date Scenarios

    <b>Dear SAP BI Gurus,
    Can anyone please give me guidance how to create a Month to Date and Year To Date Scenarios (Variables perhaps?) for 0SRR_CF_C1?  The date is in decimal and not DATE format…  I’m assuming the reason for this is to get the Time variance….  Nonetheless, I’d like to create a MTD and YTD scenario for reporting.
    Much Thanks
    Philips Manalaysay</b>

    Hi,
    You should take a look at the blog and doc below.
    /people/vikash.agrawal/blog/2006/10/17/enable-trend-reporting-150-by-manipulating-variable-value
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/25d98cf6-0d01-0010-0e9b-edcd4597335a
    Regards,

  • Arbitrary change of date and year on photos taken in folder structure

    I run Adobe Photoshop Elements 8.0 in a Microsoft Office 2007 environment originally on a Dell laptop. Before installing Adobe I had a library in My Pictures that I have maintained and uses this structure (folders by year and events). I have moved everything to a stationary computer. Now dates has been changed on the pictures pictures from 2001 has been changed to 2010 also in properties). When adding new folders (by year and months) for transfere of pictures from my camera pictures alrready in the files starts populate the folder just established.
    On the old Dell laptop the correct dates and year are still maintained (used as a second back-up).
    What happens?

    Finally got the date fixed, it was simple once I got palm support. I did a hard reset, then set the date but DID NOT click on TODAY at the bottom of the screen, the secret is to tap on the actual DAY on the calendar, NOT TODAY (after you set the year)
    Post relates to: Tungsten E2

  • Split month, date and year

    How to split month,date and year from date field ? is there any standard function module.

    You can do this.
    data: year(4) type c,
          month(2) type c,
          day(2) type c.
    year = sy-datum(4).
    month = sy-datum+4(2).
    day = sy-datum+6(2).
    write:/ year.
    write:/ month.
    write:/ day.
    Regards,
    Rich Heilman

  • Default Month and Year in Date Paramater

    Hi,
    I have a question and not able to understand how to show a default current month year i.e 112010 as a deualt value in the prompt.
    Thanks in Advance,
    Poojak

    one more problem i found with that code is:
    if current date is January's date, it gives 12010 instead of 012010 and if you are filtering column is holding values like mmyyyy format, it'll give no results..
    i want you to create a repository variable which holds current_date format in mmyyyy format..
    now, use that repository variable here in default section by selecting server variable..
    select to_Char(sysdate, 'mm') || to_Char(sysdate, 'yyyy') from dual

  • Month to Date and Year to date calculation

    Hello Experts,
    It would be great If you could provide the formula to implement in BO universe or in the Reporting level for the below requirement.
    MTD, LastMonth, Year to Date, Last to LastMonth and examples are below.
    Last Week:
    Eg: Monday through Sunday
    Description: Based on Todayu2019s date, select the Monday of the previous week for the start date and Sunday will be the end date.
    Example:
    If Today is May 22, 2009
    The result would be, Monday = May 11, 2009, Sunday = May 17, 2009
    MTD:
    If Today is May 22, 2009
    I need a result MTD = May 1, 2009 u2013 May 21, 2009
    LastMonth:
    If Today is May 22, 2009
    I need a result LastMaont = April 1, 2009 u2013 April 30, 2009
    Last to LastMonth:
    If Today is May 22, 2009
    I need a result LastMaont = March 1, 2009 u2013 March 31, 2009
    Thank you.

    Nisniki,
    Here are the methods using WebI:
    MTD: 
    Create a local variable "MTD Start"
    =RelativeDate(LastDayOfMonth(RelativeDate(CurrentDate();-30));1)
    Create a local variable "MTD End"
    =currentdate()
    LastMonth
    =LastDayOfMonth(RelativeDate(CurrentDate();-30))
    Year to Date
    create a local variable "YTD Begin"
    =ToDate("01/01/"+FormatNumber(Year(CurrentDate());"####");"mm/dd/yyyy")
    (reuse "MTD End" or build a "YTD End" variable same as "MTD End")
    Last to LastMonth
    (similiar to MTD, but using "60" versus "30" to move back two months versus moving back 1 month.
    To perform this stuff in the universe requires an understanding of the SQL syntax for the paricular vendor your are working with.  ANSI SQL agrees to represent and compute dates uniformly, however, the functions to make it happen varies by the vendor.
    Thanks,
    John

  • Date and Year

    Dear all
    I am involved in Implementation .
    My client requirement is very specific and rare they wanted in IT0022 ( Education ) Instead of Start and End Date they want only the year of Passing to be recorded.
    Even in IT0023 ( Previous Employment ) They wanted only the Month and Year ,they dont want the date to be includedin the Begin date .
    Can it Happen? If so How to do it.
    Regards
    Raji

    Raji,
    You may try entering begin date as begin of the passing year and end date as end of the passing year.. You can display the data in report the way you want...(custom report or query )..
    Hope this helps.

  • Auto Generated No with Date and year

    I m using this method to create a auto generated no.
    in pre-insert trigger
    declare
              v_l varchar2(10);
         begin
              select max(doc_no) into v_l from Table ;
              if v_l is not null or v_l<>0 then
                   :table.doc_no:= v_l+1;
              else
                   :table.doc_no:=1;     
              end if;
         exception
              when no_data_found then
              :table.doc_no:=1;
         end;I want to generate auto generate no|| month||year
    please guide me

    Kame wrote:
    I want to generate auto generate no|| month||year
    please guide meYou can get an auto-generated number using SEQUENCE in Oracle.
    Do you have a specific date column in your table from which you need to get the MONTH and YEAR Data?
    To get MONTH, you can use something like:
    TO_CHAR(your_date_column, 'MONTH')To get YEAR, you can use
    TO_CHAR(your_date_column, 'YYYY')your_date_column should contain data of date datatype.
    Examples:
    SQL> CREATE SEQUENCE SEQ
      2     MINVALUE 1
      3     MAXVALUE 999999999
      4     START WITH 1
      5     INCREMENT BY 1
      6  /
    Sequence created.
    SQL> SELECT SYSDATE FROM Dual
      2  /
    SYSDATE
    10-JUN-09
    SQL> SELECT TO_CHAR(sysdate, 'MONTH') FROM Dual
      2  /
    TO_CHAR(SYSDATE,'MONTH')
    JUNE
    SQL> SELECT TO_CHAR(sysdate, 'YYYY') FROM Dual
      2  /
    TO_C
    2009
    SQL> SELECT      TO_CHAR (SEQ.NEXTVAL)
      2           || TO_CHAR (SYSDATE, 'fmMONTH')
      3           || TO_CHAR (SYSDATE, 'YYYY')
      4              auto_gen
      5    FROM   DUAL
      6  /
    AUTO_GEN
    1JUNE2009
    SQL> /
    AUTO_GEN
    2JUNE2009
    SQL> /
    AUTO_GEN
    3JUNE2009
    SQL> /
    AUTO_GEN
    4JUNE2009
    SQL>Hope this helps.
    Regards,
    Jo
    Edit: Corrected Query

  • Quarter to date and year to date

    i need to create a formula that if the end user selects parameter  QTD, the report should retrieve all records where the effective date  is in the current quarter. having trouble with that anyone help?  The following is somewhat working, but i need to retrieve records in the currentqtr.
    if {?Date Range}='QTD' and {Sheet1_.EFF_DT} in Calendar1stQtr then {@qtd}=1.00
    else
    if {?Date Range}='QTD' and {Sheet1_.EFF_DT} in Calendar2ndQtr then {@qtd}=2.00
    else
    if {?Date Range}='QTD' and {Sheet1_.EFF_DT} in Calendar3rdQtr then {@qtd}=3.00
    else
    if {?Date Range}='QTD' and {Sheet1_.EFF_DT} in Calendar4thQtr then {@qtd}=4.00

    If all you want is to get the records with Effective date in the current quarter when QTD is chosen in the parameter then try this:
    if {?Date Range}='QTD' then
    {Sheet1_.EFF_DT} in
    select month(currentdate)
    case 1 to 3:
    Calendar1stQtr
    case 4 to 6:
    Calendar2ndQtr
    case 7 to 9:
    Calendar3rdQtr
    case 10 to 12:
    Calendar4thQtr
    default:
    date(1800,01,01) to date(1800,01,01);  // This will never process

  • T3 change date and year and time

    How do I change the date and time and year on a T3?

    Go to the Prefs app -> Date & Time.
    or do a soft reset, stick the stylus tip into the hole labeled "RESET"
    It will reboot and take you directly to the Date & Time panel.
    webosnation.com is another option for help.

  • In recrutiment in letters default data and time should come

    Dear Group
    Here i am have a problem that my client whats interview date and time should be disployed in letters.
    But for this i want to enhance 2 fields in costome infotype but the abapr is saying that this cannot be done .because these r not appearing in pb50and pb60.so kindly tell me any way so how can i get the date and time displayed

    see in so10 we have maintained letters but in interview invitation letter interview date and time should come.so for this we r maintaing in custom infotye9xxx so it has to pick that time and date from this infotye and it should display in this letter .

  • When I add a meeting invitation to ical it enters on wrong date...help!  It shows up as a random date and year, When I add a meeting invitation to ical it enters on wrong date.

    I am running Mountian Lion on a new (8 months) MBPro 13".  I recently started having iCal enter meeting invitations that I receive on the wrong dates!  Not just a day or hour off...but a year or more!  Of course at first I didn't even notice I would just click to accept and add the invite to the calendar and when I would return it was gone.  If I do a "quick look" at the invitation from within the Mail it shows the correct time and date...but it I open it, it's totally ramdom what date it picks.

    I am having a similar problem:  invitations sent (presumably from outlook), when accepted from my iPad, appear in the calendar with the wrong time zone.
    this actually happens even when the meeting is in the same time zone I'm in:  I am in GMT -5, and even when the meeting is in GMT-5, it defaults to GMT (or, in some instances, PST).  My settings have my time zone set correctly.
    Any help much appreciated.
    PS:  Using iPad original wit iOS5

  • Sql queries for date and year

    Hi Friends,
    I Have a view named - item_sales with 4 column
    Item code
    Item name
    Transaction_YYYYMM (Date stored in YYYYMM format )
    QTY_RECEIVED
    QTY_SOLD
    Sample data is
    ITEM_CODE ITEM NAME  TRANSACTION_YYYMM     QTY_RECD    QTY_SOLD
    AX             TSHIRT                201307                             3000               2000
    AX             TSHIRT                201308                             2000               500
    AX             TSHIRT                201309                             1000              3000
    CX             XLSHIRT              201307                              3000             2000
    CX             XLSHIRT              201308                              3000             2500
    CX             XLSHIRT             201309                               3000             2500
    EVERY MONTH END I WILL RUN THIS QUERY TO FIND OUT THE BELOW DETAILS
    1. TO FIND ITEM_NAME WISE  -  QTY_RECEIVED AND QTY_SOLD ( FOR CURRENT MONTH - EXAMPLE SEP )
    2. TO FIND ITEM_NAME WISE  -  QTY_RECEIVED AND QTY_SOLD   (FOR CURRENT YEAR EXAMPLE FROM JAN TO SEP )
    OUTPUT FOR SEPTEMBER MONTH LOOK LIKE THIS
                                                            SEP-MONTH                              JAN TO SEP
    ITEM_CODE   ITEM_NAME    QTY_RECEIVED  QTY_SOLD      QTY_RECEIVED  QTY_SOLD
    AX                TSHIRT                   1000                 3000                 6000                 5500
    CX                XLSHIRT                  3000                2000                 9000                 7000
    Pls advise me how to write queries for this
    Rdk

    Just FYI, you *can* edit your own posts, you know
    Rdk wrote:
    Transaction_YYYYMM (Date stored in YYYYMM format )
    First "problem". Don't store dates as string. Store them as dates. It will save you so much headache don't the road you won't believe it.
    True, this is a view, so maybe not as critical - assuming the underlying *DATA* is actually a date.
    1. TO FIND ITEM_NAME WISE  -  QTY_RECEIVED AND QTY_SOLD ( FOR CURRENT MONTH - EXAMPLE SEP )
    2. TO FIND ITEM_NAME WISE  -  QTY_RECEIVED AND QTY_SOLD   (FOR CURRENT YEAR EXAMPLE FROM JAN TO SEP )
    So yeah, based on these requirements, I'd recommend you make that column a DATE, not a string. Dates are easier to parse for date-related logic - such as month by month as you need here.
    Using that, here's one way to do it:
    with w_data as (
          select 'AX' item_code, 'TSHIRT ' item_name, to_date('20130701','yyyymmdd') trans_dt, 3000 qty_recd, 2000 qty_sold from dual union all
          select 'AX'          , 'TSHIRT '          , to_date('20130801','yyyymmdd')         , 2000         , 500           from dual union all
          select 'AX'          , 'TSHIRT '          , to_date('20130901','yyyymmdd')         , 1000         , 3000          from dual union all
          select 'CX'          , 'XLSHIRT'          , to_date('20130701','yyyymmdd')         , 3000         , 2000          from dual union all
          select 'CX'          , 'XLSHIRT'          , to_date('20130801','yyyymmdd')         , 3000         , 2500          from dual union all
          select 'CX'          , 'XLSHIRT'          , to_date('20130901','yyyymmdd')         , 3000         , 2500          from dual
       w_base as (
          select item_code, item_name, trans_dt, qty_recd, qty_sold,
                 sum(qty_recd) over (partition by item_code, trunc(trans_dt, 'MM')) mm_recd,
                 sum(qty_sold) over (partition by item_code, trunc(trans_dt, 'MM')) mm_sold,
                 sum(qty_recd) over (partition by item_code, trunc(trans_dt, 'YY')) yy_recd,
                 sum(qty_sold) over (partition by item_code, trunc(trans_dt, 'YY')) yy_sold,
                 row_number() over (partition by item_code order by trans_dt desc) rnum
            from w_data d
    Select item_code, item_name, mm_recd, mm_sold, yy_recd, yy_sold
      from w_base
    where rnum = 1
    IT ITEM_NA    MM_RECD    MM_SOLD    YY_RECD    YY_SOLD
    AX TSHIRT        1000       3000       6000       5500
    CX XLSHIRT       3000       2500       9000       7000

  • Month-to-Date and Year-to-Date values in Query

    Hello experts,
    One of our BI reports has the following requirement: the user should be asked for the report date. After the user inputs the date, the report shows the key figures in three different "flavors": one is the values for that date, the second one is the cumulate values from the first day of the month of the report date to the report date itself, and the third is the cumulate values from the first day of the year of the report date to the report date itself.
      I created my report date variable based on 0CALDAY. Then I searched for SAP-exit variables that would help me achieve this, but could not really find any, except for 0P_ABO10, 0P_ABO11, 0P_ABO12 variables, all of them have as description "Start of Key Date Year". I tried creating a few selections in which the dates taken were defined as a range from each of these variables to the report date variable (for the year-to-date values), but I got the error "Variable 0P_ABO10 could not be substituted". I also got this error for the other two variables. And I could not find any SAP-exit variables like "Start of Key Date Month", in order to do the Month-to-Date part. My next try was to use the field "Key Date" with a variable in it, instead my own report date variable based on 0CALDAY, but it gave me the same errors.
    I searched the forums and found a few threads that looked useful, like
    First and Last day of month and
    1st day of month / 1st day of week variables
    However, they require some ABAP coding, and I do not know where to place the code (actually, I do not know where to work with ABAP code), and I also believe that I would have to do some changes to it.
    Any suggestions?

    Hi Pedro,
    You have to create customer exit in T_Code: CMOD
    1. Create a Z project
    2. Select RSR00001 as enhancement type.
    3. Go into include ZXRSRU01
    4. create a code like
    Here A is your variable based on 0calmonth with type customer exit and B is variable for 0calday.
    Try to write logic for your case taking this as example.
    WHEN 'A'.
        IF I_Step = 2.
          Loop at I_T_VAR_RANGE into L_T_VAR_RANGE where VNAM = 'B'.
            Concatenate L_T_VAR_RANGE-LOW(4) '001' into D1.
            Concatenate L_T_VAR_RANGE-LOW(4) '012' into D2.
            Clear L_S_Range.
            L_S_Range-low = D1.
            L_S_RANGE-high = D2.
            L_S_RANGE-sign = 'I'.
            L_S_RANGE-opt = 'BT'.
            Append L_S_Range to E_T_Range.
          ENDLOOP.
        ENDIF.
    If you want exact code I can help you in that.
    Thanks,
    Kams

  • Wrong date and year on calendar

    Hi there, I did get all things working right. I finilly got my new Tungsten E2 working. But know for some reason every time I open the calendar it opens to 2005. I have go to year change in the this year and date before I see what I am looking for or to put in a new appt. I have look in all of the preferences, options. Nothing is working. I am taken a big dislike to this new PDA.
    Post relates to: Tungsten E2

    Finally got the date fixed, it was simple once I got palm support. I did a hard reset, then set the date but DID NOT click on TODAY at the bottom of the screen, the secret is to tap on the actual DAY on the calendar, NOT TODAY (after you set the year)
    Post relates to: Tungsten E2

Maybe you are looking for