Choosing SQL database ...

Re: Choosing SQL database ...

Postby Otto » Tue Oct 27, 2009 9:28 am

Hello Reinaldo,

>Your 2 cents + my 2 cents = 4 cents (or maybe more....?)

I think you have to make a division:

Your 2 cents / my 2 cents = 1 and this is the answer or solution

One only has to know how to divide 2 cents by 2 cents. :)

I would like to make some tests with ADS. Is it really as easy as you wrote – download the free version and change the RDD to ADS?
Best regards,
Otto
********************************************************************
mod harbour - Vamos a la conquista de la Web
modharbour.org
https://www.facebook.com/groups/modharbour.club
********************************************************************
User avatar
Otto
 
Posts: 6312
Joined: Fri Oct 07, 2005 7:07 pm

Re: Choosing SQL database ...

Postby Adolfo » Tue Oct 27, 2009 12:48 pm

Reinaldo...

PLEASE.. forget about DBF's ( although I'm using them with no problems in ALL my products ), you can't compare SQL to DBF. not even ADS. SO knowing how to manage a DBF is worthless in order to work with SQL, thay are completely separate ways of working with data. I've done incremental searching with Mysql, Paging, Scipting.. and I don't use hundreds of lines.. just ADO features and STANDARD SQL.

ADS is a good product, perfect if you want to keep working with dbf's, but it can't be compared to SQL, and DBF LOGIC is quite oldfashioned. ADS Local is not Transactional. There's no HOSTING offering ADS, you'll have to mount your own server to have it working. ADS 5 users is sold in 844€ ( better no ask for a 25 user ), MYSQL ENTERPRISE BASIC ( Enough for 250 users ) costs 475€ ( FREE is you hire a HOSTING )
So IMO for large amount of users.. go SQL.

About SQLITE, perfect, SQL for small LANs, all the knowledge on SQL can be used on any large DB, a completely UPTODATE knowledge.. and with ADO... better... you can use ADO with all WEB programming languajes.

If ADO will disappear with new Windows Versions.... I doubt it. It was included in Vista, and in 7 too.. I use it in my "developer machine".
ADO.NET.. some differences, 3 instances (SQL Connection, SQLADAPTER and DATASET ) instead of 2 ( Connection and RECORSET ) , and many many more methods and datas.

From Chile..a SQL FANBOY... :lol:
Adolfo

( just kidding :oops: )
;-) Ji,ji,ji... buena la cosa... "all you need is code"

http://www.xdata.cl - Desarrollo Inteligente
----------
Asus TUF F15, 32GB Ram, 2 * 1 TB NVME M.2, GTX 1650
User avatar
Adolfo
 
Posts: 860
Joined: Tue Oct 11, 2005 11:57 am
Location: Chile

Re: Choosing SQL database ...

Postby Rimantas » Tue Oct 27, 2009 1:04 pm

Adolfo wrote:...
PLEASE.. forget about DBF's ( although I'm using them with no problems in ALL my products ), you can't compare SQL to DBF. not even ADS. SO knowing how to manage a DBF is worthless in order to work with SQL, thay are completely separate ways of working with data. I've done incremental searching with Mysql, Paging, Scipting.. and I don't use hundreds of lines.. just ADO features and STANDARD SQL.
...


Big + for Adolfo ... :)

Regards !
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Choosing SQL database ...

Postby reinaldocrespo » Tue Oct 27, 2009 1:11 pm

Rimantas;

I wonder what kind of tests you did that made ads local "slow"...

