View Full Version : Batch rename items in Data Explorer
Resurgam
07-19-2007, 02:53 AM
I have a number of databases which store the results of eBay auctions, via the Firefox Scrapbook extension, but all the results appear in the Data Explorer prefixed by (in my case) "ebay.co.uk" followed by the actual item name. This isn't a problem, except that it wastes valuable screen space. Is there any method to perform a 'batch rename' in the Data Explorer panel, to remove the prefix?
Regards, Geoffrey
janrif
07-19-2007, 06:57 AM
Originally posted by Resurgam
Is there any method to perform a 'batch rename' in the Data Explorer panel, to remove the prefix? How about selecting all the items in the explorer pane & then changing the Item Title in the Attributes pane? Wouldn't that work for you?
Resurgam
07-19-2007, 07:41 AM
Dear Jan,
Thanks for your reply and suggestion, but what I am trying to do is just remove a specific recurring part of the Item Title. A typical imported example would be:
eBay.co.uk: Battleship,HMS WARSPITE (1913)~Jutland,1916.RP (item 120067912285 end time 02-Jan-07 18:38:55 GMT)
I just want to remove the "eBay.co.uk: " portion of the title. If I select all items and go to 'attributes', the field is empty.
Regards, Geoffrey
janrif
07-19-2007, 08:12 AM
Originally posted by Resurgam
[snip] I just want to remove the "eBay.co.uk: " portion of the title. If I select all items and go to 'attributes', the field is empty. Sorry, I think I mis-understood what you wanted to do & I'm not sure it's possible but maybe someone more knowledgeable than I will come along w an idea.
ashwken
07-19-2007, 10:04 AM
Originally posted by Resurgam
eBay.co.uk: Battleship,HMS WARSPITE (1913)~Jutland,1916.RP (item 120067912285 end time 02-Jan-07 18:38:55 GMT)
I just want to remove the "eBay.co.uk: " portion of the title.
Probably the best way to handle this is to make the change to the Item Title shortly after creating it, before the situation gets away from you. Incorporating the renaming of the imported Item earlier in your workflow is probably your best solution.
If you currently have a large number of Items to rename (more than a few dozen, which could be renamed manually with F2), probably the best course of action would be to Export to oml/xml, then do a Search/Replace with a compitent text editor (Notepad or equivalent), then Import the modified oml/xml back into UR (or maybe a new UR database).
I have not personal tried this with Stored webpages, you might want to run some tests, but it should work.
Also, when exporting be sure to select ALL fields to be exported, since it will probably be best to Import back into a new folder (creating new Items). I don't know how UR ia going to handle a new Item with the same URL attribute as an exisitng Item - like I said run some tests.
You can run the Export against a selected folder to narrow the focus, and for testing.
This is just off the top of my head unless anyone else has any ideas.
Updated:
You might want to check Tools | Options | Import (More) - Use Page Title for Item Title, changing this setting may have an impact on how new Items are named.
Updated - Another Thought:
Although I'm not familiar with FF Scrapbook, but if all (any) of the webpages still exist in Scrapbook can you Export or Save As out to individual html files (or .mht)?
How does Scrapbook name the resulting html files?
Could you use a program such as Lupas Rename (http://rename.lupasfreeware.org/) to parse the filenames to your liking prior to import to UR?
Just thinking out loud.
Resurgam
07-20-2007, 03:49 AM
Many thanks again for the helpful suggestions, but I've let it get out of hand, with 3,000 items in two databases. I think, on balance, I'd rather put up with the loss of screen space in the data explorer panel than try to export/import on a mass scale, though this does sound as if it should work.
Again, thanks for the quick responses and helpful suggestions.
wordmuse
07-21-2007, 07:30 PM
The only thing I could come up with is to use something like Macro Toolworks and create a macro that deletes the set number of keys in your prefix and then moves to the next item. It would simulate pressing these keys:
Ctrl+1 (to make sure you're in the data explorer)
F2 (to edit the item)
Ctrl+Home (to go to the beginning of the item's text)
Del
Del
...
Del (however many deletes you need to get rid of the prefix)
Enter (to secure the changes)
DownArrow (to move to the next item)
Just tried it on my machine and it works. You might have to fiddle with it, but I'm fairly confident that I'm close.
Regards,
Bal
kinook
07-23-2007, 03:58 PM
You could use SQLite to update the database, something like:
BEGIN;
UPDATE Item SET ItemTitle = substr(ItemTitle, 11, 1000) WHERE ItemTitle LIKE 'ebay.co.uk%';
UPDATE ItemAttribute SET Value = substr(Value, 11, 1000)
WHERE AttributeID = 5 AND Value LIKE 'ebay.co.uk%';
COMMIT;
http://www.kinook.com/Forum/showthread.php?threadid=2825
vBulletin® v3.8.11, Copyright ©2000-2024, vBulletin Solutions Inc.