184
185
186
187
188
189
190
191
192
193
|
# File 'lib/worlddb.rb', line 184
def tables
puts "Stats:"
puts " #{'%5d' % Country.count} countries (#{Country.where(s: true).count} supras, #{Country.where(d:true).count} deps)"
puts " #{'%5d' % Region.count} regions"
puts " #{'%5d' % City.where(m: true).where(c: false).count} metros"
puts " #{'%5d' % City.where(c: true).count} cities (#{City.where(c: true).where(m: true).count} metros)"
puts " #{'%5d' % City.where(d: true).count} districts"
puts " #{'%5d' % Tag.count} tags"
puts " #{'%5d' % Tagging.count} taggings"
end
|