db_query_range

Versions
mediamosa-21
db_query_range($query, $from, $count, array $args = array(), array $options = array())

Executes a query against the active database, restricted to a range.

See also

DatabaseConnection::defaultOptions()

Parameters

$query The prepared statement query to run. Although it will accept both named and unnamed placeholders, named placeholders are strongly preferred as they are more self-documenting.

$from The first record from the result set to return.

$count The number of records to return from the result set.

$args An array of values to substitute into the query. If the query uses named placeholders, this is an associative array in any order. If the query uses unnamed placeholders (?), this is an indexed array and the order must match the order of placeholders in the query string.

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

Return value

DatabaseStatementInterface A prepared statement object, already executed.

Related topics

▾ 44 functions call db_query_range()

aggregator_block_view in modules/aggregator/aggregator.module
Implements hook_block_view().
aggregator_feed_items_load in modules/aggregator/aggregator.pages.inc
Load feed items
aggregator_page_categories in modules/aggregator/aggregator.pages.inc
Menu callback; displays all the categories used by the aggregator.
aggregator_page_rss in modules/aggregator/aggregator.pages.inc
Menu callback; generate an RSS 0.92 feed of aggregator items or categories.
aggregator_page_sources in modules/aggregator/aggregator.pages.inc
Menu callback; displays all the feeds used by the aggregator.
block_add_block_form_validate in modules/block/block.admin.inc
block_admin_configure_validate in modules/block/block.admin.inc
block_theme_initialize in modules/block/block.module
Assign an initial, default set of blocks for a theme.
comment_update_7013 in modules/comment/comment.install
Migrate data from the comment field to field storage.
devel_generate_add_comments in sites/all/modules/devel/devel_generate.inc
devel_generate_add_terms in sites/all/modules/devel/devel_generate.inc
devel_generate_terms in sites/all/modules/devel/devel_generate.inc
devel_get_users in sites/all/modules/devel/devel_generate.inc
devel_node_access_block_view in sites/all/modules/devel/devel_node_access.module
devel_switch_user_list in sites/all/modules/devel/devel.module
forum_node_presave in modules/forum/forum.module
Implements hook_node_presave().
forum_node_validate in modules/forum/forum.module
Implements hook_node_validate().
hook_file_references in modules/system/system.api.php
Report the number of times a file is referenced by a module.
hook_update_index in modules/search/search.api.php
Update the search index for this module.
locale_date_format_save in includes/locale.inc
Save locale specific date formats to the database.
menu_edit_menu_validate in modules/menu/menu.admin.inc
Validates the human and machine-readable names when adding or editing a menu.
menu_get_item in includes/menu.inc
Get a router item.
menu_node_prepare in modules/menu/menu.module
Implements hook_node_prepare().
node_assign_owner_action_validate in modules/node/node.module
Validates settings form for node_assign_owner_action().
node_type_save in modules/node/node.module
Saves a node type to the database.
node_update_index in modules/node/node.module
Implements hook_update_index().
path_admin_overview in modules/path/path.admin.inc
Return a listing of all defined URL aliases.
php_enable in modules/php/php.install
Implements hook_enable().
profile_autocomplete in modules/profile/profile.pages.inc
Callback to allow autocomplete of profile text fields.
profile_category_access in modules/profile/profile.module
Menu item access callback - check if a user has access to a profile category.
system_date_format_save in modules/system/system.module
Save a date format to the database.
taxonomy_update_7005 in modules/taxonomy/taxonomy.install
Migrate {taxonomy_term_node} table to field storage.
tracker_cron in modules/tracker/tracker.module
Implements hook_cron().
user_block_view in modules/user/user.module
Implements hook_block_view().
user_file_references in modules/user/user.module
Implements hook_file_references().
user_update_7000 in modules/user/user.install
Increase the length of the password field to accommodate better hashes.
user_update_7002 in modules/user/user.install
Convert user time zones from time zone offsets to time zone names.
user_update_7004 in modules/user/user.install
Add the user's pictures to the {file} table and make them managed files.
_comment_update_node_statistics in modules/comment/comment.module
Updates the comment statistics for a given node. This should be called any time a comment is added, deleted, or updated.
_forum_update_forum_index in modules/forum/forum.module
Updates the taxonomy index for a given node.
_mediamosa_migration_kill_child_assets in sites/all/modules/mediamosa_migration/mediamosa_migration.inc
Migrate childs asset mediafiles to the root. Remove childs assets.
_node_access_rebuild_batch_operation in modules/node/node.module
Batch operation for node_access_rebuild_batch.
_tracker_calculate_changed in modules/tracker/tracker.module
Determine the max timestamp between $node->changed and the last comment.
_tracker_remove in modules/tracker/tracker.module
Clean up indexed data when nodes or comments are removed.

Code

includes/database/database.inc, line 2176

<?php
function db_query_range($query, $from, $count, array $args = array(), array $options = array()) {
  if (empty($options['target'])) {
    $options['target'] = 'default';
  }

  return Database::getConnection($options['target'])->queryRange($query, $from, $count, $args, $options);
}
?>