This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JDBC and the fly likes does Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "does "order by" change the data in the table?" Watch "does "order by" change the data in the table?" New topic
Author

does "order by" change the data in the table?

sahar sa
Ranch Hand

Joined: Jul 06, 2009
Posts: 102
Dear,
I have a table and I want to retrive some data from this table. I want them to be sorted so I have this snippet code:

now I want to know after that I retrived this information from table.
the data in the table is also sorted?
Thankyou, beforehand,
Sahar.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41033
    
  43
SELECT statements do not alter data in the database. What's more, relational databases have no notion of records in a table being sorted. It's only when some (or all) of them get SELECTed that an ordering is applied to the result.


Ping & DNS - my free Android networking tools app
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: does "order by" change the data in the table?
 
Similar Threads
sorting problems in struts jsp
Problems with java and mysql error: 1064
Retrieving ArrayList from Display Table after sorting
Retrieving ArrayList from Display Table after sorting
Sorting Data