# Warehouse\_ID not working correctly

**URL:** <https://community.shiphero.com/t/warehouse-id-not-working-correctly/561>\
**Category:** GraphQL API\
**Created:** [July 2, 2020, 5:41pm UTC](https://community.shiphero.com/t/warehouse-id-not-working-correctly/561 "2020-07-02T17:41:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Devin\_Mabra](https://avatars.discourse-cdn.com/v4/letter/d/7cd45c/32.png) [@Devin\_Mabra](https://community.shiphero.com/u/Devin_Mabra)\
**Post date:** [July 2, 2020, 5:41pm UTC](https://community.shiphero.com/t/warehouse-id-not-working-correctly/561/1 "2020-07-02T17:41:49Z")

</div>

Hi,

I have the following query, which returns a warehouse\_id that is not “V2FyZWhvdXNlOjEwMDg3”, please advise:

```
query {
  orders(warehouse_id:"V2FyZWhvdXNlOjEwMDg3") {
request_id
complexity
data(first: 1) {
  edges {
    node {
      legacy_id
      order_number
      line_items {
        edges {
          node {
            warehouse
            warehouse_id
          }
        }
        
      }
    }
  }
pageInfo {
  hasNextPage
  hasPreviousPage
}
}
  }
}

```

**Returns:**

```
{
  "data": {
"orders": {
  "request_id": "5efe19a24501192ab3bd9db8",
  "complexity": 101,
  "data": {
    "edges": [
      {
        "node": {
          "legacy_id": 123389541,
          "order_number": "#DC-1088",
          "line_items": {
            "edges": [
              {
                "node": {
                  "warehouse": "Primary",
                  "warehouse_id": "V2FyZWhvdXNlOjU4OTg="
                }
              },
              {
                "node": {
                  "warehouse": "Primary",
                  "warehouse_id": "V2FyZWhvdXNlOjU4OTg="
                }
              }
            ]
          }
        }
      }
    ],
    "pageInfo": {
      "hasNextPage": true,
      "hasPreviousPage": false
    }
  }
}
  }
}
```

---

<div class="post-metadata">

**Author:** ![Devin\_Mabra](https://avatars.discourse-cdn.com/v4/letter/d/7cd45c/32.png) [@Devin\_Mabra](https://community.shiphero.com/u/Devin_Mabra)\
**Post date:** [July 2, 2020, 5:42pm UTC](https://community.shiphero.com/t/warehouse-id-not-working-correctly/561/2 "2020-07-02T17:42:32Z")

</div>

Should note this is in our staging environment

---

<div class="post-metadata">

**Author:** ![tomasw](https://sea2.discourse-cdn.com/flex020/user_avatar/community.shiphero.com/tomasw/32/248_2.png) [@tomasw](https://community.shiphero.com/u/tomasw)\
**Post date:** [July 7, 2020, 12:32pm UTC](https://community.shiphero.com/t/warehouse-id-not-working-correctly/561/3 "2020-07-07T12:32:49Z")

</div>

Hi @Devin_Mabra  
I apologize for the delay in my response!  
That seems to be because that is the warehouse when the order was imported, then it got changed because of the Custom Status.  
And the line items might also be different because it’s a multi-warehouse account, and they might be allocated/shipped from different warehouses  
Line items might differ from the order warehouse\_is because of this reason, that is could be allocated or shipped from different warehouses (for example when the order has Allow Split) or you have some Multi Warehouse allocation rules set up as well.  
Let me know if this doesn’t help.  
Thanks in advance!  
Tom
