function tripal_associate_dbxref

2.x tripal_db.api.inc tripal_associate_dbxref($basetable, $record_id, $dbxref, $options = array())
3.x tripal_chado.module.DEPRECATED.api.inc tripal_associate_dbxref($basetable, $record_id, $dbxref, $options = array())

Add a record to a database reference linking table (ie: feature_dbxref).

Parameters

$basetable: The base table for which the dbxref should be associated. Thus to associate a dbxref with a feature the basetable=feature and dbxref_id is added to the feature_dbxref table.

$record_id: The primary key of the basetable to associate the dbxref with. This should be in integer.

$dbxref: An associative array describing the dbxref. Valid keys include: 'accession' => the accession for the dbxref, 'db_name' => the name of the database the dbxref belongs to. 'db_id' => the primary key of the database the dbxref belongs to.

$options: An associative array of options. Valid keys include:

  • insert_dbxref: Insert the dbxref if it doesn't already exist. TRUE is the default.
5 calls to tripal_associate_dbxref()
chado_update_node_form_dbxrefs in legacy/tripal_core/api/tripal_core.chado_nodes.dbxrefs.api.inc
This function is used in hook_insert or hook_update and handles inserting of any new dbxrefs and creation of links between those dbxrefs and node content
tripal_db_add_dbxref_link in legacy/tripal_db/api/tripal_db.DEPRECATED.inc
tripal_feature_add_dbxref in legacy/tripal_feature/api/tripal_feature.DEPRECATED.inc
tripal_pub_add_publications in tripal_chado/includes/loaders/tripal_chado.pub_importers.inc
Adds publications that have been retrieved from a remote database and consolidated into an array of details.
tripal_pub_add_pub_dbxref in legacy/tripal_pub/api/tripal_pub.DEPRECATED.inc
3 string references to 'tripal_associate_dbxref'

File

tripal_chado/api/modules/tripal_chado.module.DEPRECATED.api.inc, line 635
These api functions are deprecated, if your site is currently using them please update your code with the newer tripal_chado functions.

Code

function tripal_associate_dbxref($basetable, $record_id, $dbxref, $options = array()) {
  chado_associate_dbxref($basetable, $record_id, $dbxref, $options);
}