Search multiple field on one line

Discussions relating to plugin development, and the Jiwa API.

Search multiple field on one line

Postby Ernst » Fri Aug 25, 2017 3:33 pm

Has anybody done or can help with multiple fields on one line. We are looking for something similar to using the three search lines with and AND,but for speed of use just want to type it all on the first line.

So in the demo for example going to inventory search, and putting "red shirt" in the description will give you all the red shirts. The same as putting red on the first line, and then shirt on the second line.

The Like statement allows us to do red%shirt but this would only work if the first word came first.

Apparently the old Clear system did this nicely, so we would like to match it.

Cheers,
User avatar
Ernst
Kohai
Kohai
 
Posts: 219
Joined: Tue Feb 19, 2008 3:43 pm
Topics Solved: 12

Re: Search multiple field on one line

Postby Mike.Sheen » Sat Aug 26, 2017 7:39 pm

Hi Ernst,

To make this clear, you want to be able to type into a search field in a Jiwa search dialog the following:

Red shirt

And it to return results where the field contains the text Red AND shirt?

Mike
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Overflow Error
Overflow Error
 
Posts: 2444
Joined: Tue Feb 12, 2008 11:12 am
Location: Perth, Republic of Western Australia
Topics Solved: 756

Re: Search multiple field on one line

Postby Ernst » Fri Sep 08, 2017 10:33 am

Hi Mike,

Yip thats exactly it, We would like to just put in a string of words on the first line, like a google search, and see all the words with AND between them.
Is there a way to change the way the search finds things.

Can think of a number of clients who would find this really usefull.

Thx,
User avatar
Ernst
Kohai
Kohai
 
Posts: 219
Joined: Tue Feb 19, 2008 3:43 pm
Topics Solved: 12

Re: Search multiple field on one line

Postby Ernst » Thu Sep 21, 2017 11:56 am

Hi Mike,
Any update on if this will be possible?
Thx,
User avatar
Ernst
Kohai
Kohai
 
Posts: 219
Joined: Tue Feb 19, 2008 3:43 pm
Topics Solved: 12

Re: Search multiple field on one line

Postby Mike.Sheen » Thu Sep 21, 2017 6:39 pm

Ernst wrote:Hi Mike,
Any update on if this will be possible?
Thx,


Sorry, Ernst - haven't had a chance. I'll spend a few minutes on it once 7.1 is released.

Mike
Mike Sheen
Chief Software Engineer
Jiwa Financials

If I do answer your question to your satisfaction, please mark it as the post solving the topic so others with the same issue can readily identify the solution
User avatar
Mike.Sheen
Overflow Error
Overflow Error
 
Posts: 2444
Joined: Tue Feb 12, 2008 11:12 am
Location: Perth, Republic of Western Australia
Topics Solved: 756

Re: Search multiple field on one line

Postby Ernst » Fri Sep 22, 2017 12:35 pm

Brilliant Thanks
User avatar
Ernst
Kohai
Kohai
 
Posts: 219
Joined: Tue Feb 19, 2008 3:43 pm
Topics Solved: 12

Re: Search multiple field on one line

Postby Scott.Pearce » Fri Sep 22, 2017 5:07 pm

I had a quick look at this. It appears to me that it's not possible. *Maybe* via some ugly string manipulation. To that end, I'm going to add some events into the various search functions that will allow a plugin to more easily and robustly hook in and manipulate behaviour. These events will of course be in 7.1 and later.
Scott Pearce
Senior Analyst/Programmer
Jiwa Financials
User avatar
Scott.Pearce
Senpai
Senpai
 
Posts: 742
Joined: Tue Feb 12, 2008 11:27 am
Location: New South Wales, Australia
Topics Solved: 221

Re: Search multiple field on one line

Postby perry » Thu Sep 28, 2017 2:46 pm

Hi Scott,

Do you think using full text search on SQL would work?

select * from vIN_Main_Search
where contains(Description,'"parts*" OR "computer*" )

I would create an index view (avoid changing standard table definitions), then fulltext catalog on the description field.
Perry Ma
S. Programmer
Lonicera Pty Ltd
http://www.lonicera.com.au
perry
Frequent Contributor
Frequent Contributor
 
Posts: 173
Joined: Mon Oct 27, 2008 2:26 pm
Topics Solved: 15

Re: Search multiple field on one line

Postby Ernst » Fri Sep 29, 2017 1:16 pm

Description would have to be full text indexed. To use that.
If we could split the search box into 3 using the space between the search words, and have 3 AND Like %Text%, that would work.

But how do we modify the where clause from our plugin?
User avatar
Ernst
Kohai
Kohai
 
Posts: 219
Joined: Tue Feb 19, 2008 3:43 pm
Topics Solved: 12

Re: Search multiple field on one line

Postby Ernst » Fri Oct 13, 2017 9:56 am

Hi Mike/ Scott,

Now that 7.01 is out, any more thought on this one.

Was looking at viewtopic.php?f=26&t=504&p=1699&hilit=search#p1699

And wondering if it is possible to get the entered field, and build our own "Where" clause.

Thanks,
User avatar
Ernst
Kohai
Kohai
 
Posts: 219
Joined: Tue Feb 19, 2008 3:43 pm
Topics Solved: 12

Next

Return to Technical and or Programming

Who is online

Users browsing this forum: No registered users and 15 guests

cron