Need Help with ListView

epsharp

Member
Licensed User
Longtime User
Back in March, I requested some advice for using Basic4PPC to develop commercial desktop applications and Erel advised me to develop a prototype system and test it.

It took some time but I did just that and the results exceeded all my expectations. The response time for database queries is truly awesome!

I converted the SQLite wrapper to MySql in order to use high concurrency and an ACID compliant engine (InnoDB) and I have included a copy in the attached. I made no changes to the existing methods so that programs written for SQLite will also work on MySql by simply changing the connection open string. I have added a data adapter class but it does nothing more than return a data table at the moment.

My problem is the lack of data alignment in the Table control (you simply can't show a Profit/Loss Statement with left aligned numbers ). The ListView.dll by Filippo would work just fine but I cannot find any source code and the existing DLL only supports SQLite!

Is it possible to obtain a copy of the ListView source code or to prevail upon Filippo to include the attached MySqlDeskTop.dll?

Thank you in advance for your assistance.

Regards,

Ed Sharp

NB. Although the ExecuteTable only returns double or string (as per SQLite) the MySql database supports ALL datatypes as does ListView.
 

Attachments

  • MySql.ZIP
    113.6 KB · Views: 498
D

Deleted member 103

Guest
Hi epsharp,

I wasn't able to check it because i have no MySQL-file, but it should work like this example, doesn't it?

Ciao,
Filippo
 

Attachments

  • MySQLExample.zip
    138 KB · Views: 508

giannimaione

Well-Known Member
Licensed User
Longtime User
Hi all,

dll MySqlDesktop.dll work fine, very good on desktop.
I can use a remote mysql DB, with follow string
"Data Source=62.149.231.110; Initial Catalog=DataBase; User ID=gianni Password=myPassword;" :sign0060:

can you develop MySqlDesktop.dll for device???

regards,
gianni

ps:
Ciao Filippo,
la dll MySqlDesktop.dll , funziona bene ; e' possibile anche gestire un db remoto.
Purtroppo (sembra) che questa dll non funziona sul device...
e' possibile ottenere una dll per device????
 

epsharp

Member
Licensed User
Longtime User
Hi Filippo and Gianni,

For Filippo,

I had already tried your example before I made my original post. The timing differences are significant between listview and PPC table (see attached) and I was hoping for an even better response time using a MySqlDataAdapter to fill a DataTable. However, the times shown in the example are for relatively large queries (11,000 rows) and in the real world, one would hope that queries would be much shorter. By putting a limit of 200 rows on the query, the response was about one second and I think that is OK for now. Maybe a future release might include support for DataSource.

For Gianni,

I think I made a mistake in naming the project MySqlDesktop, but I was following along the lines of the existing SQLite. Except for a few spaces and comma placements, there is no difference in the existing SQLDesktop and SQLDevice source files. Likewise in the MySql wrapper. The same DLL can be used on either the Desktop or Device.

For All,

I will shortly post the MySql wrapper in the Share forum and will change the name to simply MySql.dll, to be used in both the Desktop and Device. I am testing a additional method not in SQLite of GetDate. MySql shows all date fields as yyyy-mm-dd (2009-12-31) and requires this format when inserting or updating, but it returns a string of mm/dd/yyyy + Time. If you show this on a form and the operator changes the date, it will throw an exception error when trying to update. Reader.GetDate will return yyyy-mm-dd.


Thank you for your help Filippo.

Regards,

Ed Sharp
 

Attachments

  • listview.png
    listview.png
    12.7 KB · Views: 363
  • ppcTable.jpg
    ppcTable.jpg
    64.2 KB · Views: 336

encolo

Member
Licensed User
Longtime User
:sign0163:
Hi all

I have test mysqldeskto.dll on the vm6.5 emulator and it not work, but on the desktop work fine, with my database on the desktop

Why don't work on the emulator?

Bye
 

sitajony

Active Member
Licensed User
Hi, encolo.
There's two lib version, desktop and Device...
You need to select the device version on the Device collumn (when you click on Add DLL) and Desktop for desktop...

Comme j'ai l'impression que tu n'es pas anglais je vais le traduire...
Il y'a 2 version de Lib, PC et PPC...
Tu as besoin de séléctionner la version PPC sur la collune "PPC" (quand tu clique sur "Add DLL") and PC pour PC...
 

chavarrya

New Member
Licensed User
Help!!

I'm tring to conecct with local mysql DB, but it's imposible for me.
Somebody can help me!
 
Top