ak47suk1

keusahawanan

Jun 13th, 2013
62
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2.  
  3. $db = new PDO('mysql:host=localhost;
  4.     dbname=moodle;
  5.     charset=utf8',
  6.     'namapengguna',
  7.      'katalaluanpengguna');
  8.  
  9. $db->exec('TRUNCATE TABLE keusahawanan');
  10.  
  11. echo 'Truncate table finished...';
  12.  
  13. $senarainomatrik = $db->exec('INSERT INTO
  14.     keusahawanan(matrik,userid)
  15.     SELECT username,id
  16.     from mdl_user
  17.     where id in (SELECT
  18.         userid FROM
  19.         `mdl_feedback_completed`
  20.          WHERE `feedback`=19
  21.          and timemodified > 1363326999)');
RAW Paste Data