Search on other field

QuestionsSearch on other field
Gurdeep Sembi asked 7 years ago

Hi Abu,

Using the inline search, is it possible to show the search results based on the values in a hidden column?

I was thinking there might be something similar to $col["sortname"] for the search?

Thanks

1 Answers
Abu Ghufran answered 7 years ago

You can use dbname to different field which you need to search on, you can use any field with any sql expression.
e.g.
$col["dbname"] = "date_format(invdate,'%b %d, %Y')";

With this, when you search on that column, it will make sql like WHERE date_format(invdate,'%b %d, %Y') = '<your-input>';

Your Answer

0 + 1 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate it.

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?