November 16, 2009 at 1:43 pm
Hello room,
I have three year of data with time stamp (2009-07-01 03:55.07.678) on it.
I wanted to split those data into a month per year.
How can I do that? Can somone give me lights?
Thanks,
TJ
November 16, 2009 at 2:01 pm
What is the Datatype you have? Is it Timestamp Datatype or Datatime Datatype that you are using as a timestamp.
You can implement it using Database Partitioning.
Follow the link http://www.learnsqlwithbru.com/Database%20Partitioning%20in%20SQL%20Server%202005.htm
Blog -- LearnSQLWithBru
Join on Facebook Page Facebook.comLearnSQLWithBru
Twitter -- BruMedishetty
November 16, 2009 at 3:56 pm
You might want to look at the date part function in Books On Line:
DATEPART (Transact-SQL)
ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/tsqlref9/html/15f1a5bc-4c0c-4c48-848d-8ec03473e6c1.htm
November 16, 2009 at 4:44 pm
Edwin-376531 (11/16/2009)
Hello room,I have three year of data with time stamp (2009-07-01 03:55.07.678) on it.
I wanted to split those data into a month per year.
How can I do that? Can somone give me lights?
Thanks,
TJ
As you can see from the 2 vastly different answers that you've got so far, your question is a bit unclear. You want to 'split' the data? What does that mean, storage, querying? What problem are you facing that makes you think the data needs 'split'? Can you give us an example of what you are trying to do?
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply