0

I'm creating a database which holds information on measurements which I make with a device that holds a sample. Inserting the sample into the device creates unique boundary conditions which can never be replicated again. I want to identify these periods of time during which the sample was in the device with ordinal numbers which I will put in a column of a table in the database. How should I label this column? I was thinking something like 'insertion ordinal' but can users understand that?

  • I don't think I understand. Do you have exactly one sequence of in-out times? <0,1>, <5,19>,<20,23>,... where the pairs are never overlapping? Do you want to label the time spans with an ordinal or what? – Mitch Apr 16 '15 at 13:19
  • In other words, you are defining periods of time, and using ordinal numbers to label those periods? – Hot Licks Apr 16 '15 at 16:57
0

Ordinals can apply to the items in any ordered set. There is no word specifically for ordinals that apply to non-overlapping arbitrary time-spans that are demarcated by a starting and an ending time.

If you are tracking sample specimens over multiple calendar days, be sure to include the Date element as part of the time, and not merely a Time Of Day value. You could have two tests, days apart, both of which began at the stroke of noon.

If you use DateTime values, there would be no need for an ordinal column, as you could order the set at any time merely by reference to the StartTime column.

1

Sounds like you actually need 3 fields in your table instead:

Sample UID, Insertion Timestamp, Removal Timestamp

Abbreviate as you like, but make sure to keep the names distinct from your hopefully present creation/modification timestamp fields!


Edited: This provides a unique identifier (UID) to serve instead of an ordinal and also more information: Not only do the timestamps provide a natural order, they also provide information about timing and duration and splitting the data into multiple fields makes querying the database later easier.

  • I wanted to avoid timestamps because I considered the exact time unnecessary. – user4768948 Apr 17 '15 at 7:04
  • The data costs no meaningful amount of space extra, and may prove useful later, perhaps for e.g. duration. – Sam Apr 17 '15 at 9:25
0

What do you think about timestamp.

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.