in reply to Re^2: Perl : How to Create Unique String/Number?
in thread Perl : How to Create Unique String/Number?

mmm, what characters should I not put because I want to generate an unique string that would be used for naming files?
  • Comment on Re^3: Perl : How to Create Unique String/Number?

Replies are listed 'Best First'.
Re^4: Perl : How to Create Unique String/Number?
by thor (Priest) on Jan 28, 2005 at 00:54 UTC
    I'm not sure I understand the question. My original reply was with regards to the dangers of using time and IP address to generate a unique string. That having been said, I'll try my best to answer your question.

    There are no characters that are taboo when generating a unique string. The problem lies in generating a string that's guaranteed to be unique. Using things that shouldn't collide isn't good enough. Data::UUID guarantees no collision for the very foreseeable future. Use the solution that others have done a good job at implementing. You can have more fun in the spare time that you gain that way.

    thor

    Feel the white light, the light within
    Be your own disciple, fan the sparks of will
    For all of us waiting, your kingdom will come