Developer forum

Forum » CMS - Standard features » Move 1000 + items at once

Move 1000 + items at once

Hans Ravnsfjall
Hans Ravnsfjall
Reply

Hi

 

we have 1.000+ items currently positioned under Group (page) A, but we want to move all these items under Group B

Is this possible to do somehow at once? Anybody eg have a SQL sentence I could use in Firehose? Would be way to time consuming to move them one by one.

/Hans


Replies

 
Vladimir Shushunov Dynamicweb Employee
Vladimir Shushunov
Reply
This post has been marked as an answer

Hi Hans,

Your items are subpages?
If so then you may use SQL:

Update Page set  [PageParentPageId] = newPageId where [PageParentPageId] = oldPageId

Please be careful....

Best regards,
Vladimir

Votes for this answer: 1
 
Hans Ravnsfjall
Hans Ravnsfjall
Reply

Hi Vladimir

Thank you. I tried this

Update Page set  [PageParentPageId] = 6255 where [PageParentPageId] = 9766

And SQL FIREHOSE said 1000+ records where affected

However, in the pagetree, they are still placed under 9766

Any idea how this could be? NB: 9766 is a first child of 6255

 

/Hans

 
Nicolai Pedersen
Reply
This post has been marked as an answer

You need to reset the pagetree cache when you do thinks directly on the database. You can do that by creating a test page and delete it again (delete updates the entire cache).

BR Nicolai

Votes for this answer: 1
 
Hans Ravnsfjall
Hans Ravnsfjall
Reply

Thanx :) Works like a charm :)

 

/Hans

 
Jens Mouritzen
Jens Mouritzen
Reply

We got an issue were we havee deleted all our unpublished paragraphs with these queries in firehose:

DELETE Paragraph WHERE ParagraphShowParagraph = 'false'

and this query as well

DELETE Paragraph WHERE ParagraphShowParagraph = 0

We have done the "Create paragraph to refresh the cache".  But the paragraphs persists.

2019-02-21_14_58_28-Dynamicweb_Admin_–_Google_Chrome.png

 

You must be logged in to post in the forum