# Pinecone basic sample is not returning complete result

**URL:** https://community.pinecone.io/t/pinecone-basic-sample-is-not-returning-complete-result/3967
**Category:** Support
**Created:** [January 4, 2024, 6:09am UTC](https://community.pinecone.io/t/pinecone-basic-sample-is-not-returning-complete-result/3967 "2024-01-04T06:09:49Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![jaysharma391](https://sea2.discourse-cdn.com/flex020/user_avatar/community.pinecone.io/jaysharma391/32/690_2.png) [@jaysharma391](https://community.pinecone.io/u/jaysharma391)
#### Post date: [January 4, 2024, 6:09am UTC](https://community.pinecone.io/t/pinecone-basic-sample-is-not-returning-complete-result/3967/1 "2024-01-04T06:09:49Z")

</div>

Hello,  
I am following guide as a starter of pinecone:

> [Quickstart](https://docs.pinecone.io/docs/quickstart)

It is able to create index (can see it on dashboard also), insert data and query but in response of query it is not showing any matches:

> query\_response: {‘matches’: , ‘namespace’: ‘ns1’}

Request:

> index.query( namespace=“ns1”, vector=[0.3, 0.3, 0.3, 0.3, 0.3, 0.3, 0.3, 0.3], top\_k=3, include\_values=True )

_Complete sample:_

> import pinecone
> 
> pinecone.init(api\_key=“xxxx”, environment=“gcp-starter”)
> 
> create\_index = pinecone.create\_index(“quickstart”, dimension=8, metric=“euclidean”)
> 
> describe\_index = pinecone.describe\_index(“quickstart”)
> 
> print("describe\_index: ", describe\_index)
> 
> index = pinecone.Index(“quickstart”)
> 
> describe\_index\_stats = index.describe\_index\_stats()
> 
> print("describe\_index\_stats: ", describe\_index)
> 
> upsert\_response = index.upsert(
> 
> vectors=[
> 
> {“id”: “vec1”, “values”: [0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1]},
> 
> {“id”: “vec2”, “values”: [0.2, 0.2, 0.2, 0.2, 0.2, 0.2, 0.2, 0.2]},
> 
> {“id”: “vec3”, “values”: [0.3, 0.3, 0.3, 0.3, 0.3, 0.3, 0.3, 0.3]},
> 
> {“id”: “vec4”, “values”: [0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4]}
> 
> ],
> 
> namespace=“ns1”
> 
> )
> 
> print("upsert\_response 1: ", upsert\_response)
> 
> upsert\_response = index.upsert(
> 
> vectors=[
> 
> {“id”: “vec5”, “values”: [0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5]},
> 
> {“id”: “vec6”, “values”: [0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6]},
> 
> {“id”: “vec7”, “values”: [0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7]},
> 
> {“id”: “vec8”, “values”: [0.8, 0.8, 0.8, 0.8, 0.8, 0.8, 0.8, 0.8]}
> 
> ],
> 
> namespace=“ns2”
> 
> )
> 
> print("upsert\_response 2: ", upsert\_response)
> 
> describe\_index\_stats = index.describe\_index\_stats()
> 
> print("describe\_index\_stats: ", describe\_index)
> 
> query\_response = index.query(
> 
> vector=[0.3, 0.3, 0.3, 0.3, 0.3, 0.3, 0.3, 0.3],
> 
> top\_k=3,
> 
> namespace=“ns1”,
> 
> include\_values=True,
> 
> include\_metadata=True
> 
> )
> 
> print("query\_response: ", query\_response)
> 
> del\_response = pinecone.delete\_index(“quickstart”)
> 
> print("del\_response: ", del\_response)

---

<div class="post-metadata">

### Author: ![jaysharma391](https://sea2.discourse-cdn.com/flex020/user_avatar/community.pinecone.io/jaysharma391/32/690_2.png) [@jaysharma391](https://community.pinecone.io/u/jaysharma391)
#### Post date: [January 5, 2024, 5:02am UTC](https://community.pinecone.io/t/pinecone-basic-sample-is-not-returning-complete-result/3967/2 "2024-01-05T05:02:51Z")

</div>

Any suggestion if I missed anything in sample app ?

---

<div class="post-metadata">

### Author: ![zeke](https://sea2.discourse-cdn.com/flex020/user_avatar/community.pinecone.io/zeke/32/4257_2.png) [@zeke](https://community.pinecone.io/u/zeke)
#### Post date: [January 16, 2024, 10:35pm UTC](https://community.pinecone.io/t/pinecone-basic-sample-is-not-returning-complete-result/3967/3 "2024-01-16T22:35:58Z")

</div>

HI @jaysharma391, are you still experiencing this same behavior if you try to create and query the index?

If so, please share where/how you are running the above code. For example, are you using a Colab notebook or running a single Python file?

Additionally, I encourage you to check out our new [Quickstart](https://docs.pinecone.io/docs/quickstart) guide that shows how to connect to the [new API](https://docs.pinecone.io/docs/new-api) that accompanied today’s release of our [serverless architecture](https://www.pinecone.io/blog/serverless/?utm_content=278636209&utm_medium=social&utm_source=linkedin&hss_channel=lcp-20299330).

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex020/uploads/pinecone/original/1X/d16664eba369eeee623700cf12feab5562b37eaf.jpeg) [@system](https://community.pinecone.io/u/system)
#### Post date: [January 30, 2024, 10:36pm UTC](https://community.pinecone.io/t/pinecone-basic-sample-is-not-returning-complete-result/3967/4 "2024-01-30T22:36:45Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
