converting a mysql_row to an integer
is there an easy way to convert a row obtained from a result of a query into an integer in C/C++...

eg

`while((row = mysql_fetch_row(result)) != NULL)   //iterating over each row of the result

{
 printf("%s\n",row[0]);
}'` 


output
100
101
102

mysql_row is of the type string so i can easyily display..but my problem is i want to convert that to an intger so that i can add all the column values of the result

i.e 100+101+102

i guess using sscanf helps but dont knw how to use it in this situation...plz hlp

    


converting a mysql_row to an integer
===

is there an easy way to convert a row obtained from a result of a query into an integer in C/C++...

eg

`while((row = mysql_fetch_row(result)) != NULL)   //iterating over each row of the result

{
 printf("%s\n",row[0]);
}'` 


output
100
101
102

mysql_row is of the type string so i can easyily display..but my problem is i want to convert that to an intger so that i can add all the column values of the result

i.e 100+101+102

i guess using sscanf helps but dont knw how to use it in this situation...plz hlp

    

