CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5
  1. #1
    Join Date
    Aug 2006
    Posts
    7

    Changing the year(in current date ) in solaris Urgent!!!

    Hi can anyone help me how to change the year of current date in solaris..

    pls specify the format so that i can change its year ..

    i know this
    "date mmdd hhmn" but how do i change teh year i wannt to change from current year to different year

  2. #2
    Join Date
    Oct 2002
    Location
    Austria
    Posts
    1,284

    Re: Changing the year(in current date ) in solaris Urgent!!!

    man date gave me this
    Code:
    date [-u|--utc|--universal] [MMDDhhmm[[CC]YY][.ss]]
    but that is not solaris
    Kurt

  3. #3
    Join Date
    Aug 2006
    Posts
    7

    Re: Changing the year(in current date ) in solaris Urgent!!!

    hi Kurt thnx for reply,
    so u mean if current date is suppose 2Aug2000 and if i want to change to todays date that is 14Aug2006 9pm then

    i will write as below

    "081421001906"

    i didnt understand abt -u n other options
    Pls suggest

  4. #4
    Join Date
    Oct 2002
    Location
    Austria
    Posts
    1,284

    Re: Changing the year(in current date ) in solaris Urgent!!!

    I understand to set todays date would be
    Code:
    date 0814140306
    Kurt
    edit: in your example that would be

    Code:
    date 0814210006
    Last edited by ZuK; August 14th, 2006 at 07:06 AM.

  5. #5
    Join Date
    Aug 2006
    Posts
    7

    Re: Changing the year(in current date ) in solaris Urgent!!!

    thnks .. i cld change it ..by another option with date command.. its working
    i used "date -u 081421002006".its working thanks


    did u tried ur command on any unix

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured