Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

SBO_TN

Hi Experts...

Plz check this Sbo_TN.

*IF (@transaction_type = 'A'OR @transaction_type ='U') AND @object_type = '2'

BEGIN

If exists (SELECT T0.CardCode FROM OCRD AS T0 INNER JOIN

OCPR T1 ON T0.CardCode = T1.CardCode

WHERE (T0.CntctPrsn IS NULL OR T1.Cellolar is NULL ) AND (T0.CardCode = @list_of_cols_val_tab_del))

begin

SET @error = 111

SET @error_message = N'MUST SPECIFY CONTACT PERSON MOBILE NO.'

end

END*

This query running successfully. But I need that user can't put characters, symbols, or space in Cellolar field. It should just accept 10 numeric digits.

Plz help for same.

Regards,

Ravi

Former Member
Former Member replied

Try:

WHERE (T0.CntctPrsn IS NULL OR ISNUMERIC(T1.Cellolar) = 0 OR LEN(T1.Cellolar)>10)

AND (T0.CardCode = @list_of_cols_val_tab_del))

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question