No announcement yet.

Regarding Between, In and Like functions..

  • Filter
  • Time
  • Show
Clear All
new posts

  • Borje Hagsten
    See now Stephane grabbed samples generously given by Michael Mattias
    in newsgroup. While the above still applies, not a very nice thing to
    do, grab something and then call it "my code".

    Michael was very kind to help you out there, Stephane, so I suggest you
    apologize to him for this. Things like this makes people unwilling to help..


    Leave a comment:

  • Borje Hagsten
    started a topic Regarding Between, In and Like functions..

    Regarding Between, In and Like functions..

    None of the suggested functions in source code is very useful. By
    placing them in separate functions, you only add a bunch of instructions
    that takes un-necessary time, without making things much easier.

    Instead of using "IF PBBetween(X, LVal, HVal)", it's much faster and
    easier to use "IF (X > LVal) AND (X < HVal) THEN" directly in code.
    Same with the others. Simply use the core functions directly in code.

    Tip for optimization: When checking for range of values, put the most
    probable case first. It's a flow, where code bounces out on first
    "hit". In sample above, if X in most cases will be higher, put
    (X < HVal) check first so it won't have to check lower range first.
    Can save lots of time in huge loops..