I have a column defined in SharePoint as "Single line of text" when I deploy my webpart, and try to enter text in the field I get the following error from my log file:

"Error converting data type varchar to numeric."

This works in my development environment, but not in my production. I have triple checked my column type, but still get this error. I am able to enter numeric values in the field and it saves just as desired, however when I try to enter text I get the error.

I may have once had the column defined as number, and changed it to "Single Line of text". I'm afraid it's holding on to the previous column type definition.

Any ideas?

  • could you please share the complete logs n also code / screenprint where you declare column. – Waqas Sarwar MVP Jun 24 '14 at 4:53
  • Try this: Go to the field edit page by clicking on the field in SharePoint UI. Change nothing and just click OK (Make sure "Single Line Of Text" is selected). CLICK OK not cancel. – Paiman Samadian Jun 24 '14 at 5:25
  • Have you tried deleting the field and creating it once again? – luccio Jun 24 '14 at 8:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.