Our database has a memo field called description (example below)
"Smith Joe
User Object Details
Lan Id:
Location: example
Employee Number: 1111111
Manager: 2222222
Group:
Division Code updated successfully in OIM
User Info after processing user in OIM
Smith Joe
User Object Details
Lan Id: aaaaaa
Location: example
Employee Number: 1111111
Manager: bbbbbb
Group: Full-Time
DIVISION_CODE attribute updated successfully"
I need to be able to extract the value's of Lan ID and Employee Number. I'm currently using the following
Formula for Lan ID
//whileprintingrecords;
//numbervar v_start;
//numbervar v_end;
//v_start := instr({Sheet1_.Description},"Lan Id:");
//v_end := instr(mid({Sheet1_.Description}, v_start + 14),"");
//mid({Sheet1_.Description},v_start,(14 + v_end))
Formula for Employee Number
whileprintingrecords;
numbervar v_start;
numbervar v_end;
v_start := instr({Sheet1_.Description},"Employee Number:");
//v_end := instr(mid({Sheet1_.Description}, v_start + 24)," ");
v_end := instr(mid({Sheet1_.Description}, 18,8)," ");
if {Sheet1_.Description} like ["*Employee Number:*"] then mid({Sheet1_.Description},v_start,(24 + v_end)) else ""
If anyone has a better way of doing this I would appreciate any suggestions.
One problem I run into periodically is "Start position is less than 1 or not an integer"
"Smith Joe
User Object Details
Lan Id:
Location: example
Employee Number: 1111111
Manager: 2222222
Group:
Division Code updated successfully in OIM
User Info after processing user in OIM
Smith Joe
User Object Details
Lan Id: aaaaaa
Location: example
Employee Number: 1111111
Manager: bbbbbb
Group: Full-Time
DIVISION_CODE attribute updated successfully"
I need to be able to extract the value's of Lan ID and Employee Number. I'm currently using the following
Formula for Lan ID
//whileprintingrecords;
//numbervar v_start;
//numbervar v_end;
//v_start := instr({Sheet1_.Description},"Lan Id:");
//v_end := instr(mid({Sheet1_.Description}, v_start + 14),"");
//mid({Sheet1_.Description},v_start,(14 + v_end))
Formula for Employee Number
whileprintingrecords;
numbervar v_start;
numbervar v_end;
v_start := instr({Sheet1_.Description},"Employee Number:");
//v_end := instr(mid({Sheet1_.Description}, v_start + 24)," ");
v_end := instr(mid({Sheet1_.Description}, 18,8)," ");
if {Sheet1_.Description} like ["*Employee Number:*"] then mid({Sheet1_.Description},v_start,(24 + v_end)) else ""
If anyone has a better way of doing this I would appreciate any suggestions.
One problem I run into periodically is "Start position is less than 1 or not an integer"