A frequent mistake people make is forgetting that when you connect across the internet speed is not the same as on a local LAN. Therefore you must avoid full dbf "browses" (which you can't do with SQL anyway). Instead you work with sets of data. If you only bring a cross 1 record and its children (on a relation), that data will probably travel in less than 1 second over regular DSL.

In other words; when working with an internet connection to ADS-DBF/ADT tables you have to avoid this:

Dbusearea( ::lNew ,::cRDD ,::cFileName ,::cAlias , ::lShared ,::lReadonly )
Browse()

That works fine on a LAN but not on a WAN over internet.

If instead you do this:

Dbusearea( ::lNew ,::cRDD ,::cFileName ,::cAlias , ::lShared ,::lReadonly )
( ::cArea )->( dbSeek( Key ) )
? ( ::cArea )->Name

or

replace ( ::cArea )->Name With "First-Name"

That happens in less than a second. As soon as I have a chance, I'm going to spend some time writing a small fw app to show how to connect and work with ADS-DBF-ADT tables using ISAM and SQL over an internet connection.

In the interest to help, in the meanwhile, if anyone is interested I can provide you with a user name and password to connect to ADS-DBF/CDX tables using a php web-app on a browser where my customers currently create service tickets. I will also show the php code where connection and queries to the actual DBFs happens. The code is very similar to what a fwh win32 app would also be.

I hope that helps,



Reinaldo.
User avatar
reinaldocrespo
 
Posts: 979
Joined: Thu Nov 17, 2005 5:49 pm
Location: Fort Lauderdale, FL

Re: Choosing SQL database ...

Postby reinaldocrespo » Tue Oct 27, 2009 2:21 pm

PLEASE.. forget about DBF's ( although I'm using them with no problems in ALL my products ), you can't compare SQL to DBF. not even ADS.


But you forget; ADS IS SQL.

SO knowing how to manage a DBF is worthless in order to work with SQL,

With ADS you can work ISAM and SQL in the same app... so nothing is worthless.

I've done incremental searching with Mysql, Paging, Scipting.. and I don't use hundreds of lines.. just ADO features and STANDARD SQL.

I don't think so my friend.

Ok, so you have a 250k records table. And you what to display the full table to do an incremental search. As you type the bar moves to the nearest record. For argument's sake let's say you are displaying 250k customers with their address and telephones. It is ordered alphabetically. You type "R" and the bar moves to Ramos, then you type "i" and the bar moves to Rivera, then you type "o" and the bar moves to "Rios"... Or better yet, after typing the first "R", press the up arrow key. You should move to something like "Quesada". And you do with with 250k records using SQL ... I don't think so. In order to imitate an incremental search you would first have to fetch the whole table: "Select * from customers", load that into a memory array (or use the returning cursor) and now you can do the incremental search, or you wait for the first keystroke ("R") and you execute "Select * from customers where lastname between 'Ra' and 'Rz'" and now display that on a browse. In the last case, you are not display the whole table, so forget about moving up with the arrow key to anything previous to the first "R" last name. This is ok when working with a web app. But for a win32 app..., very limiting. There! the power of ISAM.

...if you want to keep working with dbf's, but it can't be compared to SQL, and DBF LOGIC is quite oldfashioned. ADS Local is not Transactional.


Old-fashioned... hum... So is RDDs but boy they are so much faster than any .net or ADO or ODBC or any of them combined. That actually give small shops like ours an advantage. Nothing is faster than DBF/CDX ( or ADS/ADI for that matter).

There's no HOSTING offering ADS, you'll have to mount your own server to have it working.

Now, that's a good point. You are taking about web access. You are right here. Not only that, you do have to recompile php if working with a linux server. If you are developing web-apps exclusively and no win32 apps to touch the data from within the LAN... well that's precisely where sqlite is recommended.

ADS 5 users is sold in 844€ ( better no ask for a 25 user )
I'm quite sure that my customers pay around $500 for a 5 user and $5,770 for 250 users (that's US dollars).

So IMO for large amount of users.. go SQL.

Right. And ADS is SQL.

About SQLITE, perfect, SQL for small LANs, all the knowledge on SQL can be used on any large DB, a completely UPTODATE knowledge.. and with ADO... better... you can use ADO with all WEB programming languajes.

No different than ADS; which is my point. With ADS you can use ODBC/ADO/.NET/php/Java/Perl...

If ADO will disappear with new Windows Versions....

I'll tell you what will disappear: RDDs! (if user support continues to withdraw).

Thank you for your reply. I'm not taking merits away from SQL set based transactions. I'm very happy I was introduced to SQL and pleased with its results. BTW- I did it by using ADS and slowly changing some parts to SQL. I was not up to completely re-writing my apps. Your comments are quite in tune with my own. My point is that (1) ISAM is also a good thing (2) ADS is the only SQL with ISAM combined and (3) The local version is free and the client-server version (especially for 250 users) is worth paying for.

There is a ADS FWh user in Chile - Patricio. Do you know him?

Reinaldo.
User avatar
reinaldocrespo
 
Posts: 979
Joined: Thu Nov 17, 2005 5:49 pm
Location: Fort Lauderdale, FL

Re: Choosing SQL database ...

