number of columns in a table field

Kay C Lan lan.kc.macmail at gmail.com
Tue May 30 22:28:03 EDT 2006


On 5/31/06, Russ McBride <russmcb at tsw.berkeley.edu> wrote:
>
> I know, I should probably give up on table fields, but call they're
> useful for building interfaces to databases that I can't give up on
> them yet.

Hmmm, I use Rev to build db front ends all the time and the thing I
love about it is you 'don't' end up with a table, although you can if
you want. There are some great advantages to moving away from simple
table views (although I appreciate that there are times and certain
data that is better suited to simple table views):

1) Can display 100+ columns of data on a single card - no scrolling
2) Certain data lends itself to other controls other than 'fields':
    a) Checkbox - anything that is Yes/No,True/False,On/Off,Day/Night etc
    b) Option Menu - anything that is going into a 'Set' or 'Enum'
column ie student names, product names, countries, etc
    c) Radio buttons - similar to above but the set is much smaller.
3) Data checking made easy - You virtually eliminate the need to do
data checking prior to inserting into you db. With a Checkbox you are
guaranteed that the data is on or off, with a table you have to check
that the user has correctly entered Y/N,T/F,1/0. With Option Menus you
illimenate the posibillity of mispelllimgs causeing problens with set
colunms.
4) Code simplification - related to the above topic, with individual
fields to contain text, numbers, dates, times, and dates & time, you
can place individual scripts in that control to ensure that the data
is correctly formatted prior to entry and the check is carried out
immediately after data entry. With tables, especially if you are
dealing with a LOT of columns, writing a script to parse the data to
then check each individual column is a little more complex, and
certainly much harder to troubleshoot 6 months down the track.
Carrying out data checking on leaving each column is also more
difficult to implement.

Whilst Table representation certainly has its advantages and place, I
think if you look a little deeper into a 'customised' display you'll
be quickly impressed with the power and flexibility it provides.

Food for thought:-)



More information about the use-livecode mailing list