我正在使用 LINQ 访问 sql 数据库。下面的代码安全吗?
var addRec = (from p in db.5544
where p.ID == newAddID
select p).Single();
addRec.Address1 = comAddTxt1.Text; //create address record
addRec.Address2 = comAddTxt2.Text;
addRec.Address3 = comAddTxt3.Text;
addRec.Address4 = comAddTxt4.Text;
addRec.PostCode = pstCdeTxt.Text;
addRec.Town = twnTxt.Text;
addRec.County = cntyTxt.Text;
addRec.Country = cntComBox.SelectedItem.Text;
db.SubmitChanges();
谢谢,