Concat Expression Formula - InfoPath Dev
in

InfoPath Dev

Concat Expression Formula

Last post 09-09-2007 10:28 PM by Monte Cristo. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 09-09-2007 07:15 PM

    Concat Expression Formula

    Hi,

    I have a database with one table, it has three coloumns, (1) a simple number format 0001, 0002, 0003 & so on....[text format in access] (2) Name [text format in access] (3) date [date format in access]

    So I have connected this database as my main connection and this all works.

    I have an expression box which queries the database coloumn (1) but the expression box returs the value without the 0's so all I get is 3, 4, 5 etc.

    This is the formula in the expression box: concat(Year, "-", ProductLine, "-", max(@Claim_Number) + 1)

    BTW - @Claim_Number is the one querying the database coloumn (1)

    Can anyone please tell me how I can return the values of coloumn (1) with the leading zeros? I have tried to change the format of the coloumn in access to a number (long integer) still not returning the values with the leading zero's.

    Thanks,

  • 09-09-2007 09:12 PM In reply to

    Re: Concat Expression Formula

    Hi Monte Cristo,

    Why are you calling the max function? I think that may be one of the problems. Try removing that and see if the data type of @Claim_Number is of type text. If it is, you will have to use a custom function to get the maximum (some string enumeration will be required.

    Good luck!

    Patrick Halstead
    Project Manager at Qdabra
  • 09-09-2007 10:28 PM In reply to

    Re: Concat Expression Formula

    Hi Patrick,

    I am calling on the max function to provide the next available number in the sequence, so the tbl in the database has only 0001, 0002 & 0003, so I use the max + 1 to return the next number in the sequence.

    Once I have this number and I've filled out the form I record a new record in the database and it repeats.

    Custom function any idea where to start?

    Thanks,

Page 1 of 1 (3 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.