Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Problem with recordset

New Here ,
Sep 23, 2009 Sep 23, 2009

Im learning about cs4 handling and recordset, I created a recordset that shows the correct records when I test the SQL statement, but my dreamweaver generated page does not display the results, just blank page. The whole dreamweaver generated code for the page index.php is:

<?php require_once('Connections/test_conn.php'); ?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
  if (PHP_VERSION < 6) {
    $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
  }

  $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

  switch ($theType) {
    case "text":
      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
      break;   
    case "long":
    case "int":
      $theValue = ($theValue != "") ? intval($theValue) : "NULL";
      break;
    case "double":
      $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
      break;
    case "date":
      $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
      break;
    case "defined":
      $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
      break;
  }
  return $theValue;
}
}

mysql_select_db($database_test_conn, $test_conn);
$query_Recordset1 = "SELECT config_gps.Ficha_gps,   track_gps.Hora,   DATE_FORMAT(track_gps.Fecha,'%d-%m-%Y') as Fecha,   track_gps.`Status`,   track_gps.Velocidad,   track_gps.Calleune,   track_gps.Calletowo,   track_gps.Temp,   track_gps.Evento,   track_gps.Longitud,   track_gps.Latitud,   track_gps.Ficha_gps,   track_gps.Direccion,   track_gps.Provincia,                                     data_car.Ficha FROM asig_vehiculos   INNER JOIN data_car ON (asig_vehiculos.Id_data_car = data_car.Id)   INNER JOIN config_gps ON (data_car.Config_gps = config_gps.Id)   INNER JOIN track_gps ON (config_gps.Ficha_gps = track_gps.Ficha_gps)   INNER JOIN `client_data` ON (asig_vehiculos.Id_group = `client_data`.`group`) WHERE client_data.group = data_car.id order by data_car.Ficha asc; ";
$Recordset1 = mysql_query($query_Recordset1, $test_conn) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>TestPage</title>
</head>

<body>

Just want to show the results here:

<?php echo $row_Recordset1['']; ?>

but nothing happens! just blank page, with no errors


</body>
</html>
<?php
mysql_free_result($Recordset1);
?>

What may be wrong here?  Thanks!

TOPICS
Server side applications
509
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Sep 23, 2009 Sep 23, 2009
LATEST

Thread moved to the Dreamweaver Application Development forum.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines