coppermine-gallery.com/forum

Support => cpg1.3.x Support => Older/other versions => cpg1.3 Upload => Topic started by: Phalanx on August 02, 2004, 06:50:11 PM

Title: Is there a way to move users upload album?
Post by: Phalanx on August 02, 2004, 06:50:11 PM
Is it possible or there's a way to move users upload album into the main category? There are alot of users album I like to move but, it seem the only way is to move them manual by ftp and re-batchadd.
Title: Re: Is there a way to move users upload album?
Post by: Casper on August 02, 2004, 07:56:54 PM
There is no normal method.

You can do it in the database, by changing the category the album is in there.
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 03, 2004, 03:30:33 AM
Hi,
Thanks for reply. Which sql table field should I look for the users upload albums? I don't think it's cms_cpg_albums .

Assuming that I can move it. Do you know if the author of the users will retain in the album info? Once the albums is now in a different category?
Title: Re: Is there a way to move users upload album?
Post by: Casper on August 03, 2004, 11:48:12 AM
Yes the table you need to edit is the albums table.

The album will now be 'owned' by the admin, and if uploads to it are allowed, ALL members with upload permissions will be able to upload to it.  If uploads to it are not allowed, only you, the admin, will be able to upload to it.

The pics will still be shown as being uploaded by the original owner, and will display as his in his profile.
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 04, 2004, 07:30:51 AM
When you mean "and if uploads to it are allowed" , you mean for the users to upload to the main category?

If it is, this was my purpose as I don't want to them to have permission to upload, cause users tend to mess things up alot, and not upload by the order I like.

Thats why I like to be able to move to main category by myself from their users galleries album, with their permission of course.

So in final what you mean is that, if I move their albums by mysql in albums table. The author of that album will now be show as uploaded by admin?

Phalanx
Title: Re: Is there a way to move users upload album?
Post by: Casper on August 04, 2004, 09:38:11 AM
If you want to restrict uploads, then yes, this will do as you ask.

The owner of the album will now be you, BUT the pics will still be shown as uploaded by the original owner.
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 06, 2004, 08:27:39 PM
Thank you. I tried to follow this and move by mysql and its prove to be difficult and monotomous task. It's ok to do this when there's a few albums but I have over 400 albums in main category and who know how many in users galleries. Its quite impossible to search a select albums in so many pages.

Is there a way to move an albums by its aid into a new pos (category) by just using the command prompt? I'm not an expert on mysql and I don't want to screw things up. Thanks alot if you can assist me on this, this is my last question.
Thanks.
Title: Re: Is there a way to move users upload album?
Post by: Nibbler on August 06, 2004, 08:39:55 PM
You can enter the queries manually:

UPDATE cpg_albums set category = 5 WHERE aid = 2
UPDATE cpg_albums set category = 5 WHERE aid > 56
UPDATE cpg_albums set category = 5 WHERE aid IN ('3','7','123')
UPDATE cpg_albums set category = 5 WHERE aid BETWEEN 50 AND 65


just a few examples, change cpg_ to the prefix you are actually using
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 07, 2004, 05:27:18 PM
So I would enter these queries from phyadmin in:

Click on Query tabs

where it said SQL-query on database Mytable:

I type this in: UPDATE cpg_albums set category = 5 WHERE aid = 2

then click on Submit Query leave everything else as is? Just to verify.

Thanks.
Title: Re: Is there a way to move users upload album?
Post by: Joachim Müller on August 08, 2004, 10:19:11 AM
be sure to understand what you're doing with a tool like phpMyAdmin, I recommend doing a backup (dump) of your mySQL tables before actually running any queries like that.

GauGau
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 09, 2004, 12:06:23 AM
Yea I realize this and take the precautions.

But is the steps I ask above is the correct way of entering the query? Can you verify, thanks.
Title: Re: Is there a way to move users upload album?
Post by: Joachim Müller on August 09, 2004, 12:09:07 AM
yes, by clicking on the "query" tab you get a textarea field where you can type your query or copy-n-paste it in.

