com.mongodb.util.JSONParseException: db.UserFactualContent.find( {'$or': [ {'NAME':{'$regex':'(?i)Bangalore'}}, {'DESCRIPTION':{'$regex':'(?i)Bangalore'}}],'$and':[{'FLAG':'public' }]},{ 'DESCRIPTION': 1,'NAME': 1,'TOKEN':1}, '$orderby' : { 'clicks' : -1 } } ) ^

hibernate.org | 7 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Hibernate Community • View topic - Exception in sort query

    hibernate.org | 7 months ago
    com.mongodb.util.JSONParseException: db.UserFactualContent.find( {'$or': [ {'NAME':{'$regex':'(?i)Bangalore'}}, {'DESCRIPTION':{'$regex':'(?i)Bangalore'}}],'$and':[{'FLAG':'public' }]},{ 'DESCRIPTION': 1,'NAME': 1,'TOKEN':1}, '$orderby' : { 'clicks' : -1 } } ) ^
  2. 0

    From the [forum|https://forum.hibernate.org/viewtopic.php?f=31&t=1039404]: Table names with a dot cause a parsing error in queries: {code} com.mongodb.util.JSONParseException: db.test.myTest.count() ^ at com.mongodb.util.JSONParser.parse(JSON.java:208) at com.mongodb.util.JSONParser.parse(JSON.java:155) at com.mongodb.util.JSON.parse(JSON.java:93) at com.mongodb.util.JSON.parse(JSON.java:74) at org.hibernate.ogm.datastore.mongodb.query.parsing.nativequery.impl.MongoDBQueryDescriptorBuilder.build(MongoDBQueryDescriptorBuilder.java:48) at org.hibernate.ogm.datastore.mongodb.MongoDBDialect.parseNativeQuery(MongoDBDialect.java:725) at org.hibernate.ogm.datastore.mongodb.MongoDBDialect.parseNativeQuery(MongoDBDialect.java:128) at org.hibernate.ogm.dialect.impl.ForwardingGridDialect.parseNativeQuery(ForwardingGridDialect.java:191) at org.hibernate.ogm.query.impl.NativeNoSqlQueryInterpreter.getCustomQuery(NativeNoSqlQueryInterpreter.java:50) at org.hibernate.ogm.query.impl.NativeNoSqlQueryInterpreter.createQueryPlan(NativeNoSqlQueryInterpreter.java:45) at org.hibernate.engine.query.spi.QueryPlanCache.getNativeSQLQueryPlan(QueryPlanCache.java:226) at org.hibernate.ogm.hibernatecore.impl.OgmSessionImpl.list(OgmSessionImpl.java:307) at org.hibernate.ogm.query.impl.NoSQLQueryImpl.list(NoSQLQueryImpl.java:130) at org.hibernate.jpa.internal.QueryImpl.list(QueryImpl.java:573) at org.hibernate.jpa.internal.QueryImpl.getSingleResult(QueryImpl.java:495) {code}

    Hibernate JIRA | 2 years ago | Gunnar Morling
    com.mongodb.util.JSONParseException: db.test.myTest.count() ^
  3. 0

    com.mongodb.util.JSONParseException

    GitHub | 4 years ago | ignatov
    com.mongodb.util.JSONParseException: mydb.things.find(); ^
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    mongodb sink exception

    GitHub | 3 years ago | sathiyas
    org.springframework.messaging.MessageHandlingException: error occurred in message handler [org.springframework.integration.mongodb.outbound.MongoDbStoringMessageHandler#0]

    1 unregistered visitors
    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. com.mongodb.util.JSONParseException

      db.UserFactualContent.find( {'$or': [ {'NAME':{'$regex':'(?i)Bangalore'}}, {'DESCRIPTION':{'$regex':'(?i)Bangalore'}}],'$and':[{'FLAG':'public' }]},{ 'DESCRIPTION': 1,'NAME': 1,'TOKEN':1}, '$orderby' : { 'clicks' : -1 } } ) ^

      at com.mongodb.util.JSONParser.parse()
    2. MongoDB Java Driver
      JSON.parse
      1. com.mongodb.util.JSONParser.parse(JSON.java:230)
      2. com.mongodb.util.JSONParser.parse(JSON.java:155)
      3. com.mongodb.util.JSON.parse(JSON.java:92)
      4. com.mongodb.util.JSON.parse(JSON.java:73)
      4 frames
    3. org.hibernate.ogm
      MongoDBDialect.parseNativeQuery
      1. org.hibernate.ogm.datastore.mongodb.query.parsing.nativequery.impl.MongoDBQueryDescriptorBuilder.build(MongoDBQueryDescriptorBuilder.java:71)
      2. org.hibernate.ogm.datastore.mongodb.MongoDBDialect.parseNativeQuery(MongoDBDialect.java:866)
      3. org.hibernate.ogm.datastore.mongodb.MongoDBDialect.parseNativeQuery(MongoDBDialect.java:143)
      3 frames
    4. Hibernate Object Grid Mapper
      NativeNoSqlQueryInterpreter.createQueryPlan
      1. org.hibernate.ogm.dialect.impl.ForwardingGridDialect.parseNativeQuery(ForwardingGridDialect.java:200)
      2. org.hibernate.ogm.query.impl.NativeNoSqlQueryInterpreter.getCustomQuery(NativeNoSqlQueryInterpreter.java:50)
      3. org.hibernate.ogm.query.impl.NativeNoSqlQueryInterpreter.createQueryPlan(NativeNoSqlQueryInterpreter.java:45)
      3 frames
    5. Hibernate
      QueryPlanCache.getNativeSQLQueryPlan
      1. org.hibernate.engine.query.spi.QueryPlanCache.getNativeSQLQueryPlan(QueryPlanCache.java:210)
      1 frame
    6. Hibernate Object Grid Mapper
      NoSQLQueryImpl.list
      1. org.hibernate.ogm.hibernatecore.impl.OgmSessionImpl.list(OgmSessionImpl.java:301)
      2. org.hibernate.ogm.query.impl.NoSQLQueryImpl.list(NoSQLQueryImpl.java:130)
      2 frames
    7. org.hibernate.jpa
      QueryImpl.getResultList
      1. org.hibernate.jpa.internal.QueryImpl.list(QueryImpl.java:593)
      2. org.hibernate.jpa.internal.QueryImpl.getResultList(QueryImpl.java:470)
      2 frames