2024 Aug 23 12:22 PM - edited 2024 Aug 27 4:22 PM
Hi experts,
I have a field that displays a document number. For some kinds of document type, document number should be display as it is in the DB, while for some kinds of document type, document number should remove leading zeroes and this can be done by alpha routine in data element.
My question is, can I use different date elements casting against the document type? I tried the below code but looks like only the first date element is working.
SELECT from tableA { cast(DocNumber as DE1) } where DocType = 'X' UNION all SELECT from tableB { cast(DocNumber as DE2) } where DocType = 'Y.'
Anyone could give some help here?
Regards,
Ming
Request clarification before answering.
in your case expression, do what you need to do(removing 0...), the final output(cast to a normal type if needed) should display as it is(no conversion here).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
64 | |
8 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.