tencent cloud

Performance Testing Service

Related Agreements
Service Level Agreement
Use Limits
Privacy Policy
Data Processing And Security Agreement
ドキュメントPerformance Testing Service

Item.delete

フォーカスモード
フォントサイズ
最終更新日: 2025-03-10 17:04:52
Item.delete marks the data row represented by this Item as deleted, and it will not be used during the execution of the current script.
datele(): void

Return

Type
Description
void
No content returned.

Usage Examples

Mark a row of data in the parameter file as deleted:
import dataset from 'pts/dataset';

export function setup() {
// Traverse the parameter file named 'test.csv'.
dataset.forEach('test.csv', (item) => {
// If the data value of the key 'key1' in the data row item is '1', mark it as deleted, and it will not be used during the execution of this script.
if (item.data.key1 === '1') {
item.delete();
}
});
}

export default function() {
// The data rows with 'key1' column having a value of '1' will not be accessed during the script execution.
const record = dataset.random('test.csv');
console.log(JSON.stringify(record));
}


ヘルプとサポート

この記事はお役に立ちましたか?

フィードバック