List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:March 4 2002 10:45pm
Subject:Re: difference between two times
View as plain text  
>The file is attached and is also available at
>http://estore.homeip.net/time/pctimesheetnew.php.txt.  What do you mean by
>supplying a column alias...how would I do that?  Thanks.

Instead of writing:

SELECT some-long-expression

Write:

SELECT some-long-expression AS xyz

Then the output column will be named xyz, and you can do this:

$total = mysql_result($result2, 0, "xyz");

But now that I look more closely at your code again, the problem is actually
fairly simple.  Your query is in $query2, but you're passing $query to
mysql_db_query().  That's bound to give you a result you don't want. :-)

Thread
difference between two timesNathan Cowles4 Mar
Re: difference between two timesPaul DuBois4 Mar
  • Re: difference between two timesNathan Cowles4 Mar
    • RE: difference between two timesRoger Baklund4 Mar
      • RE: difference between two timesNathan Cowles5 Mar
Re: difference between two timesPaul DuBois4 Mar
  • Re: difference between two timesNathan Cowles4 Mar
Re: difference between two timesPaul DuBois4 Mar
  • Re: difference between two timesNathan Cowles4 Mar
Re: difference between two timesPaul DuBois4 Mar