Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7717387
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T02:53:07+00:00 2026-06-01T02:53:07+00:00

I am using SQL Server 2000. When I try to update a column of

  • 0

I am using SQL Server 2000. When I try to update a column of type varchar(20) with a text value of more than 10 characters, I get an error

String or binary data would be truncated.

Why is it? varchar(20) should accept a text of up to 20 characters… why can I not update it with text with more than 10 characters?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T02:53:08+00:00Added an answer on June 1, 2026 at 2:53 am

    If your string variable is declared as nvarchar(n), then it will take up twice as much space as a varchar(n)

    10 x 2 = 20
    

    So, anything greater than 10 double-byte chars will not fit into a varchar(20)

    If you are inserting/updating into a column of type varchar, also declare your string variable as varchar with the appropriate size.

    declare @str varchar(20)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Using SQL Server 2000 I get a database from sql 2005, then i try
When I try to import Text File into SQL Server 2000 using DTS, it
i am using sql server 2000 can i use full text search on the
Using SQL Server 2000 Table ID Date Value 001 23-02-2009 300 001 24-02-2009 400
Using SQL Server 2000 Master Table ID Date Value 001 23-04-2009 200 001 24-04-2009
I'm using SQL Server 2000 and i'm trying to run an update query to
Using SQL Server 2000 I Want to Check the colum value whether it is
I'm using SQL Server 2000 and my ERP vendor has used a Text datatype
Using sql server 2000, I would like to take my production data and put
Using SQL Server 2000 Table PersonID Date 001 11-02-2009 002 11-02-2009 003 11-02-2009 001

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.