Hi
I need to clear table 1100 — that is, delete all its values.
I tried running this QAction, but it didn't work.
1100 is table
1001 is parameter
1002 is parameter
1003 is parameter
1004 is parameter
#####################################
(This part of QAction delete table)
object[] columnClearInfo = { 1100, 1101, 1102, 1103, 1104 };
object[] columnClearValues = {
newobject[0], // PK
newobject[0], // UUID
newobject[0], // Name
newobject[0], // State
newobject[0], // Chunking
};
protocol.NotifyProtocol(220, columnClearInfo, columnClearValues);
#####################################
<Paramid="1101">
<Name>ServiceTableUUID</Name>
<Description>UID</Description>
<Type>read</Type>
<Interprete>
<RawType>other</RawType>
<Type>string</Type>
<LengthType>next param</LengthType>
</Interprete>
<Display>
<RTDisplay>true</RTDisplay>
</Display>
<Measurement>
<Type>string</Type>
</Measurement>
</Param>
<Paramid="1102">
<Name>ServiceTableService</Name>
<Description>Service Name</Description>
<Type>read</Type>
<Interprete>
<RawType>other</RawType>
<Type>string</Type>
<LengthType>next param</LengthType>
</Interprete>
<Display>
<RTDisplay>true</RTDisplay>
</Display>
<Measurement>
<Type>string</Type>
</Measurement>
</Param>
<Paramid="1103">
<Name>ServiceTableStateService</Name>
<Description>Service Status</Description>
<Type>read</Type>
<Interprete>
<RawType>other</RawType>
<Type>string</Type>
<LengthType>next param</LengthType>
</Interprete>
<Display>
<RTDisplay>true</RTDisplay>
</Display>
<Measurement>
<Type>string</Type>
</Measurement>
</Param>
<Paramid="1104">
<Name>ServiceTablechunk</Name>
<Description>Chunk</Description>
<Type>read</Type>
<Interprete>
<RawType>other</RawType>
<Type>string</Type>
<LengthType>next param</LengthType>
</Interprete>
<Display>
<RTDisplay>true</RTDisplay>
</Display>
<Measurement>
<Type>string</Type>
</Measurement>
</Param>
<Paramid="1100"trending="true">
<Name>ServiceTable</Name>
<Description>Table Of Services</Description>
<Type>array</Type>
<ArrayOptionsindex="0"options="key" >
<ColumnOptionidx="0"pid="1101"type="retrieved"options=";save" />
<ColumnOptionidx="1"pid="1102"type="retrieved"options=";save" />
<ColumnOptionidx="2"pid="1103"type="retrieved"options=";save" />
<ColumnOptionidx="3"pid="1104"type="retrieved"options=";save" />
</ArrayOptions>
<Information>
<Subtext>
<![CDATA[Table Of Services]]>
</Subtext>
</Information>
<Display>
<RTDisplay>true</RTDisplay>
<Positions>
<Position>
<Page>Services</Page>
<Column>0</Column>
<Row>0</Row>
</Position>
</Positions>
</Display>
<Measurement>
<Typeoptions="tab=columns:1101|0-1102|1-1103|2-1104|3,width:350-220-112-100,sort:STRING-STRING-STRING-STRING,lines:10,filter:true">table</Type>
</Measurement>
</Param>
Hi Jose,
ClearAllkeys as mentioned by Miguel should work but if it doesn't, could you give more clarity to the situation you are facing?
When do we want to clear the table? Perhaps we want to make the table volatile if we want to clear the table on restart?
Do we need to save all the table columns?
What are we doing to fill up the table? is the fillarray being done right after we do protocol.ClearAllKeys(1100)?

Hi Joshua,
I initially tried using protocol.ClearAllKeys(1100);, but it didn’t seem to work. Then I changed it to assign the result to an object like this:
object result = protocol.ClearAllKeys(1100);
and it started working. I'm not sure why storing the return value made a difference, but it resolved the issue.