Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

apply map error : field not found

  Hi,

I am having an error with apply map. It says field not found<psp_status> while loading table svr_rpx

status:

mapping load * inline [
psp_staus,psp_status_exp
R,Reserved
]
;

svr_rpx:

load psp_status,applymap('status',psp_status) as psp_status;
select psp_status from 

svr_rpx_missing1 ;

Please help me out with the syntax.

Thanks,

Anju

6 Replies
Not applicable
Author

Hi Anju,

    Kindly make sure about the field psp_status in the underlying table. Also why you are trying to do the proceeding load?

-Jay

jagan
Luminary Alumni
Luminary Alumni

Hi Anju,

Try this script, it is working

status:
mapping load * inline [
psp_staus,psp_status_exp
R,Reserved
];

svr_rpx:
load psp_status,
applymap('status', psp_status) as psp_status_value;
load * inline [
psp_status
R
];

Regards,

Jagan.

tresesco
MVP
MVP

Try like this:

MapTable:

mapping load * inline [
psp_staus,psp_status_exp
R,Reserved
]
;

svr_rpx:

load psp_status,applymap('MapTable',psp_status) as Mapped_psp_status;
select psp_status from 

svr_rpx_missing1 ;

Note: Changes are in red.

Not applicable
Author

Hi Tresesco,

I tried this .But this did not work for me.

Thank You!

Not applicable
Author

You'll need to have the same field loaded twice in the SQL as well.

load psp_status,applymap('MapTable',psp_status) as Mapped_psp_status;
select psp_status,psp_status from 

svr_rpx_missing1 ;

Not applicable
Author

Hi All,

I was able to solve it.There seems to be a bug.

It works when psp_status is in capital letters.

"

svr_rpx:

load *,applymap('status',PSP_STATUS) as psp_status_new;
select PSP_STATUS from

svr_rpx_missing1 ;

"

Regards,

Anju