Completely replace MySQL (or any SQL) DB with Google Sheets [closed] - javascript

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
Let's say HYPOTHETICALLY that...
I am building a webtool that pushes data onto a user-selected MySQL table in a user-selected MySQL database using user-selected MySQL username [bogus_username] with user-selected MySQL password [bogus_password].
I would like to extend this hypothetical tool's capability to where it can push data onto any sort of database.
Technically, a Google Sheet is a "database."
So, how do I hypothetically build a script that logs onto a user's google drive and opens a google sheet up for data manipulation?
I am looking for a solution that either uses client-side JS, nodeJS, or PHP. Either language will do. I am just trying to understand how to do this CONCEPTUALLY, so what language you build the script in doesn't matter, as long as I can understand it.
all these "hypothetical"s mean I KNOW I DON'T HAVE CODE! I am not looking for code, but for code concept

Google sheets has a an api. There are many modules which use this api or provide wrappers for this api. Since you mention NodeJS you could hust do an npm search.
Somewhere in your code you will have a storeRecord function which could, depending on your configuration, store the data to mysql or google sheets, or whatever. You will need to implement some different code for database systems that do not use the same protocol. If the protocol is the same (e.g. ODBC is used by many databases) then you will just require different configuration settings.

Related

How do I make a web app with Google APIs? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 10 months ago.
Improve this question
I am pretty new to web dev, and I wanted to create a simple UI in Javascript with the Google Maps Places API to familiarize myself with everything. My question is, would I just make direct URL requests with the user’s variables, or would I have to create something server side, and if so, what would I have to do?
It depends on your application's functionality. Generally, you could keep all everything on the client-side. If you app is a server-rendered one, meaning you would be using a JavaScript framework like React or Vue, you could use just the website state to keep track of users' variables and send out requests to the Google APIs to do the heavy work.
You could also look into tools like Firebase, also created by the folks at Google to handle storage or user authentication. There are rich docs on how to include Firebase in your web application for your framework of choice. This way you can create language-agnostic backend resources that conform to all of the security measures and scales automatically so you can focus on the users' experience.
In case you would like to offer some less-common functionality or have complete control over the backend you could write up an API of your own and have it deployed on a separate backend server.

Best way to manage users without a DB [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 1 year ago.
Improve this question
I'm building a simple webapp for a local company looking for a way to manage the shifts of their 10 employees and to quickly check them from anywhere.
For tests sake I've used a plain txt file uploaded into a page manually and a basic parser to retrieve users (employees) and their data but, for obvious reasons (security breaches), I'm looking for a way to manage these data without having to resort to a DB since it'd be a waste of resources for just 10 employees.
Any idea is welcome :D
P.S.: I'm actually using js scripts but I don't mind using PHP or any other language if it means reaching the goal
There are multiple ways,
You can store user details in .json file hosted on S3 bucket and access it via S3 public URL or CloudFront Signed URL.
Hard code the all 10 users details in Static JSON/XML file within your web app source bundle (Not recommended).
User Any Cloud database (dynamoDB, mariaDB etc.) and access it via Lymda function. (most recommended)
Since you are only storing the users names and time of shifts, I would use JSON file format to store this information. You could also encrypt any sensitive data, but if you are going to be storing passwords and other sensitive data then maybe you should use a Database.

React Web App File Saving (Suggestions) [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
I'm building a React web app that takes in torrent pieces and these have to be temporarily stored somewhere for a web player to then view them.
Does anyone have any suggestions on how I can temporarily store this data to be used later for the streaming aspect of the process?
At the moment, I have pieces that are being stored in an array in a var, but I'm unsure if I should store this somewhere before using the data.
I know JavaScript inherently doesn't allow this sort of functionality for security reasons, but I would like to somehow store the files until they get disposed of on user exit or something.
I think you should choose firebase for this purpose. It is secure, user friendly and lightweight web and mobile apps development program.
Since you want to store your data temporarily, then it will be best place to choose.
I myself used it so many times to store my data for long and short period. The thing I like most about it, is that you don't even need any server side scripting to save data in firebase Database. React provide its package manager that you can use to create and store data. So you can do this using client side language only.
Firebase Authentication helps you to secure data from other user's access. You can create your own login details for protection.
Firebase Storage helps you to put your files under one folder.
Firebase Database can store the links of your files so when user wants to access it in future they can click that link.
There are many other benefits of using firebase, you will know when you use it. If you still have difficulty to use it let me help you with that.
Thanks

Want to create a new application for website traffic monitoring ( analysis ) [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I want to create my own application for monitoring traffic of my website without using any third party tools like google analytics. In which I want to log screenshots, user details, page details and cookies. So what technology should I opt so as to achieve this goal and which will be best suited and what work flow should I follow.
I've never done this kind of work previously so I'm new to this. Any help would be greatly appreciated.
The technologies I know are : javascript, nodejs, django(python).
You will have to break down your application as it is a humongous task to create something like GA.
You will have to track many user activities(click,spend time etc).so you can do that in plain js or use a cross-platform lightweight library(angular.js) that can make your life a little easy.
Now since you will have to send large set of traced data to you database with minimum latency,use Node.js in this scenario.Simple Ajax call would also work but then it would be very slow.
Now comes your database.Prefer NoSql since it suits your requirement of unstructured data ,preferrablly MongoDb which can help you with its own mapReduce,large storage capacity
.Since there will be lot of calculation involved you can use your python knowledge which can help you process data a lot faster.you can use other languages as well(eg.Go)
Your processed data and results can then be stored in Redis(which acts as a caching layer).
you can use sophisticated graphic library like d3.js,Highcharts.js for displaying Graphical data on the client-side.
There are a lot of factors that can be involved.This is just a very basic outline of what you could do.

How to implement Google Analytics and save daily statistics of a webpage in a database [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I would like to know how to implement Google analytics and make an SQL query from PHP to save daily webpage statistics.
Thank you for your answers.
There are a lot of issues that you will need to overcome to get this to work. It's not as simple as just adding a file to your site. You will first need to set up analytics on your site using the javascript that Google provides.
Next you will need to connect to the Google servers either using a PHP API like GAPI, curl or OAuth. You could also try a JSON solution. I personally like using the OAuth method for the ease of use. There are OAuth libraries that can do the heavy lifting, too.
After you have the data you need, you need to add it to the database. You can do this within the PHP for the request, or with AJAX. Both methods are decent. The SQL itself is up to you. If you are using some sort of CMS, try using their database methods instead of writing your own. If you are writing one from scratch, I would suggest the PDO API in PHP. It takes care of a lot of the security vulnerabilities you usually have with SQL and it's well documented.
All-in-all, there are a lot of moving parts to this process. I would suggest looking for someone who has all, or most, of the leg work already done before diving into it yourself.

Categories