ABAP – S/4 Concatenate

Home / SAP / ABAP Coding / ABAP – S/4 Concatenate

Here’s another fun little tidbit for the new coding in S/4.  If you want to concatenate a string together you used need to do:

CONCATENATE ‘X’ ‘Y’ into lv_var.

now you can do:

lv_var = ‘X’ && ‘Y’.

Even better, you don’t run into type mismatches either.  For example, if you have a time stamp, the value is in a packed format.  This means that you must first concatenate things into a string, then copy them to the final value.  with the &&, you can skip all that and do it in a simple one line statement.

ABAP really is getting better 🙂

Thanks for reading,

As always, thanks for reading and don't forget to check out our SAP Service Management Products at my other company JaveLLin Solutions,
Mike

Leave a Reply

Your email address will not be published. Required fields are marked *