If the question is about SQL queries, consider using "sql-queries"; if the question is about the database API, use "db-api."

learn more… | top users | synonyms

-1
votes
0answers
11 views

SQL dump for cache_views

Has anyone got an SQL dump for the cache_views table?
0
votes
1answer
26 views

The website encountered an unexpected error. Please try again later

When creating a new user account, as a visitor or unregistered user, I get the following message: The website encountered an unexpected error. Please try again later. and the account is not fully ...
1
vote
1answer
12 views

Port database queries from d6 to d7

I have inherited a drupal 6 site with some custom modules, all of which are making use of db_query() commands. Now I'm porting the site with all it's modules to drupal 7, and consequently have to ...
-1
votes
1answer
12 views

Basic template - new drupal project

I would like to hear how other Drupal developers / companies are dealing with the following issues: Suppose that as a company you often have to make small Drupal websites with minor changes ...
1
vote
3answers
30 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 ...
0
votes
0answers
7 views

Where to change the input query of uc_order table

I had a requirement of modifying the columns of uc_order table. But now, I'm unable to find the input query which running during the checkout process. If anyone knows from which file this input query ...
0
votes
0answers
9 views

DUAL table query

How do I construct the following query with DB API (so it's database engine independent): SELECT 1 FROM DUAL This example is for MySQL. I believe the Postgres version is SELECT 1
1
vote
1answer
23 views

Getting information from database and giving it to javascript

The main thing I want to achieve is that my module makes a google map with markers. For now im doing this: ...
0
votes
0answers
4 views

Why changing a value in organic group table og_membership joined to a node it is not changing it at all?

I'm in a Drupal Database so... Why changing a value in og_membership joined to a node it is not changing it at all. I am looking for any other cache table or something but I can't.
0
votes
1answer
37 views

Adding an image base field to custom content entity

consider the following situation: I have created a custom content entity with several base fields (string and string_long fields) and it works flawlessly. In addition I want the entity to hold an ...
-1
votes
0answers
30 views

Updating from 7.32 to 7.34: any changes in the DB

I just tried to update my Drupal installation from 7.32 to 7.34. Since I'm on a shared hosting enviroment, I just deleted all the files (except sites/), uploaded the new ones and then ran update.php ...
0
votes
2answers
27 views

Automatize user accounts

I have a database with x users. I would like to add those accounts on my drupal database without having to recreate them one by one. I would like to do a script mike that but i'm not really sure it ...
0
votes
0answers
12 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
16 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
0answers
13 views

Database tables cck_scorm

I need some help aboute the database tables of cck_scorm module. Additional, where in the drupal site i could change these fields, like: whatgrade, updatefreq ..... Is there a document that I could ...
0
votes
2answers
19 views

Merge Users from Prod to Staging/Dev

I have users registering on my prod environment, but I also have accounts created internally on my staging environment. Is there a drush command similar to sql-sync or Drupal module that will simply ...
0
votes
0answers
5 views

Use exsisting database for user log-in

I am new to Drupal and would like to know if it's possible to use Log-in credentials from another database as the users table in Drupal. I have a web application with user accounts on a sql db that I ...
0
votes
1answer
23 views

Synchronize data between 2 Drupal sites dynamically

I currently have two Drupal sites and I would like to synchronize in a specific way the data of each one. More precisely, the first one contains detailed informations and the other only has the main ...
0
votes
0answers
13 views

Dynamic query: count groups even if row is empty

I have a dynamic query like this: $query = db_select('node', 'n'); $query->innerJoin('foo', 'f', 'n.nid = f.nid'); $query->leftJoin('bar', 'b', 'n.nid = b.nid'); $query->groupBy('b.nid'); ...
0
votes
0answers
18 views

Drupal, xampp and oci8

I would like to apologise in advance if have posted it in the wrong group. Here is the problem, I am trying to develop a Drupal site, on a local using XAMPP, and it wants me to install "oci8", here ...
0
votes
1answer
14 views

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

I have noticed at my Drupal 7 that there are gaps between the uid's of new users. The UID of a new user should increase by one from the highest assigned UID in database. However, I have noticed gaps ...
0
votes
0answers
31 views

Repair table structures in database

I've recently had a lot of trouble, self-inflicted I will admit, with my Drupal 7 website and as a result have had to restore my database from a backup several times. In doing so, the structure of ...
-3
votes
1answer
63 views

Fetch data from database and show in custom module's form [closed]

I used the following code in my module to build a form : $form['promo_type'] = array( '#type' => 'select', '#title' => 'Promotion Type', '#options' => array(t('Digital Coupon')), ); ...
5
votes
2answers
144 views

Where should I be storing custom node-related data?

There are several types of data my website generates for every node. Node's popularity score, node's comment count obtained from a 3rd party API, etc... This data is set for every node. In the past ...
1
vote
1answer
35 views

Calling a procedure from drupal

I have a procedure structure like this in an Oracle database: procedure overlapping_course ( v_id number, v_program varchar2, v_message_type varchar2, v_user_type varchar2, v_language ...
0
votes
0answers
19 views

Master master replication, variable table breaks replication

We have a setup that requires master master replication for both HA and load balancing. I have excluded all cache tables from replication, although only cache_form is actually used because we run ...
0
votes
1answer
76 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: ...
1
vote
1answer
111 views

Populate dropdown with data from database in Drupal7 using jQuery

Error is seen when i made a drop down list to populate data from Database. Database : dtable File in the template of hook_theme named : myModueForm_theme.tpl.php <?php $sel = "<select ...
0
votes
1answer
17 views

Nested select with Drupals DataBase interface

I have the following SQL query and need to translate it to the drupal API: SELECT *, (SELECT COUNT(*) FROM newsletter WHERE email = pupils.email ) AS newsletter_flag FROM ...
0
votes
2answers
48 views

Query on custom drupal 7 field

I'm facing problem in Drupal query for order by custom field Here is my query $result = db_query('SELECT n.nid FROM {node} n WHERE n.type = :ntype', array(':ntype' => 'portfolio')); this work ...
0
votes
1answer
25 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: ...
1
vote
1answer
37 views

Is it possible to done search indexing locally, then upload it?

I want to perform search items indexing on the local system . Due to high number of items and And slowing down the server Can I do something like this , then I upload the result to the DB? Without ...
0
votes
0answers
25 views

Need help debugging a DatabaseSchemaObjectExistsException error

I'm getting this error both when I try to flush the cache and when i try to run update.php. I honestly have no idea where to start so any help is greatly appreciated. ...
1
vote
1answer
14 views

How to attach a database of data to a content / entity type

I have an sqlite database representing a collection of Foo which is immutable. I would like to be able to take this collection of Foo in the GUI of Drupal, and append a few fields onto each Foo ...
0
votes
2answers
25 views

how to connect to database for form submission

I have website and on its home page there is form in which user enter his own label .As user enters label if the user with same label exists in database it through message that "This Label already ...
1
vote
1answer
34 views

server migration issue

I've developed a website and deployed it in a server, I consider this server as a test server. Now, I'm in the final stage of development and I'm looking to move the website content to new server. In ...
0
votes
2answers
49 views

Database query in template.php

Is it ok to query the database in a template.php file of a sub-theme. If not where do I put it? Below I have function that is querying the database and it works fine but I want to make sure I doing it ...
0
votes
3answers
144 views

PDOException: SQLSTATE[42S02]: Base table or view not found

I am getting a PDO error which seems related to the Mass Contact module. I installed, played with and then disabled the Mass Contact module. Now when I run cron I get the error: PDOException: ...
0
votes
1answer
49 views

Update database with update module disabled

I have recently inherited a site which needs protecting from the recent security exploits. The site has not been very well maintained but the hosting company can provide me with a database dump from ...
0
votes
1answer
162 views

Create custom form and store form data into database [closed]

I am start working with Drupal just some days ago. I am really a amateur in Drupal . I just want to know how can I create a form in Drupal with textbox or check-boxes and store the value of the form ...
0
votes
0answers
44 views

Unable to login / Warning: array_flip(): Can only flip STRING and INTEGER values!

My site has completely become unusable as it's not allowing users to log in into the site. The problem happened when I truncated the accesslog, login activity tables from the database. Later I ...
0
votes
1answer
289 views

problem migrating my drupal site PDOException: SQLSTATE[42000] [1044] Access denied for user [closed]

I have just loaded my drupal 7.32 site to JustHost from my pc (running xampp) copied the files across, and exported and imported the database to JustHost cpanel, i browse onto the website and I get ...
1
vote
1answer
26 views

How can I recover from a backup but include many changes from a dynamic site?

After the Drupageddon disaster, I've discovered that my backup plan is not sufficient. I have daily, weekly, monthly and yearly DB and file backups thanks to backup_migrate and backup_migrate_prune, ...
0
votes
1answer
15 views

SQL command to remove hypens from data value

A commerce site that I am working on has products titles and skus in the format of DS-PC-CDJ2000. The client wants the each hyphen removing and replacing with a space; DS PC CDJ2000 There are ...
0
votes
0answers
15 views

ReCreated a Content Type but it does displayed

I seem to have run in to a problem when re-creating a Content Type, I had a Content Type called Gallery on my drupal 7.32 site, I then deleted it, but then wanted to create it again. When I re-created ...
0
votes
1answer
30 views

Retrieve a list of values from a lookup table using db_select

I have a "jobs" table where each job can have multiple specialties. So I have a specialties table with a list of all available specialties and I have a lookup table that just has a job_number and a ...
0
votes
1answer
40 views

How do you check if table is empty before resetting the auto increment

I have a database table that a user can add to and remove data from within my drupal module. What I would like to do is automatically check to see if the table is completely empty after every delete, ...
0
votes
1answer
25 views

Why won't my module table populate

I have a page that is supposed to output a table of values from my database. I am logged in as an admin and another page I created works just fine, outputting a form for data to be entered into the ...
3
votes
2answers
107 views

How to push form values to database in Drupal

I am building a drupal site in which I would like the admin to have the ability to input goals into a table on the drupal database that can then be output to other users to be completed. The form for ...
0
votes
3answers
74 views

Get all rows from database

I have the table where I store uid column, and I want to get all values from table, but I only get the frist elemnt, where is my problem ? My query: $sql = db_select('voting_nomination_counter', 'v') ...