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. hijri calender with sql server 2005

hijri calender with sql server 2005

Scheduled Pinned Locked Moved Database
databasesql-serversysadminquestion
2 Posts 2 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.
  • A Offline
    A Offline
    Ahmad Adnan
    wrote on last edited by
    #1

    im working on windows applicaction and i want to support th ehijri calnder (islamic calnder) the year 1428 will be 2007. but when im trying to inser new filed gave me out of range (1765<) here is some examples:- declare @x datetime set @x= convert(datetime ,'01/01/1428',131) print @x the result is ===> "Jan 19 2007 12:00AM" convert from hijri to gregorian worked well but declare @x datetime set @x= convert(datetime ,'01/01/1482',101) print @x the result is ===> "The conversion of a char data type to a datetime data type resulted in an out-of-range datetime value. " tha means cant convert from hijri to gregorian so plz what is the best method for me to accept the both pc calender setting for my application. regards

    G 1 Reply Last reply
    0
    • A Ahmad Adnan

      im working on windows applicaction and i want to support th ehijri calnder (islamic calnder) the year 1428 will be 2007. but when im trying to inser new filed gave me out of range (1765<) here is some examples:- declare @x datetime set @x= convert(datetime ,'01/01/1428',131) print @x the result is ===> "Jan 19 2007 12:00AM" convert from hijri to gregorian worked well but declare @x datetime set @x= convert(datetime ,'01/01/1482',101) print @x the result is ===> "The conversion of a char data type to a datetime data type resulted in an out-of-range datetime value. " tha means cant convert from hijri to gregorian so plz what is the best method for me to accept the both pc calender setting for my application. regards

      G Offline
      G Offline
      GuyThiebaut
      wrote on last edited by
      #2

      Here is a clue. Try both of these queries: declare @x datetime set @x= convert(datetime ,'01/01/1428',131) print @x print convert(datetime ,'01/19/2007',101) Regards Guy

      You always pass failure on the way to success.
      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