Monday, 22 September 2014

Converting Character Datatype Field Value to Numeric Datatype Value in Peoplecode


Incrementing  interview ID  i.e  from  000001  to 000002

local number &i = 1;
local number   &max_interview_id ;
Local String &InterviewID ;


&InterviewID  = NumberToString("%06", &i );

/* I have used value()  from character to numeric data type conversion  */

&max_interview_id = Value(LTrim(RTrim(&InterviewID)));
&InterviewID = NumberToString("%06", &max_interview_id + 1);
  
  

No comments:

Post a Comment