F
f
I am writing a system which is going to be used on different
databases. I use the DAO design pattern. The idea is that my system
focus on business logic only and it is up to the implementation of the
DAO that links my system to different databases with different schema.
My question is how to design the primary key in my system for each
data piece. I think the key is nessary for me when I write this
system, even though I know my system is to used differently, because
sometimes I need to join the data or whatever. And the key needs to be
translated to different databases when DAO is implemented.
DO I need the primary key for my Data? How to design the key so it can
be easily implemented by different database?
THanks,
ff
databases. I use the DAO design pattern. The idea is that my system
focus on business logic only and it is up to the implementation of the
DAO that links my system to different databases with different schema.
My question is how to design the primary key in my system for each
data piece. I think the key is nessary for me when I write this
system, even though I know my system is to used differently, because
sometimes I need to join the data or whatever. And the key needs to be
translated to different databases when DAO is implemented.
DO I need the primary key for my Data? How to design the key so it can
be easily implemented by different database?
THanks,
ff