Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to get the value of a single cell from excel file

Hi All,

I have a excel file which i am trying to load into QV and attached is the sample, if you can look at the file in column D row 10 (Cell D10) we have Apr Wk1, Now my requirement is i need to just get that Apr value out of the file and display it as its showing the month.

Can someone throw any suggestions on this?

Thanks.

1 Solution

Accepted Solutions
Not applicable
Author

Hi Andre,

Sorry i unintentionally deleted your post.But that was the one i was looking for, Thanks a lot for your help.

LOAD left(BR, 3) as CellValue

FROM (ooxml, no labels, header is 8 lines, table is [Earned])

where A = 'Reg';

View solution in original post

13 Replies
MayilVahanan

HI

Try like this

CrossTable(Month, Value, 3)

LOAD Reg,

     Dis,

     [Dis Name],

     [Apr Wk1] AS Apr

FROM

[Test (1).xlsx]

(ooxml, embedded labels, header is 8 lines, table is Sheet1);

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Not applicable
Author

Looks like we have hardcoded the Cell D10 value to be AprWk1 which cannot be done as this file keeps changing for every month and the month name changes in that cell.

MayilVahanan

Hi

Try like this

CrossTable(Month, Value, 3)

LOAD Reg,

     Dis,

     [Dis Name],

     [Apr Wk1]

FROM

[Test (1).xlsx]

(ooxml, embedded labels, header is 8 lines, table is Sheet1);

NoConcatenate

Load Replace(Month,'Wk1','') AS Month, Reg,

     Dis,

     [Dis Name],

     Value Resident Test;

DROP Table Test;

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Not applicable
Author

Hi,

Please correct me if i am wrong but looks like in the cross table again we are using the Apr Wk1 , we dont need this because the month name keeps changing, also i tried to run the above code and i receive an error, can you please make the change and send me a sample QVD which can work.

Thanks

MayilVahanan

HI

Can you provide your sample data which explain your scenario?

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
sudeepkm
Specialist III
Specialist III

I've a solution but it may not be best practice.

You can use:

LOAD *

FROM

T123085Test.xlsx

(ooxml, embedded labels, header is 8 lines, table is Sheet1);

Then in your chart you need to create expressions conditional basis as the Field name is changing every month. Based on the current month the field name will be present in your data file and will be displayed in the Chart. but if the Month mismatches then it will not show any data.

T123085.png

Not applicable
Author

Hi,

I dont have any sample data or anything and i dont even want any data , all i am looking for is a text box which shows the name of the month which is displayed in cell D10.

Please let me know if i am unclear.

Thanks

Not applicable
Author

Hi

Hi,

Looks like we are trying to bring the data over here, but i dont want any data at all  all i am looking for is a text box which shows the name of the month which is displayed in cell D10.

Please let me know if i am unclear.

Thanks

ThornOfCrowns
Specialist II
Specialist II

You'll have to bring some data over to display as you can't set a pointer from QV to an Excel Cell reference.