Announcement

Collapse
No announcement yet.

mysql error // Unknown column 'attachmentid' in 'field list'

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Steve Machol
    replied
    System error: 2 = No such file or directory

    To fix these immediate errors, run these queries to recreate these tables (assuming you have no table prefix):

    DROP TABLE IF EXISTS attachmentviews;
    CREATE TABLE attachmentviews (
    attachmentid INT UNSIGNED NOT NULL DEFAULT '0',
    KEY postid (attachmentid)
    );


    DROP TABLE IF EXISTS threadviews;
    CREATE TABLE threadviews (
    threadid INT UNSIGNED NOT NULL DEFAULT '0',
    KEY threadid (threadid)
    );

    Leave a comment:


  • Floris
    replied
    Originally posted by cihangir
    hi floris,

    i got the errno: 2 yesterday, until i recreated the tables for attachmentviews and threadviews.

    the error, that i get now, is "mysql error number: 1054":

    Invalid SQL: SELECT attachmentid, COUNT(*) AS views FROM attachmentviews GROUP BY attachmentid
    mysql error: Unknown column 'attachmentid' in 'field list'
    As you manually added the tables back, I think you added it wrong or are missing something. I suggest to restore it from a backup.

    Leave a comment:


  • cihangir
    replied
    hi floris,

    i got the errno: 2 yesterday, until i recreated the tables for attachmentviews and threadviews.

    the error, that i get now, is "mysql error number: 1054":

    Invalid SQL: SELECT attachmentid, COUNT(*) AS views FROM attachmentviews GROUP BY attachmentid
    mysql error: Unknown column 'attachmentid' in 'field list'

    Leave a comment:


  • Floris
    replied
    If I am not mistaken, Errno: 2 means that it can't write the database to a directory. This is a host issue, request your host for a backup.

    Leave a comment:


  • mysql error // Unknown column 'attachmentid' in 'field list'

    our mysql crashed yesterday. after restarting it, we got 2 db errors:
    Can't find file: 'attachmentviews.MYD' (errno: 2)
    Can't find file: 'threadviews.MYD' (errno: 2)

    running "repair/optimizetables" in acp did not worked, so i dropped and recreated the attachmentviews und threadviews tables.


    now i got a new mysql error:

    Database error in vBulletin 3.0.3:

    Invalid SQL: SELECT attachmentid, COUNT(*) AS views FROM attachmentviews GROUP BY attachmentid
    mysql error: Unknown column 'attachmentid' in 'field list'

    mysql error number: 1054

    Date: Friday 24th of December 2004 08:47:45 AM
    Script: http://forum.x.net/admincp/cronadmin...cron&cronid=10
    Referer: http://forum.x.net/admincp/cronadmin...cron&cronid=10
    Username: zoque
    IP Address: 82.82.x.x
    i'd be very thankful for any kind of help.
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Working...
X