alter table file_revisions drop primary key, add primary key (vid, fid);

see:

http://lists.drupal.org/pipermail/development/2007-January/021581.html

Comments

gerhard killesreiter’s picture

Status: Active » Needs review
StatusFileSize
new840 bytes

here is a patch. pgsql part is missing, no idea if it would be neccessary.

RobRoy’s picture

Status: Needs review » Needs work

And all these new/modified keys should be included in system_install() as well and (maybe) for pgsql.

Crell’s picture

Using ab with a hitcount of 100 on a fresh HEAD, 10 nodes on the front page, 3 with attachments, and MySQL query cache off. I didn't see any appreciable difference with this patch. Both before and after, multiple ab runs hovered between 304 and 310 mean ms per request.

Also, you're missing an underscore in the table name. :-)

Crell’s picture

Status: Needs work » Closed (won't fix)

No progress and didn't accomplish anything anyway.