Hi Appian team,
I have changed the display name for CDT and there for modified the field name in interface as well. I have done the below code change, but the regular expression added for validation is not working as expected.
Can anyone help me out to solve this issue?
below is the code snippet used.
a!textField( label: "Purchase order (PO)/Sales order (SO)/STO/Requisition", labelPosition: "ABOVE", value: trim( index( ri!PF_Request, "Order_Del_Number", null ) ), saveInto: { a!save( ri!PF_Request.Order_Del_Number, /*if(ri!PF_Request.GBEID=18,*/ /*left(*/ /*trim(*/ /*save!value*/ /*),10),*/ /*trim(*/ /*save!value*/ /*))*/ trim(save!value) ) }, required: true, validations:if(ri!PF_Request.GBEID = 18, if(regexmatch("^([0-9]{1,10})$",ri!PF_Request.Order_Del_Number),null,"The number provided should not contain any special character and can have upto 10 digits"), null ) )
Also please see the below discuss link to understand what are the changes I have made.
Thanks
Sunu Sam
https://community.appian.com/discussions/f/process/22377/how-can-i-just-give-a-display-name-to-columns-in-cdt-which-has-a-different-name-in-database-tables-also-i-have-more-questions-regarding-appian-features/87736#87736
Discussion posts and replies are publicly visible
HI Richard ,
I am adding the cdt which i have used for datatype using XSD import/export.
<xsd:element name="Order_Del_Number" nillable="true" type="xsd:string"> <xsd:annotation> <xsd:appinfo source="appian.jpa">@Column(name="purchaseorder", length=255)</xsd:appinfo> </xsd:annotation> </xsd:element>
Let me know is that right or not?
Hi sunus,
looks fine to me regarding names. But i am not sure regarding " columnDefinition"
Perhaps check that again.
kind Regards,
Richard
Yes, this was the issue ,because of the condition it was not working , thanks a lot Richard for giving this hint.
Regards