Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
tyagishaila
Specialist
Specialist

Drop Table

Hi Community Members,

Is it always necessary drop< table>, if we are using resident table?

1 Solution

Accepted Solutions
Anonymous
Not applicable

Hi Shaila

It is not necessary to drop table if you are using Resident

we drop it because to avoid synthetic keys

if the scrip looks like below you does'nt need to drop the table as they are not linked

Table1:

load

Name,

Marks

from

test.xlsx(.........)

Sum_table:

Load

Name as New_Name,

sum(Marks) as New_Marks

resident Table1;

if the script look like below the you need to drop because they form the synthetic key

Table1:

load

Name,

Marks

from

test.xlsx(.........)

Sum_table:

Load

Name

sum(Marks) as Marks

resident Table1;

Regards

Harsha

View solution in original post

10 Replies
Anonymous
Not applicable

Hi Shaila

It is not necessary to drop table if you are using Resident

we drop it because to avoid synthetic keys

if the scrip looks like below you does'nt need to drop the table as they are not linked

Table1:

load

Name,

Marks

from

test.xlsx(.........)

Sum_table:

Load

Name as New_Name,

sum(Marks) as New_Marks

resident Table1;

if the script look like below the you need to drop because they form the synthetic key

Table1:

load

Name,

Marks

from

test.xlsx(.........)

Sum_table:

Load

Name

sum(Marks) as Marks

resident Table1;

Regards

Harsha

tyagishaila
Specialist
Specialist
Author

Okay,

Thanks Harsha

saumyashah90
Specialist
Specialist

Hi Shaila,

It is not necessary but if we don't drop it will creat a duplicate table or else it will concatenate .

tyagishaila
Specialist
Specialist
Author

And if we join two tables then is it necessary, to drop any of table.

(we are not using resident table here, because both tables are different)

Anonymous
Not applicable

Close the post my mark it as correct answer  if you got the correct answer so it can be helpful to others

Regards

Harsha

Not applicable

Hi Shaila,

If you join two tables, why do yu need to drop any of them?

saumyashah90
Specialist
Specialist

1)Once you Join the Table it will generate one table having the resultant data ....so no extra table will be left to drop..

2)But if you use keep you might have to drop it in future

tyagishaila
Specialist
Specialist
Author

Hi Pooja,

Actually I don't need, I am just asking.

because when we join tables then both table join into one table.

after that if we drop 2nd table. then can we lost information?

Not applicable

Hi,

As per my understanding, Drop table can be added in the start of the script to remove synthetic tables.

Drop table [$Syn Table 1];

....................................

Set date...

Set time...

..................................

Regards,

Kuldeep