Cavo reads MySql

164 views
Skip to first unread message

Henry Fidler

unread,
Mar 4, 2021, 1:16:16 PMMar 4
to
What will be the way for CaVo to read/write MySql (on a internet host)?

Thanks
Henry

Fabio Rotheia

unread,
Mar 4, 2021, 11:15:17 PMMar 4
to
Hello Henry!

You can use the ODBC driver for mysql and VO`s SQL classes, but make sure the database is marked for external access on the internet host.

Best regards,
Fábio Rotheia

Henry Fidler

unread,
Mar 5, 2021, 6:27:04 AMMar 5
to
Fábio many thanks

I understand I have to use:
<oSQLConnection>:Connect([<cDataSource>], [<cUserID>], [<cPassword>])

I have a WordPress website which uses a MySql DataBank with a name and password.
What will be the cDataSource?

Many thanks
Henry

Wolfgang Riedmann

unread,
Mar 5, 2021, 7:33:37 AMMar 5
to
Hi Henry,

something like that should work:

cDriver := "MySQL ODBC 3.51 Driver"
cServer := "192.168.254.20"
cDB := "MyDB"
cUser := "myuser"
cPassword := "Mypassword"

oConn := SQLConnection{}
cConnectString := "DRIVER={" + cDriver + "};SERVER=" + cServer + ;
";DATABASE=" + cDB + ";UID=" + cUser + ";PWD=" + cPassword + ;
"; OPTION=3" // OPTION=16834"
oConn:DriverConnect( self, SQL_DRIVER_NOPROMPT, cConnectString )


But please pay attention if your provider permits external access to
the database!
Normally internet server databases are not opened for external
connections!

Wolfgang
--

Henry Fidler

unread,
Mar 5, 2021, 2:36:06 PMMar 5
to
Wolfgang thanks for your answer

1. Driver: Where do I find the driver for MySQL ?
2. Server: How do I find the server name? (is it the URL?)

Thanks
Henry

Franz Rachbauer

unread,
Mar 6, 2021, 3:24:47 AMMar 6
to
Actual and previous ODBC Drivers for MySQL you can find here:
https://dev.mysql.com/downloads/connector/odbc/

Server Name ist the IP of the host where the MySQL DB is hostet, but as
Wolfgang already says: Providers do not permit external access to their
DB hosts! So I always use small PHP apps at the providers host, which
get the request by url, read the db and get back the result.

Franz

Wolfgang Riedmann

unread,
Mar 7, 2021, 11:24:48 AMMar 7
to
Hi Henry,

please let me add a few things to what Franz wrote (I use a similar
approach to access databases that have no public access):

- you don't need any ODBC driver in that case
- please beware that you have a public access to the database then.
First, use a SSL connection, and second, protect the access with a
password
- since you don't need any ODBC driver, you don't have to configure
anything on the client machines

Every time when it comes to connections over the internet, security has
to be the most important issue!

Sometimes it may be better to build a webservice to interact with your
internet application, maybe up- and downloading CSV, XML or JSON files
(but always use password protection and SSL).

Wolfgang
--

Henry Fidler

unread,
Mar 8, 2021, 8:48:47 AMMar 8
to
Wofgang many thanks

My host makes it possible to choose external access.

I understand the security risk, and I hope the site (built with WordPress) will be interesting enough also for hackers,
otherwise I´ll have to learn PHP (or similar)

Thanks
Henry

Phil McGuinness

unread,
Mar 9, 2021, 5:16:26 AMMar 9
to
Henry

A VO + PHP + Wordpress developers.

Number one platform to hack for web is Wordpress.... constant attack because of its market share, like Windows a big foot print.
With 39,000 plugins there is one problem. How you lock it down to Administrator verse power user important.
We refuse to provide top level access to anybody. Client take my business elsewhere we say good buy.
The security risk allow SEO people or others to install plugins it is just not worth it.
Then you have brute force attacks, DDOS attacks.. know and published back doors etc.. have to maintain standards.
To allow external access to SQL database on public website known IP .. the hackers love it.
24x7 there are the robots that look for the holes.

The only way to exchange data to and from that works is HTTPS / User passed, Encode 64 and usual JSON data.
The SQL service on other end returns JSON or XML.

You do not have to learn PHP at all,, who is building and securing the Wordpress site. Wordpress written in PHP.
You plan what want to request or send and those scripts written.

In VO you use POST / GET and deliver and receive data.
We do this across system maybe 20,000 times a day

snip[ My host makes it possible to choose external access. ]
You host has to deal with the hack attacks and enough attacks they change their mine.
Have been through all this learning curve over say 17 years and I can tell what works and will continue to work.

snip[ > I understand the security risk, ]
No.. you think you do. When you waste hours and hours of down time trying to fight off the endless, endless hack attacks.
My developer setup a new MS 2016 server and had not activate the virus/malware protection.
Basically a bare server with IIS running. Within 4 hours the server was totally encrypted and wanted ransomware.
He also thought.. it will be safe have not put any sites on their yet.

snip[ and I hope the site (built with WordPress) will be interesting enough also for hackers, ]
The hacker community in this area massive.

We have one of our cPANEL running 120 x WP sites.. Thursday 70 x time normal traffic and XRP attack on Wordpress.
We can deal with the port, but this attack at 400 hits a second had like 30 different attack vectors trying to take cPANEL down.
That particular attack and how it was organised, never seen before. So it is a constantly changing attack system.

Why you would not protect your SQL from attack and handle the data in the way they works and is safer is HUGE RISK.
When a host gets this sort of hack they have to block IP all the time.. they soon tell you sort it out.

Phil McGuinness
---------

Henry Fidler

unread,
Mar 9, 2021, 4:04:58 PMMar 9
to
Phil, many thanks for your important info.
Henry
Reply all
Reply to author
Forward
0 new messages