Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Join this live chat April 6, 10AM EST - QlikView to Qlik Sense REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
smilingjohn
Creator III
Creator III

Variable

HI ALl,

Can someone explain me what does the below expression does ?

mid(FileName(),34,6) as Year_Month,

1 Solution

Accepted Solutions
avinashelite

mid(FileName(),34,6) as Year_Month,


mid() if the function to fetch the values between a range

34 - starting point of the fetching the values

6 - is the length till it should fetch i.e it will fetch the values from 34 to 40

View solution in original post

3 Replies
prma7799
Master III
Master III

From Qlikview Help

Mid - script and chart function

Mid() returns the part of the input string starting at the position of the character defined by the second argument, 'start', and returning the number of characters defined by the third argument, 'count'. If 'count' is omitted, the rest of the input string is returned. The first character in the input string is numbered 1.

Syntax:

Mid(text, start[, count])

Return data type: string

Arguments:

ArgumentDescription
textThe original string.
startInteger defining the position of the first character in text to include.
countDefines the string length of the output string. If omitted, all characters from the position defined by start are included.
avinashelite

mid(FileName(),34,6) as Year_Month,


mid() if the function to fetch the values between a range

34 - starting point of the fetching the values

6 - is the length till it should fetch i.e it will fetch the values from 34 to 40

View solution in original post

marcus_malinow
Specialist III
Specialist III

hate to nit-pick

it will retrieve characters 34 to 39 (inclusive)