================================================================================
XMLPort LinkTable case-insensitive property
================================================================================

xmlport 1405 "Import Export Workflow"
{
    schema
    {
        tableelement(Workflow; Workflow)
        {
            tableelement("Workflow Step"; "Workflow Step")
            {
                LinkFields = "Workflow Code" = field(Code);
                LinkTable = Workflow;
                MaxOccurs = Unbounded;
                
                fieldattribute(ID; "Workflow Step".ID)
                {
                }
                
                tableelement("Workflow Rule"; "Workflow Rule")
                {
                    LinkFields = "Workflow Code" = field("Workflow Code"), "Workflow Step ID" = field(ID);
                    LinkTable = "Workflow Step";
                    MinOccurs = Zero;
                    
                    fieldattribute(RuleID; "Workflow Rule".ID)
                    {
                    }
                    fieldattribute(RuleTableNumber; "Workflow Rule"."Table ID")
                    {
                    }
                }
            }
        }
    }
}

--------------------------------------------------------------------------------

(source_file
  (xmlport_declaration
    (xmlport_keyword)
    object_id: (integer)
    object_name: (quoted_identifier)
    (schema_section
      (schema_keyword)
      (xmlport_element
        name: (identifier)
        source: (identifier)
        (xmlport_element
          name: (quoted_identifier)
          source: (quoted_identifier)
          (property
            name: (property_name)
            value: (property_expression
              (comparison_expression
                left: (quoted_identifier)
                operator: (comparison_operator)
                right: (call_expression
                  function: (identifier)
                  arguments: (argument_list
                    (identifier))))))
          (property
            name: (property_name)
            value: (identifier))
          (property
            name: (property_name)
            value: (identifier))
          (xmlport_attribute
            name: (identifier)
            source: (member_expression
              object: (quoted_identifier)
              member: (identifier)))
          (xmlport_element
            name: (quoted_identifier)
            source: (quoted_identifier)
            (property
              name: (property_name)
              value: (link_value_list
                (link_value
                  field: (quoted_identifier)
                  value: (quoted_identifier))
                (link_value
                  field: (quoted_identifier)
                  value: (identifier))))
            (property
              name: (property_name)
              value: (quoted_identifier))
            (property
              name: (property_name)
              value: (identifier))
            (xmlport_attribute
              name: (identifier)
              source: (member_expression
                object: (quoted_identifier)
                member: (identifier)))
            (xmlport_attribute
              name: (identifier)
              source: (member_expression
                object: (quoted_identifier)
                member: (quoted_identifier)))))))))

================================================================================
XMLPort LinkTable with various case variations
================================================================================

xmlport 50000 "Test LinkTable Cases"
{
    schema
    {
        tableelement(Customer; Customer)
        {
            tableelement("Sales Header"; "Sales Header")  
            {
                linktable = Customer;
                LinkTable = Customer;
                LINKTABLE = Customer;
                linkTable = Customer;
            }
        }
    }
}

--------------------------------------------------------------------------------

(source_file
  (xmlport_declaration
    (xmlport_keyword)
    object_id: (integer)
    object_name: (quoted_identifier)
    (schema_section
      (schema_keyword)
      (xmlport_element
        name: (identifier)
        source: (identifier)
        (xmlport_element
          name: (quoted_identifier)
          source: (quoted_identifier)
          (property
            name: (property_name)
            value: (identifier))
          (property
            name: (property_name)
            value: (identifier))
          (property
            name: (property_name)
            value: (identifier))
          (property
            name: (property_name)
            value: (identifier)))))))
