We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 44234
    • 219 Posts
    Hi,

    I am trying to search a custom table using simple search. I have tried to follow the tutorial in the docs but cant seem to get it to work. I think the issue is the joinCriteria, but I dont know how to resolve it.

    My custom package is built and functioning correctly.

    The table in question has 4 columns labeled: isbn, title, stations and page. There are around 9500 rows.

    I want to search the station column and return any resources using the title column. The titles match the longtitle in my modx resources.

    My code:
    &customPackages=`IndexToStations:station:its:{core_path}foo/:IndexToStations.title = modResource.longtitle`


    When I search a value the page starts processing but does nothing until the site/browser grinds to a halt. There is no error in the modx log.

    Can anyone give me some guidance?

    Many Thanks

    This question has been answered by davidpede. See the first response.

      Find me on Twitter, GitHub or Google+
    • discuss.answer
      • 44234
      • 219 Posts
      I managed to resolve this. The problem was that I had forgotten to add an index for the title column. Once I added this to the database and the package schema, it worked perfectly.
        Find me on Twitter, GitHub or Google+
        • 44231
        • 126 Posts
        hi I know this thread is a long time ago
        I having a problem with simple search I need a urgent project that needing a search engine
        just a simple search engine just type the keyword of the search object then show result to the page

        Do you think you can give me a hand over this manner!?

        thanks