Re: [Harbour] Re: RDDSQL Question.
> >> OK, but how do you reaslise datacommits to database ?? >> > > Using RDDINFO( RDDI_EXECUTE, "UPDATE ...") > > 3. Modifying database .. .. The programmer must call SQL command explicitly to modify SQL tables. SSI provides a method to detect which cached rows was changed or appended. Which is this method ? and how it work ? Bruno ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
Hi, Jacek Kubica wrote: May be could you post a working sample using this mix way of work using a browse etc etc MK> Sorry, I do not use browse(). I use our own GUI. OK, but how do you reaslise datacommits to database ?? Using RDDINFO( RDDI_EXECUTE, "UPDATE ...") Using ODBC, native client or something else ?? Using rddsql, sddmy. BTW. sddoci works very well here ! Thanks Viktor ! +2 :) Regards, Mindaugas ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
Itamar Lins wrote: Yes, I understand. Another problem we consider a table with 3Gib for example how to work with it via browse? because my system is 100% via browse style excel. This is syntaxe below is impraticable. DBUSEAREA(, "select * from my_table") How to calculate end of query and run SQL again using browse ? DBUSEAREA(, "select * from my_table limit 100") Let's say table has unique numeric id column (auto_increment or similar). We use two techniques to solve the problem: 1) even if database is large (but not huge), you can try to do: select id from * mytable order by id; MySql returns 5 ids very quickly. Later on page down/page up action you just do subqueries: select * from mytable where id in (...) order by id; ... is a list of first, second, third, ... numbers of ids from the "ids query". 2) if table is huge the second technique is better: First page: select * from mytable order by id limit 20 Next page (after page down): select * from mytable where id > nPrevQueryLastId order by id limit 20 Please, do not ask how to use it browse. We are doing it by MoveTo(), LineTo(), TextOut(), etc and a lot of code on the top of it. Regards, Mindaugas ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
Bruno Luciani wrote: well , some code sample would be usefull This "sample" is 73 files with implementation of all GUI app development environment. It will not work together, if you delete one file. I can send some 20 lines sample, but it gives nothing to you. But I won't share the whole code because: it's not multiplatform, not enough portable, contains lithuanian function names, etc, etc. We can manage to use it in very comfortable way in a small group of programmers. But it is not what I want to see in Harbour project. Regards, Mindaugas ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
> I already did some month ago ( search for "New SQL classes #1" ) but > everything "stopped" around class vs RDD. It was in 2008 October ;) So maybe the topic could need some actualization. Most importantly we have (thanks to Mindaugas) RDDSQL since (committed in 2008 December), which gives us a very nice and natural base for accessing SQL (or in fact any 3rd party) data sources. In fact by now we have a base driver for all SQL vendors you mention except DB2, well, and ADO. [ But seeing the "huge" interest in touching RDDADO, maybe this isn't such a miss. Perhaps we could have and sddusr and ado implemented as .prg SDD. ] We also have the naming right. > Even the programming style can be very different, f.e. my apps are > tbrowse centric others don't use tbrowse at all. > > IMHO what we call xBase doesn't exist. I don't see many similarities > between Harbour, Visual FoxPro and Visual Object beyond few reserved > names so it seems quite difficult to extend Harbour beyond the Clipper > known "spaces". Sorry but I cannot remember the exact discussion details, we also had a enormous amount of development, plus quite possibly lots of new followers since then, so it'd still be great if you could "reopen" the topic with that (and RDDSQL) in mind. Brgds, Viktor ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
On Wed, Mar 3, 2010 at 7:00 PM, Viktor Szakáts wrote: > For sure it'd be powerful addition, so pls feel free > to open the topic, I'm sure many are interested. I already did some month ago ( search for "New SQL classes #1" ) but everything "stopped" around class vs RDD. Even the programming style can be very different, f.e. my apps are tbrowse centric others don't use tbrowse at all. IMHO what we call xBase doesn't exist. I don't see many similarities between Harbour, Visual FoxPro and Visual Object beyond few reserved names so it seems quite difficult to extend Harbour beyond the Clipper known "spaces". best regards, Lorenzo ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
>> Another problem we consider a table with 3Gib for example how to work with >> it via browse? because my system is 100% via browse style excel. >> >> This is syntaxe below is impraticable. >> >> DBUSEAREA(, "select * from my_table") >> >> How to calculate end of query and run SQL again using browse ? > > In my experience the move from dbf to sql require a major rewrite of > the app logic. > I've done some experiments but without sth like .Net/JDBC DataSet > connecting SQL to the UI is not so easy. > > I think we should start a serious discussion about SQL support and try > to join the forces to create sth that match the features of .Net and > Java. For sure it'd be powerful addition, so pls feel free to open the topic, I'm sure many are interested. Brgds, Viktor ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
On Wed, Mar 3, 2010 at 4:07 PM, Itamar Lins wrote: > Another problem we consider a table with 3Gib for example how to work with > it via browse? because my system is 100% via browse style excel. > > This is syntaxe below is impraticable. > > DBUSEAREA(, "select * from my_table") > > How to calculate end of query and run SQL again using browse ? In my experience the move from dbf to sql require a major rewrite of the app logic. I've done some experiments but without sth like .Net/JDBC DataSet connecting SQL to the UI is not so easy. I think we should start a serious discussion about SQL support and try to join the forces to create sth that match the features of .Net and Java. best regards, Lorenzo ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
well , some code sample would be usefull Bruno 2010/3/3 Mindaugas Kavaliauskas > Hi, > > > > Bruno Luciani wrote: > >> May be could you post a working sample using this mix way of work >> using a browse etc etc >> > > Sorry, I do not use browse(). I use our own GUI. > > > > Regards, > Mindaugas > ___ > Harbour mailing list (attachment size limit: 40KB) > Harbour@harbour-project.org > http://lists.harbour-project.org/mailman/listinfo/harbour > ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
Hi, Bruno Luciani wrote: May be could you post a working sample using this mix way of work using a browse etc etc Sorry, I do not use browse(). I use our own GUI. Regards, Mindaugas ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
May be could you post a working sample using this mix way of work using a browse etc etc It is very interesting Bruno 2010/3/3 Mindaugas Kavaliauskas > Hi, > > > > But if I for example use: >> My Browse() function and modify a field? >> Because I change only in temporary cache query. >> How to proceed for commit? >> > > In my code on edit dialog "OK" button, o do both actions: execute query and > set field values. > > There is also my primary idea to store "dirty" flag for records, and later > (ex. on browse close) iterate these "dirty" records and execute SQL update > queries. I have not implemented this yet, since, I'm using another way to > update DB. This "dirty" flag way has also some drawbacks, so, I do not want > to do implementation until I do not use it and find it really a good > solution for final application. > > > > Regards, > Mindaugas > > ___ > Harbour mailing list (attachment size limit: 40KB) > Harbour@harbour-project.org > http://lists.harbour-project.org/mailman/listinfo/harbour > ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour
Re: [Harbour] Re: RDDSQL Question.
Hi, But if I for example use: My Browse() function and modify a field? Because I change only in temporary cache query. How to proceed for commit? In my code on edit dialog "OK" button, o do both actions: execute query and set field values. There is also my primary idea to store "dirty" flag for records, and later (ex. on browse close) iterate these "dirty" records and execute SQL update queries. I have not implemented this yet, since, I'm using another way to update DB. This "dirty" flag way has also some drawbacks, so, I do not want to do implementation until I do not use it and find it really a good solution for final application. Regards, Mindaugas ___ Harbour mailing list (attachment size limit: 40KB) Harbour@harbour-project.org http://lists.harbour-project.org/mailman/listinfo/harbour