Strings and variables in select statements

2004-03-23 Thread Annie Law
Hi, I would appreciate help with the following. I have a table where each of the values in a column consists of a combination of letters and numbers followed by a decimal then a single digit. Examples of the two types of entries that could be found in this column(accession_num) are: BQ877252.1

Re: Strings and variables in select statements

2004-03-23 Thread Ligaya Turmelle
I'm a beginner so don't quote me. I beleive you need something like: Select hs_identifiers.hs_id_num from hs_identifiers, where (accession_num LIKE (result of another select statement)%); I beleive that should give you the first part and if there is anything after it. Respectfully, Ligaya

RE: Strings and variables in select statements

2004-03-23 Thread tweewan.wong
PROTECTED] Subject: Re: Strings and variables in select statements I'm a beginner so don't quote me. I beleive you need something like: Select hs_identifiers.hs_id_num from hs_identifiers, where (accession_num LIKE (result of another select statement)%); I beleive that should give you the first

$Variables and Select statements

2002-12-18 Thread C. Reeve
Hi, From the code below $wk gets the values (w1, w2, w3, etc.) as it goes through the 'for' loop. w1, w2, etc. are also colums in the table manager. What I can't figure out is why the select statement fails (no error, just no data) when I use $wk as apposed to hardcoding w1, w2, etc. Is this

RE: $Variables and Select statements

2002-12-18 Thread Basil Hussain
Hi, while ($line = mysql_fetch_array($result, MYSQL_ASSOC)) { echo TR WIDTH=150TD ALIGN=left.$line['name']./TDTD ALIGN=right.$line['$wk']./TD; } Here is your problem. Your are indeed substituting $wk into the query correctly, but when you go to output the

Re: $Variables and Select statements

2002-12-18 Thread C. Reeve
- Original Message - From: Basil Hussain [EMAIL PROTECTED] To: C. Reeve [EMAIL PROTECTED]; MySQL List [EMAIL PROTECTED] Sent: Wednesday, December 18, 2002 11:57 AM Subject: RE: $Variables and Select statements Hi, while ($line = mysql_fetch_array($result, MYSQL_ASSOC