# Equals

> Compare two queries for equality.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Entities](/engine/7000.0/script-reference/unity/entities.md)
* **Assembly:** UnityEngine.EntitiesModule

## Equals(EntityQuery)

Compare two queries for equality.

```csharp
public bool Equals(EntityQuery other)
```

### Parameters

**** (\[EntityQuery]\(/engine/7000.0/script-reference/unity/entities/entityquery)): The other query

### Returns

| Type                                                          | Description                                              |
| ------------------------------------------------------------- | -------------------------------------------------------- |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if the two queries are equivalent, or false if not. |

## Equals(Object)

Compare a query to another object (assumed to be a boxed EntityQuery).

```csharp
[ExcludeFromBurstCompatTesting("Takes managed object")]
public override bool Equals(object obj)
```

### Parameters

**** (\[Object]\(https\://learn.microsoft.com/dotnet/api/system.object)): The other query.

### Returns

| Type                                                          | Description                                            |
| ------------------------------------------------------------- | ------------------------------------------------------ |
| [bool](https://learn.microsoft.com/dotnet/api/system.boolean) | True if `obj` is an equivalent query, or false if not. |
