row_id

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
ericsodt
Forum Commoner
Posts: 51
Joined: Fri Aug 22, 2003 12:12 pm
Location: VA

row_id

Post by ericsodt »

I know in Oracle you can update date by selecting the rowID along with what your selecting, does anyone know if you can do that with MySQL and better yet, how about Access... Microsoft has <span style='color:blue' title='I&#39;m naughty, are you naughty?'>smurf</span> as far as documentation goes for Access...

Thanks guys
User avatar
Pyrite
Forum Regular
Posts: 769
Joined: Tue Sep 23, 2003 11:07 pm
Location: The Republic of Texas
Contact:

Post by Pyrite »

Why not see if something like ADOdb could help you? I assume you're using php right?

Google "adodb"
hedge
Forum Contributor
Posts: 234
Joined: Fri Aug 30, 2002 10:19 am
Location: Calgary, AB, Canada

Re: row_id

Post by hedge »

ericsodt wrote:I know in Oracle you can update date by selecting the rowID along with what your selecting, does anyone know if you can do that with MySQL and better yet, how about Access... Microsoft has s**t as far as documentation goes for Access...

Thanks guys
Access doesn't, don't know about MySQL
microthick
Forum Regular
Posts: 543
Joined: Wed Sep 24, 2003 2:15 pm
Location: Vancouver, BC

Post by microthick »

The LIMIT clause is sorta similar to rowid I think.
User avatar
JAM
DevNet Resident
Posts: 2101
Joined: Fri Aug 08, 2003 6:53 pm
Location: Sweden
Contact:

Post by JAM »

microthick wrote:The LIMIT clause is sorta similar to rowid I think.
No, LIMIT is purely for selecting the amount of rows you want to retrieve,, and if used in a UPDATE query, you will update LIMIT rows LIMIT as in amount of rows updated.

Code: Select all

update table set foo='bar' LIMIT 14
... will update 14 rows of the 9288 (just an example) ones stored.

ericsodt, can you give us an example? As of today, there are no such update in select function in mysql however.
microthick
Forum Regular
Posts: 543
Joined: Wed Sep 24, 2003 2:15 pm
Location: Vancouver, BC

Post by microthick »

With LIMIT you can go:

LIMIT 10, 30

and this will select rows 10 through 40.

This feature is similar to the rowid function he's describing.
Post Reply