# Table columns are not being recognized (empty table)

**URL:** <https://www.ruby-forum.com/t/table-columns-are-not-being-recognized-empty-table/143200>\
**Category:** Rails\
**Created:** [July 16, 2008, 8:15am UTC](https://www.ruby-forum.com/t/table-columns-are-not-being-recognized-empty-table/143200 "2008-07-16T08:15:01Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![LLL](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/4491bb/32.png) [@LLL](https://www.ruby-forum.com/u/LLL)\
**Post date:** [July 16, 2008, 8:15am UTC](https://www.ruby-forum.com/t/table-columns-are-not-being-recognized-empty-table/143200/1 "2008-07-16T08:15:01Z")

</div>

Upon viewing one of my tables in the MySQL Query Browser, I found out  
that it was “empty”, and the columns are not being recognized. (And  
I’ve ran rake:db migrate).

Why aren’t the columns showing up?

I posted a question about an error related to this in the RailsSpace  
Group (  
[http://groups.google.com/group/railsspace/browse\_thread/thread/9b1894f7b3e2f664?hl=en](http://groups.google.com/group/railsspace/browse_thread/thread/9b1894f7b3e2f664?hl=en)  
)… and I’m pretty sure that the reason for the error is because the  
table is empty.

Has anyone else experienced this problem before? Will deleting, and  
regenerating the model (and migration), fix it? Or… what should I  
do?

The file looks like this:.  
class CreateSpecs \< ActiveRecord::Migration  
def self.up  
create\_table :specs do |t|  
t.column :user\_id, :integer, :null =\> false  
t.column :first\_name, :string, :default =\> “”  
t.column :last\_name, :string, :default =\> “”  
t.column :gender, :string  
t.column :birthdate, :date  
t.column :occupation, :string, :default =\> “”  
t.column :city, :string, :default =\> “”  
t.column :state, :string, :default =\> “”  
t.column :zip\_code, :string, :default =\> “”  
end  
end

def self.down  
drop\_table :specs  
end  
end
