Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How do I lpad a varchar2 item with 0's to a length of 3 in APEX 5.0?

user2536792May 13 2015 — edited May 14 2015

This is an interactive report entry form.

I tried entering Column Attributes of String("000" + :P8_PARAMETER_1).slice(-3);

I tried creating a Dynamic Action - Change with a javascript expression of

var str = :P8_PARAMETER_1

var pad = "000"

var :P8_PARAMETER_1 = pad.substring(0, pad.length - str.length) + str

I tried for the Dynamic action value True set to execute javascript code of P8_PARAMETER_1.lpad("0", 3)

When the record is created it is not padded with zeros.

Thanks,


Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 11 2015
Added on May 13 2015
2 comments
784 views