Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

gidon500
Contributor II

elimenate first character for data

Hi I have a filed which includes serial no of computers in order to make my reprot i need to get the serial number without the first charater for exp.  SENNO.  SCHC900  should be CHC900   or SZ100 should be Z100

thanks for your help

gidon

Tags (1)
1 Solution

Accepted Solutions

Re: elimenate first character for data

Hi Gidon,

Use Left() and Len() functions to get it:

Right([Serial Number], Len([Serial Number]) -1) AS SerialWithoutFirstChar

Hope that helps.

Miguel

5 Replies

Re: elimenate first character for data

Hi Gidon,

Use Left() and Len() functions to get it:

Right([Serial Number], Len([Serial Number]) -1) AS SerialWithoutFirstChar

Hope that helps.

Miguel

mwoolf
Honored Contributor II

elimenate first character for data

If you want to change the serialNo in script:

mid(SerialNo,2,len(SerialNo)-1) as SerialNo

In a chart expression:

mid(SerialNo,2,len(SerialNo)-1)

gidon500
Contributor II

elimenate first character for data

Hi miguel thaks for your fast response  it works great thanks gidon

magavi_framsteg
Contributor III

Re: elimenate first character for data

Hi Gidon.

It would be sufficient to use the mid function with two parameters, like below:

mid([Serial Number], 2) as [Serial Number]

Kind regards

Magnus Åvitsland

BI Consultant

Framsteg Business Intelligence Corp.

Re: elimenate first character for data

Magnus,

I agree: easier, cleaner and simpler.


Miguel