Home Forums ASE Support Serialized data in postmeta – how to remove

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #19771
    Hyun Supul

    Hi I can’t tell you 100% sure without looking at your table entries, but those metadata you see may not have been created _directly_ by ASE, but rather indirectly by the WordPress code itself. So it’s possible other themes or plugins you use may bring back those metadata. It’s also questionable how much benefit you will gain by removing those entries. The amount of space you save would not be that significant compared to the image data themseleves. (Where each image take up hundreds of KB if not MBs, whereas an entry in DB may take up a few dozen bytes if even that.) Also when you have more entries in DB it doesn’t affect search time that much either.

    Given that, it should be very possible to remove specific columns or matching data using some SQL or PHP codes. (You can use WP functions such as delete_post_meta or use SQL statments such as DELETE) If you can show me a few rows of wp_postmeta table I can give you suggestions. But bear in mind that changing DB using this kind of method is a very dangerous operation. I can’t take any responsibility whatsoever. Before you do anything you should back up your DB first.

    • This reply was modified 2 years, 7 months ago by Hyun Supul.

    Hi Hyun,

    I agree with you that the data seems quite insignificant, but if we leave all seemingly insignificant data left behind by plug-ins as well as WordPress itself… Well, it grows and eventually will slow down queries:-)

    As for delete_post_meta, I’m not sure that would be possible, because the aesop reference is only part of the larger meta_value.

    Anyway, here is one meta_value for you to wrap your head around, thanks!

    a:5:{s:5:"width";i:1325;s:6:"height";i:2000;s:4:"file";s:20:"2014/07/DSC84661.jpg";s:5:"sizes";a:11:{s:15:"aesop-component";a:4:{s:4:"file";s:22:"DSC84661-1250x1887.jpg";s:5:"width";i:1250;s:6:"height";i:1887;s:9:"mime-type";s:10:"image/jpeg";}s:9:"thumbnail";a:4:{s:4:"file";s:20:"DSC84661-180x180.jpg";s:5:"width";i:180;s:6:"height";i:180;s:9:"mime-type";s:10:"image/jpeg";}s:6:"medium";a:4:{s:4:"file";s:20:"DSC84661-398x600.jpg";s:5:"width";i:398;s:6:"height";i:600;s:9:"mime-type";s:10:"image/jpeg";}s:12:"medium_large";a:4:{s:4:"file";s:21:"DSC84661-768x1159.jpg";s:5:"width";i:768;s:6:"height";i:1159;s:9:"mime-type";s:10:"image/jpeg";}s:5:"large";a:4:{s:4:"file";s:22:"DSC84661-1325x2000.jpg";s:5:"width";i:1325;s:6:"height";i:2000;s:9:"mime-type";s:10:"image/jpeg";}s:14:"post-thumbnail";a:4:{s:4:"file";s:21:"DSC84661-1148x574.jpg";s:5:"width";i:1148;s:6:"height";i:574;s:9:"mime-type";s:10:"image/jpeg";}s:19:"fotografie-featured";a:4:{s:4:"file";s:20:"DSC84661-533x533.jpg";s:5:"width";i:533;s:6:"height";i:533;s:9:"mime-type";s:10:"image/jpeg";}s:25:"fotografie-featured-fluid";a:4:{s:4:"file";s:20:"DSC84661-640x640.jpg";s:5:"width";i:640;s:6:"height";i:640;s:9:"mime-type";s:10:"image/jpeg";}s:17:"fotografie-slider";a:4:{s:4:"file";s:22:"DSC84661-1325x1080.jpg";s:5:"width";i:1325;s:6:"height";i:1080;s:9:"mime-type";s:10:"image/jpeg";}s:21:"fotografie-hero-image";a:4:{s:4:"file";s:20:"DSC84661-864x864.jpg";s:5:"width";i:864;s:6:"height";i:864;s:9:"mime-type";s:10:"image/jpeg";}s:29:"jetpack-portfolio-admin-thumb";a:4:{s:4:"file";s:18:"DSC84661-50x50.jpg";s:5:"width";i:50;s:6:"height";i:50;s:9:"mime-type";s:10:"image/jpeg";}}s:10:"image_meta";a:12:{s:8:"aperture";s:3:"7.1";s:6:"credit";s:0:"";s:6:"camera";s:11:"NIKON D7000";s:7:"caption";s:0:"";s:17:"created_timestamp";s:10:"1391965555";s:9:"copyright";s:27:"© 2014, Ron van Middendorp";s:12:"focal_length";s:2:"17";s:3:"iso";s:3:"500";s:13:"shutter_speed";s:5:"0.002";s:5:"title";s:0:"";s:11:"orientation";s:1:"0";s:8:"keywords";a:0:{}}}


    Is it me, or can the meta in my previous post not be expanded?

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.