Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a column named oltp, which gives numeric values.
I want to display some text based on the numeric value.
[1-Total,2-Detail,3-Back Order & 4-Order Line]
in data load editor. Plzzz help
Like @Frank_Hartmann said with dual function. Or you can create a column in your data model.
You can first load a mapping table:
map_fieldvalue_fieldtext:
mapping load * inline [
value, field
1, Total
2, Detail
3, Back Order
4, Order Line
]
;
and in your load script when loading the table with the numeric value, you can also add a field that is, applymap('map_fieldvalue_fieldtext', value) as fieldtext
Even if you use the Dual function, you could use this as well
dual(applymap('map_fieldvalue_fieldtext', value), value) as fielddual.
i think dual function is what you need:
Like @Frank_Hartmann said with dual function. Or you can create a column in your data model.
You can first load a mapping table:
map_fieldvalue_fieldtext:
mapping load * inline [
value, field
1, Total
2, Detail
3, Back Order
4, Order Line
]
;
and in your load script when loading the table with the numeric value, you can also add a field that is, applymap('map_fieldvalue_fieldtext', value) as fieldtext
Even if you use the Dual function, you could use this as well
dual(applymap('map_fieldvalue_fieldtext', value), value) as fielddual.