Jump to content

Variable values from database


wrathican

Recommended Posts

hi guys.

im checking my database tables for an entry. i have three tables and run a search against all 3for the same thing, so for this i have three queries. two of the tables are completely empty and one has an entry. so one of my three queries has been successful and contains a value. the other two queries should fail/be empty. but when i echo the variable the values would be stored in they have a value of "1". any idea why this is?

this is my query:

$qpilkos = "SELECT pil_access FROM kos_pilot WHERE pil_id='".$pil_id."'";
$rpilkos = mysql_query($qpilkos);
$pikosarr = mysql_fetch_assoc($rpilkos);
$paccess = $pikosarr['pil_access'];

Link to comment
https://forums.phpfreaks.com/topic/87624-variable-values-from-database/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.