Clarity

  • 1.  Similar data, why is different lookup required?

    Posted Feb 24, 2017 05:11 AM

    Just wondering again...

    I have this section in my NSQL

    @select:DIM_PROP:USER_DEF:IMPLIED:ISSUE:(CASE

    WHEN odf.top= 1 Then 'Yes'

     

    ELSE ''

    END):Top_Issue@,

    Works fine and I can associate the attribute  with a lookup

     

    When I have this NSQL section in another portlet

       @select:DIM_PROP:USER_DEF:IMPLIED:risk:(CASE

    WHEN odf.top = 1 Then 'Yes'

    ELSE ''

    END):Top_Risk@,

     

    I cannot see that lookup to associate it with the attribute. However, I can associate it with a similar lookup

     

    To that sounds that in one case the odf.top is considered numeric (the enum) in the other case text.

     

    Where might it be defined so that I cannot use the same lookup in both cases?



  • 2.  Re: Similar data, why is different lookup required?

    Posted Feb 24, 2017 05:47 PM

    Change the IMPLIED to explicitly state the data type and then at least it'll be consistent?



  • 3.  Re: Similar data, why is different lookup required?

    Posted Feb 24, 2017 05:55 PM

    Thanks Dave_3.0 something like that occurred to me as well.

    So you think the for one reason or other the data type of that field is implied differently in those two queries.

    Wondering  - before having tried - if a data type is implied can it be forced to another?

    At least 1 could be both integer and string.



  • 4.  Re: Similar data, why is different lookup required?

    Posted Feb 24, 2017 06:01 PM

    To be honest, I have no idea why your "same code" would cause a different 'implied' datatype - (if I had not seen your evidence that the expected lookup datatype is different I would have doubted it).

     

    "At least 1 could be both integer and string" - you might think that (as I would), but "1" is not the same as 1 when it comes to choosing datatypes!