KX Community

Find answers, ask questions, and connect with our KX Community around the world.
KX Community Guidelines

Home Forums KX Academy Issue with xkey Re: Issue with xkey

  • gyorokpeter-kx

    Member
    May 2, 2023 at 12:00 am

    The phenomenon you are seeing is because there are two columns named c in complexTab!example. In general duplicated column names in a table are a bad idea, and some functions even check for this and throw an error. But xkey just uses the # operator, which takes the first occurrence of the column to determine its value, so the first c column gets duplicated. ! is a built-in operator so it can use a different implementation to rearrange some pointers in memory that doesn’t rely on the column names.