Greets Everyone..
i have grid view like this
picture below..
http://i48.tinypic.com/vdd1qa.png now i want a new page naming result... which will have only total of table1(pic provided above)..
and i want it to result like this.
RESULTS ID school_name maths_total science_total computer_total
1. karen's 700 1000 1050
i have a table naming result for this source code in my result page's load event
string connstr = "provider=microsoft.ace.oledb.12.0;data source=c:\\users\\jammy\\documents\\visual studio 2010\\websites\\testing\\app_data\\test.accdb;persist security info=true";
OleDbConnection conn = new OleDbConnection();
conn.ConnectionString = connstr;
OleDbDataAdapter adapter = new OleDbDataAdapter();
adapter.InsertCommand = new OleDbCommand();
adapter.InsertCommand.CommandText = "INSERT INTO result('name',mat_total','sci_total,'com_total') SELECT SUM(math),SUM(science),SUM(computer) FROM table1";
conn.Open();
adapter.InsertCommand.Connection = conn;
adapter.InsertCommand.ExecuteNonQuery();
whenever i am debbuging, i got this error
Exception Details: System.Data.OleDb.OleDbException: Syntax error in INSERT INTO statement.
kindly help me with this source