ing" as="xs:string"></xxf:variable>
                                    <xxf:variable select="$phone-string castable as xs:positiveInteger and string-length($phone-string) = 10" name="is-valid-phone-string" as="xs:boolean"></xxf:variable>
                                    <xf:setvalue ref="$binding" if="$is-valid-phone-string" value="$phone-string"></xf:setvalue>
                                    <xf:setvalue ref="$binding" if="not($is-valid-phone-string)" value="if ($phone-string = '') then '' else 'IN