diff --git a/lib/migration_runner.rb b/lib/migration_runner.rb
index <HASH>..<HASH> 100644
--- a/lib/migration_runner.rb
+++ b/lib/migration_runner.rb
@@ -54,7 +54,7 @@ module DataMapper
         if level.nil?
           migration.perform_up()
         else
-          migration.perform_up() if migration.position <= level
+          migration.perform_up() if migration.position <= level.to_i
         end
       end
     end
@@ -68,7 +68,7 @@ module DataMapper
         if level.nil?
           migration.perform_down()
         else
-          migration.perform_down() if migration.position > level
+          migration.perform_down() if migration.position > level.to_i
         end
       end
     end
Make sure our level is an integer.