Hello

I am in need of some good advice. I have a small desktop program written in Tk. It normally uses a local SQLite database to save/read data. Now I want to give it the possibility to query some data I want to store online on a MySQL database. This would give me more freedom to control/update/etc the data the users can query. I have to admit this is my first attempt to let a desktop application access an online database, I beg for mercy.

The first possibility is to give the application direct access to the database. I have already implemented it and it just works. When a user starts a query, results are presented to the Desktop app. However, I have some obvious concerns about this approach as it exposes the database to the external world through my desktop apps. Even if the database does not contain any sensitive data, I guess this is not good practice. Am I right?

Sorry if my questions are naive.

I read online that I could/should build a web service layer between the desktop app and the database. What is the most basic Perl solution/modules to achieve this? Could you point me to some information keeping in mind I really need a simple solution to implement? It is a small project. Any online database service that you know work well with the Perl proposed solution?


In reply to online database for desktop app by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.