Postby Enrico Maria Giordano » Tue Oct 27, 2009 2:53 pm

Adolfo wrote:I've done incremental searching with Mysql, Paging, Scipting.. and I don't use hundreds of lines.. just ADO features and STANDARD SQL.


I strongly doubt of this. Please can you show us how do you make incremental searching using ADO and standard SQL?

Adolfo wrote:and DBF LOGIC is quite oldfashioned.


Please don't reverse the reality. SQL is much older than DBF's logic.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8710
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Choosing SQL database ...

Postby Adolfo » Tue Oct 27, 2009 3:35 pm

EMG...

Preparing a small sample with Incremental search ( and paging if I have time)
Give some hours

Adolfo
;-) Ji,ji,ji... buena la cosa... "all you need is code"

http://www.xdata.cl - Desarrollo Inteligente
----------
Asus TUF F15, 32GB Ram, 2 * 1 TB NVME M.2, GTX 1650
User avatar
Adolfo
 
Posts: 860
Joined: Tue Oct 11, 2005 11:57 am
Location: Chile

Re: Choosing SQL database ...

Postby Enrico Maria Giordano » Tue Oct 27, 2009 4:27 pm

Thank you. But please notice that paging has nothing to do with incremental searching.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8710
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Choosing SQL database ...

Postby Rimantas » Tue Oct 27, 2009 5:09 pm

reinaldocrespo wrote:Rimantas;

I wonder what kind of tests you did that made ads local "slow"...



Yes , Reinaldo , it's very slow . And that in network enviroment . At first I did localy at own PC . It seems that will be OK - but here I was running as one user at the same PC ... Then I put this on server of enterprise . After some hours they called me and said that program is working very slow .... :) . I tested in enterprise - if are <= 2 users , then it can suffer . But if are working more than 2 users - the speed is downing very very . So I returned to DBF+CDX without ADS local ... Excuse , Reinaldo , but mine impresion about ADS local isn't good ... :)

Adolfo , did you received mine e-mail ? :wink:

Regards !
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Choosing SQL database ...

Postby Rick Lipkin » Tue Oct 27, 2009 5:58 pm

To All

I use both ADS for .dbf client\server .. dbfcdx for small single installations .. and SQL Server for 'enterprise' lan\wan applications.

I don't think there is 'one size fits all' and depending on your target audience .. DBFCDX in a small lan environment seems to work best for me.

I do like ADS .. I still use it, even for Enterprise solutions .. however, .dbf is considered in many CIO's eyes something along the lines of 'desktop' database .. akin to MS Access or even 'clipper' ..

Please do not get me wrong .. I am not knocking any .dbf platform nor am I saying anything bad about 'clipper' .. but the conotations of those products in todays marketplace are not what many CIO's even think about when either you approach them to sell your product .. nor do you find many CIO's even turn over those rocks ( .dbf ) when they plan on developing a large 'in-house' project.

I have fought this battle for many years .. and I like Harbour\xHarbour and where 'open source' is taking the IT industry .. forcing these close minded' CIO's to re-think their expensive dB2's and Oracles databases of the world.

For me .. I like Sql Server because ADO is supported nicely with Windows 7 and you do not need any client or run-time or dot net to connect to Microsoft's Sql Server ..

Depending on your application and your targeted client .. Enterprise = sql server .. large to medium client\server = ADS .. small business with a small local lan = dbfcdx.

Rick Lipkin
User avatar
Rick Lipkin
 
Posts: 2663
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Re: Choosing SQL database ...

Postby reinaldocrespo » Tue Oct 27, 2009 7:11 pm

Rick;

Well said. For a CIO, it is easy. Go with the most expensive and cover you ass. Run no risks. Who's ever been fired for choosing Oracle?

On the SQL list, I'm going to add one more: iAnywhere SQL. Believe it or not, this is the most widely used SQL in the market today. It is imbedded most data apps on mobile devices (blackberry, iphone), on most routers (including Cisco), and even on over the counter win32 apps (such as QuickBooks).

Last month I saw a demo using iAnywhere SQL replicating data from a blackberry to a windows server. It replicates data to just about any SQL (ms, oracle, ASE ). It looked very very impressive. But I have no experience using it.


Reinaldo.
User avatar
reinaldocrespo
 
Posts: 979
Joined: Thu Nov 17, 2005 5:49 pm
Location: Fort Lauderdale, FL

