Page 2 of 2

Not able to import a new collection csv file

Posted: Wed Jul 23, 2014 9:30 pm
by Alex Van Name

how would you set the data types to 'array' or 'number' as opposed to a string, which is the default?


Not able to import a new collection csv file

Posted: Wed Jul 23, 2014 10:01 pm
by Alex Van Name

Image

This is how the data is exported from Appery.io DB to csv.

The reverse format for import is ok, just have to export to windows csv file


Not able to import a new collection csv file

Posted: Thu Jul 24, 2014 3:10 am
by Yurii Orishchuk

Hi Alex,

please specify what problem you have.

Also please try following use case to understand how import/export works.

  1. Open your Appery.io DB.

  2. Export to local .csv file.

    Open .csv file in text editor and you will see correct format.

    Regards.


Not able to import a new collection csv file

Posted: Fri Jul 25, 2014 3:46 am
by Anil Sagar

If one opens a file in excel and still wants to keep the formatting intact such that one can import it back into DB on appery then following code code can be used in excel.

Public Sub OutputQuotedCSV()
Const QSTR As String = """"
Dim myRecord As Range
Dim myField As Range
Dim nFileNum As Long
Dim sOut As String

Code: Select all

     nFileNum = FreeFile 
     Open "File1.csv" For Output As #nFileNum 
     For Each myRecord In Range("A1:A" & _ 
                 Range("A" & Rows.Count).End(xlUp).Row) 
         With myRecord 
             For Each myField In Range(.Cells(1), _ 
                         Cells(.Row, 256).End(xlToLeft)) 
                 sOut = sOut & "," & QSTR & _ 
                     Replace(myField.Text, QSTR, QSTR & QSTR) & QSTR 
             Next myField 
             Print #nFileNum, Mid(sOut, 2) 
             sOut = Empty 
         End With 
     Next myRecord 
     Close #nFileNum 
 End Sub 

For this code to work, you would have to activate "developer" mode in excel (office 2013), goto file menu-options-customize ribbon-choose developer. You will now see a developer tab in the menu.

Then, open the excel sheet you want to modify. Goto developer tab-visual basic-Insert a module-copy paste the above code-come back to your excel sheet-click on macros button in menu items-choose the module name you created in VB-run the macro.

You will find a .txt file now created in the same folder on your pc as your excel sheet. Change the extension to .csv. You are ready to upload that file now back into your appery DB

I used the following link to find the above method:

http://www.mcgimpsey.com/excel/textfi...


Not able to import a new collection csv file

Posted: Fri Jul 25, 2014 3:59 am
by Illya Stepanov

Thanks for sharing that, Anil!


Not able to import a new collection csv file

Posted: Mon Jan 19, 2015 7:29 pm
by Kal

This is a great tip! Thanks, Anil.

Support, would it be possible to include this in the documentation somehow. 99% of the people will edit CSV in Excel, and get stuck because Appery does not import the Excel generated CSV file. The above work-around works fine.


Not able to import a new collection csv file

Posted: Tue Jan 20, 2015 4:13 pm
by Maryna Brodina

Hello!

Sent your request to tech writers, thanks!