Coder Social home page Coder Social logo

jlg's Introduction

Let me help you upload your old bulk data to Firebase

  1. Export the Excel file as CSV

  2. Use this tool to convert this CSV to JSON

  3. Use a text editor Find-and-Replace to change { to "x": {. Also remove the [] in the beginning and ending.

  4. Use this Linux command to change each of the x to incemental numbers

awk 'BEGIN { cntr = 0 } /"x":/ { cntr++ ; print "\""cntr"\":" } !/header/ { print $0 }' codebeautify.json > output.json

(Remember this code doesn't do the exact thing for us, so one more step)

  1. "x": is not removed, so to remove it use text editor Find-and-Replace to change "x": to blank.

  2. Last step, but important - convert the encoding of the file to strictly UTF-8, nothing else is accepted.

Done! Goto Firebase Database Console and upload the output.json using Import JSON.

Recommended to use Visual Studio Code for the purpose (especially Step 6).

jlg's People

Contributors

rounakdatta avatar

Stargazers

Roman avatar

Watchers

James Cloos avatar Arko Chatterjee avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.