# Vector database

**URL:** <https://forum.weaviate.io/t/vector-database/9937>\
**Category:** Support\
**Created:** [January 29, 2025, 9:46am UTC](https://forum.weaviate.io/t/vector-database/9937 "2025-01-29T09:46:56Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![DhanushKumar\_R](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/dhanushkumar_r/32/3310_2.png) [@DhanushKumar\_R](https://forum.weaviate.io/u/DhanushKumar_R)\
**Post date:** [January 29, 2025, 9:46am UTC](https://forum.weaviate.io/t/vector-database/9937/1 "2025-01-29T09:46:56Z")

</div>

Consider i have two files one for HR and another for credit cards ,I have to build a vector store for both them but separately ,like when I have ask a HR related query ,i goes to HR and fetch only from there ,it should not go to credit card.Will anyone please share the documents for this to work on it

---

<div class="post-metadata">

**Author:** ![DudaNogueira](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/dudanogueira/32/7846_2.png) [@DudaNogueira](https://forum.weaviate.io/u/DudaNogueira)\
**Post date:** [January 29, 2025, 10:33am UTC](https://forum.weaviate.io/t/vector-database/9937/2 "2025-01-29T10:33:07Z")

</div>

Hi!

Checkout this recipe we have using llamaindex:

> <https://github.com/weaviate/recipes/blob/main/integrations/llm-frameworks/llamaindex/sql-router-query-engine/sql-query-router.ipynb>

The llamaindex’s [RouterQueryEngine](https://docs.llamaindex.ai/en/stable/examples/query_engine/RouterQueryEngine/) will allow you to set up different indexes, and depending on the initial query, it will route to the most related one.

Do you think this helps?

Thanks!

---

<div class="post-metadata">

**Author:** ![DhanushKumar\_R](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/dhanushkumar_r/32/3310_2.png) [@DhanushKumar\_R](https://forum.weaviate.io/u/DhanushKumar_R)\
**Post date:** [January 29, 2025, 11:02am UTC](https://forum.weaviate.io/t/vector-database/9937/3 "2025-01-29T11:02:27Z")

</div>

Thanks for the reply,  
I am requesting any reference ,where i create two different collections for two different documents (i.e.)., HR document will store in separate vector store ,similarly credit card document will store in separate vector store ,  
how can i perform embedding on both the documents simulatenously and push it into weaviate under different collections .

---

<div class="post-metadata">

**Author:** ![DudaNogueira](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/dudanogueira/32/7846_2.png) [@DudaNogueira](https://forum.weaviate.io/u/DudaNogueira)\
**Post date:** [January 29, 2025, 7:11pm UTC](https://forum.weaviate.io/t/vector-database/9937/4 "2025-01-29T19:11:21Z")

</div>

Hi!

You can create the two collections, and define the vectorizer configurations for each.

Whenever you ingest content, Weaviate will vectorize it for you.

If you are using llamaindex, you can definie the collection name using a different `index_name`.

Let me know if that helps!

Thanks!

---

<div class="post-metadata">

**Author:** ![DhanushKumar\_R](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/dhanushkumar_r/32/3310_2.png) [@DhanushKumar\_R](https://forum.weaviate.io/u/DhanushKumar_R)\
**Post date:** [January 30, 2025, 4:39am UTC](https://forum.weaviate.io/t/vector-database/9937/5 "2025-01-30T04:39:53Z")

</div>

Thank you so much for your response ,May I have any references, please

---

<div class="post-metadata">

**Author:** ![DudaNogueira](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/dudanogueira/32/7846_2.png) [@DudaNogueira](https://forum.weaviate.io/u/DudaNogueira)\
**Post date:** [January 30, 2025, 1:38pm UTC](https://forum.weaviate.io/t/vector-database/9937/6 "2025-01-30T13:38:36Z")

</div>

Hi!

We have some recipes using llamaindex here:

> **[recipes/integrations/llm-frameworks/llamaindex at main · weaviate/recipes](https://github.com/weaviate/recipes/tree/main/integrations/llm-frameworks/llamaindex)**
>
> This repository shares end-to-end notebooks on how to use various Weaviate features and integrations! - weaviate/recipes

I have recently rewritten them to use the v4 client and integration, so they are up to date.

Here you can find a simple query engine:

> <https://github.com/weaviate/recipes/blob/main/integrations/llm-frameworks/llamaindex/simple-query-engine/simple-query-engine.ipynb>

For instance:

```python
# Let's name our index properly as BlogPost, as we will need it later.
vector_store = WeaviateVectorStore(
    weaviate_client=client, index_name="BlogPost"
)
storage_context = StorageContext.from_defaults(vector_store=vector_store)
index = VectorStoreIndex.from_documents(
    documents, storage_context=storage_context
)

```

This is how you can set the name of the collection (note the `index_name`).

Now this recipe, combined with the aforementioned example, can get you two indices, that you can feed to the query router as per the Query Router example.

Let me know if that helps.
