-
Notifications
You must be signed in to change notification settings - Fork 664
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
read from blob not working #971
Comments
for csv's i can do something like:
and thus read from string. I'd prefer a blob though. So that the syntax with XLSX is the same With XLSX i get the following error if i add the blob.
The XLSX itself is a simple created xlsx in microsoft excell containing two rows
|
Creat bug report. Lets solve this together. Ill have a look next time I have 30 mins free. |
I've found this issue online: open-xml-templating/docxtemplater#102 "The issue was the .docx file was not in the same folder as the HTML page." though it's a blob in memory |
I've created a work-around which is quite simple and according to caniuse.com browser compatible
where xlsx can also be changed to csv and it also works for csv's This creates a physical file in the local browser cache. The file however does not contain an extension, and you need to disable the autoExt. |
AlaSQL is based on unpaid voluntary work. Thank you for taking the time to make it better.
Something not working as expected?
we're using https://github.com/danialfarid/ng-file-upload for uploading files resulting in a File Object
(https://developer.mozilla.org/nl/docs/Web/API/File)
So basically you would expect that i could read it from a blob using the following code:
alasql.promise('select * from CSV(?)', file).then( function() { console.log( arguments ) }, function() { console.log( arguments ) } );
or this code
alasql.promise('select * from CSV(?)', [file]).then( function() { console.log( arguments ) }, function() { console.log( arguments ) } );
it however does nothing, no errors, no promise resolved nothing.
I'm expecting atleast an error :(
I just downloaded the latest zip from here. We're loading these two files:
The text was updated successfully, but these errors were encountered: