0

what changes i have to do in this query to searching. I'm working on open-edx project with django (python) and i want to implement elastic search in this project. I want to search courses by it's incomplete name like if there Robotics named courses will be find out if i only search ro, rob, robo, robot etc.... please help me !

    enter: if search_term:
            filters = True
            search_result = searcher.search(search_term,field_dictionary=match_field_dict,size=20,from_=20*(int(page) if page else 0))
        else:
            search_result = searcher.search(field_dictionary=match_field_dict,size=20,from_=20*(int(page) if page else 0))

api.py file

result1

result2

Sagar Patel
  • 4,993
  • 1
  • 8
  • 19
  • this might help https://stackoverflow.com/questions/52531342/contains-query-or-partial-matching-in-elasticsearch – Hemal Patel Oct 10 '22 at 11:47

0 Answers0