Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Leverage your QlikView investment to modernize BI – see how! Join Group
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Partner
Partner

Remove space in emailadresses

I got a qvw that reads in data from excel and then adds it to nPrint.
No spaces are allowed in [e-post] as well it has to be lowercase.

I sorted out the lower as lower([e-post]) as [e-post],

Can I make one line to handle both the lower and the remove of spaces in e-post?

I read about 10 posts in the forum but could not find anything that worked, I tried a few different trims, replace etc.

The space can be anywhere in the e-mail, it's users who adds them.

Tags (2)
1 Solution

Accepted Solutions
Highlighted
MVP & Luminary
MVP & Luminary

Re: Remove space in emailadresses

Maybe: lower(purgechar([e-post], ' ')) as [e-post]

- Marcus

View solution in original post

6 Replies
Highlighted
MVP & Luminary
MVP & Luminary

Re: Remove space in emailadresses

Maybe: lower(purgechar([e-post], ' ')) as [e-post]

- Marcus

View solution in original post

Highlighted
Partner
Partner

Re: Remove space in emailadresses

trim(PurgeChar([e-post],' ')) as [e-post], this solved first problem,
but can I incoporate lower on the same line?

I used to have lower([e-post]) as [e-post] for the lower before I added this.

Highlighted
Partner
Partner

Re: Remove space in emailadresses

Hi JacobT,

 

Try this:

Lower(Replace([e-post], ' ', '')) as [e-post],

 

Highlighted
Partner
Partner

Re: Remove space in emailadresses

lower(PurgeChar([e-post],' ')) as [e-post], worked space between '' ofc, thank you for the help!

Highlighted
MVP & Luminary
MVP & Luminary

Re: Remove space in emailadresses

You could easily nest these functions - depending on the task (not in this case) it might be useful to apply functions like lower/upper at the most inside because it could reduce the efforts with the keepchar/purgechar and similar.

- Marcus

Highlighted
Partner
Partner

Re: Remove space in emailadresses

Both these expressions should work:

PurgeChar( Lower([e-m ai l]), ' ')

and

Replace( Lower([e-m ai l]), ' ','')

 

Using this script:

LOAD * inline [
e-m ai l
jacob T@qlikcommunity.com
Vegar@ qlik community.com];

Plees ekskuse my Swenglish and or Norweglish spelling misstakes