No, your Solr unique key field should ALWAYS be of type "string". In some cases you can get away with other types, but eventually you may run into some Solr feature which requires that the unique key field be a string, so it is better to avoid the potential problems from the start. You can put letters or digits in the string as you please, but keep the type as "string".

Also, DO NOT change the type of a field unless you are prepared to fully reindex your data.

-- Jack Krupansky

-----Original Message----- From: Otis Gospodnetic
Sent: Wednesday, December 05, 2012 7:15 AM
To: solr-user@lucene.apache.org
Subject: Re: Is it ok to have a alphanumberic ID for entries?

That would be fine.

Otis
--
SOLR Performance Monitoring - http://sematext.com/spm
On Dec 5, 2012 7:14 AM, "Spadez" <james_will...@hotmail.com> wrote:

I was wondering, with my current setup I have an ID field which is a
number.
If I wanted to then change it so my ID field was actually a mix of numbers
and letters (to do with the backend system), would this cause any sort of
problem?

I would never do any kind of sorting by ID on my search page, the ID will
purely be used in order to update and delete entries from the solr index.





--
View this message in context:
http://lucene.472066.n3.nabble.com/Is-it-ok-to-have-a-alphanumberic-ID-for-entries-tp4024441.html
Sent from the Solr - User mailing list archive at Nabble.com.


Reply via email to