Magento use an eav model to save values in the database.
You have to search an attribute called “include_in_menu” in the “eav_attribute” table.
You can use following query to update all categories:
update catalog_category_entity_int cci inner join eav_attribute a on a.attribute_id = cci.attribute_id set cci.value = 1 where a.attribute_code = 'include_in_menu';
Thanks