How to get Tally Prime data in PHP server - php

Need to fetch tally data file in php server.How to do that in laravel.
I tried with CData connect server but it was not helpful.I want to fetch tally data file record in php server.
CData connect server URL :
https://www.cdata.com/kb/tech/tally-connect-php.rst#Create-a-Virtual-MySQL-Database-for-Tally-Data_9ykr6hah3

It is not recommended to get tally data from outside LAN,
as it involves exposing all tally data to world
If tally is running in same system as your php server then you can use curl to send request in XML
Refer this - how to insert data into tally using php?
and for xmls use this postman collection

Related

Simultaneous database query causing database error max_user_connections

I'm trying to import the excel data to mysql database by PHP Ajax method. When the user upload an excel, the jQuery will fetch each row by loop and send it to PHP via ajax but there are about 500++ rows. Due to that, the PHP is running the query simultaneously and causing the database error already has more than 'max_user_connections' active connections. Some of the query are working but some not.
the jQuery will fetch each row by loop and send it to PHP via ajax
...this is a design flaw. If you try to generate 500 AJAX requests in a short space of time it's inevitable, due to its asynchronous nature, that a lot of them will overlap and overload the server and database...but I think you've realised that already, from your description.
So you didn't really ask a question, but are you just looking for alternative implementation options?
It would make more sense to either
just upload the whole file as-is and let the server-side code process it.
Or
If you must read it on the client-side, you should at least send all the rows in one AJAX request (e.g. as a JSON array or something).

How can I secure JSON web service?

I have location data containing lat,long,location_name to be shown in the map. Only logged in users can see this map. What I did was that I used php and with a select * to MySQL DB and then I used json_encode to format the data in usable way and echoed it to be grabbed in the front-end and used in map api. This php file echoing the JSON file is called mapData.php
I want this file to not be accessible even from logged user. I came across session and request headers in the mapData.php file (internal api file)but then again if h hacker sign up to my service and open dev console he/she can see the received file and with one side requesting tool can put the header and see the data. Or maybe changing the access level with Linux but I have no idea how.
Another method is uglify and minifying JSON but since I am having 29000 rows in my dB with another inner join I think it will slow down the process. Any suggestion for securing this internal api so that even logged in user cannot access to it?
I would hide the map data file in a subdirectory, then use a service to access the data file and retrieve just the data you need. If you absolutely need the 29,000 rows at once, then there's not much you can do. Even if you encrypt it, eventually the data is going to be in native JavaScript format, and then it's just a matter of running a debugger and peering in the data structures.

Swift connection to database without php output

I have a simple question about the database structure and connection to my iOS App.
Is there any solution to get datas from my databse using Swift without PHP output? I want a PHP script which connects to the database and echo the result. The app should load the datas directly from the database like PHP (mysqli).
It is really important for me to protect the datas in the database! Nobody should see the datas when he opens a URL in the browser of my server.

getting data from arduino to a database(mysql or any)

I would like your help on these. Does anyone know how to get data from arduino to a database? Specifically mysql or any other database that we can use.
You need a backend on your server. The Arduino calls a php script with POST or GET Parameters and the php script writes the content to your database.
Add some HTTP Basic Auth and the job is done,

Json and Internal db

I need to save the information that I get from a json, the result did a webserver with php MySql connection, and save me the information in an internal db, so I do not have to download every time the json, what can I use to save information from the json directly to the database?
Create your own SQLite data base in the android device and the table should like the web data base.If your web data base is updated then your android device need to be updated.
Just store the data in your app's SQLite database:
http://developer.android.com/guide/topics/data/data-storage.html#db

Categories