Simple concatenation

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • 3acks
    New Member
    • May 2007
    • 16

    #1

    Simple concatenation

    I know I've done this before, but for some reason the answer alludes my brain this Monday morning...

    When I concatenate two number fields line:[system] & [sequence], it is dropping the leading zeros.

    ex: system = 72 and sequence = 001
    concatenate as line:[system] & [sequence= 721

    I want to see line = 72001

    Thanks
  • 3acks
    New Member
    • May 2007
    • 16

    #2
    Now I remember.

    Line: [System Number] & Format([Seq No],"000")

    Comment

    • theaybaras
      New Member
      • May 2007
      • 52

      #3
      Glad you got things figured out!

      theAybaras

      Comment

      • NeoPa
        Recognized Expert Moderator MVP
        • Oct 2006
        • 32669

        #4
        Originally posted by 3acks
        Now I remember.

        Line: [System Number] & Format([Seq No],"000")
        Two further issues that MAY need to be considered.
        1. [System Number] may need Format()-ing too.
        2. If either value can be a null and you want a string expression returned anyway - use '+' instead of '&'

        Comment

        Working...