Already a member? Log in

Sign up with your...

or

Sign Up with your email address

Add Tags

Duplicate Tags

Rename Tags

Share It With Others!

Save Link

Sign in

Sign Up with your email address

Sign up

By clicking the button, you agree to the Terms & Conditions.

Forgot Password?

Please enter your username below and press the send button.
A password reset link will be sent to you.

If you are unable to access the email address originally associated with your Delicious account, we recommend creating a new account.

ADVERTISEMENT

Links 1 through 10 of 702 Dmitry Tatarinov's Bookmarks

Share It With Others!

UPDATE wp_posts
SET post_parent = [post number of your new post]
WHERE post_type = 'attachment'
AND post_parent = 0

Share It With Others!

Share It With Others!

Share It With Others!

Share It With Others!

Share It With Others!

SELECT *
FROM wp_posts
WHERE
-- the attachments
post_type = 'attachment'
AND (
-- ignore anything without a parent
post_parent != 0
-- filter on anything that has a parent that does not exist
AND post_parent NOT IN (SELECT ID FROM wp_posts)
)

Share It With Others!

Share It With Others!

Share It With Others!

Share It With Others!

ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT