How do i define an index for a database column in my class definition? I want to speed up some of my queries and need to index a database table column. I would like to use my class definition file to create the index but I didn’t find any documentation on it.
(2 attempts)
Fabian answered:
George is working on it already and it'll work as advertised in the next Version of Nitro/Og (which will be 0.31.0).
Fabian answered:
If you want UNIQUE indexes you can set :unique for a property like this:
property :name, String, :unique => true
Special other indexes still have to be set by hand in the database it seems. There's an :sql_index advertised in Og, but it doesn't seem to work yet.