0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

memo用

Posted at
getMessage() ); die(); } $sql_column = "SELECT COLUMN_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME= 'schedule'";//カラム名を取得したい条件をWHEREにいれる。 $stmt_column = $dbh_column->query($sql_column); if ( !$stmt_column ) { echo $dbh_column->errorInfo(); exit(); } $row_column = $stmt_column->fetch(PDO::FETCH_ASSOC); while ( $row_column = $stmt_column->fetch(PDO::FETCH_ASSOC) ) { array_push($join_member ,$row_column["COLUMN_NAME"]); } print_r($join_member); $dbh_column = null; //カラム終了 //セル取得 $dbh =new PDO('mysql:host=localhost;dbname=test;charset=utf8', $user, $pass); $dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);//dbhのDBに属性を設定 $sql = "SELECT * FROM schedule";//リクエスト分 $stmt = $dbh->query($sql);//stmtに全てのリクエストを取得する。 //セル取得 ?> おみくじ メール送信テスト画面 ".$row['date'].""; } $stmt = $dbh->query($sql);//stmtに全てのリクエストを取得する。 echo ""; for($i = 0 ; $i < count($join_member); $i++){ echo ""; echo ""; $stmt = $dbh->query($sql);//stmtに全てのリクエストを取得する。 foreach ($stmt as $row){//繰り返しテーブルの行を追加する。 echo ""; } echo ""; } ?>
名前
$join_member[$i]".$row["$join_member[$i]"]."
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?