-1

I have a table of real estate objects. The objects are shown in three lists (sell, rent long, rent short), each object in exactly one list (defined by an ENUM field).

I want to add field seq INT to the table to be able to reorder objects in every of the three lists (ORDER BY seq). Should I permit objects of different lists have the same seq?

  • Would you ever be selecting more than one object type at the same time? – Hogan Jul 26 '12 at 17:32
  • @Hogan: Never (except of the routine which re-generates all output). – porton Jul 26 '12 at 17:35
2

If you will never be selecting more than one object type at the same time you can have duplicates over types.

Whenever I've done it this way I've always regretted it. It does not cost much to make then unique and it can solve lots of issues. (For example a rent long changes to a rent short).

If it is not "to hard" I highly recommend not sharing values in this case.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.