• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hibernate Sequence,How to Create a idenfifier YYMMDD-abc-secuence number of a day.

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I need to create a complex identifier.

It's for a document register. The table of document has to be identified this id:
for example:
YYMMDD-abc-secuence number of insert a day.
100102-doc-000000001
100102-doc-000000002
100102-doc-000000003
...
100102-doc-000000043
...
100103-doc-000000001
100103-doc-000000002
...

I don't need Idea how to do these kind of idenfier.
I tried to implement this example, but doen't work. http://blog.anorakgirl.co.uk/?p=43

I use hibernate annotations, with struts2+spring.

Suggestions?

Many thanks!




 
There is no beard big enough to make me comfortable enough with my masculinity to wear pink. Tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic