$dsn = "mysql:dbname=sier;host=namysql.database.windows.net"; $user = "hoge@namysql"; $password = "hogehoge"; try { $dbh = new PDO($dsn, $user, $password); } catch (PDOException $e){ print('connection failed:'.$e->getMessage()); } $sql = "select * from forein"; $stmt = $dbh->query($sql); $result = $stmt->fetchAll(PDO::FETCH_ASSOC); print_r('<pre>'); var_dump($result); print_r('</pre>');
ぎゃーーー!
って別に驚くことではないが。。