Diese Seite mit anderen teilen ...

Informationen zum Thema:
Forum:
WinDev Forum
Beiträge im Thema:
7
Erster Beitrag:
vor 2 Jahren, 11 Monaten
Letzter Beitrag:
vor 2 Jahren, 11 Monaten
Beteiligte Autoren:
DarrenF, Allard, Alexandre Leclerc

[WD19] Ping Allard

Startbeitrag von DarrenF am 04.03.2015 12:05

Hi Allard,

A while ago (about a year), I started a discussion regarding a customer of mine wanting to connect to the office from home.

You posted a reply regarding using your WD app with a MySQL database on the web:
http://27130.foren.mysnip.de/read.php?27131,198679,198769#msg-198769

I now have a need to do the same with an app I'm writing for my own use, but I don't have much experience of using MySQL and certainly no experience with using in this way.

Would it be possible to outline how you set this up?

Any help would be much appreciated... :cheers:

Antworten:

Hi Darren,

It works great. and it is not that difficult. So you say you have no experience with mysql. That does not really matter. You van use h commands just like when using hyperfile cs.

Ok This is all from memory so bare with me:
1 You need the mysql connection .There is a stuff you can download from pc soft.
2 You need to download a file, I do not know now how it is called , if I have time this afternoon I will lookup the name of the file. You can download it from the net and need to include it in your application.

It comes in handy if you have php myadmin installed on your server. Most likely this is the case. You can download it for free. It is recommended to install this on your def machine as well. Then you can manage mysql on your def machine as well.

Do your development in windev . Then make a db with phpmyadmin. Connect to the db as you would connect to a hyperfile cs but use the mysql server connection type. I'll post you some stuff from my app later on.
The hcreateifnotfound will create all the tables in mysql. However if you later on add files to the analysis the tables are not updated as they are in hyperfile.
You can remove all the tables and let hcreatenotfound() do the creation for you or you can manually add table with the php myadmin. It is recommended that you do last since if you need to add tables to a life app ( in the future ) you need to add the tables manually as well.
Well that is about it. Development can be just like you normally do. If you have webdev you can make a website that runs on the same db as well. Cool

Ok there is one thing to keep in mind. You have to specify in mysql what your ip adres Is and open access for that address. Do not use a * and give everyone access. If you do that you have an open db on the net that can be easily hacked by others. You state you use it for personal use. Then accessing the db this way is just fine. Do not go this way with and app that you sell to the public. For then you need to give everyone access to the db.

Regards
Allard

von Allard - am 04.03.2015 12:35
Hi Darren,

You have also two other (and much more simple) solutions, if you can:

1. Have a Hyper File CS database secured on a computer/server and open required firewall ports to forward you external connections to it.

2. Use Remote Desktop. Use http://www.terminalserviceplus.com/ as a solution for our customers. It just works great and the price tag is perfect. You could then access your application very easily without any modifications of your software.

As a side note, buying HFSQL "Cloud" services is cheap and a very easy solution if you are already using HFSQL CS. We use kalanda.net (but for full WebSite hosting, not just HFSQL - https://www.kalanda.net/apps/cart.php?gid=4) and it works very well.

Best regards,
Alexandre Leclerc

von Alexandre Leclerc - am 04.03.2015 13:52
Brilliant Allard - thanks!

Yes, phpmyadmin is about the limit of my exposure to MySQL, that and installing the MySQL connector.

I'll digest the information and give it a try! :spos:

von DarrenF - am 04.03.2015 13:55
Alexandre,

Thanks for your suggestions...

I wanted a low cost solution to try it out and see how it all works and I already have some Linux hosting with a MySQL DB.

Also, this isn't for a customer (yet), but in any case, I need an "always on" solution, so the remote desktop probably won't work as it relies on the remote machine being "always on".

von DarrenF - am 04.03.2015 14:02
Hi Allard,

Is this the file that needs to be included; WX180PACKMYSQL035.exe ?

Linked to via this page?
http://www.windev.com/ts/download/common-modules-18/mysql.htm

von DarrenF - am 04.03.2015 14:51
Hi Darren,

Yes , LibMySQL.DLL is the file. Add this and up you go.


regards

Allard

ps

Mysql has a bit different , you could call it syntax, for defining the types. It doesnot have a currecy etc, but a whole lot of other types so if you are doing modifications manually try it out. The hcreatenotfound() creation can give some insight in how windev analyse is converted.

This is kind of powerfull even on a 50 cent hosting account. I had an app I used for the local scouting group. (In fact a hike, big walking hiking event) They accesed it concurrently with 15 users. It worked great. (App made with windev in only view days)
This was a simple two day event so I gave it a go but again opening up the mysql to the world isnot recommended!

Regards

Allard

von Allard - am 04.03.2015 16:00
Zur Information:
MySnip.de hat keinen Einfluss auf die Inhalte der Beiträge. Bitte kontaktieren Sie den Administrator des Forums bei Problemen oder Löschforderungen über die Kontaktseite.
Falls die Kontaktaufnahme mit dem Administrator des Forums fehlschlägt, kontaktieren Sie uns bitte über die in unserem Impressum angegebenen Daten.