|
|
Welcome to the Invelos forums. Please read the forum
rules before posting.
Read access to our public forums is open to everyone. To post messages, a free
registration is required.
If you have an Invelos account, sign in to post.
|
|
|
|
Invelos Forums->DVD Profiler: Plugins |
Page:
1... 35 36 37 38 39 ...52 Previous Next
|
New Plugin: BulkEdit - Bulk Editing, XML and CSV Import of Profiles |
|
|
|
Author |
Message |
Registered: March 13, 2007 | Reputation: | Posts: 2,217 |
| Posted: | | | | Quoting mediadogg: Quote: Initial supported fields will be: location, slot, notes, collection#, collectiontype. Input file will be in standard CSV format.
Any others I should add? How about the Purchase-Infos? I have the XSLT ready also, but since I'm a bit skeptic about the whole XML- import, doing it all inside BulkEdit would be much more preferable. The math was quite simple, for Slot "Slot mod 4" with replacing the result 0 with 4. For Location it was "ceiling(Slot div 4) + ((substring-after(Location,'D') - 1) * 100)" I had some strange things going on there, the aspect ratio didn't show on some titles (both "2001"), titles with region 0 had no 0 shown, and the crew consisted only of director. But everything was fixable with a profile update. cya, Mithi PS slotchanger.xsl, Test-XMLs | | | Mithi's little XSLT tinkering - the power of XML --- DVD-Profiler Mini-Wiki |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | Yeah, I was thinking about Purchase Info. Ok.
Thanks for the modulo math. In the back of my mind, I had been considering a "Math" augment to the Regex tool in BE. It would accept as input a Regex variable (e.g. $1), perform some math (say Visual Basic), and return the result. I can use your worked out expressions to try it.
Those two things will take awhile, so I will go ahead and release what I have now, and do another release later.
Meanwhile, I have no problem if you offer the ljckbailey your stuff - maybe he will enjoy it - he seems kind of technical.
Thinking on the fly ... maybe C# .Net has way to execute XSL easily. Then I could use your XSL code snippet directly in the "Math" tool. So, if you want ti post it, I will give it a go. (Oh, now I see - you already did that in your last post ... cool.)
As usual, we get more goodies from a collaboration. I love it. | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | BulkEdit V2.46 Available - Please do not quote this post, as information will be edited. - Bug in Export to Excel file location repaired. - "Export to Excel" menu renamed to "Export to Excel (XML)" - Menu option added: Tools \ BulkEdit \ Bulk Load Personal Data Bulk Load Personal DataThis new menu provides a quick way to update existing profiles with revised or new personal data. Quote: Notice: The changes are made in Real Time, on the fly, as the data is read from the file. It is imperative that your database be backed up before using this function. You have been warned.
Input File Format: CSV, with "," as delimeter, double quotes used for strings with spaces
Fields Supported (case insensitive): ProfileID - All DVDP formats supported, including manual profiles and disc IDs. Required field, used as a key only, and must already exist in the database. Disc - A number from 1 to any reasonable disc#. Defaulted to 1, if incorrect or missing. Read Only, used to identify the disc for Location, Slot, etc. Location - Text field used to fill in the DVDP Location field of the corresponding Disc. Slot - Text field used to fill in the DVDP Slot field of the corresponding Disc. Notes - Text field used to fill in the DVDP Notes field. EXISTING NOTES WILL BE OVERLAID. PreNotes - Text field pasted at the beginning of the existing DVDP Notes field. PostNotes - Text field pasted at the end of the existing DVDP Notes field. Collection# - A number used to fill in the DVDP collection number field. Blank accepted. Use "-1" to set None flag. CollectionType - A text field "owned", "ordered", "wishlist", or the exact spelling of any already defined custom categories in your database.
A future release will add more fields. Purchase Info has already been requested. MyLinks is also a candidate. Quote: Disclaimers and Limitations (1) There has been limited testing, although the code and methods have been derived from existing BulkEdit code. There are numerous tests in an attempt to protect against crashes from ill-formed data, but be careful. (2) No support for alternate delimiters in the CSV file. Code Page 1252 assumed. (3) Exact spelling of fields is required. There must be exactly 1 header record at the beginning of the file. (4) Standard line delimiters are expected in the file. (5) Each line of the file should have exactly the same number of fields as the header
Examples (fields can be in any order, only ProfileID required): profileid, location, disc, slot, notes, prenotes, postnotes, collectiontype, collection# <---header 4942463602307.17, "top shelf", 1, 23,"new notes","in front","at the end","ordered",10001 085391161035, "Page: 2", 4, "Disc: 4","notice blank collection number","front","back","netflix","" 025195021197, "upstairs", 2, 3 ,,"None set in collection number","back","bluray",-1 ICFD8461A80517AC6, "Disc ID as key", 2, 3 ,,"None set in collection number","back","bluray",-1 <---preserves notes M000000000004.15,"Manual ID is key", 1, 23,"new notes","in front","at the end","ordered",10001
profileid, disc, location, slot 4942463602307.17, 1, "top shelf", 23 085391161035, 4, "Page: 2", "Disc: 4" 025195021197, 2,"upstairs", 3 ICFD8461A80517AC6, 2,"Disc ID as key", 7 M000000000004.15, 1, "Manual ID is key", 189
profileid, collection# 4942463602307.17, 10001 085391161035, 402 025195021197, 3 ICFD8461A80517AC6, -1 <--- None M000000000004.15, "" <-- Blank Collection#
Known Bugs (to be fixed in next release) (1) Except for Notes, missing (null) fields are not skipped. Temporary workaround is to only include fields in the header and following records that you plan to update.
Please report any bugs promptly, and I will fix them at the highest priority. | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 13, 2007 | Reputation: | Posts: 2,217 |
| Posted: | | | | Quoting mediadogg: Quote: Thanks for the modulo math. De nada. While I was trying to work them out I came to a little problem: I thought I had a solution (which was wrong, but let disregard that ) that would have required me to have the old slot and location present for both manipulations. That would have meant of course as soon as I apply the changes to the first column, I would be missing the data for the second operation. Copying to another data-field, e.g. Notes would have been possible of course, but that would mean losing data. Therefor: would it be possible to include temporary (or transient?) columns for manipulations in the grid? No saving possible of course. Quote: Meanwhile, I have no problem if you offer the ljckbailey your stuff - maybe he will enjoy it - he seems kind of technical. If he wants he can go ahead with the information in my last posting and a look at my MSXML-help-page. | | | Mithi's little XSLT tinkering - the power of XML --- DVD-Profiler Mini-Wiki | | | Last edited: by Mithi |
| Registered: March 13, 2007 | Posts: 646 |
| Posted: | | | | I tried to use bulk edit to update collection number of some 500 profiles. I wanted to increment said profiles by 3, e.g. 2015 + 3 = 2018 a.s.o. I tried to use Tool4 using (\d{4}) in the Look For field and $1+3 in the Replace With which obviously didn't come out right, because Replace With is a text field. Stupid me. I then realized that this specific action can't be done in Tool 4. If it is at all possible I would love bulk edit to be able to increment the collection number field by a user defined integer. The functionality within DVDP is NOT reliable, me thinks. I would also like it if the input fields in tool 4 could be wider. Some times I'm lazy and paste entire title strings there. And if you think it is important. I saw that Tool 4 has an extra 4 in the label. I have v2.37. |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | Quoting Mithi: Quote: Quoting mediadogg:
Quote: Thanks for the modulo math. De nada. While I was trying to work them out I came to a little problem: I thought I had a solution (which was wrong, but let disregard that ) that would have required me to have the old slot and location present for both manipulations. That would have meant of course as soon as I apply the changes to the first column, I would be missing the data for the second operation. Copying to another data-field, e.g. Notes would have been possible of course, but that would mean losing data. Therefor: would it be possible to include temporary (or transient?) columns for manipulations in the grid? No saving possible of course.
Quote: Meanwhile, I have no problem if you offer the ljckbailey your stuff - maybe he will enjoy it - he seems kind of technical. If he wants he can go ahead with the information in my last posting and a look at my MSXML-help-page. Hmmm, temporary columns ... nice idea. Putting on the list. What I have done when I needed one, was use an almost always blank field, in my collection, such as "labelSideB", or if you have less than 5 Genres, you can use the "Genre5" column, and clear it out later (Edit: oops, Genre fields not in the copy list (yet) - my bad). | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | Quoting xyrano: Quote: I tried to use bulk edit to update collection number of some 500 profiles. I wanted to increment said profiles by 3, e.g. 2015 + 3 = 2018 a.s.o. I tried to use Tool4 using (\d{4}) in the Look For field and $1+3 in the Replace With which obviously didn't come out right, because Replace With is a text field. Stupid me. I then realized that this specific action can't be done in Tool 4. If it is at all possible I would love bulk edit to be able to increment the collection number field by a user defined integer. The functionality within DVDP is NOT reliable, me thinks.
I would also like it if the input fields in tool 4 could be wider. Some times I'm lazy and paste entire title strings there. And if you think it is important. I saw that Tool 4 has an extra 4 in the label.
I have v2.37. Ok, you will soon (days?) get the Regex "Math" option in Tool4, which will do exactly what you want, and the fields will be widened. Meanwhile, some options: (1) the increment option is already on Slot (context menu). If you are using Slot, you could save it elsewhere, say in Label Side B, copy collection# into Slot, Increment, copy back to Collection#, restore Slot from Label Side B, then use Regex to clear Label Side B. Whew! (2) Version 2.46 has a new bulk load personal data function. You could just create a simple CSV of the new collection numbers (profileID used as key) and bulk load them. Relatively fast. See my recent post for examples. (3) On the list for future release: add increment to collection number. | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 13, 2007 | Posts: 646 |
| Posted: | | | | Excellent! Thank you! No rush though!!! I'll look for the "Math" option in a release in the future. |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | Quoting xyrano: Quote: Excellent! Thank you! No rush though!!! I'll look for the "Math" option in a release in the future. I couldn't talk you into giving the Bulk Load a try? One of my examples is exactly your case. Even if just a few profiles, so I get some feedback ... a bit of a carrot to keep me working on the other goodies. | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 13, 2007 | Reputation: | Posts: 2,217 |
| Posted: | | | | Quoting mediadogg: Quote: Hmmm, temporary columns ... nice idea. Putting on the list. No rush, just planting the evil thought ... Quote: What I have done when I needed one, was use an almost always blank field, in my collection, such as "labelSideB", or if you have less than 5 Genres, you can use the "Genre5" column, and clear it out later (Edit: oops, Genre fields not in the copy list (yet) - my bad). Yes, LabelSide was coincidentally also my first thought, it's just that it is still "overwriting valid data" even if it is kinda useless. Genre 4 and 5 on the other hand would work quite nice for me. | | | Mithi's little XSLT tinkering - the power of XML --- DVD-Profiler Mini-Wiki |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | Cleaning up some bugs in the Regex+Math feature. I think it will be a useful thing.
@Mithi, I can't seem to get the Location calculation to work. So far, I only have C# available as a language. I hope to also be able to add Visual Basic.
Here is what I am using:
// Look For in Location, using Regex search D(\d+) // This Math is the Regex Replace // So far, this does not work for the first 100 discs int slot = int.Parse(RowData("Slot")); double A = Math.Ceiling((double)(slot / 4)); double B = ( $1 - 1) * 100; return "Page: "+(A + B).ToString();
// Look For in Slot, using Regex search (\d+) // This Math is in the Regex Replace if (($1 % 4) == 0) return "Disc: 4"; else return "Disc: "+($1 % 4).ToString();
If you know C# or Visual Basic, could you verify the logic? Thanks. (I realize that this particular case may be solved already, but it is as good a test case as any.) | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | Quoting xyrano: Quote: I tried to use bulk edit to update collection number of some 500 profiles. I wanted to increment said profiles by 3, e.g. 2015 + 3 = 2018 a.s.o. I tried to use Tool4 using (\d{4}) in the Look For field and $1+3 in the Replace With which obviously didn't come out right, because Replace With is a text field. Stupid me. I then realized that this specific action can't be done in Tool 4. If it is at all possible I would love bulk edit to be able to increment the collection number field by a user defined integer. The functionality within DVDP is NOT reliable, me thinks.
I would also like it if the input fields in tool 4 could be wider. Some times I'm lazy and paste entire title strings there. And if you think it is important. I saw that Tool 4 has an extra 4 in the label.
I have v2.37. The upcoming V2.47, when I get the bugs out, will use "return ($1 + 3).ToString();" as the Replace With expression, since it is based on Microsoft C#. Can you deal with this kind of programming? I am trying to avoid writing my own parser / compiler by using the built-in Microsoft tools. | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 20, 2007 | Posts: 17 |
| Posted: | | | | Quoting mediadogg: Quote: BulkEdit V2.46 Available - Please do not quote this post, as information will be edited.
- Bug in Export to Excel file location repaired. - "Export to Excel" menu renamed to "Export to Excel (XML)" - Menu option added: Tools \ BulkEdit \ Bulk Load Personal Data
Bulk Load Personal Data This new menu provides a quick way to update existing profiles with revised or new personal data.
Quote: Notice: The changes are made in Real Time, on the fly, as the data is read from the file. It is imperative that your database be backed up before using this function. You have been warned.
Input File Format: CSV, with "," as delimeter, double quotes used for strings with spaces
Fields Supported (case insensitive): ProfileID - All DVDP formats supported, including manual profiles and disc IDs. Required field, used as a key only, and must already exist in the database. Disc - A number from 1 to any reasonable disc#. Defaulted to 1, if incorrect or missing. Read Only, used to identify the disc for Location, Slot, etc. Location - Text field used to fill in the DVDP Location field of the corresponding Disc. Slot - Text field used to fill in the DVDP Slot field of the corresponding Disc. Notes - Text field used to fill in the DVDP Notes field. EXISTING NOTES WILL BE OVERLAID. PreNotes - Text field pasted at the beginning of the existing DVDP Notes field. PostNotes - Text field pasted at the end of the existing DVDP Notes field. Collection# - A number used to fill in the DVDP collection number field. Blank accepted. Use "-1" to set None flag. CollectionType - A text field "owned", "ordered", "wishlist", or the exact spelling of any already defined custom categories in your database.
A future release will add more fields. Purchase Info has already been requested. MyLinks is also a candidate.
Quote: Disclaimers and Limitations (1) There has been limited testing, although the code and methods have been derived from existing BulkEdit code. There are numerous tests in an attempt to protect against crashes from ill-formed data, but be careful. (2) No support for alternate delimiters in the CSV file. Code Page 1252 assumed. (3) Exact spelling of fields is required. There must be exactly 1 header record at the beginning of the file. (4) Standard line delimiters are expected in the file. (5) Each line of the file should have exactly the same number of fields as the header
Examples (fields can be in any order, only ProfileID required): profileid, location, disc, slot, notes, prenotes, postnotes, collectiontype, collection# <---header 4942463602307.17, "top shelf", 1, 23,"new notes","in front","at the end","ordered",10001 085391161035, "Page: 2", 4, "Disc: 4","notice blank collection number","front","back","netflix","" 025195021197, "upstairs", 2, 3 ,,"None set in collection number","back","bluray",-1 ICFD8461A80517AC6, "Disc ID as key", 2, 3 ,,"None set in collection number","back","bluray",-1 <---preserves notes M000000000004.15,"Manual ID is key", 1, 23,"new notes","in front","at the end","ordered",10001
profileid, disc, location, slot 4942463602307.17, 1, "top shelf", 23 085391161035, 4, "Page: 2", "Disc: 4" 025195021197, 2,"upstairs", 3 ICFD8461A80517AC6, 2,"Disc ID as key", 7 M000000000004.15, 1, "Manual ID is key", 189
profileid, collection# 4942463602307.17, 10001 085391161035, 402 025195021197, 3 ICFD8461A80517AC6, -1 <--- None M000000000004.15, "" <-- Blank Collection#
Known Bugs (to be fixed in next release) (1) Except for Notes, missing (null) fields are not skipped. Temporary workaround is to only include fields in the header and following records that you plan to update.
Please report any bugs promptly, and I will fix them at the highest priority. Hey Guys, Spent some time formatting and preparing csv import files now and am experiencing an error on execution. I get a "DVD Profiler" Error Box reporting "Disk index out of range". When "Cancel" is selected, I get a momentary "Warning" box containing "Incorrect CSV Format". The Progress bar (0 progress) is left on screen until DVD Profiler is restarted. The format seems OK to me. I'm inserting a copy of it here: profileid,collection#,disc,location,slot 25192019975,1000,1,''Blu-Ray ~ Page: 1 Disk: 1'',"" 24543575337,1001,1,''Blu-Ray ~ Page: 1 Disk: 2'',"" 24543575283,1002,1,''Blu-Ray ~ Page: 1 Disk: 3'',"" 884000000000,1003,1,''Blu-Ray ~ Page: 1 Disk: 4'',"" 97361433240,1004,1,''Blu-Ray ~ Page: 2 Disk: 1'',"" 24543414278,1005,1,''Blu-Ray ~ Page: 2 Disk: 2'',"" 25192046865,1006,1,''Blu-Ray ~ Page: 2 Disk: 3'',"" 25192027277,1007,1,''Blu-Ray ~ Page: 2 Disk: 4'',"" 97360715842,1008,1,''Blu-Ray ~ Page: 3 Disk: 1'',"" 43396215207,1009,1,''Blu-Ray ~ Page: 3 Disk: 2'',"" 24543656135,1010,1,''Blu-Ray ~ Page: 3 Disk: 3'',"" 43396359260,1011,1,''Blu-Ray ~ Page: 3 Disk: 4'',"" 787000000000,1012,1,''Blu-Ray ~ Page: 4 Disk: 2'',"" 787000000000,1013,1,''Blu-Ray ~ Page: 4 Disk: 4'',"" 884000000000,1014,1,''Blu-Ray ~ Page: 5 Disk: 1'',"" I68AEF20A039C56CF,1015,1,''Blu-Ray ~ Page: 5 Disk: 2'',"" I26A939D870EB737E,1016,1,''Blu-Ray ~ Page: 5 Disk: 3'',"" I3B45A70530A0F29B,1017,1,''Blu-Ray ~ Page: 5 Disk: 4'',"" I18C0D1BDD587049E,1018,1,''Blu-Ray ~ Page: 6 Disk: 1'',"" 43396359260,"",2,''Blu-Ray ~ Page: 4 Disk: 1'',"" 884000000000,"",3,''Blu-Ray ~ Page: 4 Disk: 3'',"" Thanks in advance for any help. |
| Registered: March 18, 2007 | Reputation: | Posts: 6,463 |
| Posted: | | | | @ljckbailey, checking it out now ...
Also working on Regex Math.
Some immediate thoughts on these two records:
43396359260,"",2,''Blu-Ray ~ Page: 4 Disk: 1'',"" <- only 11 digits in the ProfileID? (043396359260 is Karate Kid) 884000000000,"",3,''Blu-Ray ~ Page: 4 Disk: 3'',"" <- Is this a valid UPC? Manual ID must start with "M"
I realize that the error message is not very helpful, but that's two things I noticed that might be causing an error. Also, do those discs (2 and 3) actually exist?
I will test my code to ensure that errors like that are correctly trapped and accurately reported.
(Aside: based on what you are doing, I have misunderstood your previous example. But, no matter, it should be possible to write code in the Math box to do whatever anybody wants. I'm just using your example as a way to test whether Math is working correctly.) | | | Thanks for your support. Free Plugins available here. Advanced plugins available here. Hey, new product!!! BDPFrog. | | | Last edited: by mediadogg |
| Registered: March 13, 2007 | Reputation: | Posts: 2,217 |
| Posted: | | | | Unfortunate I know nothing of programming besides my little XSLT. So, first step is fairly easy: the next greater integer of old-slot divided by 4 Quote: double A = Math.Ceiling((double)(slot / 4)); looks good, but what is (double)? If you only use this however of course all 4 Changers will get the same Location 1,1,1,1,2,2...100 So I take the number from e.g. "D2" => "2" subtract 1 and multiply with 100 and add that to the Location. That will add 0 to all D1-Locations (100 to D2, 200 to D3 and 300 to D4) If your formula works for D2-D4 I have no idea what could go wrong on D1 | | | Mithi's little XSLT tinkering - the power of XML --- DVD-Profiler Mini-Wiki |
| Registered: March 20, 2007 | Posts: 17 |
| Posted: | | | | It looks like in the process of moving data between your BulkEdit sheet & excel, etc profileid's have been corrupted by excel - removing leading zeros and by rounding exponentializing others . . .
ahhhhhh
I correct a few by hand to verify that that is the issue . . . then start over.
Thanks | | | Last edited: by ljckbailey |
|
|
Invelos Forums->DVD Profiler: Plugins |
Page:
1... 35 36 37 38 39 ...52 Previous Next
|
|
|
|
|
|
|
|
|