Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I just started working with Qlikview and do have a simple table (three columns) to load.
I don't know if there is a way to do this, but that's why I ask for you help.
The table I use has rows which are identical.
Since I need to be able to have all rows (including identical rows) and want to link this table to another table (with the same amounth of rows offcourse).
So I thought to add a column with an ID. There is going to be added once in a while a few thousands of rows so I don't want to do this by hand and don't want to have to lookup which ID's are used and which aren't. Thus I prefer to add a column with an automaticaly generated ID.
I think the solution I am looking for looks very much like this: http://community.qlik.com/message/63485#63485
I hope someone can help me.
Hi,
How about using RecNo() function in the load script and alias the column name. Please find the explanation below...
RecNo( )
Returns an integer for the number of the currently read row of the
input table. The first record is number 1.
Thanks,
DV
Hi,
How about using RecNo() function in the load script and alias the column name. Please find the explanation below...
RecNo( )
Returns an integer for the number of the currently read row of the
input table. The first record is number 1.
Thanks,
DV
Thanks DV,
This is exactly what I was looking for and lets me have all the (not any more) identical rows
Now I tried to apply this to a crosstable in two ways and both don't work;
1. Crosstable( Vraagnummer, Antwoorden ) LOAD Date(Datum) as Datum, 'ANTW'&RecNo() as AntwoordID,
(several columns)
FROM...... table location etc.
2. Crosstable( Vraagnummer, Antwoorden, 'ANTW'&RecNo() as AntwoordID ) LOAD Date(Datum) as Datum,
(several columns)
FROM...... table location etc.
How can I make a table with a column 'AntwoordID', 'Datum', 'Vraagnummer' and a (crosstable)column 'Antwoorden'?
You are welcome mate.
I would recommend you to use the resident load or preceeding load.
Hope this helps!
Cheers - DV