Mohammad Arif Maseed
Mohammad Arif Maseed

Reputation: 39

JavaScript ADODBE connection update query not working

JavaScript ADODBE connection how to put or between them in query. Need help:

rs.Open("update customer set Name='" + txtname + "',F_Name='" + txtfname + "',Cnic='" + txtcnic + "',Dues='" + txtdues + "',Fees= '" + txtfees + "'  where Id = '" + id + "'", connection);

Upvotes: 0

Views: 127

Answers (2)

Mohammad Arif Maseed
Mohammad Arif Maseed

Reputation: 39

document.write("<table>");
    document.write("<tr>");
    for (var i = 0; i < rs.Fields.Count ; i++) 
    {

         document.write("<th style='color: #009900;'>" + rs.Fields(i).Name + "</th>");
    }
    document.write("</tr>");

    while (!rs.EOF) {
        document.write("<tr>");

        for (var i = 0; i < rs.Fields.Count; i++)
         {

         document.write("<td >" + rs.Fields(i) +  "</td>");

      }
        document.write("</tr>");
        rs.movenext();
    }

document.write("");

Upvotes: 0

Sanyami Vaidya
Sanyami Vaidya

Reputation: 809

Try this

rs.Open("update customer set Name='" + txtname + "',F_Name='" + txtfname + "',Cnic='" + txtcnic + "',Dues='" + txtdues + "',Fees= '" + txtfees + "'  where Id = '" + id + "'", connection);

Upvotes: 1

Related Questions