Skip to main content
Announcements
UPGRADE ADVISORY for Qlik Replicate 2024.5: Read More
cancel
Showing results for 
Search instead for 
Did you mean: 
vchilakamarthi
Contributor II
Contributor II

QEM Python API to get table details in task.

Hello,

Exporting the current replicate task from QEM would give me a JSON that has table manipulation settings.

It has the following info.

manipulations": [{
"name": "SOURCE_OWNER.TABLE_NAME",
"table_manipulation": {
"owner": "SOURCE_OWNER",
"name": "SOURCE_TABLE_NAME",
"new_table_name": "TARGET_TABLE_NAME",
"new_owner_name": "TARGET_OWNER",


That gives me access to source/target table details and also the column mapping.

Which API could give me this information ?

I don't see get_task_details or get_tables return this info.

https://help.qlik.com/en-US/enterprise-manager/May2023/Content/EnterpriseManager/EnterpriseManager_A...

Also which api can give me  STORE_CHANGE_SETTINGS of a given task.

Labels (1)
2 Solutions

Accepted Solutions
Heinvandenheuvel
Specialist III
Specialist III

What about the GetTableStatus call. It returns an array with :

{
"table_details":[
   {
   "schema_on_source":"{string}",
   "table_on_source":"{string}",
   "schema_on_target":"{string}",
   "table_on_target":"{string}",
   :

No columns mapping but the manipulation JSON will only show you those columns which are manipulated.

For full table and column information only REPCTL dumpmetadata can help you.

>> Also which api can give me  STORE_CHANGE_SETTINGS of a given task.

You'll have to EXPORT the task look for the store change line to see if it is there.  I believe the task_setting parameter is common_settings.save_changes_enabled,   Absence = default = off.

But don't take my word for it. Take a test task, export once with and once without store change and DIFF

Hein.

 

View solution in original post

vchilakamarthi
Contributor II
Contributor II
Author

Ok, what I need is found in two different places.

1. If store_change_settings on a task is enabled 

get_task_details - store_changes_enabled (boolean)

https://help.qlik.com/en-US/enterprise-manager/May2023/Content/EnterpriseManager/EnterpriseManager_A...

2. Get source and target table names and their owners in a given QLIK replicate task (like you suggested above already) using get_table_statuses

https://help.qlik.com/en-US/enterprise-manager/May2023/Content/EnterpriseManager/EnterpriseManager_A...

Thsi is good ...thank you for your time.

View solution in original post

3 Replies
Heinvandenheuvel
Specialist III
Specialist III

What about the GetTableStatus call. It returns an array with :

{
"table_details":[
   {
   "schema_on_source":"{string}",
   "table_on_source":"{string}",
   "schema_on_target":"{string}",
   "table_on_target":"{string}",
   :

No columns mapping but the manipulation JSON will only show you those columns which are manipulated.

For full table and column information only REPCTL dumpmetadata can help you.

>> Also which api can give me  STORE_CHANGE_SETTINGS of a given task.

You'll have to EXPORT the task look for the store change line to see if it is there.  I believe the task_setting parameter is common_settings.save_changes_enabled,   Absence = default = off.

But don't take my word for it. Take a test task, export once with and once without store change and DIFF

Hein.

 

vchilakamarthi
Contributor II
Contributor II
Author

Thank you let me test it out and see what I get. 

vchilakamarthi
Contributor II
Contributor II
Author

Ok, what I need is found in two different places.

1. If store_change_settings on a task is enabled 

get_task_details - store_changes_enabled (boolean)

https://help.qlik.com/en-US/enterprise-manager/May2023/Content/EnterpriseManager/EnterpriseManager_A...

2. Get source and target table names and their owners in a given QLIK replicate task (like you suggested above already) using get_table_statuses

https://help.qlik.com/en-US/enterprise-manager/May2023/Content/EnterpriseManager/EnterpriseManager_A...

Thsi is good ...thank you for your time.