Sage2Mysql

Posted on Leave a commentPosted in Uncategorized

Daten aus SAGE (khk) in MYSQL übertragen mittels ODBC.     <?php set_time_limit(0); $conn2 = mysql_connect(‘localhost’,’ID’,’PW’); $db=mysql_select_db(‘data’); function querykhk($query) { global $conn; if (!$conn) $conn = odbc_connect(‘KHK’,’ID’,’PW’); $result=odbc_exec($conn, $query); if (!$result) echo “KHK Query Error $query (“.odbc_errormsg().”)”; return $result; } function query($query) { global $conn2; $result=mysql_query($query); if (!$result) { echo “Mysql Error $query (“.mysql_error().”)”; sleep(10); […]