Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 2604

Drupal provides a standard, vendor-agnostic abstraction layer for accessing database servers.

4 votes
Accepted

Why is this db_select not working?

This is answered in this other question: How to perform join with multiple columns using db_select? Calls to SelectQuery::join() (like-wise SelectQuery::leftJoin(), SelectQuery::innerJoin(), an …
sanzante's user avatar
  • 6,991
3 votes
Accepted

Why does user column name has UNIQUE Constraint?

It's a bad idea, your are modifying a core feature of Drupal that others module (and the core itself) may relay on. That's the reason why that column has 'UNIQUE' option, because Drupal requires uniqu …
sanzante's user avatar
  • 6,991
1 vote

Can failure to increase new user's UID consistently by one be related to this line inside us...

uid and other identifiers are not sequential since Drupal 7. Identifiers are generated using a sequence API, see this issue: https://www.drupal.org/node/356074 If you check the db_next_id you'll see …
sanzante's user avatar
  • 6,991
2 votes

What are the differences between EntityFieldQuery and field_get_items()

They are intended for different purposes. EntityFieldQuery is an object to query entities using conditions that includes the value of their fields (for example: retrieve all entities of type node th …
sanzante's user avatar
  • 6,991
1 vote
Accepted

Query returns no result

Usually it's better if you use EntityFieldQuery instead of db_select. See EntityFieldQuery vs Db_select() From EntityFieldQuery use page: The EntityFieldQuery API lets you fetch information about …
sanzante's user avatar
  • 6,991
0 votes

Can I use the Migrate module to sync a site database with a Filemaker Pro database?

So, you'll have the Drupal 8 connection configuration and your migrate source database: $databases['migrate']['default'] = array ( 'database' => 'source-database-name', 'username' => 'source-database-username … ', 'password' => 'source-database-password', 'host' => 'source-database-server', 'port' => '3306', 'namespace' => 'Drupal\\Core\\Database\\Driver\\mysql', 'driver' => 'mysql', ) …
sanzante's user avatar
  • 6,991
12 votes

Get pure SQL from Drupal::entityQuery

* * @var \Drupal\Core\Database\Query\SelectInterface */ protected $sqlQuery; Unfortunately, the Query objects don't allow to access the $sqlQuery or print the SQL string. …
sanzante's user avatar
  • 6,991
2 votes

How cron.php works for watchdog?

crontab calls cron.php. This file makes a complete Drupal bootsrap and then Drupal starts to call all modules that implements the hook_cron(). So, if you want to do something when cron is run, write …
sanzante's user avatar
  • 6,991
2 votes

Uploading an image from a form in my custom module

You shoud use Drupal file managing system. When Drupal is aware of a file, its data is stored in the file related tables. If you need to do something with a file you only need its identifier, called f …
sanzante's user avatar
  • 6,991
5 votes

How to access label of List (text) via node_load()

You can access the key label in a simple way using an Entity Metadata Wrapper: $wrapper = entity_metadata_wrapper('node', $nid); $label = $wrapper->field_sport_type->label(); Or using de $node load …
sanzante's user avatar
  • 6,991
0 votes
Accepted

Can't create table when installing module

If you only disable the module and enable it Drupal doesn't create configuration and tables because they should be in the database,m as Drupal knows module was enabled once. …
sanzante's user avatar
  • 6,991
1 vote
Accepted

What services must I leave switched on in Elysia cron

Some of them, for example, remove temporal data from the database (probably the reason your database is growing). …
sanzante's user avatar
  • 6,991