Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Moving all images from one album to another  (Read 5237 times)

0 Members and 1 Guest are viewing this topic.

Phill Luckhurst

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4822
    • Windsurf.me
Moving all images from one album to another
« on: July 31, 2007, 10:46:12 am »

Once every 6 months I move older images from one folder into an archive folder*, remove the old album and create a new one. At the moment I have to move each file individually which is quite time consuming. Is there a simple way to move all files from one album to another?

*It is a windsurfing website so each season gets replaced with a new one and any more than 4 seasons ago get archived in an album rotation sort of way.

http://www.windsurf.me.uk
« Last Edit: July 31, 2007, 07:36:28 pm by Nibbler »
Logged
It is a mistake to think you can solve any major problems just with potatoes.

Nibbler

  • Guest
Re: Moving all images from one album to another
« Reply #1 on: July 31, 2007, 10:56:22 am »

Assuming you mean 'album' and not 'folder', the simplest way is to run an SQL query.

Code: [Select]
UPDATE cpg_pictures SET aid = <newaid> WHERE aid = <oldaid>
Replace <newaid> <oldaid> and cpg_ as appropriate, backup the table before running.
Logged

Phill Luckhurst

  • Administrator
  • Coppermine addict
  • *****
  • Country: gb
  • Offline Offline
  • Gender: Male
  • Posts: 4822
    • Windsurf.me
Re: Moving all images from one album to another
« Reply #2 on: July 31, 2007, 07:23:16 pm »

Cheers Nibbler. It worked a treat ;D.

Logged
It is a mistake to think you can solve any major problems just with potatoes.

madhatt

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Moving all images from one album to another
« Reply #3 on: August 01, 2007, 09:00:50 pm »

Thanks Nib, works great for me too.
Logged
Pages: [1]   Go Up
 

Page created in 0.017 seconds with 20 queries.