Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

The Database Forum


You are currently viewing our The Database Forum as a guest. Please register to participate.
Login



Reply
#1054 - Unknown column 'wp_posts.post_id' in 'where clause'
Old 02-23-2012, 07:13 AM #1054 - Unknown column 'wp_posts.post_id' in 'where clause'
Junior Talker

Posts: 2
Trades: 0
I am trying to update one table with a value from another table and continue getting the above error. i am using phpmyadmin

the 2 tables i have are as follows
Table 1
wp_posts

fields
post_id
posts_title

Table 2
wp_postmeta

fields
post_id
meta_key
meta_value

I am trying to get the value from post_title to meta_value
using the following sql statement

UPDATE`wp_postmeta` SET `meta_value` = concat('MSP Studio Photographer - ',`wp_posts`.`post_title`) WHERE `wp_postmeta`.`meta_key`='_aioseop_title' and `wp_postmeta`.`post_id`= `wp_posts`.`post_id`;
brandenschmahl is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 02-24-2012, 07:08 PM Re: #1054 - Unknown column 'wp_posts.post_id' in 'where clause'
mgraphic's Avatar
Truth Seeker

Latest Blog Post:
JAMISONTUNES
Posts: 2,960
Name: Keith Marshall
Location: Connecticut
Trades: 0
It shows that the column post_id does not exist in the table wp_post, are you sure that is true or not?
__________________

<mgraphic /> - I don't have a solution but I admire the problem.
mgraphic is offline
Reply With Quote
View Public Profile
 
Old 03-07-2012, 06:26 AM Re: #1054 - Unknown column 'wp_posts.post_id' in 'where clause'
Junior Talker

Posts: 2
Trades: 0
Yes I have double checked the spelling and existance of the column, definately there in the table.
brandenschmahl is offline
Reply With Quote
View Public Profile
 
Old 03-07-2012, 09:39 AM Re: #1054 - Unknown column 'wp_posts.post_id' in 'where clause'
chrishirst's Avatar
Defies a Status

Posts: 43,949
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Remove the "backticks".
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Reply     « Reply to #1054 - Unknown column 'wp_posts.post_id' in 'where clause'
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.19250 seconds with 11 queries