S
S
Sergey Margelov2012-09-15 18:20:06
MySQL
Sergey Margelov, 2012-09-15 18:20:06

Create proper MySQL query?

Good afternoon.
An amateur layout designer took on a complex project. My knowledge of MySQL is very superficial. The task is as follows: It is
necessary to extract all values ​​of the created field from all rows with catid != 16 of the jos_content table and in the wp_posts table change the post value in the post_type field to the page value in all rows in which the value of the post_date field corresponds to that found in the source table. In short, a kind of modification of the vlookup function from excel, only with the help of a MySQL query in the phpmyadmin panel. I really hope that I managed to formulate the conditions (I re-read it myself - I understood, and this is an indicator). Many thanks in advance.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
edogs, 2012-09-15
@smargelov

You would have a php / mysql programmer in the team. No offense, but if _such_ level questions arise, then believe me - you will make jambs in a _complex_ project in bulk.
Basically: something like
update wp_posts set post_type='page' where post_type='post' and post_date in (select `created` from jost_content where catid<.16)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question