Re: Choosing SQL database ...

Postby Adolfo » Tue Oct 27, 2009 7:19 pm

Hi everyone..

Here you hace a sample on Incremental search with ADO, TADOBASE ( my class, a clone of tDatabase ) and MYSQL.
You need to have Mysql ODBC CLient 5.1

http://dev.mysql.com/downloads/connector/odbc/5.1.html

The test.. just unrar and execute....
http://200.72.140.34/privado/adobase/test.rar

It's a routine taken from one of my systems... so it may have some bugs... My server is not a big one, and I have reduce "Mysql" connections from outside the lan.

Just begin typing wahtever you want.. see the cursor move... and.... REINALDO... use the navigation keys whenever you wanted.

Any comment or suggestion... are welcome.
My class is also available.. see on the spanish forums.

From Chile
Adolfo
;-) Ji,ji,ji... buena la cosa... "all you need is code"

http://www.xdata.cl - Desarrollo Inteligente
----------
Asus TUF F15, 32GB Ram, 2 * 1 TB NVME M.2, GTX 1650
User avatar
Adolfo
 
Posts: 860
Joined: Tue Oct 11, 2005 11:57 am
Location: Chile

Re: Choosing SQL database ...

Postby Enrico Maria Giordano » Tue Oct 27, 2009 8:52 pm

Sorry, but I don't know what to do with your EXE. I stated that you simply can't make incremental searching using standard SQL. If you think different then you have to demonstrate it showing us how to do it.

EMG
User avatar
Enrico Maria Giordano
 
Posts: 8710
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Choosing SQL database ...

Postby Adolfo » Tue Oct 27, 2009 8:58 pm

Enrico Maria Giordano wrote:Sorry, but I don't know what to do with your EXE. I stated that you simply can't make incremental searching using standard SQL. If you think different then you have to demonstrate it showing us how to do it.

EMG


Enrico.. it's simple.... UNRAR it, you get an EXE... EXECUTE it... and use the sample... Type anything.. and see... IS IT TOO HARD ?
... or if you prefer.. I make a video.. and you just sit and see.

I ABSOLUTELY THINK DIFFERENT.. but I don't have to demostrate anything to you... I USE INCREMENTAL SEARCH WITH ADO AND MYSQL.. that's a fact... and I don't have to show you how... think a bit, you'll get it after some time...

Theres plenty of info and docs on ADO in the web, do as I did.. read, try, investigate... and you are done... just because you were unable to do it... doesn't mean Is imposible.

From CHILE
Adolfo
;-) Ji,ji,ji... buena la cosa... "all you need is code"

http://www.xdata.cl - Desarrollo Inteligente
----------
Asus TUF F15, 32GB Ram, 2 * 1 TB NVME M.2, GTX 1650
User avatar
Adolfo
 
Posts: 860
Joined: Tue Oct 11, 2005 11:57 am
Location: Chile

Re: Choosing SQL database ...

Postby reinaldocrespo » Tue Oct 27, 2009 9:37 pm

Adolfo;

I can't find what to do with an .exe either. I'm sorry. But I'll keep trying in the next few days. Don't be offended, please. Maybe you have some kind of special trick. But I don't think you can do incremental search using good and plain SQL. I don't think there's one single app out there that does it with SQL statements unless, of course, you fetch the whole table across the wire... and then either work with the memory array or navigate ISAM style (you'll need a skip(-1) ).

In the SQL model, there is no record before or after any other record. There isn't a next or a previous record. Thus, there is no skip() or skip(-1). Now, you can fetch a set and with the set you do have next and previous. But an SQL is not sequential and there is no record numbers either (recno() ).

Do share the the code. Just a short self-contained or code-snippet. Pure and simple SQL.

And, again; please don't be offended. I'm not daring you. Take this as a learning/idea exchange. I'm sure I'll learn some from your code. I'll also share some SQL triggers that I'm currently using with ADS if you like and then translate that to navigational commands for us to compare. I'm thinking that when we say "incremental-search" we are not speaking about the same thing.

... and, before I forget, thank you for taking the time and effort to write your sample even though I haven't been able to use it just yet (but hopefully I will).



Reinaldo.
User avatar
reinaldocrespo
 
Posts: 979
Joined: Thu Nov 17, 2005 5:49 pm
Location: Fort Lauderdale, FL

PreviousNext

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 78 guests