db_merge

  1. drupal
    1. drupal7
Versionen
drupal7 db_merge($table, array $options = array())

Returns a new MergeQuery object for the active database.

Übergabeparameter

$table The table into which to merge.

$options An array of options to control how the query operates.

Rückgabewert

A new MergeQuery object for this connection.

Verwandte Themen

▾ 27 functions call db_merge()

actions_save in includes/actions.inc
Save an action and its associated user-supplied parameter values to the database.
aggregator_aggregator_parse in modules/aggregator/aggregator.parser.inc
Implementation of hook_aggregator_parse().
aggregator_remove in modules/aggregator/aggregator.module
Removes all items from a feed.
aggregator_save_category in modules/aggregator/aggregator.module
Add/edit/delete aggregator categories.
aggregator_save_feed in modules/aggregator/aggregator.module
Add/edit/delete an aggregator feed.
aggregator_save_item in modules/aggregator/aggregator.processor.inc
Add/edit/delete an aggregator item.
cache_set in includes/cache.inc
Store data in the persistent cache.
DatabaseMergeTestCase::testInvalidMerge in modules/simpletest/tests/database_test.test
Test that an invalid merge query throws an exception like it is supposed to.
DatabaseMergeTestCase::testMergeInsert in modules/simpletest/tests/database_test.test
Confirm that we can merge-insert a record successfully.
DatabaseMergeTestCase::testMergeInsertWithoutUpdate in modules/simpletest/tests/database_test.test
Test that we can merge-insert without any update fields.
DatabaseMergeTestCase::testMergeUpdate in modules/simpletest/tests/database_test.test
Confirm that we can merge-update a record successfully.
DatabaseMergeTestCase::testMergeUpdateExcept in modules/simpletest/tests/database_test.test
Confirm that we can merge-update a record successfully, with exclusion.
DatabaseMergeTestCase::testMergeUpdateExplicit in modules/simpletest/tests/database_test.test
Confirm that we can merge-update a record successfully, with alternate replacement.
DatabaseMergeTestCase::testMergeUpdateExpression in modules/simpletest/tests/database_test.test
Confirm that we can merge-update a record successfully, with expressions.
DatabaseMergeTestCase::testMergeUpdateWithoutUpdate in modules/simpletest/tests/database_test.test
Confirm that we can merge-update without any update fields.
node_tag_new in modules/node/node.module
Update the 'last viewed' timestamp of the specified node for current user.
poll_update in modules/poll/poll.module
Implementation of hook_update().
profile_save_profile in modules/profile/profile.module
search_index in modules/search/search.module
Update the full-text search index for a particular item.
search_update_totals in modules/search/search.module
This function is called on shutdown to ensure that search_total is always up to date (even if cron times out or otherwise fails).
statistics_exit in modules/statistics/statistics.module
Implementation of hook_exit().
user_set_authmaps in modules/user/user.module
Save mappings of which external authentication module(s) authenticated a user. Maps external usernames to user ids in the users table.
variable_set in includes/bootstrap.inc
Set a persistent variable.
_registry_parse_file in includes/registry.inc
Parse a file and save its function and class listings.
_registry_parse_files in includes/registry.inc
Parse all files that have changed since the registry was last built, and save their function and class listings.
_sess_write in includes/session.inc
Session handler assigned by session_set_save_handler().
_update_cache_set in modules/update/update.module
Store data in the private update status cache table.

Code

includes/database/database.inc, line 1869

<?php
function db_merge($table, array $options = array()) {
  if (empty($options['target']) || $options['target'] == 'slave') {
    $options['target'] = 'default';
  }
  return Database::getConnection($options['target'])->merge($table, $options);
}
?>

Kommentare

Kommentar hinzufügen

Der Inhalt dieses Feldes wird nicht öffentlich zugänglich angezeigt.
  • Internet- und E-Mail-Adressen werden automatisch umgewandelt.
  • Zulässige HTML-Tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Zeilen und Absätze werden automatisch erzeugt.

Weitere Informationen über Formatierungsoptionen

Kommentar hinzufügen

Der Inhalt dieses Feldes wird nicht öffentlich zugänglich angezeigt.
  • Internet- und E-Mail-Adressen werden automatisch umgewandelt.
  • Zulässige HTML-Tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Zeilen und Absätze werden automatisch erzeugt.

Weitere Informationen über Formatierungsoptionen