Skip to Content
0

Inline declaration specifying type

Jul 13, 2017 at 10:52 AM

46

avatar image

As of 7.40 we can finally make use of inline data declarations.

Can you use an inline data declaration and specify the type at once?

For example when I do a select on a database type I want to use a hashed type as the output type. But when I use an inline data declaration it will always generate a STANDARD TABLE.

SELECT matnr, maktx
FROM makt
INTO @DATA(lt_makt) <-- This should be a hashed table with key MATNR
  WHERE spras = sy-langu.
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Horst Keller
Jul 13, 2017 at 11:51 AM
0

No, in SELECT this isn't possible.

It is possible in other write positions, where the type of the source is completely known.

Show 1 Share
10 |10000 characters needed characters left characters exceeded

That was a fast answer. Thanks Horst.

Too bad this isn't possible (yet). Maybe a feature for in the future?

0