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
Usha Raj
NA
144
59.7k
Error Converting nvarchar to int
Apr 6 2015 3:24 AM
Am trying to add the table column value into another table ,the column data type is varchar(.i.e QQ20150001),but while adding into another table am getting the error like "Error Converting nvarchar to int"
my code is:
page.DAL
public void SaveData(string JobTitle, string RequiredExp,string JobLocation,int RegistrationId,string RequirementId)
{
SqlConnection con = dbcon.OpenCoonection( );
SqlCommand cmd = new SqlCommand("USP_InsertSavedJobs", con);
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.Add("@JobTitle", JobTitle);
cmd.Parameters.Add("@RequiredExp", RequiredExp);
cmd.Parameters.Add("@JobLocation", JobLocation);
cmd.Parameters.AddWithValue("@RegId", RegistrationId);
cmd.Parameters.Add("@RequirementId", RequirementId);// Am getting the this value from other table by using session
cmd.ExecuteNonQuery();
dbcon.CloseConnection();
}
Can any one tell me what's going wrong?
Reply
Answers (
20
)
how can transfer data from one database to another database
Sql Server Performance & Database Performance