# Is SetOverride-like behavior (sphinx) supported?

**URL:** <https://discuss.elastic.co/t/is-setoverride-like-behavior-sphinx-supported/3627>\
**Category:** Elasticsearch\
**Created:** [December 4, 2010, 7:27pm UTC](https://discuss.elastic.co/t/is-setoverride-like-behavior-sphinx-supported/3627 "2010-12-04T19:27:26Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![brandonlee](https://avatars.discourse-cdn.com/v4/letter/b/ecd19e/32.png) [@brandonlee](https://discuss.elastic.co/u/brandonlee)\
**Post date:** [December 4, 2010, 7:27pm UTC](https://discuss.elastic.co/t/is-setoverride-like-behavior-sphinx-supported/3627/1 "2010-12-04T19:27:26Z")

</div>

See [http://www.sphinxsearch.com/docs/current.html#api-func-setoverride](http://www.sphinxsearch.com/docs/current.html#api-func-setoverride)

---

<div class="post-metadata">

**Author:** ![Lukas\_Vlcek1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lukas_vlcek1/32/819_2.png) [@Lukas\_Vlcek1](https://discuss.elastic.co/u/Lukas_Vlcek1)\
**Post date:** [December 4, 2010, 7:50pm UTC](https://discuss.elastic.co/t/is-setoverride-like-behavior-sphinx-supported/3627/2 "2010-12-04T19:50:34Z")

</div>

Hi,

I am not familiar with Sphinx but doesn't the ES custom score scripting  
sound interesting?  
[http://www.elasticsearch.com/docs/elasticsearch/rest\_api/query\_dsl/custom\_score\_query/](http://www.elasticsearch.com/docs/elasticsearch/rest_api/query_dsl/custom_score_query/)

[http://www.elasticsearch.com/docs/elasticsearch/rest\_api/query\_dsl/custom\_score\_query/](http://www.elasticsearch.com/docs/elasticsearch/rest_api/query_dsl/custom_score_query/)  
Regards,  
Lukas

On Sat, Dec 4, 2010 at 8:27 PM, brandonlee [mluggy@gmail.com](mailto:mluggy@gmail.com) wrote:

> See [Sphinx | Open Source Search Server](http://www.sphinxsearch.com/docs/current.html#api-func-setoverride)

---

<div class="post-metadata">

**Author:** ![brandonlee](https://avatars.discourse-cdn.com/v4/letter/b/ecd19e/32.png) [@brandonlee](https://discuss.elastic.co/u/brandonlee)\
**Post date:** [December 4, 2010, 8:50pm UTC](https://discuss.elastic.co/t/is-setoverride-like-behavior-sphinx-supported/3627/3 "2010-12-04T20:50:49Z")

</div>

It does sounds interesting but will require me to store all of the  
values I want to override with inside ES, whereas Sphinx lets you load  
those values dynamically and externally...

On Dec 4, 9:50 pm, Lukáš Vlček [lukas.vl...@gmail.com](mailto:lukas.vl...@gmail.com) wrote:

> Hi,
> 
> I am not familiar with Sphinx but doesn't the ES custom score scripting  
> sound interesting?[http://www.elasticsearch.com/docs/elasticsearch/rest\_api/query\_dsl/cu](http://www.elasticsearch.com/docs/elasticsearch/rest_api/query_dsl/cu)...
> 
> [http://www.elasticsearch.com/docs/elasticsearch/rest\_api/query\_dsl/cu...](http://www.elasticsearch.com/docs/elasticsearch/rest_api/query_dsl/cu...)  
> Regards,  
> Lukas
> 
> On Sat, Dec 4, 2010 at 8:27 PM, brandonlee [mlu...@gmail.com](mailto:mlu...@gmail.com) wrote:
> 
> > Seehttp://www.sphinxsearch.com/docs/current.html#api-func-setoverride

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [December 4, 2010, 8:54pm UTC](https://discuss.elastic.co/t/is-setoverride-like-behavior-sphinx-supported/3627/4 "2010-12-04T20:54:59Z")

</div>

Note that the script itself is driven by you, the user, so you can have whatever values you want in that formula. For example, assume the value you want to inject to the scoring is 3.14, then you can have a custom score function script that looks like this:

\_score \* 3.14

Though, in such a case, it make more sense (performance wise), to provide that value as a parameter (so the compiled script will be reused). This is explained on the same custom\_score query page, under the Script parameters.  
On Saturday, December 4, 2010 at 10:50 PM, brandonlee wrote:

> It does sounds interesting but will require me to store all of the  
> values I want to override with inside ES, whereas Sphinx lets you load  
> those values dynamically and externally...
> 
> On Dec 4, 9:50 pm, LukÃ¡Å¡ VlÄek [lukas.vl...@gmail.com](mailto:lukas.vl...@gmail.com) wrote:
> 
> > Hi,
> > 
> > I am not familiar with Sphinx but doesn't the ES custom score scripting  
> > sound interesting?[http://www.elasticsearch.com/docs/elasticsearch/rest\_api/query\_dsl/cu](http://www.elasticsearch.com/docs/elasticsearch/rest_api/query_dsl/cu)...
> > 
> > Regards,  
> > Lukas
> > 
> > On Sat, Dec 4, 2010 at 8:27 PM, brandonlee wrote:
> > 
> > > Seehttp://www.sphinxsearch.com/docs/current.html#api-func-setoverride  
> > > [...@gmail.com](mailto:...@gmail.com)\>[//www.elasticsearch.com/docs/elasticsearch/rest\_api/query\_dsl/cu](https://www.elasticsearch.com/docs/elasticsearch/rest_api/query_dsl/cu)...\>

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 4:15am UTC](https://discuss.elastic.co/t/is-setoverride-like-behavior-sphinx-supported/3627/5 "2017-07-06T04:15:44Z")

</div>

Closed on July 6, 2017, 4:15am UTC


