The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Unknown column 'pollid' in 'where clause'
Today we updated our vbulletin 3.7.3 to 3.8.7. During the installation some errors ocurred. This errors made reference to tables and columns that were created already.
ALTER TABLE pollvote ADD INDEX pollid (pollid, userid); I've found this thread: https://www.vbulletin.com/forum/arch.../t-109385.html that fix the problem by erasing the pollid index. I think that by mistake I've also erased the pollid column. The update was succesful, but now the polls shows database error and this code: Invalid SQL: SELECT * FROM poll WHERE pollid = 521; MySQL Error : Unknown column 'pollid' in 'where clause' Error Number : 1054 I want to know if there's any query to insert the pollid column that was erased. I have a database backup, but it's twelve hours old and the forum was opened so all the information that we created in these hours would be lost. Thanks for your response. |
#2
|
|||
|
|||
You could do this:
Code:
ALTER TABLE poll ADD COLUMN pollid INT UNSIGNED NOT NULL AUTO_INCREMENT FIRST, ADD PRIMARY KEY(pollid) But, this will assign a pollid to each record, and I have no idea if they'll be the same as they originally were. And if they aren't, things are likely to be messed up. But I don't really see that it matters - at worst you can remove the column again and be back where you are now. |
#3
|
|||
|
|||
As you say we can now make new polls, but the older polls doesn't allow us to see the results. But this is better than before, thank you.
If anyone has another idea, we'll be glad to hear it. |
#4
|
|||
|
|||
Hmm...I suppose the other thing you could have done is to restore only the poll table from your backup. But if you do that now, you'll lose the new polls.
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|