Qlik Community

Ask a Question

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
Talk to Experts Tuesday, January 26th at 10AM EST: Qlik Sense. REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Contributor III
Contributor III

How to replace first 4 digit with # in chart or scipt

Hi Everyone,

I have requirement like to convert first 4 digit into '#' .

EX:- 

I/PO/P
1234567####567
5456990####990
6789076####076
Labels (1)
3 Solutions

Accepted Solutions
MVP & Luminary
MVP & Luminary

Maybe: '####' & mid([I/P], 5)

- Marcus

View solution in original post

Partner
Partner

Hi Jash,

 

Here you go:

 

Switch:
LOAD
[I/P] as [I/P],
'####'&Right([I/P], LEN([I/P])-4) as [O/P]
;
Load * INLINE [
I/P
11315155
25145156
3141556
441431516
531313155
63123156643
];

View solution in original post

Master II
Master II

maye be :

'####'&right([I/P],len([I/P])-4) as [O/P],
Regards,
Taoufiq ZARRA

"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "

(you can mark up to 3 "solutions") 😉

View solution in original post

3 Replies
MVP & Luminary
MVP & Luminary

Maybe: '####' & mid([I/P], 5)

- Marcus

View solution in original post

Partner
Partner

Hi Jash,

 

Here you go:

 

Switch:
LOAD
[I/P] as [I/P],
'####'&Right([I/P], LEN([I/P])-4) as [O/P]
;
Load * INLINE [
I/P
11315155
25145156
3141556
441431516
531313155
63123156643
];

View solution in original post

Master II
Master II

maye be :

'####'&right([I/P],len([I/P])-4) as [O/P],
Regards,
Taoufiq ZARRA

"Please LIKE posts and "Accept as Solution" if the provided solution is helpful "

(you can mark up to 3 "solutions") 😉

View solution in original post