GEOFences :: AREA column datatype

vrish8 months ago

Hi,
I have about 30 points that I want to set on a linear geofence. Due to the accuracy level of the lat/lon, the max length of the area column is going up to 50000 characters.

The datatype for area column in tc_geofences is varchar(4096).

My geofences are working correctly today without these additions.

I have 2 questions

  1. Has anyone tested with 30 points?
  2. Is it ok for me to increase the size of the area column to either varchar(max) or (most probably) text. Has anyone seen any adverse reactions after doing this?

ERROR when posting a GEOFence

Data truncation: Data too long for column 'area' at row 1 - MysqlDataTruncation (... < QueryBuilder: 469 < DatabaseStorage: 95 < BaseObjectResource: 72 < ...)

Anton Tananaev8 months ago

You can increase the size of the column. It won't break anything, but it might be slower if you have large geofences.

I don't understand how you get 50k characters for 30 points.

vrish8 months ago

Thanks for the confirmation.

I figured the size issue out. Turns out I was having duplicate points... doh!