Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Clear or Destroy data table in 6.4 form

Avatar

Avatar
Validate 10
Level 3
Christopher_Pa4
Level 3

Likes

16 likes

Total Posts

54 posts

Correct Reply

4 solutions
Top badges earned
Validate 10
Validate 1
Ignite 5
Ignite 3
Ignite 1
View profile

Avatar
Validate 10
Level 3
Christopher_Pa4
Level 3

Likes

16 likes

Total Posts

54 posts

Correct Reply

4 solutions
Top badges earned
Validate 10
Validate 1
Ignite 5
Ignite 3
Ignite 1
View profile
Christopher_Pa4
Level 3

09-09-2019

Hello!

We are using an Adaptive Form to display search information from a database.

If we click a Search button, we run this script:

if ((txtFirstName !== null && txtLastName !== null)) {

//clear rows first   

      tableItem11.value = null;

      tableItem13.value = null;

      tableItem14.value = null;

      tableItem15.value = null;

     

  var operationInfo = {

    "formDataModelId": "/content/dam/formsanddocuments-fdm/ps_apexmulti",

    "operationTitle": "getApexMulti",

    "operationName": "get_15613995797250"

};

var inputs = {

    "FIRST_NAME" : txtFirstName,

    "LAST_NAME" : txtLastName

};

var outputs = {

    "FIRST_NAME" : tableItem11,

    //"MIDDLE_NAME" : tableItem12,

    "LAST_NAME" : tableItem13,

    "HC_PARENTDEPT_DESC" : tableItem14,

    "JOBCODE_DESCR" : tableItem15

};

guidelib.dataIntegrationUtils.executeOperation(operationInfo, inputs, outputs);     

}

else{}

However, if the user puts in new data to the search elements, the old data still shows aside from what is replaced. In the screenshot, the first search was for "Michael Smith" and returned 3 results. If I then search for "Peter Shin", one row is cleared, but the rest of the original data is there.

1830281_pastedImage_0.png

Is there a dataIntegrationUtils operation to clear all data from a table or reset it?

Thanks!

Replies

Avatar

Avatar
Establish
Community Manager
kautuk_sahni
Community Manager

Likes

1,198 likes

Total Posts

6,369 posts

Correct Reply

1,147 solutions
Top badges earned
Establish
Coach
Originator
Contributor 2
Contributor
View profile

Avatar
Establish
Community Manager
kautuk_sahni
Community Manager

Likes

1,198 likes

Total Posts

6,369 posts

Correct Reply

1,147 solutions
Top badges earned
Establish
Coach
Originator
Contributor 2
Contributor
View profile
kautuk_sahni
Community Manager

10-10-2019

Mayank Gandhi Any help here?

Avatar

Avatar
Ignite 5
Employee
workflowuser
Employee

Likes

136 likes

Total Posts

444 posts

Correct Reply

70 solutions
Top badges earned
Ignite 5
Ignite 3
Ignite 1
Give Back 50
Give Back 5
View profile

Avatar
Ignite 5
Employee
workflowuser
Employee

Likes

136 likes

Total Posts

444 posts

Correct Reply

70 solutions
Top badges earned
Ignite 5
Ignite 3
Ignite 1
Give Back 50
Give Back 5
View profile
workflowuser
Employee

10-10-2019

Let me look into this and get back

Avatar

Avatar
Springboard
Level 10
Mayank_Gandhi
Level 10

Likes

327 likes

Total Posts

1,150 posts

Correct Reply

185 solutions
Top badges earned
Springboard
Establish
Validate 1
Contributor 2
Ignite 5
View profile

Avatar
Springboard
Level 10
Mayank_Gandhi
Level 10

Likes

327 likes

Total Posts

1,150 posts

Correct Reply

185 solutions
Top badges earned
Springboard
Establish
Validate 1
Contributor 2
Ignite 5
View profile
Mayank_Gandhi
Level 10

10-10-2019

You can call table.resetData(); to reset the complete table.

Modify your code as per below script:

if ((txtFirstName.value === null) || (txtFirstName.value === "") || (txtFirstName.value).trim().length === 0) {

}

  else{

  table1570715554554.resetData();

 

}

 

var operationInfo = {

    "formDataModelId": "/content/dam/formsanddocuments-fdm/fdm2",

    "operationTitle": "get",

    "operationName": "get_15671949377350"

};

var inputs = {

    "agentID" : txtFirstName

};

var outputs = {

    "siteID" : tableItem11

};

guidelib.dataIntegrationUtils.executeOperation(operationInfo, inputs, outputs);    

Avatar

Avatar
Validate 10
Level 3
Christopher_Pa4
Level 3

Likes

16 likes

Total Posts

54 posts

Correct Reply

4 solutions
Top badges earned
Validate 10
Validate 1
Ignite 5
Ignite 3
Ignite 1
View profile

Avatar
Validate 10
Level 3
Christopher_Pa4
Level 3

Likes

16 likes

Total Posts

54 posts

Correct Reply

4 solutions
Top badges earned
Validate 10
Validate 1
Ignite 5
Ignite 3
Ignite 1
View profile
Christopher_Pa4
Level 3

10-10-2019

Thanks! We'll experiment with this and let you know if we get it working!

Avatar

Avatar
Boost 1
Level 2
sureshp23286254
Level 2

Like

1 like

Total Posts

20 posts

Correct Reply

1 solution
Top badges earned
Boost 1
Validate 1
Ignite 3
Ignite 1
Give Back
View profile

Avatar
Boost 1
Level 2
sureshp23286254
Level 2

Like

1 like

Total Posts

20 posts

Correct Reply

1 solution
Top badges earned
Boost 1
Validate 1
Ignite 3
Ignite 1
Give Back
View profile
sureshp23286254
Level 2

29-07-2020

Mayank,

  I have similar query but when i tried  table1570715554554.resetData(); it only cleared the rows and continue to see the dummy records. how to remove the blank rows? 

 

Also tried below solution but didn't work either.

 

while (table1585577511230._Row1.count > 1)

{

table1585577511230._Row1.removeInstance(0);

}

 

Do you have any other solution?

 

Thanks & Regards

     Suresh