Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. Database
  4. add 30 days from a given date

add 30 days from a given date

Scheduled Pinned Locked Moved Database
tutorialquestion
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Member 3879881
    wrote on last edited by
    #1

    Hi i have one doubt..., I want to add a month from the given date..., Mean suppose if i give a date(mm/dd/yyy)='01/01/2008' from that add 30 days and give '31/01/2008' another example if i give '02/16/2008' add 30 days and give '03/16/2008' like this, how its possible?

    Thanks & Regards, NeW OnE, please don't forget to vote on the post

    S K 2 Replies Last reply
    0
    • M Member 3879881

      Hi i have one doubt..., I want to add a month from the given date..., Mean suppose if i give a date(mm/dd/yyy)='01/01/2008' from that add 30 days and give '31/01/2008' another example if i give '02/16/2008' add 30 days and give '03/16/2008' like this, how its possible?

      Thanks & Regards, NeW OnE, please don't forget to vote on the post

      S Offline
      S Offline
      Syed Mehroz Alam
      wrote on last edited by
      #2

      You can use the DateAdd function. See msdn documentation here[^] Regard, Mehroz

      1 Reply Last reply
      0
      • M Member 3879881

        Hi i have one doubt..., I want to add a month from the given date..., Mean suppose if i give a date(mm/dd/yyy)='01/01/2008' from that add 30 days and give '31/01/2008' another example if i give '02/16/2008' add 30 days and give '03/16/2008' like this, how its possible?

        Thanks & Regards, NeW OnE, please don't forget to vote on the post

        K Offline
        K Offline
        Khawar Abbas1
        wrote on last edited by
        #3

        select dateadd(day,30,columnname) from tablename

        Do good and have good.

        M 1 Reply Last reply
        0
        • K Khawar Abbas1

          select dateadd(day,30,columnname) from tablename

          Do good and have good.

          M Offline
          M Offline
          Member 3879881
          wrote on last edited by
          #4

          thanks

          Thanks & Regards, NeW OnE, please don't forget to vote on the post

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups