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
Abey Varghese
NA
18
9.4k
Error in Update, Using Entity Framework model
Jan 18 2013 4:57 PM
Hi,
I am using Entity framework here, getting error like " An error occured while executing the command defenition".All database fiels are in correct order. Need help.
public static bool UpdateCWEquipment(string dbLocation, Int32 eqSID, string eqUnitNumber, string descr,
string manufacturer, string model, Int32 eqUnitID, bool isActive, decimal unitCost, string FEMACode,
string ICMACode)
{
try
{
//grab the connection string
string connString = ObtainConnectionString(dbLocation);
//only continue if we have a connection string
if ((!string.IsNullOrEmpty(connString)))
{
using (CWUPTestEntities ctx = new CWUPTestEntities(connString))
{
try
{
//update the information
retCount = ctx.okc_UpdateEquipmentByEquipmentSID(
eqSID,
eqUnitNumber,
descr,
manufacturer,
model,
eqUnitID,
(isActive ? "ACTIVE" : "INACTIVE"),
unitCost,
DateTime.Now.ToShortDateString(),
ICMACode,
FEMACode
);
}
catch (Exception Ex)
{
throw new Exception("Error in updating data", Ex);
}
Reply
Answers (
0
)
Remove maximize,minimize and control box in MDI child form
Difference between categories and extensions?