Hello,
I created an element with Scripted Connectors with these Header Parameters,
header_params = {
"identifier": 'DWH',
"type": 'DWH Traffic',
}
Now I modified the Code and deleted a column.
The element keep the delete column and write not initialized.
How to delete the column in the Dataminer ?
I tried to delete the element, but it won't appear / created again from the Scripted Connectors.
from datetime import datetime, timedelta
import time
import requestssession = requests.Session()
data = ""
header_params = ''header_paramss = {
"identifier": 'Rest',
"type": 'DWH Traffic',
}json_string = '''
{
"People": [
{
"Id": 1,
"Name": "John",
"Age": 25
},
{
"Id": 2,
"Name": "Alice",
"Age": 30
},
{
"Id": 3,
"Name": "Bob",
"Age": 28
}
{
"Id": 4,
"Name": "Frank",
"Age": 18
}
] }
'''time.sleep(2)
end_time = datetime.now()
fend_time = end_time.strftime("%d/%m/%Y, %H:%M:%S")
duration = end_time - start_time
sec = duration.total_seconds()
print(f'Duration for the process took: {sec:.2f} seconds')
print("End Timestamp:", fend_time)
request_body = json_string
header_params = header_paramss
print(request_body)
session.put("http://localhost:34567/api/data/parameters", json=request_body, headers=header_params)
Hi,
Data API and Scripted Connectors do not support at present the removal of parameters or columns.
It is something that is in our roadmap but for now, the only option to have those parameters removed is to delete the element and the associated auto-generated connector in the Protocols & Templates module in Cube.
Then, the next time your Scripted Connector executes, a new element will be created and will no longer have the old parameters.
Yes, that is the case currently and it is a limitation we will address in an upcoming release.
After deleting the protocol, the data source don’t create an element anymore ?
do I need to refresh something ?
After deleting, the data source should create a new element the next time you execute it.
There was an issue associated with this in an earlier version of DataAPI but in the latest one it should be addressed so if that is not the case then there could be an issue in your system.
I see,
I need always rename the Header parameter, so the system create new element
I will check on our system
thank you
Do I need to delete the protocol too ?
DWH Traffic ?