Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi! I've got a table where a column contain a list of date for example "20/02/1964". I want to obtain a new column where i can see only the year for each date. What kind of string i have to type to obtain this result??
use date functions like
year(yourdate)
maybe you have to convert your date if Qlikview doesnot recognize it as data, the use date(date#(yourdate,'DD/MM/YYYY')
Hi,
year function will help you..
example
table a:
load
name,
age,
date,
year(date) as year
from
datasource order by year(date) ;
i hope this will help u..
you can add it in the script when loading the data using the Year function, year(data field) or use a calculated dimension in the chart and add the function there Year(data field), however it is not preferred to use calculated dimension instead add it in the load script.
Hi Gabrielle,
Are you working in the Load script og in a chart?
In Load Script:
If in the Load-script, something like this will do the trick:
Data:
Load Date, Year(Date) as Year, * From Data.Qvd (qvd);
In Charts:
If your are working in a chart you can add a calculated dimension with the expression Year(Date) :