Tangara G

Tangara G

  • NA
  • 298
  • 93.2k

What are @fn, @tel, @eml in the sql query below?

Oct 31 2016 7:35 AM
Dear experts,
 
 
I would like to know what are @fn,@tel, @eml are ?
Are these names we just anyhow gave ?  If not where on earth it came from ?
  1. protected void btnCreate_Click(object sender, EventArgs e)  
  2.         {  
  3.             DAO.MembersDAO memDAO = new DAO.MembersDAO();  
  4.   
  5.             string sql = "INSERT INTO member VALUES (@fn, @tel, @eml)";  
  6.   
  7.             //SqlParameterCollection spc = null;  
  8.             //spc.Add(new SqlParameter("@fn", SqlDbType.NVarChar)).Value = txtFullName.Text;  
  9.             //spc.Add(new SqlParameter("@tel", SqlDbType.NVarChar)).Value = txtTel.Text;  
  10.             //spc.Add(new SqlParameter("@eml", SqlDbType.NVarChar)).Value = txtEmail.Text;  
  11.   
  12.             SqlParameter[] spa = new SqlParameter[3];  
  13.             spa[0] = new SqlParameter("@fn", SqlDbType.NVarChar);  
  14.             spa[0].Value = txtFullName.Text;  
  15.             spa[1] = new SqlParameter("@tel", SqlDbType.NVarChar);  
  16.             spa[1].Value = txtTel.Text;  
  17.             spa[2] = new SqlParameter("@eml", SqlDbType.NVarChar);  
  18.             spa[2].Value = txtEmail.Text;  
  19.   
  20.             int result = memDAO.InsertMember(sql, spa);  
  21.   
  22.             if (result == 1)  
  23.             {  
  24.                 Response.Redirect("MemberList.aspx");  
  25.             } 

Answers (10)