> ## Documentation Index
> Fetch the complete documentation index at: https://www.nestjs-query.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# v0.14.x to v0.15.x

> In the  the cursor connection type was updated to allow for enabling a  field. When enabling this field  needed to explicitly name each connection type to allow each relation connection to independently enable the  field.

In previous versions of `nestjs-query` the connection type was shared between all instances which caused the totalCount field to not always be exposed. In `v0.15.x` all instances of a connection are uniquely named.

For example, suppose the following DTOS.

> [tab] todo-item.dto.ts
>
> ```ts todo-item.dto.ts theme={null}
> import { FilterableField, Connection } from '@ptc-org/nestjs-query-graphql';
> import { ObjectType, ID, GraphQLISODateTime } from '@nestjs/graphql';
> import { SubTaskDTO } from '../../sub-task/dto/sub-task.dto';
>
> @ObjectType('TodoItem')
> @Connection('subTasks', () => SubTaskDTO, { enableTotalCount: true })
> export class TodoItemDTO {
>
>   @FilterableField(() => ID)
>   id!: number;
>
>   @FilterableField()
>   title!: string;
>
>   @FilterableField({ nullable: true })
>   description?: string;
>
>   @FilterableField()
>   completed!: boolean;
>
>   @FilterableField(() => GraphQLISODateTime)
>   created!: Date;
>
>   @FilterableField(() => GraphQLISODateTime)
>   updated!: Date;
>
>   @FilterableField()
>   priority!: number;
> }
> ```

> [tab] sub-task.dto.ts
>
> ```ts sub-task.dto.ts theme={null}
> import { FilterableField, Relation } from '@ptc-org/nestjs-query-graphql';
> import { ObjectType, ID, GraphQLISODateTime } from '@nestjs/graphql';
> import { TodoItemDTO } from '../../todo-item/dto/todo-item.dto';
>
> @ObjectType('SubTask')
> @Relation('todoItem', () => TodoItemDTO, { disableRemove: true })
> export class SubTaskDTO {
>
>   @FilterableField(() => ID)
>   id!: number;
>
>   @FilterableField()
>   title!: string;
>
>   @FilterableField({ nullable: true })
>   description?: string;
>
>   @FilterableField()
>   completed!: boolean;
>
>   @FilterableField(() => GraphQLISODateTime)
>   created!: Date;
>
>   @FilterableField(() => GraphQLISODateTime)
>   updated!: Date;
>
>   @FilterableField()
>   todoItemId!: string;
> }
> ```

In previous versions the generated graphql would have been

```graphql theme={null}
type TodoItem {
  id: ID!
  title: String!
  description: String
  completed: Boolean!
  created: DateTime!
  updated: DateTime!
  age: Float!
  priority: Float!
  subTasks(paging: CursorPaging = { first: 10 }, filter: SubTaskFilter = {}, sorting: [SubTaskSort!] = []): SubTaskConnection!
}
type SubTaskConnection {
  pageInfo: PageInfo!
  edges: [SubTaskEdge!]!
}
```

In the latest version the relation gets its own connection type.

```graphql theme={null}
type TodoItem {
  id: ID!
  title: String!
  description: String
  completed: Boolean!
  created: DateTime!
  updated: DateTime!
  age: Float!
  priority: Float!
  subTasks(
    paging: CursorPaging = { first: 10 }
    filter: SubTaskFilter = {}
    sorting: [SubTaskSort!] = []
  ): TodoItemSubTasksConnection!
}
type TodoItemSubTasksConnection {
  pageInfo: PageInfo!
  edges: [SubTaskEdge!]!
  totalCount: Int!
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.