LogoLogo
2.10.2
2.10.2
  • Introduction
  • Getting started
    • Installation
      • On-premises
      • Azure Market Place
      • AWS Market Place
    • Introduction
      • Reports
      • Services
    • Tutorials
      • Amazon AWS CUR
      • Amazon AWS CUR (Athena)
      • Azure Stack
      • Azure EA
      • Azure CSP
      • Google Cloud
      • VMware vCloud
      • VMware vCenter
    • Releases
      • Upgrading to version 2
      • Archive
  • Reports
    • Accounts
    • Services
    • Summary
    • Budget
  • Services
    • Manage
    • Rates
    • Adjustments
  • ACCOUNTS
    • Budget management
  • Data pipelines
    • Extract
      • Configuration
      • Templates
      • Script basics
      • Parslets
      • Language
        • aws_sign_string
        • basename
        • buffer
        • csv
        • clear
        • discard
        • encode
        • encrypt
        • escape
        • exit_loop
        • foreach
        • generate_jwt
        • get_last_day_of
        • gosub
        • gunzip
        • hash
        • http
        • if
        • json
        • loglevel
        • loop
        • match
        • pause
        • print
        • return
        • save
        • set
        • subroutine
        • terminate
        • unzip
        • uri
        • var
    • Transform
      • Transform Preview
      • Configuration
      • Language
        • aggregate
        • append
        • calculate
        • capitalise
        • convert
        • copy
        • correlate
        • create
        • default
        • delete
        • export
        • finish
        • if
        • import
        • include
        • lowercase
        • normalise
        • option
        • rename
        • replace
        • round
        • service
        • services
        • set
        • split
        • terminate
        • timecolumns
        • timerender
        • timestamp
        • update_service
        • uppercase
        • var
        • where
    • Datasets
    • Lookups
    • Metadata
    • Reports
    • Workflows
  • Administration
    • User management
      • Users
      • Groups
    • Settings
  • Advanced
    • Integrate
      • GUI automation
        • Examples
      • API docs
      • Single Sign On
        • Azure-AD
        • Auth0
        • LDAP
    • Digging deeper
      • Transformer datadate
      • Dataset lifecycle
      • Directories
      • Databases
Powered by GitBook
On this page
  • Overview
  • Syntax
  • Details
  • Deleting columns
  • Deleting blank columns
  • Deleting rows
  • Deleting a DSET
  • Examples

Was this helpful?

Export as PDF
  1. Data pipelines
  2. Transform
  3. Language

delete

Overview

The delete statement is used to delete one or more columns or rows from one or more DSETs.

Syntax

delete columns [except]ColName1 [... ColNameN]

delete blankcolumns

delete rows

delete dsetdset_id

Details

Deleting columns

The list of column names following the initial delete columns statement may be used in one of two ways:

  1. The columns listed will be deleted

  2. All columns except those listed will be deleted

Which method to use is determined by the presence (or otherwise) of the except keyword:

delete columns One Two Three         # Delete the listed columns
delete columns except One Two Three  # Delete all but the listed columns

When using the except keyword, all column names following it must belong to the same DSET

It is not possible to delete a column from a DSET which only contains a single column. When deleting a column, the memory used to index it, along with the memory used to store the contents of its cells is released. This may be useful in situations where memory is limited.

Deleting unwanted columns early in a Transcript task will also increase the the performance of many subsequent operations performed by the task.

The second keyword may be column instead of columns. Either way, the statement behaves identically.

Deleting blank columns

The delete blankcolumns statement will delete columns that only contain blank values from the default DSET.

It is not possible to completely empty a DSET using delete blankcolumns. In the event that the last remaining column in a DSET is blank then it will not be deleted.

Deleting rows

Either delete rows or delete row may be used (both variations work in an identical manner)

Deleting a DSET

It is not possible to delete the default DSET.

Examples

Delete the column temp from the default DSET and the column Interim from the azure.Usage DSET: delete columns temp azure.Usage.Interim

Delete any columns in the default DSET that have no values in any rows: delete blankcolumns

Delete all rows where the VMID is 1234

where ([VMID] == 1234) {
    delete rows
}

Delete the DSET azure.rates delete dset azure.rates

PreviousdefaultNextexport

Last updated 5 years ago

Was this helpful?

In order to delete rows from a DSET a local filter must be in effect. A local filter is created using the statement.

When used within the body of a statement, delete rows will delete all rows in the DSET associated with the local filter where the condition is true. For more information on conditions, please refer to the article.

The delete dset statement can be used to remove a DSET from memory. This may be useful in cases where a DSET is no longer required, for example after it has been used to enrich another DSET via the statement.

where
where
where
correlate