Maybe you would look at my code for 5 minutes ? Please be aware of, at I am not expert in coading 
I have simplified my code and out-commented some of it. My password and homepage is exchanged with xxxxx.
My CODE:
/** WEATHERSTATION
*/
#include "SPI.h"
#include "Ethernet.h"
#include "sha1.h"
#include "mysql.h"
#include "EthernetUdp.h"
/* General parameters /
int hh=1; / hour number of current time /
int T; / Temperature /
int P; / Pressure /
int RH; / Relative Humidity /
int debug; / Set to 1 if debug information is needed */
int i; /*counter */
char CommandChar[]="";
unsigned int localPort = 8888;
IPAddress timeServer(94, 231, 110, 37); // dk.pool.ntp.org NTP server
int led = 9;
int Midlertidig=1;
/* Setup for Ethernet Library */
byte mac_addr[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
/* Setup for the Connector/Arduino /
Connector my_conn; / The Connector/Arduino reference */
/* SQL database information /
IPAddress server(xxx,xxx,xxx,xxx);
char user[] = "xxxxxxxxxx";
char password[] = "xxxxxxxxx";
char DeleteOne_SQL[] = ""; / Sletter et datapunkt /
char DeleteAll_SQL[] = ""; / Sletter alle datapunkter /
char Update_SQL[] = ""; / Opdaterer/ændrer et datapunkt */
const int NTP_PACKET_SIZE= 48; // NTP time stamp is in the first 48 bytes of the message
byte packetBuffer[ NTP_PACKET_SIZE];
EthernetUDP Udp;
void setup() {
pinMode(led, OUTPUT);
Ethernet.begin(mac_addr);
Serial.begin(115200);
delay(1000);
Udp.begin(localPort);
Serial.println(F("Connecting database."));
if (my_conn.mysql_connect(server, 3306, user, password))
{
Serial.print(F("Try to send SQL command: "));
delay(500);
/* Update SQL data */
my_conn.cmd_query("UPDATE xxxxxxxxxxxxxx.xxxxxxxxxxx SET temp=0 WHERE tid=0"); delay(500);
Serial.println(F("Query Success!"));
delay(500);
my_conn.disconnect();
delay(500);
}
else
Serial.println(F("Connection failed."));
}
int freeRam () {
extern int __heap_start, *__brkval;
int v;
return (int) &v - (__brkval == 0 ? (int) &__heap_start : (int) __brkval);
}
// send an NTP request to the time server at the given address
unsigned long sendNTPpacket(IPAddress& address)
{
// set all bytes in the buffer to 0
memset(packetBuffer, 0, NTP_PACKET_SIZE);
// Initialize values needed to form NTP request
// (see URL above for details on the packets)
packetBuffer[0] = 0b11100011; // LI, Version, Mode
packetBuffer[1] = 0; // Stratum, or type of clock
packetBuffer[2] = 6; // Polling Interval
packetBuffer[3] = 0xEC; // Peer Clock Precision
// 8 bytes of zero for Root Delay & Root Dispersion
packetBuffer[12] = 49;
packetBuffer[13] = 0x4E;
packetBuffer[14] = 49;
packetBuffer[15] = 52;
// all NTP fields have been given values, now
// you can send a packet requesting a timestamp:
Udp.beginPacket(address, 123); //NTP requests are to port 123
Udp.write(packetBuffer,NTP_PACKET_SIZE);
Udp.endPacket();
}
void GetTime() {
/* Midlertidig - venter en given tid /
for (int i=0; i <= 1060; i++){
digitalWrite(led, HIGH); // turn the LED on (HIGH is the voltage level)
delay(240); // wait for a second
digitalWrite(led, LOW); // turn the LED off by making the voltage LOW
delay(240);
digitalWrite(led, HIGH); // turn the LED on (HIGH is the voltage level)
delay(240); // wait for a second
digitalWrite(led, LOW); // turn the LED off by making the voltage LOW
delay(240);
Serial.print(i);
Serial.print(F("/600 "));
Serial.print(F("Free SRAM="));
Serial.println(freeRam ());
}
/*Beregner tiden */
sendNTPpacket(timeServer); // send an NTP packet to a time server
delay(1000);
if ( Udp.parsePacket() ) {
// We've received a packet, read the data from it
Udp.read(packetBuffer,NTP_PACKET_SIZE);
unsigned long highWord = word(packetBuffer[40], packetBuffer[41]);
unsigned long lowWord = word(packetBuffer[42], packetBuffer[43]);
unsigned long secsSince1900 = highWord << 16 | lowWord;
const unsigned long seventyYears = 2208988800UL;
unsigned long epoch = secsSince1900 - seventyYears;
hh=(epoch % 86400L) / 3600+2; // print the hour (86400 equals secs per day)
}
if (hh==24) hh=0;
if (hh==25) hh=1;
if (hh==26) hh=2;
}
void GetWeatherData() {
float sensorValue = analogRead(A0);
sensorValue = sensorValue/10235;
sensorValue=10000sensorValue/(5-sensorValue); /* Rx */
sensorValue=1/(log(sensorValue/10000)/3950+1/298.15)-273.15;
T = sensorValue;
Serial.print(F("T="));
Serial.println(T);
}
void DeleteAllSQLData() {}
void InsertSQLData() {
/* String Dummy1 = "";
String Dummy2 = "UPDATE xxxxxxxxxxxxxx.xxxxxxxxxxxx SET temp=";
String Dummy3 = " WHERE tid=";
char charBuf[80];
/
/ Prepare SQL string /
/ Dummy1=Dummy2;
Dummy1 +=T;
Dummy1 += Dummy3;
Dummy1 += hh;
Dummy1.toCharArray(charBuf,80);
/
/ Connect to SQL and send string if connected /
if (my_conn.mysql_connect(server, 3306, user, password))
{
Serial.print(F("Try to send SQL command: "));
delay(1000);
if (Midlertidig==5) {
my_conn.cmd_query("UPDATE xxxxxxxxxxxxxx.xxxxxxxxxxxx SET temp=5 WHERE tid=3");
Midlertidig=1;
}
if (Midlertidig==4) {
my_conn.cmd_query("UPDATE xxxxxxxxxxxxxx.xxxxxxxxxxxx SET temp=4 WHERE tid=3");
Midlertidig=5;
}
if (Midlertidig==3) {
my_conn.cmd_query("UPDATE xxxxxxxxxxxxxx.xxxxxxxxxxxx SET temp=3 WHERE tid=3");
Midlertidig=4;
}
if (Midlertidig==2) {
my_conn.cmd_query("UPDATE xxxxxxxxxxxxxx.xxxxxxxxxxxx SET temp=2 WHERE tid=3");
Midlertidig=3;
}
if (Midlertidig==1) {
my_conn.cmd_query("UPDATE xxxxxxxxxxxxxx.xxxxxxxxxxxx SET temp=1 WHERE tid=3");
Midlertidig=2;
}
/ my_conn.cmd_query(charBuf); */
delay(1000);
Serial.println(F("Query Success!"));
my_conn.disconnect();
}
else
{
Serial.println(F("Connection failed."));
}
}
void ShowDataInDisplay() {
}
void loop() {
debug=1;
hh=0;
while (1) {
/* Hent vejr data til databasen */
GetWeatherData();
/* Gemmer data i databasen */
InsertSQLData();
/* Forudsætning: database med tid 0 - 23 i første søjle og data i de andre søjler /
/ Vent en time og hent tid */
GetTime();
}
}