Importing xml in filemaker - xml-parsing

For years, I have be importing XML files from the PubMed into FileMaker, and then now I have been getting an "XML parsing error: whitespace expected Line Number: 1 Column Number: 50"
Note, I have been using the .XSL file since I wrote it approximately 20 years ago. And in my attempt to resolve the issue I have picked up examples from FileMaker sites and get the same issue.

Related

Issue displaying XLSXWriter file special characters in Google SPreadsheets (UTF8_decode)

I am using XLSXWriter php library to generate xlsx files that have special characters in a few columns .
The encoding is UTF8 and the special chars seem to display correctly both on my website and when I open them with excel .
The strange thing is that when I import the file to Google Spreadsheets there is just a bunch of squares and characters that do not match the original .
Example : âðð¼ð¼â
ð³ð¾ð±: ð¸ð¾ ð³ð´ð² ð¸ð¶
What I have tried to fix the issue :
I use utf8_decode to convert my strings before exporting the file
I tried a composer library (forceutf8) in order to fix any errors related to utf8 double encoding
I tried to export directly using UTF-8 encoding but the columns are empty when I do this
I don't really know what else to try, supposely google spreadsheets should read UTF8 encoding and even if it didn't, it makes no sense that when I use utf8_decode the characters are displaying correctly in Excel but not in Google Spreadsheets .
Any suggestion, been trying to fix this for several hours .
Thanks

Importing Data to neo4j

I am trying to import a Database on Game of Thrones for neo4j.
Github_link_to_the_data
I copied and pasted the code to my cypher browser but I keep getting errors.
Can someone please instruct me how to import this data so I can start querying this database?
Here is the error I am getting:
Neo.ClientError.Statement.SyntaxError: Invalid input ')': expected
whitespace,
comment or an expression (line 630, column 3 (offset: 24452))
"CREATE (banner)-[:BANNERMAN_OF]->(euron);"
I would appreciate some help here.
Thanks!
The Neo4j Browser has only recently been augmented with the ability to process multiple cypher statements in the query editor (separated by ;), and there are still a couple bugs being worked out here as of 3.4.5.
Your best bet for processing these is via cypher-shell, you can pipe in the input file and it will take care of the rest.
Check out this section of the docs, and pay attention to example 10.17 on how to pipe the input file.

SSIS: Can't handle line-feeds in CSV (Column delimiter not found)

I have some CSV files that appear OK in Notepad and Excel however seem to have extra line-feeds in them when I view them in VS2010 or Notepad++. When I attempt to process them in SSIS, the files fail with errors like this:
Error: 0xC0202055 at Merge Files, Interface [225]: The column delimiter for column "Column 48" was not found.
Here's a truncated example (there's about 50 columns, and the line-wrap appears to wrap randomly at the same position):
The questions are: how does Notepad and Excel open these files OK (and seemingly ignore the line-feeds)? Is there a way to get SSIS to process these files? Could it be an SSIS setting on code-page etc?
For me opening the file in Excel, saving as an excel file (xlsx but I am sure the old xls format would work fine too), then using the Excel Source in SSIS enabled me to load a file into a SQL table with this kind of problem.
Obviously this would not work if you need to load this kind of file regularly or if there was many of these files. In that case the first answer would be better.
The easiest solution for us was to stage the input into a SQL table, and then in a subsequent data-flow, query it back-out without line-feeds in the CSV output, e.g.
SELECT COLUMN1
,REPLACE(REPLACE([COLUMN2],CHAR(10),''),CHAR(13),'') AS [COLUMN2]
FROM TABLE

iOS read a certain line in a textfile [duplicate]

This question already has answers here:
Objective-C: Reading a file line by line
(18 answers)
Closed 9 years ago.
I have a large textfile that has data for my program stored. It's basically a CSV file, consisting of float numbers, one in each line. Example:
6.3580820e+03
6.3589883e+03
6.3592695e+03
6.3592695e+03
6.3635508e+03
6.3695820e+03
I know how to read a file line for line, but then I will still end up with an array with all the data in my memory. I would prefer to access a distinct line e.g. kind of readFromLine:32
Is there a way to do that without loading or reading the whole file once? If not how should I convert my data? SQLite?
I would prefer to access a distinct line e.g. kind of readFromLine:32
Is there a way to do that without loading or reading the whole file
once?
You can use NSInputStream to read the file, and the input stream will manage reading portions of the file into memory as it needs them.
If not how should I convert my data? SQLite?
The trouble with CSV files, at least for your application, is that the only way to know where a given line can be found is to read the file from the beginning and count lines. If you had an index that told you the offset from the beginning of the file for each line, or for every 10th or 100th line, or whatever, then you could look up the position of the line (or the closest preceding line) in the index and start reading your data file from the offset indicated by the index entry. Using a database format like SQLite would be another good strategy. You could also break up the large file into smaller pieces, so that loading just the relevant part of the file isn't so resource intensive.

xls2csv: wrong date cells parsing

I format dates with the command line option -f %Y-%m-%d or even %d-%b-%y
but each date comes out four years and one day ahead of the date I input
for example, date 01.06.2012 after parsing without -f option comes as 2016-06-02
toying with -f gives same result
What is the reason? Are there any workarounds,
except hardcode and substract back these 4 years and 1 day?
I am using xls2csv (by V.B.Wagner, comes with catdoc package in debian)
and switching to another parser can be very expensive option
Tools xls2csv is a Perl application that uses Spreadsheet::ParseExcel library.
Based on such library documentation, one of known problems is:
If Excel has date fields where the specified format is equal to the system-default for the short-date locale, Excel does not store the format, but defaults to an internal format which is system dependent. In these cases ParseExcel uses the date format 'yyyy-mm-dd'.
So you probably manipulate with Excel file that does not contain date formating due to above listed issue.
That's a known bug. A patch is available at
https://www.wagner.pp.ru/cgi-bin/cvstrac/catdoc/tktview?tn=14,4
It works.
By the way, there are two programs called xls2csv, we're talking about the one from the catdoc package, not the Perl program.

Resources