View Single Post
Old 10-15-2011, 09:30 AM   #9
chaley
Grand Sorcerer
chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.chaley ought to be getting tired of karma fortunes by now.
 
Posts: 12,469
Karma: 8025600
Join Date: Jan 2010
Location: Notts, England
Device: Kobo Libra 2
Regarding making columns: every column you add will add some work, somewhere. However, the work added for non-composite columns is minimal.

Regarding GPM: you got it right. GPM starts with the word program. Do note that the word "program" *must* start in column one. Your example has a space before program. That shouldn't do anything good, but it might be attempting to evaluate it somehow.

One advantage is you can have more than one line, which can make things easier to read. Using your example, you could have:
Code:
program:
list_sort(
   list_difference(
      list_union(field('#shelf'), field('tags'), ','),
      list_union(
         list_union(field('#genre'), field('#length'), ','), 
         field('#character'), 
         ','), 
      ','),
   0, ',')
This lines up the arguments for a function.

As for it running 2 times slower, that makes no sense at all to me. If and when you have some time, could you verify it? First make sure that your templates are working (e.g. no space before program, correct results). Then switch the one that you changed back to template program mode as you had before, and see if it gets faster. If it does, then something very mysterious is going on.
chaley is offline   Reply With Quote