-2

I was trying to insert data through one web application I am developing and I could not insert data, while I was troubleshooting what the problem is, I saw that I can not neither edit datetime field even directly through Microsoft SQL Server Management Studio.

I am trying to update a datetime field in SQL Server 2014 but i am getting this weird error

Error when trying to update datetime field

I am trying to make the first row same as the second one and I am getting the above error:

How I am trying to edit data

I have full-permission user and I also can edit all other columns except of datetime type columns!

Any help in this regard would be more then welcome.

Here is the column definition:

enter image description here

  • 2
    Hi There, welcome to the site. Please post entire table definitions and all the values of the record you are updating. Also post the error message you get from the application and the insert statement you are running from the application – Tom V - try topanswers.xyz Mar 18 '16 at 9:45
  • 1
    Don't add those things as images. Right click the table, select 'script as create' and post the generated code. – Tom V - try topanswers.xyz Mar 18 '16 at 20:47
7

This has nothing to do with a permissions issue.

The error message clearly states:

Conversion failed when converting the varchar value 'Receive' to data type int

So you typed the varchar value 'Receive' in another column of data type int, and it most likely has nothing to do with the datetime column.

| improve this answer | |
  • I can read what it is saying but look at the second row ... it is the same ... i copy pasted it ... – Pito Axiu Mar 18 '16 at 14:39
  • This is the reason why i came here to look for answer! – Pito Axiu Mar 18 '16 at 14:41
  • @PitoAxiu if it helped don't forget to accept. Please read through the help center to see how this site works – Tom V - try topanswers.xyz Mar 20 '16 at 8:51

Not the answer you're looking for? Browse other questions tagged or ask your own question.