pcm_get_custom_opcode() - cassiobj/PCM-Python_lib GitHub Wiki
The pcm_get_custom_opcode function is part of a Python extension for Oracle BRM. It returns custom opcode number.
The pcm_get_custom_opcode returns custom opcode number based on custom opcode name.
- opcode: String with custom opcode name.
The function returns custom opcode number.
In case of an error, the `error` exception is raised, and returns -1.
import PCMPy
try:
opcode = pcm_get_custom_opcode("C_OP_INV_ITEMS_HISTORY");
if (opcode >= 0) :
in_flist = "0 PIN_FLD_POID POID [0] 0.0.0.1 /invoice 226060 0"
result = PCMPy.pcm_op(opcode , in_flist, flag)
print("Result:", result)
except PCMPy.error as e:
print("An error occurred:", str(e))