Advertisement
Guest User

Untitled

a guest
Sep 13th, 2017
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. $server="systemdnsfile1"; #the name of the iSeries
  2. $user="user"; #a valid username that will connect to the DB
  3. $pass="pass"; #a password for the username
  4. $conn=odbc_connect($server,$user,$pass); #you may have to remove quotes
  5.  
  6. @n$db = @new PDO(
  7. "mysql:host={$sql_details['host']};dbname={$sql_details['db']}",
  8. $sql_details['user'],
  9. $sql_details['pass'],
  10. array( PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION )
  11. );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement