13 Replies Latest reply on Dec 13, 2012 3:57 PM by rviegas

    LookupField with Lookup Query


      I have a LookupField in a child form that is populated depending on the value of the previous LookupField.

      These are the properties of the second field (my problem):

      Lookup Query-> select lkv_encoded, lkv_decoded from lkv, lku where lkv.lku_key=lku.lku_key and lku_type_string_key='LOOKUP_NAME' and lkv.lkv_encoded like '$Form data.TABLE_FIELD_FROM_THIS_FORM$%'
      Column Widths-> 100,100
      Column Captions-> Code,Decode
      Column Names-> lkv_encoded,lkv_decoded
      Lookup Column Name-> lkv_encoded

      When I open the LookupField, the search is displayed properly.

      But when I click add to add the ChildForm, the lkv_decode is added to the database and I need the lkv_encode.

      How do I get the encode?
      What am I doing wrong?