Title: Incorrect Column Count
Last modified: August 17, 2023

---

# Incorrect Column Count

 *  Resolved [llregimbald](https://wordpress.org/support/users/llregimbald/)
 * (@llregimbald)
 * [2 years, 9 months ago](https://wordpress.org/support/topic/incorrect-column-count-2/)
 * I am also getting this message “DataTables warning: table id=tablepress-148 –
   Incorrect column count. For more information about this error, please see [http://datatables.net/tn/18&#8221](http://datatables.net/tn/18&#8221);
   on my page [Legal Rulings Table of Contents – SR&ED Education and Resources (sreducation.ca)](https://www.sreducation.ca/overview/policies-legal-rulings/legal-rulings-table-contents/)
   
   I also noticed that the page is only showing 12 of the 15 columns for the table.
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fincorrect-column-count-2%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [2 years, 9 months ago](https://wordpress.org/support/topic/incorrect-column-count-2/#post-16980573)
 * Hi,
 * thanks for your post, and sorry for the trouble.
 * The most common cause for this is invalid HTML code for e.g. links in the table,
   for example caused by missing quotation marks. Other possibilities are plugins
   like the ezoic automatic ads inserter, which adds combined/merged cells to the
   table, which are not compatible with the frontend feature for site visitors.
 * Now, unfortunately, your link only asks for a login, so that the table can be
   viewed. Can you maybe temporarily turn that? I’ll then be able to find out what
   exactly is causing the problem.
 * Regards,
   Tobias
 *  [ballcardgenius](https://wordpress.org/support/users/ballcardgenius/)
 * (@ballcardgenius)
 * [2 years, 9 months ago](https://wordpress.org/support/topic/incorrect-column-count-2/#post-17037189)
 * Hi [@tobiasbg](https://wordpress.org/support/users/tobiasbg/), was there any 
   resolution here? I have the same issues with my tables. I have HTML links and
   Ezoic, so not sure where to turn first. Thanks!
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [2 years, 9 months ago](https://wordpress.org/support/topic/incorrect-column-count-2/#post-17037659)
 * Hi,
 * I didn’t get a reply from llregimbald, so I’m not sure what helped for that site.
 * In your case, my guess would be ezoic. It has an ad auto integration, which insert
   merged/combined cells (using `colspan`) into tables, and this breaks the JavaScript
   features and leads to that message.
 * If you post a link to the page with your table, I can check if that’s the case
   here.
 * Regards,
   Tobias
 *  [gfuller](https://wordpress.org/support/users/gfuller/)
 * (@gfuller)
 * [2 years, 6 months ago](https://wordpress.org/support/topic/incorrect-column-count-2/#post-17244445)
 * I had this problem as well. So I thought I would pass on my solution. It seems
   like the latest update to something caused the guidelines for DataTables to change.
   Before the update, my table didn’t have column headers, which worked fine. To
   resolve the error, I added a Thead element to the tables HTML, and added two 
   tw elements. Essentially, the table ID was looking for two columns, which is 
   the correct number of columns. All I needed to fix the error was to specify a
   table header, before the table body, and a single table row with two table column
   names. The website that the error provides actually helped significantly.
 *     ```wp-block-code
       <table id="AutoNumber2">
       <thead>
       <tr>
       <th>Region</th>
       <th>Distributor</th>
       </tr>
       </thead>
       <tbody>
       ```
   
    -  This reply was modified 2 years, 6 months ago by [gfuller](https://wordpress.org/support/users/gfuller/).
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [2 years, 6 months ago](https://wordpress.org/support/topic/incorrect-column-count-2/#post-17244734)
 * Hi gfuller,
 * thanks for your input here! DataTables has always required a `<thead>` element,
   so adding it in your custom HTML code for the table is correct 🙂
 * Said that, the other posts in this thread refer to the TablePress plugin, which
   actually will allow you to create tables without having to write HTML code for
   a table yourself 🙂
 * Best wishes,
   Tobias

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Incorrect Column Count’ is closed to new replies.

 * ![](https://ps.w.org/tablepress/assets/icon.svg?rev=3192944)
 * [TablePress - Tables in WordPress made easy](https://wordpress.org/plugins/tablepress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/tablepress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/tablepress/)
 * [Active Topics](https://wordpress.org/support/plugin/tablepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/tablepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/tablepress/reviews/)

 * 5 replies
 * 4 participants
 * Last reply from: [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * Last activity: [2 years, 6 months ago](https://wordpress.org/support/topic/incorrect-column-count-2/#post-17244734)
 * Status: resolved