Retrieving CTDO data for MBARI_Samples Database

Conductivity, temperature, depth, and oxygen (CTDO) data are retrieved from the MBARI MODB database with the routine named "UpdateAllRovctd.bat". This routine runs on Windows 95 or NT. This routine is run after the collection events have been created in the database. It requires that the ROV name, date, and time of collection are known and that CTDO data exist for that dive.

To run the routine:

  1. Open DOS window
  2. Go to P: (mapped to \\Tornado\Apps)
  3. cd to P:\Java\Itd\Samples
  4. Type "UpdateAllRovctd.bat" to process all the records in the CollectionEvent table with CTDLookupStatus equal to 1. (0=Successful lookup, 1=needs lookup, 2=Unsuccessful lookup)
  5. CTDO data will be placed in the CollectionEvent table.

The DOS bat script UpdateAllRovctd.bat executes the Java code UpdateAllRovctd that utilizes the following classes, programs and routines:

  1. DbAnywhere (currently running on godzilla) to talk to MS SQL server and Sybase
  2. Java packages org.mbari.itd.samples, and com.sun.java.util.collections
  3. MODB rovctdByEpochSec stored procedures

UpdateAllRovctd does the following:

  1. For CTDLookupStatus = 1, finds CollectionEventID, CollectionEventDTG and ROVName.
  2. For ROVName = ‘Ventana’, substitute ‘vnta’, for ‘Tiburon’ substitute ‘tibr’. Find the CTDO MODB data where the ROVName matches the Rov type name, and datetime within the 15 bin of the CollectionEventDTG.
  3. For times = 12:00:00 AM (00:00:00), the default time when real time is not known, do not look up the CTDO data.
  4. Find the Temperature, Salinity, Pressure, and Dissolved Oxygen values from the rovctd table in MODB using the rovctdByEpochSec stored procedure (which performs the actions outlined in steps 2 and 3).
  5. Populate respective MBARI_Samples fields in the CollectionEvent table ‘Temperature’, ‘Salinity’, ‘CTDPressure’, and ‘DissolvedOxygen’.
  6. Change CTDLookupStatus to 0 in records for which data was found. Change to 2 in records for which data was not found.

»Next: VIMS explosion

Last updated: 07 December 2004 by Jennifer Paduan
Copyright © 1998 MBARI