# Subscription_DeletedInstances
Gets all deleted subscription instances that you have access to.
Pass in the DateFrom and DateTo parameters to filter by deletion date.
## Documentation
Gets all deleted subscription instances that you have access to.
Pass in the DateFrom and DateTo parameters to filter by deletion date.
- Catalog: `Tixly`
- Schema: `Subscription`
This is a read-only table function. The Tixly API may not support changing the data or the Invantive UniversalSQL driver for Tixly does not cover it. In the latter case, please use the table NativePlatformScalarRequests to upload data to the Tixly API.
## Parameters of Table Function
The following parameters can be used to control the behaviour of the table function `Subscription_DeletedInstances`. A value must be provided at all times for required parameters, but optional parameters in general do not need to have a value and the execution will default to a pre-defined behaviour. Values can be specified by position and by name. In both cases, all parameters not specified will be evaluated using their default values.
Value specification by position is done by listing all values from the first to the last needed value. For example: a `select * from table(value1, value2, value3)` on a table with four parameters will use the default value for the fourth parameter and the specified values for the first three.
Value specification by name is done by listing all values that require a value. For example with `select * from table(name1 => value1, name3 => value3)` on the same table will use the default values for the second and fourth parameters and the specified values for the first and third.
| Name | Data Type | Required | Default Value | Documentation |
|---|:---:|:---:|:---:|---|
| `DateFrom` | `` | ☐ | | If set, only instances deleted after this date will be returned |
| `DateTo` | `` | ☐ | | If set, only instances deleted before this date will be returned |
## Columns of Table Function
The columns of the table function `Subscription_DeletedInstances` are shown below. Each column has an SQL data type.
| Name | Data Type | Label | Required | Documentation |
|---|:---:|---|:---:|---|
| `CreatedUTCUnix` | `int64` | | ☐ | The date and time in Unix time when the subscription was originally sold |
| `Created` | `datetime` | Created | ☐ | The date and time when the subscription was originally sold |
| `CustomerId` | `int32` | Customer ID | ☐ | The id of the customer |
| `Customer` | `varchar2` | | ☐ | The name of the customer |
| `DeletedAtUTCUnix` | `int64` | | ☐ | The date and time in Unix time when the subscription instance was deleted |
| `DeletedAt` | `datetime` | | ☐ | The date and time when the subscription instance was deleted |
| `Events` | `int32` | | ☐ | Total number of events in the subscription |
| `Name` | `varchar2` | Name | ☐ | The name of the subscription type |
| `OrderId` | `int32` | Order ID | ☐ | The id of the order that was deleted |
| `OrderUrl` | `varchar2` | | ☐ | The encrypted order id to be used in url's to create a receipt link |
| `OrganisationId` | `int32` | Organisation ID | ☐ | The id of the organisation that owns the subscription |
| `SubscriptionInstanceId` | `int32` | | ☐ | A unique id for the specific subscription instance |
| `SubscriptionTypeId` | `int32` | Subscription Type ID | ☐ | The id of the subscription type |
| `TicketTypeId` | `int32` | Ticket Type ID | ☐ | The id of the ticket type that is used in the subscription |
| `TicketType` | `varchar2` | Ticket Type | ☐ | Name of the ticket type that is used in the subscription |