Django south migration attribute order
Bug #963089 reported by
Ben Wyss
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenQuake (deprecated) |
Won't Fix
|
Undecided
|
Unassigned |
Bug Description
When using Django South to automatically generation a 0001_initial.py file (the file used for migrations), the db table attributers order is changed into a random order.
please see the notes here: https:/
Changed in openquake: | |
status: | New → In Progress |
Changed in openquake: | |
status: | In Progress → New |
To post a comment you must log in.
Based on the insight into some of the upcoming developments of the FE tool, I recommend that we do not impose column order in the backend, but rather in the Middleware; namely GeoServer. In this way, if we have a purely UI requirement to change the column order (even slightly) for a table, we do not need to make any changes to the DB. docs.geoserver. org/latest/ en/user/ data/sqlview. html
To control a tables column name order in Geoserver one needs to create a sql view, see: http://
For example to make a sql view in GeoServer for the fault view table one could use:
SELECT fault_name, length_min, length_max, length_pre, strike, episodi_is, episodi_ac, u_sm_d_min, u_sm_d_max, u_sm_d_pre, u_sm_d_com, low_d_min, low_d_max, low_d_pref, low_d_com, dip_min, dip_max, dip_pref, dip_com, dip_dir, down_thro, slip_typ, slip_r_min, slip_r_max, slip_r_pre, slip_com, aseis_slip, aseis_com, dis_min, dis_max, dis_pref, re_int_min, re_int_max, re_int_pre, mov_min, mov_max, mov_pref, all_com, compiler, contrib, created, geom
FROM gem.fault_view