Okay, thanks all.
I think what I'll do is save the data in a DB, and then read it in
to an array when the script is first called. That way it doesn't need
to perform the SQL query per mime_type hundreds of times, and can just
key it from the array.
How would I go about benchmarking the
On Sat, 2005-04-23 at 20:31 -0500, Tate wrote:
I have php and postgresql installed on my laptop with linux fedora core
3. Everything is working fine, but I have created a survey and want the
entries automatically inserted into the database.
I know what my SQL should be, but I'm not sure
On Sunday 24 April 2005 12:25, Paul Reilly wrote:
How would I go about benchmarking the different options?
What tools are there to do this?
a) time the script - quick, dirty and inaccurate but may provide an
indicative result.
b) use a profiler, which can be more interesting as it will show
Hi,
I have some php application with encoding problem.
I need to change the mySql default encoding to - Hebrew iso 8859-8.
I installed phpmyadmin, you can see it and change things here (it
is not protected):
http://www.adeo.co.il/temp/php/
For some reason i can not find Hebrew iso in the
Can someone help me out with an issue I'm having?
Here is my code:
$res = mysql_query(SELECT ZG_LATITUDE, ZG_LONGITUDE FROM zip_code
wherezg_zipcode = '$zip');
List($Lat,$Lon) = mysql_fetch_row($res);
$Lat1 = ($Lat-2);
$Lat2= ($Lat+2);
$Lon1= ($Lon-2);
$Lon2= ($Lon+2);
//echo ($Lat1);
Hey,
That is a lot of code, so I only skimmed it, but right off the bat i
noticed that you are missing a space in between WHERE and zg_zipcode,
as shown below:
$res = mysql_query(SELECT ZG_LATITUDE, ZG_LONGITUDE FROM zip_code
wherezg_zipcode = '$zip');
should be:
$res = mysql_query(SELECT
ReClMaples wrote:
$zipcode = mysql_query(
SELECT * FROM zip_code where ZG_LATITUDE = $Lat1
and ZG_LATITUDE = $Lat2 and ZG_LONGITUDE = $Lon1 and ZG_LONGITUDE =
$Lon2);
Try putting single quotes around the variables in your query string;
mysql sees them as strings, not variables:
... ZG_LATITUDE =