Display last record first.


Posted on 16th Feb 2014 07:03 pm by admin

I need some help how put the last record first and first record last.

Thanks

Did you know?Explore Trending and Topic pages for more stories like this.
Code: <?php
include("connect.php");

$query="SELECT * FROM MyNotes ";
$result=mysql_query($query);
$num = mysql_num_rows ($result);
mysql_close();

if ($num > 0 ) {
$i=0;
while ($i < $num) {
$username = mysql_result($result,$i,"username");
$notes = mysql_result($result,$i,"notes");
$id = mysql_result($result,$i,"id");

echo "<b>notes:</b> $notes
";
echo "<hr><BR>";

++$i; } } else { echo "The database is empty"; }?>
No comments posted yet

Your Answer:

Login to answer
210 Like 29 Dislike
Previous forums Next forums
Other forums

Checking BOM Authorization Group
Hai Friends,

I have developed a mulitilevel BOM display report. End users have been assig

Passing JS to PHP
So I have the following
Code: <?php
getdetails(?><script type="text/

Displaying values from a SQL count...
Hi,
Easy enough question i just forget the exact method ..
I have ...

Code: //count win

selection tool on raster image
Hi!
I have to implement in my app a selection tool which lets users to select region of any shape

rand() function
just a general question guys a girls, is the rand() function 100% random or is it based on time?

Need help/w Page: 1,2,3,4 function!
So I have this code im working on where it's ment to display seperate pages having 20 logs each
I

Problem with array max size.
Hi to everyone,
I've got a homework about filling a bidimensional array un spiral shape, I alre

I got my hosting suspended XD
So I saw this challenge a day or so ago

http://www.programming-challenges.com/pg.php?page=dow

Session login issue
I'm wondering how to fix a problem I'm having with a session-based login system

Say I go to h

Progress bar tracking file downloads
Hey guys, was wondering if there was a way to track how far a file has been downloaded. I know there

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash