$row[Primaryexpertise] //not like this
$row['Primaryexpertise'] //like this
$row["Primaryexpertise"] //or like this

>i always user double quotes with postgrtesql and it works like a treat.
> the difference seems to be with mysql.

Also, even though simple variable references are expanded within 
double-quotes (ex. "where Profileid = '$profileid'"), the PHP parser seems 
to be less certain about how to deal with array indexes: is the square 
bracket intedned as plain text, as a special character (such as in a 
regular expression) or is it actually an array index?  I find that dropping 
out of quotes whenever referencing array indexes eliminates a lot of parse 
errors.  For example:

"select Primaryid from primarycodes where Code = '" . 
$row['Primaryexpertise'] . "'"

Another option is to use extract() so that the array element can be treated 
as a simple string variable:

extract($row);
$result = mysql_query("select Primaryid from primarycodes where Code =
'$Primaryexpertise'")

> String manipulation has me baffled most of the time!

Re-read the manual's chapters on strings and arrays.  Also check out the 
Zend site.  There are some interesting articles and tutorials over there 
that address issues not yet adequately covered in the manual.

-- 
CC

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to