Skip to main content
How Can We Help?

Search for answers or browse our knowledge base.

OpenWells Integration

You are here:
< Back

Introduction

XSPOC can be configured to import well configuration data from OpenWells on a regular basis.  However, to do so, you must have direct (read-only) access to the OpenWells database.  The OpenWells Import also relies on the customer using lookup tables populated with Theta-specific data.  The following data is imported from OpenWells:

  • Crank hole number
  • Rotation direction
  • Stroke length
  • Pumping unit
  • Pump barrel length
  • Plunger diameter
  • Pump type
  • Rod tapers (size, grade, and length for each)
  • Casing tapers (outer diameter and length for each)
  • Tubing tapers (size and length for each)
  • Tubing anchor depth
  • Perforations
  • Motor info (size, kind, and setting)

Procedure

  • Enable the OpenWells import by setting the system parameter, “DI_OpenWells”, to “1”.  To disable the import, set it to “0”.
     
  • Specify the connection string used to connect to the OpenWells database by setting the system parameter, “DI_OpenWellsConnectString”.  The API used is OLE DB.  In most cases, the OLE DB Client application can be used to help you construct the connection string.
  • Specify the prefix used on the OpenWells tables by setting the system parameter, “DI_OpenWellsPrefix”.  This doesn’t apply to OpenWells, but it needs to be entered as it is required by the XSPOC Import routine.
  • Specify the field in XSPOC’s tblNodeMaster table that relates to the OpenWells data by setting the system parameter, “DI_OpenWellsLinkField”.  The default value is “OtherWellID1”.
     
  • Specify the field in OpenWells CD_WELL_SOURCE table that relates to the XSPOC node by setting the system parameter, “DI_OpenWellsWellIDA”.  The default value is “WellIDA”.
     
  • If necessary, specify a method to exclude certain wells from the import.  This is done by specifying a field in tblNodeMaster and a keyword that the field will start with when the well is to be excluded.  The field name is specified by setting the system parameter, “DI_OpenWellsExcludeField”.  The keyword is specified by setting the system parameter, “DI_OpenWellsExclude”.  For example, you may choose to set “DI_OpenWellsExcludeField” to “AdhocGroup3” and “DI_OpenWellsExclude” to “Exclude”.  In this case, nodes in tblNodeMaster whose AdhocGroup 3 starts with “Exclude” will be excluded from the import.
    NOTE: When this feature is enabled, wells that are to be included need to be explicit identified.  A NULL value in the exclusion field will cause the well to be excluded.
     
  • If necessary, specify the number of characters to compare between ID fields by setting the system parameter, “DI_OpenWellsFieldLength”.  For example, a customer may use a well’s API number to relate data between XSPOC and OpenWells.  This value may be 10 characters long in XSPOC, but 14 characters in OpenWells.  In this case, you could set the value of “DI_OpenWellsFieldLength” to 10 to ensure that the wells relate.
     
  • If necessary, specify a method for importing well names from OpenWells.  This is done by setting three (3) system parameters:
    • “DI_OpenWellsNameLoad” – “DI_OpenWellsNameLoad” enables the name import.  
    • “DI_OpenWellsNameField” – “DI_OpenWellsNameField” specifies the column in OpenWells’ CD_WELL_SOURCE table to retrieve the name from.  The default value is “WellName”.  
    • “DI_OpenWellsWellNameXSPOCField” -“DI_OpenWellsWellNameXSPOCField” specifies the column in XSPOC’s tblNodeMaster table to insert the name into.  The default value is “WellName”.

NOTE: Using “NodeID” for the value of “DI_OpenWellsWellNameXSPOCField” will not enforce referential integrity with other XSPOC tables.

System Parameters

Parameter Name

Required?

Description

DI_OpenWells

Yes

Enables/disables the OpenWells import

DI_OpenWellsConnectString

Yes

OLE DB connection string

DI_OpenWellsPrefix

Yes

The OpenWells table prefix

DI_OpenWellsLinkField

No

The field in XSPOC’s tblNodeMaster table that relates wells to OpenWells; defaults to “OtherWellID1”

DI_OpenWellsWellIDA

No

The field in OpenWells’ CD_WELL_SOURCE table that relates wells to XSPOC; defaults to “WellIDA”

DI_OpenWellsExclude

No

A keyword used identify certain wells for exclusion

DI_OpenWellsExcludeField

No

The field in XSPOC’s tblNodeMaster table that indicates when a well is to be excluded

DI_OpenWellsFieldLength

No

The number of characters to compare between ID fields

DI_OpenWellsNameLoad

No

Enables/disables the import of well names

DI_OpenWellsNameField

No

The field in OpenWells’ CD_WELL_SOURCE table to use as the well name; defaults to “WellName”

DI_OpenWellsWellNameXSPOCField

No

