View Single Post
  #1 (permalink)  
Old 02-18-2007, 03:06 AM
chris_hird chris_hird is offline
Junior Member
 
Join Date: Feb 2007
Posts: 15
Default Need info on how to connect to Db2

Hi

I have gone through the manual with out being able to find any information about how to connect to a Db2 file!

here is the section of code I am trying to use
Code:
$params = array(
		'username' => 'username',
		'password' => 'password',
		'dbname' => 'systemname'
		);
		$DB = Zend_Db::factory('Db2' , $params);
		$row = array(
		'FNAME' => $_POST['fName'],
		'LASTNAME' => $_POST['lName'],
		'EMAIL' => $_POST['email'],
		'USRNAMR' => $_POST['user'],
		'PASSWD' => $_POST['pass']
		);
		$table = 'SHIELDCRM.USERS';
		$rowsAffected = $DB->insert($table, $row);
I put in an echo and I can see it starting in the function, but I get no errors and I dont get the file updated! the user, db and password are OK I use them in the studio and it shows up just fine.

Help is appreciated.

Chris...
Reply With Quote