MySQL is an open-source, relational database management system. Use this tag for questions specific MySQL, not for saying "I am using MySQL."

learn more… | top users | synonyms

0
votes
0answers
29 views

Error while adding any field in custom content type [duplicate]

I am unable to add any field in my custom content type, when I click on save button or click on upload after adding images it gives me the following error and for the text field the error is simply ...
0
votes
0answers
8 views

Add multiple conditions in search

I want to add two conditions in drupal core search. First condition contains taxonomy term parent and second condition contains taxonomy term child value. I have developed an interface now i want to ...
0
votes
1answer
33 views

I can't fetch anything else than '1' to my PDO query

Here is my PDO request : $query = db_select('review_ratings_table') ->fields('review_ratings_table',array('review_nid')) ->condition('loc_id', $loc_id, 'LIKE') ...
1
vote
3answers
68 views

Where is the base domain stored in database D7

Is there an equivalent row to the Wordpress "Home" and "Site"? In otherwords, where can I look in the database to figure out what the domain the site is on? I'm using mysql
1
vote
2answers
46 views

OWASP security and drupal

Recently, To improve our site security we implemented and enabled OWASP security in our server using mod_security. After we enabled the OWASP security, whenever I try to create or edit contents in my ...
0
votes
2answers
25 views

Why doesn't the field table in the Drupal database use entity_id as a primary key?

I'm working on trying to optimize a View SQL query and I noticed that the query being executed is using a join on a the entity_id field of a field table. I noticed that for some reason unbeknownst to ...
0
votes
0answers
28 views

GENERATE PDF WEBFORMS DRUPAL [duplicate]

I istalled webform2pdf and tcpdf for download forms and i create form i cconfigure webform2pdf but when i Click in download pdf on the form that i was created i have a error say : Fatal error: Call ...
0
votes
1answer
37 views

Fatal error: Call to undefined function system_run_automated_cron()

I migrated my database from oracle to mysql and when linking it to my drupal the following error: Fatal error: Call to undefined function system_run_automated_cron() in ...
0
votes
0answers
18 views

cpu at 100% after ubercart database update

Recently I updated ubercart tables of my database with newer ones. Now if I want to search for an existing customer inside the order based on email, cpu goes to 100% for 2 minutes freezing whole ...
1
vote
0answers
15 views

From a slow mysql query, is there a way to determine which Drupal module/path is the cause? [duplicate]

My hosting provider (Pantheon) provides mysql slow query logs. Is there a quick/easy way to determined, based on an entry in the log, which module/path is causing the problem? Since I built this ...
1
vote
2answers
28 views

How to subtract two columns with db_select()?

I have a db_select query that outputs two columns. I want to find the difference between these columns, output to another column, and then put a condition on this third column. Here is a mysql query ...
1
vote
0answers
30 views

Connection timed out and lock_may_be_available() on working site

I'm hoping someone can point me to a fix. My drupal 7 app was running fine locally this a.m. while I was testing a way to insert a row using mysql tools for a non-Drupal function. My environment is ...
1
vote
1answer
40 views

connect drupalgap app to drupal site

i have a problem and the documentation of drupalgap is not too specific. I have a site for example "www.mysite.com" and i have in a localhost a site built in drupalgap that i want to connect with ...
0
votes
1answer
62 views

Can't use drush site-install to drop tables and reinstall in MAMP

I have a local multisite instance running MAMP 3.0.7.3, and I can't use the drush site-install command to do a re-install of one of my sites without actually dropping the database first. If I try the ...
2
votes
0answers
37 views

site down due to mysql error but returns 200/OK

A site I help administer was showing a MySQL error page, Additional uncaught exception thrown while handling exception. PDOException: SQLSTATE[HY000] [2002] Can't connect to local MySQL server ...
0
votes
0answers
17 views

creating book hierarchy via mysql inserts

I have imported data from other sources into drupal 7 creating nodes and node revisions with MySQL inserts. I wish to use books module to structure some of my content, and trying to achieve it with ...
0
votes
1answer
51 views

Analyzing slow mysql querries

