Translation Truncation Consternation

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Translation Truncation Consternation

  • Creator
    Topic
  • #54623
    Jim Rawls
    Participant

      Cloverleaf 6.0.2

      RHEL 6.6

      We’re seeing a date/time field getting truncated on a copy from an input date field format (modified to 14 characters) to an output timestamp field (26 characters).  The logic is to copy PV2-8 (expected admit date) to PV1-44 (admit date/time) if PV1-44 is not populated.  The input data is a date/time (CCYYMMDDHHMMSS) and is getting chopped down to just date (CCYYMMDD).  This doesn’t seem like the correct translation response since the receiving field is larger than the sending field.  Our work-around has been to use PATHCOPY instead of COPY on the field, which is giving us the desired output.

      Is this a bug, I mean, feature?

      Thanks!

    Viewing 1 reply thread
    • Author
      Replies
      • #82258
        Jim Kosloskey
        Participant

          I suspect the reason has to do with COPYing from a DT Data Type to a TS Data Type.

          Normally the Expected Admit Date/Time is a TS Data Type (at least from 2.3.1 on) and the actuall data seems to support that. What HL/7 version is this and has the variant been modified as to Data Type for this field?

          The PATHCOPY works I think because the Data Type does not come into play.

          Try modifying the Dtata Type for this field in this variant to TS and see if the COPY functions as desired.

          email: jim.kosloskey@jim-kosloskey.com 29+ years Cloverleaf, 59 years IT - old fart.

        • #82259
          Jim Rawls
          Participant

            Both inbound and outbound variants are version 2.3.  We did not modify the type from DATE on the inbound, just the length.

            When I changed the inbound variant to TIMESTAMP (and left the length as 14) then I do get the correct output using COPY.  Thank you.

            I found this interesting because, during another attempted work-around, we copied from PV2-8 to a variable and did NOT experience truncation, but when copying from the variable to PV1-44, again we see truncation.  So apparently the variable also inherits the DATE attribute

        Viewing 1 reply thread
        • The forum ‘Cloverleaf’ is closed to new topics and replies.