The field in XSPOC’s tblNodeMaster table to use as the destination for the well name; defaults to “WellName”

Introduction

XSPOC can be configured to import well configuration data from OpenWells on a regular basis.  However, to do so, you must have direct (read-only) access to the OpenWells database.  The OpenWells Import also relies on the customer using lookup tables populated with Theta-specific data.  The following data is imported from OpenWells:

  • Crank hole number
  • Rotation direction
  • Stroke length
  • Pumping unit
  • Pump barrel length
  • Plunger diameter
  • Pump type
  • Rod tapers (size, grade, and length for each)
  • Casing tapers (outer diameter and length for each)
  • Tubing tapers (size and length for each)
  • Tubing anchor depth
  • Perforations
  • Motor info (size, kind, and setting)

Procedure

  • Enable the OpenWells import by setting the system parameter, “DI_OpenWells”, to “1”.  To disable the import, set it to “0”.  
  • Specify the connection string used to connect to the OpenWells database by setting the system parameter, “DI_OpenWellsConnectString”.  The API used is OLE DB.  In most cases, the OLE DB Client application can be used to help you construct the connection string.
  • Specify the prefix used on the OpenWells tables by setting the system parameter, “DI_OpenWellsPrefix”.  This doesn’t apply to OpenWells, but it needs to be entered as it is required by the XSPOC Import routine.
  • Specify the field in XSPOC’s tblNodeMaster table that relates to the OpenWells data by setting the system parameter, “DI_OpenWellsLinkField”.  The default value is “OtherWellID1”.  
  • Specify the field in OpenWells CD_WELL_SOURCE table that relates to the XSPOC node by setting the system parameter, “DI_OpenWellsWellIDA”.  The default value is “WellIDA”.  
  • If necessary, specify a method to exclude certain wells from the import.  This is done by specifying a field in tblNodeMaster and a keyword that the field will start with when the well is to be excluded.  The field name is specified by setting the system parameter, “DI_OpenWellsExcludeField”.  The keyword is specified by setting the system parameter, “DI_OpenWellsExclude”.  For example, you may choose to set “DI_OpenWellsExcludeField” to “AdhocGroup3” and “DI_OpenWellsExclude” to “Exclude”.  In this case, nodes in tblNodeMaster whose AdhocGroup 3 starts with “Exclude” will be excluded from the import.
    NOTE: When this feature is enabled, wells that are to be included need to be explicit identified.  A NULL value in the exclusion field will cause the well to be excluded.  
  • If necessary, specify the number of characters to compare between ID fields by setting the system parameter, “DI_OpenWellsFieldLength”.  For example, a customer may use a well’s API number to relate data between XSPOC and OpenWells.  This value may be 10 characters long in XSPOC, but 14 characters in OpenWells.  In this case, you could set the value of “DI_OpenWellsFieldLength” to 10 to ensure that the wells relate.  
  • If necessary, specify a method for importing well names from OpenWells.  This is done by setting three (3) system parameters:
    • “DI_OpenWellsNameLoad” – “DI_OpenWellsNameLoad” enables the name import.  
    • “DI_OpenWellsNameField” – “DI_OpenWellsNameField” specifies the column in OpenWells’ CD_WELL_SOURCE table to retrieve the name from.  The default value is “WellName”.  
    • “DI_OpenWellsWellNameXSPOCField” -“DI_OpenWellsWellNameXSPOCField” specifies the column in XSPOC’s tblNodeMaster table to insert the name into.  The default value is “WellName”.

NOTE: Using “NodeID” for the value of “DI_OpenWellsWellNameXSPOCField” will not enforce referential integrity with other XSPOC tables.

System Parameters

Parameter Name

Required?

Description

DI_OpenWells

Yes

Enables/disables the OpenWells import

DI_OpenWellsConnectString

Yes

OLE DB connection string

DI_OpenWellsPrefix

Yes

The OpenWells table prefix

DI_OpenWellsLinkField

No

The field in XSPOC’s tblNodeMaster table that relates wells to OpenWells; defaults to “OtherWellID1”

DI_OpenWellsWellIDA

No

The field in OpenWells’ CD_WELL_SOURCE table that relates wells to XSPOC; defaults to “WellIDA”

DI_OpenWellsExclude

No

A keyword used identify certain wells for exclusion

DI_OpenWellsExcludeField

No

The field in XSPOC’s tblNodeMaster table that indicates when a well is to be excluded

DI_OpenWellsFieldLength

No

The number of characters to compare between ID fields

DI_OpenWellsNameLoad

No

Enables/disables the import of well names

DI_OpenWellsNameField

No

The field in OpenWells’ CD_WELL_SOURCE table to use as the well name; defaults to “WellName”

DI_OpenWellsWellNameXSPOCField

No

The field in XSPOC’s tblNodeMaster table to use as the destination for the well name; defaults to “WellName”