Integrate with Rails.

47 views
Skip to first unread message

Edu Depetris

unread,
Jan 4, 2016, 3:25:21 AM1/4/16
to openmundi
Hello, 
I want to used `world.db` in my Rails 4.2 application. 
I need to be able to search country, state and city.

Anyone can help me to integrate this.

Thanks.

Gerald Bauer

unread,
Jan 4, 2016, 3:32:07 AM1/4/16
to Edu Depetris, openmundi
Hello,

> I want to used `world.db` in my Rails 4.2 application.
> I need to be able to search country, state and city.

See the world.db.admin Rails app (engine) as a "real-world" example.
Code on GitHub [1] and live demo on Heroku [2]. Cheers.

PS: The first step is to create a database migration, see
001_create_db.rb [3], for example e.g. use.

def up
LogDb.create # logs table
ConfDb.create # props table
TagDb.create # tags, taggings table
WorldDb.create
end

[1] github.com/worlddb/world.db.admin
[2] worlddb.herokuapp.com
[3] github.com/worlddb/world.db.admin/blob/master/db/migrate/001_create_db.rb

edu

unread,
Jan 6, 2016, 9:48:34 AM1/6/16
to Gerald Bauer, openmundi

Thanks, I'll check it out.

BTW awesome work!

Reply all
Reply to author
Forward
0 new messages