• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to import PDF with CSV index
#1
I'm trying to import a big pdf with a csv index, and I'm obviously missing something.

I tap IMPORT and tap CSV or PDF Bookmarks, and get the file select screen, where I can navigate / find both the PDF and the CSV files.  (But I can only select one of them, not both.)

If I select the PDF file, the Select Songs to Import screen appears, but it uses the bookmarks in the PDF file to parse the songs. (The bookmarks in the PDF are incomplete.)

If I select the CSV file, the Select Songs to Import screen appears, but it has no songs to select.

So how do I use the CSV to index / parse the PDF?

EDIT:
Reading this thread https://zubersoft.com/mobilesheets/forum...4#pid13484
1. I named both files the same name (and removed spaces from the filenames) - still same outcome.
2. I inserted a first line into the CSV file with the following path to the PDF:
/mnt/sdcard/'0 Music Scores'/1FirehouseJB.pdf
I've assumed that I need to enclose in quotes, the directory with spaces in its name.
With this in place, after selecting the CSV, I get this message:
"All columns specified in the CSV are invalid"
Which suggests I have something wrong in that first line and it's not being recognized as a path to the PDF.

Many thanks in advance.
Reply
#2
The preconditions for a successful CSV import are:
1.) CSV and PDF file must have the same filename (Except the extension) e.g. MyFakebook.CSV and MyFakebook.PDF
2.) CSV and PDF file must be in the same folder on the tablet
3.) semicolon must be used as separator in the CSV file
4.) The first line of the CSV file must contain the column titles for the metadata items to be used e.g.
title;pages;keys;source types;composers;years;tempos;signatures;albums;
5.) "title" and "pages" are mandatory, all other columns are optional
6.) all lines of the CSV file must contain the correct number of separators

Android and Win10 UI are slightly different:
on Android you just open the CSV, the PDF is found automatically via the matching filename
on Win10 you select the CSV first, then, in a second step, you select the PDF

@chrisss: I shared folders of my GoogleDrive with some examples with you. If these examples do not answer your questions, send me a pair of files that demonstrate your issues . I'll take a look at them and I'm sure I'm able to fix the CSV.
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 1709
http://www.moonlightcrisis.de - http://www.basdjo.de - http://www.frankenbaend.de


Reply
#3
itsme - I got it working - thanks very much for your help.
I believe the problem was that I had the file path in the first line, IN ADDITION to having the files named the same and in the same folder.  Took that out and it worked.

Thanks very much for your help ... and for sharing the CJB and Paul Hardy files!

best,
Chris
Reply
#4
(05-13-2018, 11:32 PM)chrisss Wrote: itsme - I got it working - thanks very much for your help.
I believe the problem was that I had the file path in the first line, IN ADDITION to having the files named the same and in the same folder.  Took that out and it worked.

Thanks very much for your help ... and for sharing the CJB and Paul Hardy files!

best,
Chris
Reply
#5
hi there can someone explain how I change the CSV file when I try to import I get, all columns are  invalid message, itsme says you have to use a semicolon as separator, how do you do that, thanks
Reply
#6
(05-21-2018, 08:47 PM)art Wrote: hi there can someone explain how I change the CSV file when I try to import I get, all columns are  invalid message, itsme says you have to use a semicolon as separator, how do you do that, thanks

Art,
I've attached a complete csv file that I've used successfully to import the Firehouse Jazz Band book as separate songs.  In case you have trouble seeing that, here is an excerpt of the first several lines:

title;pages;keys;composers;collections;genres
Title page;1;;;Firehouse JB;Dixieland
TOC;3-8;;;Firehouse JB;Dixieland
Sunday;9;Bb;Chester Conn, Benny Kreuger, Jule Styne 1926 T: Ned Miller;Firehouse JB;Dixieland
Bill Bailey, Won't You Please;10-11;F;Hughie Cannon 1902;Firehouse JB;Dixieland
Doodle-Doo-Doo;12;Bb;;Firehouse JB;Dixieland
Oh, By Jingo!;13;F;;Firehouse JB;Dixieland
Tishomingo Blues;14-15;Ab;;Firehouse JB;Dixieland

I don't know exactly what file you're starting with, or what tools you have but I'll offer a couple suggestions.  

If you're starting with a spreadsheet, Microsoft Excel won't export to CSV with a semi-colon.  But LibreOffice will - it's free open source. In LibreOffice, in the export dialog box, you simply check the box to choose a semicolon separator.

You MIGHT be able to change a comma separated file to a semicolon separated file using a text editor, doing a 'global' search+replace. 2 things might "break" it:
- if there are commas in any of the titles or other field data, a global replace will also replace those commas, messing up the field parsing.
- some text editors add CR and / or LF characters to the ends of lines, also messing things up.

You could also attach the file you're trying to work with, and we might be able to help.
Reply
#7
hi chriss, i have all the pdf files for real books, all downloaded into MS,  but importing the csv files has been a real pain, but i downloaded a couple of real book csv files from the forum, cirio has posted a few, and they seem to work, after putting the csv file in the same folder as the pdf, still have to edit though as the titles dont match up to the songs, as in the realbooks you have photographs which puts the pages out of sync, so the only way is to change them manually which is a serious pain in the arse, unless there is an easier way
Reply
#8
The easiest way to proof-read and correct CSV files (in my opinion) is opening them in LibreOffice Calc. In a spreadsheet program it's not too difficult to add or remove lines or correct pages or title. I think I could use semicolons also in Excel, but I'm not sure. It's a long time ago that I switched from Excel to LibreOffice.
Alas the PDFs cannot be shared with the CSVs because of copyright reasons. And there are many different editions around.
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 1709
http://www.moonlightcrisis.de - http://www.basdjo.de - http://www.frankenbaend.de


Reply
#9
(05-22-2018, 12:00 AM)art Wrote: ... pages out of sync, so the only way is to change them manually which is a serious pain ... unless there is an easier way 
+ 1 to itsme's answer - 
Edit the CSV in a spreadsheet on a computer with a decent screen, real keyboard, + mouse, before you load it onto the tablet - line up the titles+pages with whatever version of the PDF you have. Still a little bit of a project but in my experience considerably quicker than working on the tablet.

I've been on LibreOffice for a good while now too. The last version of Excel I used was 2003 and that one just did comma's as delimiters, IIRC. Maybe newer versions can do semicolons but I wouldn't know.
Reply
#10
hi there could somebody look at this csv and tell me what I need to do to edit the separator, I can only open this in read-only, this is all new to me so any help would be appreciated


Attached Files
.csv   Real Book 2.csv (Size: 12.62 KB / Downloads: 12)
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2018 MyBB Group.