Our Drupal site has recently started to get much more traffic and often pegs the CPU and memory when we have 50-100 active connections. We have 8cpus and 16GB of RAM. I notice that when the cpu is ...
0
votes
1answer
53 views

Install fails using MAMP – SQLSTATE[HY000] [2002]

I've been trying to set up a local installation of Drupal (I've tried both 7.35 and 8.0 beta9) using MAMP on Mac OS X 10.9.5, but evrytime I get to the "Set up database" part of installation process ...
1
vote
1answer
41 views

Not possible to drush sql-sync sqlite to mysql pragma

I have a local testing setup where I can create drupal sites easily, all running with a sqlite DB. I want to (firstly) publish the site to a remote server using a script that calls drush sql-sync ...
1
vote
2answers
114 views

mysql errors after upgrading php and mysql

recently upgraded server to php 5.6.5 and mysql 5.6.22. running drupal 7. after the upgrade we started having issues. the server seems to run well for a week or so before starting to throw error ...
0
votes
1answer
34 views

How could I do a FULL OUTER JOIN in drupal?

How can I do this code in Drupal? I cannot find how this code is writing in Drupal. SELECT column_name(s) FROM table1 FULL OUTER JOIN table2 ON table1.column_name = table2.column_name;
0
votes
1answer
15 views

How to restrict a page to a group of people?

I am trying to figure out how I can lock down a page (part of my site) to a list of users that I have in another MySQL DB. Ideally I would like to call the DB and see if the user has access each time ...
0
votes
0answers
25 views

Concat query used in a like condition

I'd like to perform a query where I get the value of various fields(stored in different tables) and check if a string exists on them. This is part of a bigger query. What I did until know is : ...
0
votes
1answer
32 views

how do i install drupal with drush

First off, I'm a drush newbie, just installed it and now I want to install drupal on my server, so I did a drush dl drupal --drupal-project-rename=Quaaoutand next I want to do a drush si standard ...
0
votes
0answers
11 views

Recurrent error MySQL writing to /tmp

Need some brains to point me in the right direction please. I've been having a problem with a legacy Drupal 6 set up, recently it has started erring with the following Can't create/write to file ...
0
votes
2answers
30 views

Batch deleting nodes breaks database

On my Drupal site, I have about 100 nodes that need deleting. I have deleted them via Views Bulk Operations. When I do this, if I make a backup of my site MySQL database and then try to restore it ...
0
votes
0answers
92 views

db_select sum operation of multiple tables column

