Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Concat two number fields

I have the following table:

Order NumberLine Number
10000500
20000750
30000800
RE-103561000

I want to merge the two fields and have the following output as Order-Line numbet:

10000-500
20000-750
30000-800
RE-10356-1000

I am able to concatenate only two text formats, but not number formats.


Can anyone help me please with a Qlikview file/.

8 Replies
senpradip007
Specialist III
Specialist III

Try to use like [Order Number] & '-' & [Line Number] As [New Field]

Not applicable
Author

it is not working.

it works for date and text formats,.

senpradip007
Specialist III
Specialist III

In my app its working fine. Still try like Text([Order Number]) & '-' & Text([Line Number]) As [New Field].

Not applicable
Author

No. this is also not working.

jagan
Partner - Champion III
Partner - Champion III

Hi,

Try like this

LOAD

*,

Text([Order Number] & '-' & [Line Number]) As [New Field]

FROM DataSource;


Regards,

Jagan.

senpradip007
Specialist III
Specialist III

Could you please upload sample app or your script?

senpradip007
Specialist III
Specialist III

Have tested with RowNo() & '-' & (RowNo()-1) AS Test2 expressions. Outcome of this expression is like

1-0

2-1

3-2

...

N-(N-1)

jonathandienst
Partner - Champion III
Partner - Champion III

Hi

Pradip Sen's answer is correct for your question. If it is not working for you, please provide details of exactly what is wrong, including the output you are getting from the example data in your post. Otherwise we are just guessing...

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein