WordPress stores user generated content, along with other configurable information, in a a database (typically MySQL).

learn more… | top users | synonyms

6
votes
2answers
450 views

How to tell which database tables belongs to which multisite site

I have a local multisite installation I use for development with a relatively large number of sites set up. Every site has its own numbered database tables (i.e. wp_n_links, wp_n_options, ...
0
votes
0answers
82 views

Unusable menus and “Illegal widget setting ID: nav_menu_item[]” error

This is a bug in my WP install that has crept up unknowingly; I can't say for sure when it began. To describe it: there were menus created in the Appearance -> Menus page early in the site's history, ...
2
votes
0answers
41 views

Should I hint table index for search query on wp_post

I'm currently inspecting a WordPress setup with multiple custom post types that should be included into search results. The database query for a search after the word Search looks like this: SELECT ...
0
votes
3answers
5k views

How to delete all records from or empty a custom database table?

I can't seem to find a simple reliable way to do this - perhaps?: // delete row ## global $wpdb; $delete = $wpdb->query( $wpdb->prepare( "DELETE * FROM `wp_table_name`" ) ); ...
0
votes
0answers
47 views

get_the_terms is not working

After I updated WordPress, a function using get_the_terms() is not working. When I run get_the_terms() I'm not getting terms, but when I add before that call wp_cache_flush(); I'm getting terms so ...
0
votes
1answer
26 views

I have a form with a custom button ,i want to add the field data to an database when clicking the custom button

So im new to wp/themes,and coding, but love it and love trying to build sites, I used the form from the theme, extracted only the email field and added a button on that field basically inside of that ...
1
vote
0answers
28 views

Show all data in database table and make it into an interactive table

I have to make a table where my data from my database can be stored and rearranged with every row. The name of every row should be a link to the function mymanual_edit(). Look at the image for ...
1
vote
1answer
105 views

How to merge local and live databases?

We've been developing for Wordpress for several years and whilst our workflow has been upgraded at several points there's one thing that we've never solved... merging a local Wordpress database with a ...
1
vote
2answers
897 views

Form that sends data to an admin panel and can export it

Is there a way to have a form submit data to a admin control panel where the data is stored and can be rectified there? Could it also be able to export the data as excel for example?
0
votes
0answers
17 views

change data in mysql but don't change in admin

I have a problem, I have changed the content of my page in MySQL, but when I reopen the same page in the WordPress Admin panel, the content hasn't changed why is this? I'm using the interconnect ...
0
votes
1answer
174 views

Catchable fatal error in formatting.php

I'm running a WordPress 4.4.2. I have one site that's working fine. When I went to set up another site, I got the following error upon trying to save the "general" settings page: Catchable fatal ...
0
votes
0answers
16 views

Excerpt data from one page into another

I'm a comparative noob at working inside WordPress. I'm trying to do my homework before asking, but haven't been able to uncover answers to the following. I could use your expertise. I'm working ...
8
votes
3answers
360 views

Ignoring initial articles (like 'a', 'an' or 'the') when sorting queries?

I'm currently trying to output a list of music titles and would like to have the sorting ignore (but still display) the initial article of the title. For example if I had a list of bands it will be ...
0
votes
0answers
26 views

WordPress Database - wp_comments?

I am working on extracting data from a WordPress database to my own. I have managed to transfer all the comments from the wp_comments table. Every comment should have an image or attachment ...
0
votes
1answer
58 views

Improving wpdb queries with large data

My plugin will handle large amounts of data that could could result in the queries reading over 5000 items in a database query. The admin will provide a set of CSV files that get stored/organized in ...
0
votes
1answer
29 views

Include post_status check within $wpdb query

I've got a function that returns a count from the database for publish posts that match the product ID to the post meta ID (both are the product type). I've realized this query returns unpublished ...
3
votes
2answers
78 views

What is the added “complexity” of custom tables?

Wordpress Codex says: Think very carefully before adding a table because it adds complexity to your plugin that many users and site builders prefer to avoid. Why is it so? Adding more tables is ...
1
vote
0answers
24 views

Emojis replaced by '?' automatically

I just discovered that all emojis on my site were replaced by the ? char. I saw this on comments and posts. Tables like wp_comments or wp_posts had a utf8mb4_unicode_ci collation before and now, so ...
0
votes
0answers
28 views

Wordpress changes not showing

I'm wondering how to fix the website when the changes are not showing instantly? I tried the following fix: Installed W3 Total Cache and Super cache and cleared all the cache on the website Cleared ...
0
votes
0answers
23 views

log in form using a separate database

in the html code i have made this form: <form action="http://www.mySite.co/login.php" method="post"> <fieldset> <p><input type="text" name="uname" placeholder="Name" required>&...
1
vote
2answers
84 views

Create WP_Query to search for posts by their categories or their parent/child categories

Hello I am really sorry if this has been asked before but I couldn't find the exact solution I need. So here's the problem I want to create a search in my Wordpress page. Whenever a user submits the ...
1
vote
1answer
16 views

Is there a way to recover the table wp_term_relationships?

I'm trying to help a Non-Profit Organization with their site (which is built with Wordpress) that suddenly became "buggy"/odd: menus were missing, categories were empty, etc. I'm no expert around ...
0
votes
0answers
79 views

siteurl value getting populated with junk in wp_options table

My website was getting this error on every page : Catchable fatal error: Object of class WP_Error could not be converted to string in /home/juhisheth/public_html/wp-includes/default-constants.php on ...
0
votes
1answer
36 views

Localize strings from db

I'm using this method to translate strings in my template. The question is, what if some strings are dynamically loaded from the db? How can i translate them? I've been googling for days and even ...
6
votes
2answers
941 views

Is there a plugin that will override the “Error establishing a database connection” message? [closed]

My provider's database server recently had some downtime and my site was displaying the classic "Error establishing a database connection" message for about an hour. I knew what the problem was but ...
0
votes
1answer
40 views

multiple wordpress installation with shared usertable on an different database

I have multiple wordpress installation, and I would like them to share the same usertable. The wordpress installations are already up and running, and they all have their own database. Is it ...
1
vote
1answer
32 views

Unable to set a default serialized array using dbdelta()

I am trying to set up a table with dbDelta() and one of the columns will have as default a serialized array with predefined values. The issue here is that dbDelta() explodes the query using ...
0
votes
0answers
20 views

Processing a lot of $wpdb isn't insert all the data

In my plugin the user provides some CSV files that are processed and either inserted or updated based on a sku (which acts as a foreign key to my DB and a primary key for where the CSV comes from). I ...
0
votes
0answers
20 views

See site's database's schema

How can I have access to my wordpress site's database schema without SSH an access ? I need to see the tables and fields but couldn't find a way without SSH (my host doesn't provide SSH access).
1
vote
0answers
22 views

How to update the values when the featured image has changed?

I'm trying to implement this function. It saves in the database the dominant color of the image uploaded as featured image in a post. It's working perfectly BUT the problem is that it only works when ...
0
votes
0answers
23 views

Access a WordPress Table from Outside Project

I have a PHP project on example.com and I have a WordPress installation on example.com/blog. I need to get data for my PHP project from one of My WordPress table. Is it possible? If it is possible ...
0
votes
1answer
20 views

Query wp_postmeta into an array based on post_id

I know this might be a simple question but can someone explain to me how to query the WP database and pull in all the "meta_key" and "meta_value" from "post_id" into an array? I have looked at code ...
2
votes
2answers
448 views

Is there a shortcut to change bulk BMP images to JPG images in a site?

Images in WordPress posts, as I understand, are uploaded manually. They are uploaded by default to uploads folder. A client of mine reported that, in one of his site, he uploaded all the images in BMP ...
3
votes
1answer
212 views

How to export WP database for import using WP-CLI on Vagrant Box?

Problem Now that I have a new environment with WP-CLI db import / export I need to import a database from a website that never had WP-CLI installed. Question What's the best Non-WP-CLI export ...
0
votes
0answers
12 views

Do I need to worry about filling meta_value column in wp_postmeta table during migration?

I am migrating article/post data from a Joolma site running 'seblod', which has scattered the data across multiple database tables, so I can't use an off the shelf migration plugin. I am transfering ...
0
votes
1answer
104 views

How Yoast SEO plugin works with variable %%name%%?

I know that Yoast SEO plugin doesn't create any database table then why in wp_postmeta numbering of meta_id are not continuous? Is it because of Yoast Plugin? Also I want to know how its feature of ...
-1
votes
1answer
24 views

Tool to check the database in Production [closed]

I Would like to use a tool to execute SELECT requests on the PRODUCTION database. This tool must be full security because my site is deployed on Internet. Any idea ? Regards
0
votes
2answers
141 views

Can't update database after wordpress update from 3.8.1 to 4.4.1

I have just updated wordpress 3.8.1 to 4.4.1. Tried to update in various ways: Before updating I have deactivated all the plugins and switched to the default theme provided by wordpress i.e. ...
0
votes
0answers
22 views

Bulk find replace to convert hundreds of old URL calls

We have a new wordpress site generated from an old html site with thousands of pages. An import process was used, but unfortunately as a result the site has hundreds of references within content to ...
0
votes
1answer
24 views

Unkown meta_value in ACF

I'm using ACF, but I wonder the meta_value means? Below is a snippet from my database: meta_id post_id meta_key meta_value 9394 4661 _carousel_0_image field_5683f27fd880e So what ...
0
votes
0answers
133 views

How do I establish a connection between Firebase user database and WordPress?

I'm making a Website and an android app. The android app stores its user details i.e., username and password on Firebase database; I'm also making a website and I want a login in the website which ...
0
votes
0answers
24 views

One WP Database outside localhost and two connections

I would like to ask for help with this problem. I have two places where I have the same WP. 1) Test site - own domain, hosting and DB - here is stored database, so siteurl is here, example: test.com ...
0
votes
0answers
20 views

Import SQL backup

So I accidentally deleted MySQL database of my wordpress, but my site is still running, I can access all the file in the filezilla but I just can't access the admin area of wordpress to make any ...
0
votes
2answers
455 views

Custom Post Type or Custom Tables

I am in the process of writing a plugin that allows end-users to submit a form that includes customer information. Upon submission, I am notified that a new customer has submitted the request form. ...
10
votes
5answers
2k views

Is it bad practice to create own table for a plugin?

If I want to save settings for my plugin then it is pretty easy and straight forward. Now I would like to save to the database a bit more. A file name, and 3 other values that only apply to that ...
0
votes
0answers
52 views

#1062 - Duplicate entry '1' for key 'PRIMARY'

I am trying to move my database from my usbwebserver to my online server. But I get this error, can anyone help me with this? #1062 - Duplicate entry '1' for key 'PRIMARY'
0
votes
0answers
18 views

Importing inventory from a csv file in the ftp to the database

I'm looking to upload the content contained in a csv file from FTP directly into a WordPress database every 24 hours. This csv file (containing inventory items) gets generated from one site, and I ...
0
votes
0answers
38 views

MS Access to wordpress sql

I have a client who runs a store and has around 125000 products and he manages his stock from MS Access server. His current site is just for product catalog but he wants to have a new site to sell ...
0
votes
1answer
711 views

WooCommerce - Query for ordered products

I'm trying to obtain all orders for particular day/time and then order products using SQL (MySQL) as seen in the query below: select p.ID as order_id, p.post_date, i.order_item_name, ...
0
votes
1answer
39 views

Does WordPress $wpdb functions wait when table is locked?

Does WordPress' $wpdb functions wait when the table is locked? For example Function A() uses $wpdb->getresults. When $wpdb->getresults wants to read a table and its locked, does it wait for ...