The polled column in the poll table was rather non-normalized. This patch adds a proper table.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Dries’s picture

In other tables we use 'hostname' not 'host'. Maybe 'poll_votes' is better than 'poll_voted'? Looks like it would be more inline with the other naming conventions.

(Shouldn't we store the vote in the new table too? That would open up the possibility to change your vote or to see who voted what. Looks like the next logical step. Maybe in another patch.)

drumm’s picture

Column changes are done.

Which vote someone did is more of a feature. I'm happy with waiting until after HEAD is reopened for that if there is demand.

drumm’s picture

FileSize
7.69 KB
Dries’s picture

Status: Needs review » Fixed

Tested and committed to HEAD. Thanks.

Cvbge’s picture

Category: task » bug
Priority: Normal » Critical
Status: Fixed » Reviewed & tested by the community
FileSize
4.39 KB

Some fixes:
1. "int(10)" -> "int", fixed typo in index name [pgsql change only]
2. added defaults for uid and hostname (needed for both)
3. postgres supports "DROP column" syntax
4. added missing DELETEs for new table in poll_delete() and poll_update()

drumm’s picture

Looks good to me.
+1

Dries’s picture

Status: Reviewed & tested by the community » Fixed

Committed to HEAD. Thanks.

Anonymous’s picture

Status: Fixed » Closed (fixed)