Setting up a WELLS_MASTER View

Introduction

This section describes how to set up a view for StrataBugs on corporate well header tables.

StrataBugs databases usually contain a sub-set of the well header data which resides in corporate well header tables, since not all wells are analysed for, or contain, biostratigraphic data. It is therefore impractical to bulk load all the corporation’s well headers into the StrataBugs well header table WELLS, but it is convenient to be able to make use of the data already entered, and to keep it synchronised when changes occur.

The WELLS_MASTER view is an in-built mechanism to achieve this. If your StrataBugs database contains a view of this name, it will allow users to select wells from the master list, and it will keep the StrataBugs well header data synchronised. StrataBugs users are not restricted to the wells available in the view. Wells with different well codes to the master view can be entered, as well as outcrop sections.

What the user sees

When the view is active, the user will see the following additional "Select…​" button on the Add/Edit Well dialog:

wells master1

This button opens a well selection dialog which appears similar to the internal StrataBugs well selector, but it will be querying the fields in the view and not the StrataBugs tables. The searchable terms are well name, well code and country, and these are the minimum fields required in the WELLS_MASTER view.

wells master2

After a well search, the selected well and header details will be copied into the StrataBugs Add/Edit Well dialog.

wells master3

When the user presses OK on this dialog, the well is saved, and as long as the well code has not been edited, the well is then linked via the code to the WELLS_MASTER view.

Any subsequent selection of the well anywhere in StrataBugs will enforce a check of the header details from the WELLS_MASTER view. Any changed details will be copied to the StrataBugs WELLS table.

Setting up the view

The view must contain the following fields (all text):

  • WELL_NAME

  • WELL_CODE

  • COUNTRY

The view can contain any or all of the additional fields in the StrataBugs WELLS table, with the exception of the fields used for monitoring creates/modifies/updates. These are:

OPERATOR

VARCHAR 25

Company name

COUNTY

VARCHAR 30

US County

OCS

VARCHAR 10

US Offshore Continental Shelf number

FIELD

VARCHAR 20

GRID_X

DOUBLE 15

Use for Eastings in local grid coordinates or UTM

GRID_Y

DOUBLE 15

Use for Nothings in local grid coordinates or UTM

SPUD_DATE

DATETIME 19

Spud date of well

COMP_DATE

DATETIME 19

Completion date of well

LAT_DEC

DOUBLE 15

Latitude in decimal degrees. Negative numbers for South. Old DMS fields have been dropped to avoid duplication

LONG_DEC

DOUBLE 15

Longitude in decimal degrees. Negative for West.

TD

DOUBLE 15

Termination depth, measured from drilling ref point

SL

DOUBLE 15

Rig elevation above sea level. Zero for offshore wells. Added to RTE to obtain RTE above sea level.

SB

DOUBLE 15

Depth of Sea bed below RTE for offshore wells. Zero for onshore wells.

RTE

DOUBLE 15

Elevation of Rotary Table above mean sea level (offshore) or above rig elevation (onshore)

KICKO

DOUBLE 15

For sidetracks, the kickoff depth.

DATUM

DOUBLE 15

Indicates where depths are measured from; 1=RTE, 2=sea Level, 3=sea bed

TYPE

VARCHAR 1

W for Well and O for outcrop. Outcrops display depths as heights above datum.

UNITS

VARCHAR 1

Original well units, F for Feet and M for Metres. All depths are stored in metres.

GEODATUM

VARCHAR 12

Geodetic datum on which coordinates are based.

The view can be set up using the Oracle syntax:

CREATE OR REPLACE FORCE VIEW WELLS_MASTER AS SELECT ....... FROM .... (WHERE);

The contents of the view will be site and company specific.

Copyright StrataData Ltd. 2025