cancel
Showing results for 
Search instead for 
Did you mean: 

Custom data types to mask fields

Former Member
0 Kudos
112

Hi collegues,

I am developing a web application that shows KPIs around dates, months, another time periods extracted from generated time data and fields that need custom visualization format.

Now we are facing some issues when we try to format those data types,

For example:

We have in our tables the field CALMONTH with the format YYYYMM.

And we want to format it like MM.YYYY for the web application, like BW does.

We successfully formated regular dates because it is a DATE data type, but CALMONTH is NVARCHAR(6).

Is there a way to create custom data types to format certain fields? It would be very useful.

Or is there any workaround?

Thanks.

Iván Cernigoj

View Entire Topic
Michał
Advisor
Advisor
0 Kudos

Ivan,

how about running TO_NVARCHAR(TO_DATE("CALMONTH", 'YYYYMM'), 'MM.YYYY') or simply SUBSTRING("CALMONTH",5,2) || '.' || SUBSTRING("CALMONTH",0,4) within your custom view/sql select ?

Best,

Michal