A
A
artshelom2017-03-30 20:46:17
MongoDB
artshelom, 2017-03-30 20:46:17

How to make multiple collections of one class in mongodb??

Good evening professionals.

@Repository
public interface PointsRepository extends MongoRepository<Point, String>{
}

Here it searches only for the Point class in the collection with the same name, is it possible to add methods to access other collections with the same class without creating other interfaces or classes in this class

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
al_gon, 2017-03-30
@artshelom

If you use custom query then whatever.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question