Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

How to get table name

Hello everyone,

Actually I try to get the name of what I LOAD to another table:

Table I want to get the name:

CONCATENATE(NAME)

       LOAD A AS "FIELD1",

                 B AS "FIELD2",

                 C AS "FIELD3",

Regards

Tags (3)
1 Solution

Accepted Solutions
anbu1984
Honored Contributor III

Re: How to get table name

NAME:

LOAD A AS "FIELD1",

                 B AS "FIELD2",

                 C AS "FIELD3",

                  "NAME" As TableName

From NAME;

CONCATENATE(NAME)

       LOAD A AS "FIELD1",

                 B AS "FIELD2",

                 C AS "FIELD3",

                  "Name2" As TableName

From Name2

3 Replies
jsanchezh
Contributor

Re: How to get table name

When you concatenate, your are adding these fields to your table called NAME.

You can try this:

NAME:

LOAD *

     FROM

MY_NEW_TABLE_NAME:

noConcatenate LOAD A AS "FIELD1",

                 B AS "FIELD2",

                 C AS "FIELD3"

FROM

Then you will have two tables: NAME and MY_NEW_TABLE_NAME but if they have the same field names you will have a synthetic table

Gabriel
Valued Contributor II

Re: How to get table name


Hi,

Naming a table is up to you to name the table with name relevant to the data you're loading. i.e. if you are loading Customer data, it make sense to name the table Customer or CUST. So if you're concatenate you just copy same table name above and paste it into the concatenate open and close bracket.

anbu1984
Honored Contributor III

Re: How to get table name

NAME:

LOAD A AS "FIELD1",

                 B AS "FIELD2",

                 C AS "FIELD3",

                  "NAME" As TableName

From NAME;

CONCATENATE(NAME)

       LOAD A AS "FIELD1",

                 B AS "FIELD2",

                 C AS "FIELD3",

                  "Name2" As TableName

From Name2

Community Browser