TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Nick Els
NA
16
656
SQL Server date format.
Oct 16 2017 7:42 AM
Thank you. I'm very new to this - I've a small program to start off with in which I'm adding records with 4 textboxes and a datapicker1 control on a Windows form. I'm not managing to get the SQL server databse to except my date format ie. "dd/mm/yyyy" - it insist I enter the date as YYYY-MM-DD
The databse is field for the date is set as DATE - I've tried adding a DEFAULT GETDATE() & also tried SYSTEM() for the field in design view, but to no avail.
CREATE TABLE [dbo].[PhoneIndex] (
[phoneId] INT IDENTITY (1, 1) NOT NULL,
[fName] VARCHAR (50) NOT NULL,
[lName] VARCHAR (50) NOT NULL,
[datePhoned] DATE NOT NULL DEFAULT GETDATE(),
[reaSon] VARCHAR (250) NOT NULL,
[PhoneNumber] NCHAR(15) NULL,
CONSTRAINT [PK_PhoneIndex] PRIMARY KEY CLUSTERED ([phoneId] ASC)
);
Source code attached ZIP file.
Thank you so much.
Nick.
Attachment:
CallsMain.zip
Reply
Answers (
2
)
Textbox numeric format
How to use Ancestors with Descendants in LINQ to XML?