Uploaded image for project: 'HPCC'
  1. HPCC
  2. HPCC-18917

Support substrings for variable length fields

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 7.0.0
    • Component/s: Code Generator
    • Labels:
      None

      Description

      Currently x[1..n] = 'x' is converted to

      x between 'x'[1..n] + '\00\00\00\00\00\00' and 'x'[1..n] + '\FF\FF\FF\FF\FF\FF'

      However there are two [problems:

      • Variable size fields have no upper bound (they also don't really have an lower bound!)
      • The padding characters are not valid unicode.  That especially applies to \FF

      One solution would be to change the filter to  x IN ['x', 'y').  That avoids the problem of \FF.  However I don't think there is a way of calculating 'y' (i.e. the next value) for a unicode string.  You would also have problems with tab characters in strings, and would need to generate ['x\00', 'y\00') to avoid the problem.

      Richard Chapman on reflection I suspect the only real solution is to implement a substring field filter.

       

        Attachments

          Activity

            People

            • Assignee:
              ghalliday Gavin Halliday
              Reporter:
              ghalliday Gavin Halliday
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: