Question: This sounds very simple, but I am frustrated for the past few hours to get this done.
I am not able to see "Macros" sub menu under "Tools" menu in Visual Studio 2008. 

I go to Tools->Customize->Commands. 
Select Tools under Categories and click Rearrange Commands. Instead of showing me the Tools Menu it shows me Files. 

Am I doing something wrong? Or is it a bug in VS 2008?

Answer: 
It's possible to get the given error if your class names don't match inflections (like acronyms) from `config/initializers/inflections.rb`.

For example, if your inflections include:

```
ActiveSupport::Inflector.inflections(:en) do |inflect|
  inflect.acronym 'DOG'
end

```

then you might need to make sure the class in your migration is:

`class CreateDOGHouses < ActiveRecord::Migration[5.0]`

rather than:

`class CreateDogHouses < ActiveRecord::Migration[5.0]`

Not super common, but if you generate a migration or a model or something, and then add part of it to inflections afterwards it may happen. (The example here will cause `NameError: uninitialized constant CreateDOGHouses` if your class name is `CreateDogHouses`, at least with Rails 5.)
If you're getting this error and it's NOT because of the migration file name, there is another possible solution. Open the class directly in the migration like this:

```
class SomeClass < ActiveRecord::Base; end

```

It should now be possible to use `SomeClass` within the migration.