how to retrive the particular data from database in php with mysql?

how to retrive the particular data from database in php with mysql?

when am using mysqlfetcharray() that display the following error. the code look like this..

<?php


$con = mysql_connect("localhost","root","");
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }

mysql_select_db("samp", $con);
$Name=$_POST['unames'];
$data=mysql_query("SELECT * FROM tbl_sample where Name='$Name'");

/*$info=mysql_fetch_array($data);*/
while($info=mysql_fetch_array($data))
{
echo"<b>NAME</b>:".$info['Name']."<br><b>KEYSKILLS</b>:".$info['Keyskills']."<br><b>EXPERIENCE</b>:".$info['Experience']."<br><b>CURRENT ADDRESS</b>".$info['CurrentAddress']."<br><b>PERMANANT ADDRESS</b>".$info['PermanantAddress']."<br><b>COMPANY ADDRESS</b>".$info['CompanyAddress']."<br><b>MOBILE NO</b>".$info['MobileNo']."<br><b>QUALIFICATION</b>".$info['Qualification']."<br><b>CURRENT LOCATION</b>".$info['CurrentLocation']."<br><b>STATE</b>".$info['State']."<br><b>NATIONALITY</b>".$info['Nationality']."<br><b>DATE OF BIRTH</b>".$info['DOB'];
}
mysql_close($con);
?>

this shows the error like this....

Warning: mysqlfetcharray(): supplied argument is not a valid MySQL result resource in C:\wamp\www\sample\related.php on line 15

plz give suggestion..

Thanks in advance

View Answers

September 9, 2011 at 5:22 PM









Related Tutorials/Questions & Answers:
how to retrive the particular data from database in php with mysql?
How to retrive a particular record from database in php with mysql?
Advertisements
retrive data from database?
retrive data from database
To retrive data from database - Struts
how to retreive data from database of a particular user after login
GWT -- retrive the data from Database
how to retreive data from database of a particular user after login
how to retrive data grom database in jsp pages.
retrive data from database using jsp in struts?
By dropdownlist retrive data from database and show in textbox in jsp.
retrive the data from access database to drop down list box in jsp
how to insert data into database using jsp & retrive
url parameter using retrive data from database in jsp
Retrive data from database and perform binary tree operations on that data in jsp or java
url parameter using retrive data from database in jsp
Selecting particular data from multiple tables at database and perfoming calculations
PHP MySQLi
how retrive data from google analystics dashbord on the client machine
store and retrive image from the database
How to retrive an inmage from database and displaying it in imgae box - Swing AWT
how to retrieve data from database ?????/
how to retrieve data from database ?????/
how to retrieve data from database ?????/
how to retrieve data from database ?????/
how to write to java program to get the particular data from the website
how to retrieve data from database
store & retrive the image from oracle database
PHP MySQLi Affected Rows
How to Retrieve Data from Facebook Using PHP
How to Retrieve Data from Facebook Using PHP
retrive data from oracle to jsp
how to display data from database in jsp
retrive image from database using jsp without stream
how to use bean to retrieve data from database
how to create a php script to download file from database mysql
how to create a php script to download file from database mysql
store and retrive image from database - JDBC
retrive article from sql databse and show using php
how to store and retrieve images int and from the database using php
retrive record from the text field and insert into to database
insert and retrive image from sql server database in jsp
PHP MySQLi Query
Retrive the data from the table in data base using jdbc
How to show data from database in textbox in jsp
how to get data from database into dropdownlist in jsp
how to get data from database into dropdownlist in jsp
how to get data from database into dropdownlist in jsp
How to display data from database in a TableView
Request URl using Retrive data from dtabase

Ads