Hi Ganesh,
you can have a look at method AMDP_GET_BP_CLASSIFICATION in Class CL_EPM_OIA_BP_CLASSIFY_AMDP (should be available in 740 SP5).
Alternatively, you might want to use a CASE statement (see https://help.sap.com/saphelp_hanaplatform/helpdata/en/20/a4389775191014b5a6bf2ccc0df2ed/content.htm).
Or see further information in http://help.sap.com/hana/sap_hana_sql_script_reference_en.pdf.
Please also consider the performance aspects of such imperative logic - you might want to consult the HANA Development experts in SAP HANA Developer Center.
Cheers,
Jasmin