title: Multiple data query and only showing it once
body: <p>Hi i have a php script which takes the data from the database my problem is that the data from column 1 - 50 is the same i want to make it display the data that has the same name only once</p>
  
  <p>The database is like this</p>
  
  <pre><code>     --------------------------------------------
       Country | State | Name | Address|
       --------------------------------------------
       Japan   | Ohio  | Bill
       Japan   | Ohio  | Anne
       Japan   | Ohio  | Shyru
       Japan   | Nagoia| Ayusawa
       Japan   | Nagoia| Neji
       Japan   | Nagoia| Kaito
       Japan   | Osaka | Suwabara
       Japan   | Osaka | Kai
       Japan   | Osaka | Jane
  </code></pre>
  
  <p>And I want to get the data Ohio , Nagoia and Osaka or any state that that would be added here but would only print the ohio only once</p>
  
  <p>this is my code below:</p>
  
  <pre><code>     &lt;?php
       $con=mysqli_connect("127.0.0.1","root","","test");
       if (mysqli_connect_errno())
         {echo "Failed to connect to MySQL: " . mysqli_connect_error();}
       $result = mysqli_query($con,"SELECT * FROM ftable ORDER BY Country");
       while($row = mysqli_fetch_array($result))
         {
           echo $row['State'];
         }
       mysqli_close($con);
       ?&gt;
  </code></pre>
  
  <p>and this code shows this</p>
  
  <pre><code>    Ohio Ohio Ohio Nagoia Nagoia Nagoia Osaka Osaka Osaka
  </code></pre>
  
  <p>and i only what it to show the state only once how can i do that? and thanks for ready this! any help would be really help</p>