Sorry, I don't fully understand...
If I understand the new API well, my query in the implementation of
getValues() should return a list of full hibernate objects in my case.
I don't see how can I still query only the ID and the label - although
today was a long day :)
Regards:
Norbi
Ron Piterman írta:
I think you get a List<Object[]> from hibernate?
you can change your model to extract object[0] as key, object[1] as
value, and return the whole object for getForPrimaryKey( key ) - ( I
think its another method signature- but the same meaning)...
Cheers,
Ron
Norbert Sándor wrote:
Hello,
Unfortunatelly I've not followed the discussion about the subject.
As the new doc says for IAutocompleteModel.getValues():
* Expected to return a list of all possible values, filtering out
values that
* match the specified String in the <strong>label</strong>
representation of the value.
Sorry for the late reaction but I think the previous version was
better. I explain why.
In my application I use Autocompleter to list Hibernate objects.
Until this modification my query was:
SELECT o.id,o.text FROM ... WHERE filter condition
but now I have to write
SELECT o FROM ... WHERE filter condition
so the query must return full objects, it may require much more DB
bandwidth.
I see that Autocompleter's implementation is now very clean
key = model.getPrimaryKey(value);
label = model.getLabelFor(value);
but it may have negative performance impact in case of more complex
applications.
Sorry if I misunderstood something...
Regards:
Norbi
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]