GauGau
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 09, 2004, 02:10:27 PM
What does it mean by this when I submit query..

You have to choose at least one Column to display

with only cpg_albums table selected

Do I need to select Add Field Columns to something?
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 09, 2004, 02:12:31 PM
This moving albums process is harder than I thought :(
Title: Re: Is there a way to move users upload album?
Post by: Casper on August 09, 2004, 02:31:30 PM
Please tell us, are you wanting to move ALL the user albums, and what is the category id you want to put them in?
Title: Re: Is there a way to move users upload album?
Post by: Joachim Müller on August 09, 2004, 03:59:30 PM
I strongly recommend you don't use phpMyAdmin at all, since you appear not to be experienced enough. You should at least post the query you entered and the full error message.

GauGau
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 09, 2004, 05:31:25 PM
Right. What I want is move the users galleries albums into the one of the main category of my choice.

This is the query I used: UPDATE cms_cpg_albums set category = 17 WHERE aid = 319  you can also see this from the screenshot

Query screenshot: http://www.909ms.com/images/jpn/cpg_query.jpg

Query error: http://www.909ms.com/images/jpn/cpg_error.jpg

Query cpg_albums: http://www.909ms.com/images/jpn/cpg_albums.jpg

If you look on the right, the 17 is the main category and 10654 is the user category. One other things that curious me is that all of the main category have a sequence for their albums, you can see ex: blueeyes 1-6 have pos of 0-5. If I were able to move aid 319 into category 17, wouldn't the 2 pos have the same number conflict? would this result in anything? just a curiuos. I hope this is some help to make me these albums :(
Title: Re: Is there a way to move users upload album?
Post by: Joachim Müller on August 09, 2004, 06:34:47 PM
your site is blocked for me, can't look at it. Does it contain adult content (if yes: you should always post a warning with adulkt links)?

GauGau
Title: Re: Is there a way to move users upload album?
Post by: Casper on August 09, 2004, 09:20:32 PM
Try running this query from within the table.  This query works fine for me.

If you are going to do them 1 at a time, you may as well just click on the edit icon next to each album row.  But I agree with gaugau, you could end up ruining your site if you make an error.  Make a dump before you do any work, so you can restore if you need to.
There will be no conflict when the albums move, the database will just change the position within the category accordingly.

@ gaugau, it's not an adult site, so no warning needed.
Title: Re: Is there a way to move users upload album?
Post by: Phalanx on August 09, 2004, 10:47:45 PM
Thank you guys  :). I guess i will just do this manually 1 by 1 by clicking on icons. If I need any more help from this, guess I will just come back here and bother you agains  ;D.
Thanks.
Title: Re: Is there a way to move users upload album?
Post by: Joachim Müller on August 09, 2004, 11:21:19 PM
Quote from: Casper on August 09, 2004, 09:20:32 PM@ gaugau, it's not an adult site, so no warning needed.
I work for an american company - they have established a content-based web-filter that blocks pages in a manner that is sometimes hard to understand for europeans... ;)

GauGau
Title: Re: Is there a way to move users upload album?
Post by: Casper on August 10, 2004, 12:47:23 AM
Quote from: GauGau on August 09, 2004, 11:21:19 PM
sometimes hard to understand for europeans... ;)

Hey, I'm European too  ;)
Title: Re: Is there a way to move users upload album?
Post by: Joachim Müller on August 10, 2004, 07:24:45 AM
I know, that's why I posted this ;). They block for example the web pages of regular political parties (labour, torries, greens, liberals) under the keyword "occult/religion" - this is something Europeans find hard to understand...

GauGau
Title: Re: Is there a way to move users upload album?
Post by: omniscientdeveloper on August 10, 2004, 10:35:04 AM
peans suck anyways :P
Title: Re: Is there a way to move users upload album?
Post by: Joachim Müller on August 10, 2004, 02:55:32 PM
Hehe ;D