Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Guys:
Could someone please advise me how to limit the load data into Qlikview?
For Example: I would only like to load all the data for Year 2011 and not those data that as from Year 2007 to 2011.
The database starts from 2007 to 2011.
Thank you guys.
Hi
You can limit your load with
select column
from table
where year = 2011
or similar in your load statement
Hi,
You can write some thing like this
Load
Field1,
Field2,
...
...
From TableName
Where Year>=2010 and Year<=2011;
Regards
Anand
Hi,
sql select * from table-X where year > 2010 and year <=2011;
Hi Sushil Kumar:
Thanks for your reply.
Do I write this in the Edit script Main Tab or in the first tab?
I have three table for the report so do I need to write all in the different tab under Edit script?
I will just try it.
Thanks for your reply
Hi,
It's all in the script, your table should look like the following
Table: // name of the table in QlikView
LOAD ID, // name of fields in QlikView (you can change them)
Date,
Amount;
SQL SELECT ID, Date, Amount
FROM Database.SalesTable
WHERE Year = 2011;
Hope that helps.
BI Consultant
Hi richardgan,
It hardly matters whether you write in a single tab or in multitab... Multitab is prferred for clear understanding...
HTH
Make it dynamic, for further years.
where year = year(today())
Hi Guys:
Thank you all for your kind help.
I try the sugesstion and the error message is:-
Unknown statement Where Year>=2010 and Year<=2011;
The other Error message is:-
Unknown Statement Where Year =2011
Below is the Edit script:
tbinventorytrans:
Load InventoryKey1,
InventoryDate,
Year(InventoryDate) as Inventoryyear1,
Year (InventoryDate) as year, //=====Checking
num(month(InventoryDate)) as month,//==== Checking
num(Month(InventoryDate),'00') as Inventorymonth1,
Year(InventoryDate) & num(Month(InventoryDate)) as InventoryYearMonth1,
Day(InventoryDate) as Inventoryday1,
date(daystart(InventoryDate),'DD-MM-YYYY') as InventoryDate1,
InventoryStatus,
InventoryGoodqty,
InventoryBadqty,
InventoryQcqty,
prodid,
custacc,
invtype,
locid
FROM
where year >=2011 and year<=2011;
Hi
check out which field of your table contains the year information.. then use that field to apply the condition.