Win Surprise Gifts!!!
Top 5 Contributors of the Month
Post New Question
Subscribe to Forum
how to get only year from datetime datatype..
April 08, 2010
i assigned datetime datatype for an column(year).
if the user enter the year in the textbox(year column)
it appears as " mm/dd/yy " format..
i nedd only year from this to be saved into my db when user enter the year...
this is for wpf windows applciation,c#...
Posted Date: April 09, 2010 Points: 5
Go through the below code
Posted Date: November 26, 2010 Points: 5
the above query will only retrive, but it will not store only the year.
if you use the DateTime datatype, it will store this format "mm/dd/yy"
You can use varchar or char.
To post reply
Related Questions Related Questions
Image datatype quivalant in MySQL
How to add a button to calendar control which shows years.so that I can select particular year.
How to find elapsed time between two DateTime
problem in datetime and gridview
Difference between Varchar(MAX) and TEXT Datatype in Sql Server?
Format Datetime to 21 st Sep 2010
How to get current date, day and year in sql server?
B.TECH final year project
Order By with DateTime column
Difference between Datatype Image and Varbinary in SQL Server
Latest Forum Questions From The Same Category
Share WPF Application over net
Rich Desktop Interactive application
How To Find the Combobox in Wpf
Getting Row Value is null in WPF.
Combobox Binding in WPF
Add button to datagrid Dynamially in wpf
Detecting Mobile Device IMEI, IMSI, Model, Comport Information using AT commands in VB.Net
Show the Default Text Of Combobox as "--Select--" when combo is binding to dataset.
how to stop .swf html page any button click in wpf,any idea please share with me
Find more Forum Questions on C#, ASP.Net, Vb.Net, SQL Server and more
Quick Links For Forum Categories:
Hall of Fame
Terms of Service
Tell A Friend