Whats the best way to connect to the Samba SQL datbase from a website

I know this is possible, but there are so many different ways to accomplish this Im not sure how to do it.

I would need to connect without any port forwarding in the internet as I do not have access to the web management

I wish for this to be done so that Custom Entity fields can be used on my website to display how many points a customer needs to redeem a free item…

You will struggle.
With no port forwarding you won’t be able to communicate directly to SQL and there are probably better ways than that anyway.

If you want your website to allow customers to see their points on your website I personally would look to do something like this…

Your website will most likely have MySQL within the hosting so would make a new table within that and make a script to routinely update entity details and points in that table and make a page on the website to read that new table.

SambaPOS doesn’t run on MySQL itself but via scripting you can select and insert data into MySQL.

There was a few posts a while ago which touched on basics of scripting and MySQL

This would also be allot safer I would say that opening ports etc to your MSSQL database locally.

Someone might even come back with even better option.
You could even just have a Json array in a text file on the webs host.

Either of these ideas will require some custom coding on your website.

So what your saying I need to do, is create a script Inside Samba, which sends the table to my web servers MySql database?

Im saying that is one option which comes to my mind.
The website would have its own database and a script in samba set to be triggered say once an hour would qry SambaPOS MSSQL info then using that list update the table on website.
Someone might have a better solution.

To be clear …

From your website hosted externally, you can connect to the POS MS SQL Database, but you will need to open ports on your POS Server where the MS SQL DB resides, and set your internal Router to forward those ports to the internal IP of the POS Server.

You do not need to open/forward ports on your external website host.

Im Unable to open/forward any pots on the server where the MS SQL DB resides.

Im confused at this part, so I need to have a JScript which will update a table in a external MySql datbase from the MSSQL there, do you know any where I could find documentation on how to acheive this, because anything I search about Jscript just shows resources abut Javascript and updating with PHP