Home > DeveloperSection > Forums > Error while insert value in table.
john rob

Total Post:108

Posted on    December-15-2012 4:18 AM

 MSSQL Server MSSQL Server 

 2 Reply(s)
 1129  View(s)
Rate this:
 when i insert any value in table when a error generated 
my table:
create table customer
id int primary key,
f_name varchar,
l_name varchar,
age int

insert Query:
insert into customer values(1,'John','Rob',22)


Msg 8152, Level 16, State 14, Line 1
String or binary data would be truncated.
The statement has been terminated.
 help me anybody.

Vijay Shukla

Total Post:100

Posted on    December-15-2012 4:22 AM

You can just alter your table with this below code:
create table customer
id int primary key,
f_name varchar(50),
l_name varchar(50),
age int

Shankar M

Total Post:25

Posted on    April-09-2013 9:19 PM

Hi John,

The Error Message says that the values that you are trying to insert to the column specified has exceeded the column length. Alter your table structure and try working it.


Don't want to miss updates? Please click the below button!

Follow MindStick