I have two tables table 1 is table 2 is I need sum of points and sum of pur_amount of each uid as per the vuid Here is my code $query = db_select('table1', 'pp'); $query->join('table2', ...
0
votes
1answer
49 views

Does Drupal cache db_query results for multiple users?

I am running into something strange and perhaps someone here can help me. I am trying to prevent two things from happening at once because the second attempt might be influenced by the first attempt. ...
3
votes
0answers
68 views

Drupal Commerce causing database deadlocks

I'm trying to get to the bottom of a known Drupal Commerce bug to do with row locking. When a user logs in on my development site, Drupal Commerce starts multiple identical queries that look like ...
0
votes
2answers
38 views

Adding Placeholders for PHP variables

When creating a query using db_query in my module I want to make sure it's as secure as possible. So I'd like to use placeholders in my 'WHERE' clauses. The problem I'm having is how to use ...
0
votes
1answer
65 views

Run a Drupal website offline (±without server)? — E.g. hand it over on a usb-stick / by mail? — Run it from the HD, while retaining functionality?

Why run Drupal offline? Since I use free webhosting, I don't have 100% up-time, so I started wondering whether I could maintain such Drupal functionality, while at the same time working offline. An ...
3
votes
3answers
103 views

Git-like way of updating Drupal database

It's easy to update Drupal on the local / remote server using Git. However, sometimes when I make modifications in the actual module settings or any other settings on my local server – those are ...
3
votes
4answers
144 views

How can I find a module or activity that is excessively writing to the database?

Problem: We have two productions servers: primary and failover. The two machines are linked via mysql replication. The mysql relay logs are clogging and bringing servers down the failover server. I ...
0
votes
0answers
29 views

How can I stop this query from being run by commerce module whenever I enable or disable new module?

I have a drupal commerce site that I created NOT with kickstart that has about 500K downloadable products (pdfs) and product displays. Whenever I disable or enable a new module, the multiple copies ...
0
votes
1answer
35 views

Problems with SQL Syntax using Left Join and OR

I need some help with my SQL. I've got the following code but it's returning multiples of each item and I don't understand why. When I only include the first Left join it returns results as ...
0
votes
2answers
38 views

My php is showing a numeric value for my list field…Why?

In a form I'm trying to take a value a user selected from a radio button and compare it with what's in the database. The value for the radio button is stored in $form_state['storage']['level']. The ...
0
votes
0answers
25 views

Moving New Content from Local to Remote Prod Site

I have a local development Drupal site using WAMP to build. I moved it over to Bluehost successfully. But now I would like a process to regularly update my remote site with local changes I'm making. I ...
0
votes
1answer
67 views

Displaying Database Data Within the Flow the Site

I have a multi-page form that works fine in and of itself (pathfindertool.module). However, once a user clicks submit I want the page to display some records on the page. And it DOES display the ...
0
votes
0answers
5 views

Is geographical Mysql replication doable in Drupal

I have a website with 3 languages : fr/en/ja. I would like to have 2 database server (or 3 ?) : - DB Server A : manages traffic for fr/en - DB Server B : located in Japan - manages traffic from ja. ...
0
votes
0answers
48 views

How to fix encoding mismatch problem

So I had a local testing Drupal installation, which uses a MYSQL database version which supports utf8mb4 encoding. I deployed this local site to the remote server by copying the files and database, ...
1
vote
1answer
110 views

drush sql-dump gives warning

When I ran drush sql-dump --result-file, it came back with a warning and a success message. system(): Cannot execute a blank command exec.inc:36 [warning] Database dump saved to ...
0
votes
1answer
59 views

SQL replace() function in PDO

I'd like to convert the instructions from this answer into a general script that can be reused across projects. I'm wondering how these commands can be written in Drupal 7 PDO format: UPDATE ...
0
votes
1answer
48 views

What MySQL privileges would a read-only drupal db user need [closed]

I am in the process of configuring a server that will be on the front end and will be the read-only installation. Can anyone give me some guidance on what to look for for in regards to what tables ...
0
votes
0answers
27 views

How to move Drupal7 website on Bitnami stack?

I want to transfer my Drupal7 website from one local machine to the other. I have prepared database dump using BackUp&Migrate module. However, I can`t open website front page after putting the ...
1
vote
1answer
236 views

MySQL 5.1 to MySQL 5.6 Update Causes php-cgi Error in Drupal 7 - PDO Issue?

I recently performed a MySQL upgrade on Windows Server 2008R2. I moved from MySQL 5.1 to MySQL 5.6.22 (Community Edition). (NOTE: PHP is currently 5.3.0) Things went just fine for all my WordPress ...
0
votes
1answer
48 views

Drush sql-sync failing with Ubuntu 14.04

I'm having no luck with sql-sync, there's two seemingly unrelated errors it's throwing at me which I'll detail below. I've been successfully sql-sync'ing the same site to another server, so I'm ...
0
votes
0answers
20 views

Cleaning database after Import

I imported millions of nodes (ca. 3 Millions) but i needed to abort sometimes and continue the Import. (like RAM resources) The Import is correct but i did a look into Drupal 7 Database and saw that i ...
0
votes
1answer
263 views

Does Drupal 7 support connecting to DB using MySQLi?

I have tried to connect to Mysql DB using Mysqli by declaring 'driver' => 'mysqli' inside DB array in settings.php but I get the following error: Warning: ...
0
votes
0answers
53 views

Using a different local non-Drupal database to store entities?

So we have a simple mysql database that stores information about people, which is used by multiple sites on our environment. I'd like to use entities to interact with this database, but I can't figure ...
0
votes
1answer
69 views

Migration failed with source plugin exception

I'm getting the following error: Migration failed with source plugin exception Migration failed with source plugin exception: SQLSTATE[HY000]: General error: 1366 Incorrect integer value: ...