Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Delete a field

Hello,

Actually I tried to manage my database and I wanted to know how can I delete an entire field.

Header 1Header 2Header 3

Field 1

User 1PWD 1
Field 2User 2PWD 2
Field 3user 3PWD 3

If I delete Field 2:

Header 1Header 2Header 3
Field 1User 1PWD 1
Field 3User 3PWD 3

Regards

1 Solution

Accepted Solutions
qlikviewwizard
Master II
Master II

Hi KennyHua

We can not delete any field from data model. But we can do following:

1. We can not select the field in SELECT statement

2. We can comment the field

3.We can use DROP Field FieldName from TableName statement.

Hope this will help you.

View solution in original post

12 Replies
sasiparupudi1
Master III
Master III

you can use dropfiled function

drop Field YourField;

Ralf-Narfeldt
Employee
Employee

Do you mean data you have loaded into QlikView?

If you loaded it as Table1:

Table2:

Load * resident Table1 where Header1 <> 'Field2';

Drop Table1;

veidlburkhard
Creator III
Creator III

Hi Kenny,

seems you want to delete one row and not  a field. If so you can use the file wizard and easily delete the marked row or chose a conditon to conditionally delete it:

DeleteRow.jpg

Hope this helps

Burkhard

sasiparupudi1
Master III
Master III

Hi

If you want to delete a row in an already loaded table, you could only use another resident load excluding the problem row.

I suggest you go wiith the solution given by

Ralf-Narfeldt
Employee
Employee

That's how I interpreted it based on the data example, that it was a row to be deleted.

Not applicable
Author

It's very interesting, but do you know if it's possible de keep the column name ? Because actually when I take your way, Each column is replaced by @1, @,2 and I want to keep Header 1, Header 2, ...

I don't want to creat alias because I have a lot of table to manage

Regards

veidlburkhard
Creator III
Creator III

Hi Kenny,

no need to create aliases. Simply click on embedded lables. See below

DeleteRow.jpg

Regards

Burkhard

Not applicable
Author

Hi,

Sorry to keep asking you, but I got something different with your picture:

DELETE:

  LOAD

  Header 1,

  Header 2,

  Hearder 3

  FROM

  [..\DATA\TABLES - Copie\COUNTRY.qvd]

  (qvd, filters(

  Remove(Row, Pos(Top,$(vNB_OF_ROW)))

));

And I got with the Wizard:

delete.PNG

Regards

Ralf-Narfeldt
Employee
Employee

I still think it would be easier to do it in a resident load

INPUT:

  LOAD

  Header 1,

  Header 2,

  Hearder 3

  FROM

  [..\DATA\TABLES - Copie\COUNTRY.qvd]

  (qvd);


DELETE:

Load * resident INPUT where Header1 <> 'Field2';

Drop Table INPUT;