Dear Friends
Can we have a database (MySQL) which is in LINUX and my Qt application is running in windows, can we fetch the data from that database ? I can have my application cross-platform in LINUX and work. But if my user likes to work in windows and communicate with some database inLINUX, is it possible. I thinking of using ftp for this. Is this the right solution. ? Thanks for any help or suggestions. Thanks Sujan
Dear Friends
Can we have a database (MySQL) which is in LINUX and my Qt application is running in windows, can we fetch the data from that database ? I can have my application cross-platform in LINUX and work. But if my user likes to work in windows and communicate with some database inLINUX, is it possible. I thinking of using ftp for this. Is this the right solution. ? Thanks for any help or suggestions. Thanks Sujan
_______________________________________________ Interest mailing list Inte...@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest
-- Alexandre BERAUD Ingénieur Développement INFFLUX 01.49.57.92.00
Cheers
--
Rodrigo Gonçalves de Oliveira
Manaus, Brazil
rodrigo...@gmail.com | rod...@thecoreme.org
+55 92 82599445
http://br.linkedin.com/in/rodrigogoliveira
Of course you can, as MySQL is a server process. Don't use FTP for this though, it's a
protocol to transfer *files*, not database records. See the QSqlDatabase class and related
classes and examples.
Regards,
--
/- Yves Bailly - Software developper -\
\- Sescoi R&D - http://www.sescoi.fr -/
"The possible is done. The impossible is being done. For miracles,
thanks to allow a little delay."
No you can't. Just as an .exe program can't run on a Linux box, a Windows program can't communicate with another program running on Linux. For exemple, a Windows Firefox can't fetch web pages hosted by a Linux Apache server. Such a thing NEVER happens, hopefully. Therefore, the answer is no, except in all other cases, an vice versa.
Yes, you can have a QT application on Windows that accesses a MySql
Database on Linux. I use this concept on my own project!
I have a DB on a linux server and my QT application connects to it.
It doesn't matter if my QT application is running on a Windows or a
Linux. (Of course, I must have a internet/LAN connection between the
server and client application!)
Indeed, doesn't matter where MySql is running, too.
You can freely choose the best design.
Best Regards,
Thales Lange.
Lol its not like 60% of the internet is built around windows apps communicating with apache/php/mysql servers on linux.
No you can't. Just as an .exe program can't run on a Linux box, a Windows program can't communicate with another program running on Linux. For exemple, a Windows Firefox can't fetch web pages hosted by a Linux Apache server. Such a thing NEVER happens, hopefully. Therefore, the answer is no, except in all other cases, an vice versa.
Regards,
Am 15.02.2012 um 14:58 schrieb BERAUD Alexandre <abe...@infflux.com>:
> No you can't. Just as an .exe program can't run on a Linux box, a Windows program can't communicate with another program running on Linux.
No wait... this is for an OpenGL-accelerated t-shirt shop, isn't it?
There the DB protocols are a bit different there (maybe that's what you were referring to as "except in all other cases"?).
Unfortunatelly that works only if you have "Windows for T-Shirts 3.11(tm)".
And it is absolutely correct that the queries and result sets sent from and from Windows to Linux are being transferred with FTP - the Fast T-shirt Protocol.
But not on a direct route, but rather via Google RainCloud where the bits are taken apart and re-assembled for the proper target architecture (ever heard of Endianness of processors? It's a bit similar here).
And it doesn't stop here! The RainCloud will translate your queries; and result sets, if you have the Google "GetWhatIMean" (GWIM) plugin installed!
So for instance the following TSQL (T-Shirt Query Language":
BUY "Ein schönes T-Shirt"
FROM "Susans T-Shirts Shop"
WHERE "Zu einem guten Preis"
AND "Die Farbe ist OpenGL beschleunigt";
will automatically be translated to
BUY "A lousy t-shirt"
FROM "The truckload from China"
WHERE "The price is ridiculous"
AND "The colour is washed out after 5 times";
But just as you can accelerate t-shirt colours with OpenGL you can also hardware-accelerate your DB queries from Windows to Linux with a wireless connection! You just need to reconnect the wires 3 to 5 and 8 to 11 (remember the CPU Endianness? Same here...).
Good luck!
Oliver
P.S. Sorry, totally could not resist ;)
On a serious side: Susan, the thing is that OFF COURSE you can make a connection from Windows to any other platform! Just as is the case with the browser example, same goes for DBs. It's called networking and is VERY BASIC KNOWLEDGE any student learns in the 3rd semester or so (that excludes probably those infamous "Learn [put any fancy programming language here] in 21 days" classes that I came across in "Cyderabad" though - yes, been there, seen that, done with it!).
So if you are really serious about LEARNING the very fundamentals then buy a good book, read and understand - and then come back with real questions :)
"Computer Networks" by Andrew S. Tanenbaum is a classic, and any book about SQL and databases.
Then map this knowledge to Qt classes such as QSqlDatabase. Read and understand the Qt documentation. Study the Qt examples. Do experiments.
But questions like "Can I connect from a Windows client to a DB on some other platform" reveal your total lack on the matter and will continue to draw sarcastic comments such as mine.
And no, I don't think blocking people on this list because of ignorant questions is a good thing. This list should be open to anyone! But pushing them into the "right direction" should be acceptable, too ;)
Alex
Le 16/02/2012 09:26, Till Oliver Knoll a écrit :
> And no, I don't think blocking people on this list because of ignorant
> questions is a good thing. This list should be open to anyone! But
> pushing them into the "right direction" should be acceptable, too ;)
--
Alexandre BERAUD
Ingénieur Développement
INFFLUX
01.49.57.92.00
_______________________________________________
Folks:
> Alternatively... how about a more noob friendly Qt-Interest list? Some people
> get off on helping noobs (helps them sleep better at night I guess)... but I think
> most of us just get annoyed by his(her?) noise.
I don’t help “noobs” on mailing lists because I “get off on it”;
I help newcomers on mailing lists and forums and etc. because
I know what it is like to be using a big, complex, and yes, buggy
piece of software for the first time. And how easy it is to be-
come lost, or at least hung up on one small thing you just can’t
understand.* And so I try to help them because with just a
little help, just a key to unlock a door here and there, they
just MIGHT enjoy using the software enough that they
keep using it and become contributing members in that
software’s community of users.
Perhaps that’s not a role some want to play. If it’s not, then
perhaps we should launch the Qt-condescending-know-it-
alls-...@qt-project.org mailing list right now.**
Atlant
* Yes, I understand that’s not the case for the poster we’re
discussing; I’m thinking of the more-general situation.
** If you feel this E-mail has nothing to do with you and
that this alleged shoe does not fit you, please feel free
to disregard it/not wear this shoe.
How To Ask Questions The Smart Way
http://catb.org/esr/faqs/smart-questions.html
And a milder form of STFW:
http://lmgtfy.com/
“Sometimes I think the surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us.”
Bill Waterson (Calvin & Hobbes)
Alex