and instead of a void i made it a char.
So, you want the function to return 1 character. Doesn't seem very useful to me.
// Serial.print(field->name);
test = field->name;
field->name is an array of chars that you are trying to assign to a char. That won't work the way you seem to think it will.
Serial.println();
return test;
So, we're done? I don't think so. We haven't gotten anything but the field name, so far, and you already knew what that was. It was what you did the SELECT on.
C:\Users\Casper van Kampen\Desktop\arduino-1.0\libraries\MySQLconnector\mysql.cpp:348: error: return-statement with no value, in function returning 'char'
Every return statement needs to return 1 char. What one char do you want to return when there is an error?
C:\Users\Casper van Kampen\Desktop\arduino-1.0\libraries\MySQLconnector\mysql.cpp:351: error: invalid conversion from 'char*' to 'char'
You can't store an array of characters in one character. This doesn't seem like it should be too hard to understand.
If you are going to add a method to the class, you need to make it a void method that takes a pointer to where to store the data.
void Connector::show_results2(char *putTheDataHere, int bufSiz)
{
}
Then, you need to call the function with that pointer.
char queryResults[128]; // Make some place to store the data
queryResults[0] = '\0';
my_conn.show_results2(queryResults, sizeof(queryResults));
Serial.print("Query results: ");
Serial.println(queryResults);
In the method, then use stcat() to append data to the array, making sure not to exceed the size of the array (in the second argument).