sitecoresitecore-rocks

Bulk inserts with Sitecore Rocks


Is it possible to do a bulk insert with Sitecore Rocks? Something along the lines of SQL's

INSERT INTO TABLE1 SELECT COL1, COL2 FROM TABLE2

If so, what is the syntax? I'd like to add an item under any other item of a given template type.

I've tried using this syntax:

 insert into (
 @@itemname,
 @@templateitem,
 @@path,
 [etc.]
 )   
 select  
'Bulk-Add-Item',
//*[@@id='{B2477E15-F54E-4DA1-B09D-825FF4D13F1D}'],
Path + '/Item',
[etc.]

To this, Query Analyzer responds: "values" expected at position 440.

Please note that I have not found a working concatenation operator. For example, Select @@item + '/value' from //sitecore/content/home/* just returns '/value'. I've also tried ||, &&, and CONCATENATE without success.

There is apparently a way of doing bulk updates with CSV, but doing bulk updates directly from Sitecore Query Analyzer would be very useful


Solution

  • Currently you cannot do bulk inserts, but it is a really nice idea. I'll see what I can do.

    Regarding the concatenation operator, this following works in the Query Analyzer:

    select @Text + "/Value" from /sitecore/content/Home
    

    This returns "Welcome to Sitecore/Value".

    The @@item just returns empty, because it is not a valid system attribute.