Program Freezing using SQLRDD

Program Freezing using SQLRDD

Postby sistemasit » Thu Jan 29, 2015 9:59 pm

I just start using SQLRDD for evaluating, The connection is OK, I checked if my table is there (SR_ExistTable), but my program freeze with this simple command for testing

USE TABLE1 VIA "SQLRDD"

What could it be? :|
sistemasit
 
Posts: 25
Joined: Mon Jan 26, 2015 9:53 am
Location: Belem - Brazil

Re: Program Freezing using SQLRDD

Postby sistemasit » Thu Jan 29, 2015 10:58 pm

I realized that it freezes when I try to open a table create by myself inside the "data manager", but if I create with the command (DbCreate) it works perfectly!!! :shock:
sistemasit
 
Posts: 25
Joined: Mon Jan 26, 2015 9:53 am
Location: Belem - Brazil

Re: Program Freezing using SQLRDD

Postby Antonio Linares » Fri Jan 30, 2015 5:12 am

Rubem,

if you are about to start the development of a new app, better use ADO and forget about SQLRDD

With ADO you will have full source code and total control over your app code.
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41289
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Program Freezing using SQLRDD

Postby jose_murugosa » Fri Jan 30, 2015 10:07 am

I´m Using SQLRDD from FWH 11.05 and I use it now, I never had problems with it even changin from 11.05 to 13.01, and it is really atractive that you'd use the same software with different database managers and with dbfs by changing a single line of code, but when you work with big tables, if you want performance, you will have to rewrite many of your source, and you couldn't use it with harbour , harbour64 or fwh64, I agree that as Antonio said Ado is a better way if it's a new application, If I had to create a new application I would prefere to do it with ado, tdolphin or any other solution open source.

In that way you would have think that is really important to have control of the source, and IT IS FREE :)

If I have to develope a new software I believe I would use tDolphin, It's supported by a member of the FWH team and It's excelent.
Saludos/Regards,
José Murugosa
FWH + Harbour + Bcc7. Una seda!
User avatar
jose_murugosa
 
Posts: 1144
Joined: Mon Feb 06, 2006 4:28 pm
Location: Uruguay

Re: Program Freezing using SQLRDD

Postby sistemasit » Fri Jan 30, 2015 11:13 am

No, It is not a new APP, I am linking a new database on my existing one. :|

So I think It's better to use SQLRDD, right?
sistemasit
 
Posts: 25
Joined: Mon Jan 26, 2015 9:53 am
Location: Belem - Brazil

Re: Program Freezing using SQLRDD

Postby Antonio Linares » Fri Jan 30, 2015 11:24 am

If it works, then it may be the fastest way to migrate your app without modifying your source code :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41289
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Program Freezing using SQLRDD

Postby sistemasit » Fri Jan 30, 2015 11:35 am

I am not that hurry, how big are the changes?
sistemasit
 
Posts: 25
Joined: Mon Jan 26, 2015 9:53 am
Location: Belem - Brazil

Re: Program Freezing using SQLRDD

Postby carlos vargas » Fri Jan 30, 2015 1:38 pm

to use the "use table" in sqlrdd , it is necessary that the same rdd have created the table , since adiconalmente and internally tables are created with field definitions and indexes , if you try to open a table created is not directly could and dara error.

if you try to read or manipulate a table created by another app or from this is necessary from sql instruccione and indicate when making the connection:

please note the CONNECT_QUERY_ONLY, this permite work only with sql instruction.

Code: Select all  Expand view

nHandle := SR_AddConnection( CONNECT_ODBC + CONNECT_QUERY_ONLY, _cConn )
...
IF select("MYTABLA") > 0
 MYTABLA->(dbclosearea())
ENDIF
...
nError := oSql:Exec( "SELECT * FOR USUARIOS", .t., .t., NIL, "MYTABLA" )
...
MYTABLA->(xbrowse())
 

here MYTABLA is a table create with dbfcdx rdd is exclusive for you, is only for view or search not for append or replace.
for alter table (append o replace) you should use sql instruction ( INSERT OR UPDATE to table in database) and requery data again

Code: Select all  Expand view

IF select("MYTABLA") > 0
 MYTABLA->(dbzap())
ENDIF
...
nError := oSql:Exec( "SELECT * FOR USUARIOS", .t., .t., NIL, "MYTABLA" )
 
Salu2
Carlos Vargas
Desde Managua, Nicaragua (CA)
User avatar
carlos vargas
 
Posts: 1683
Joined: Tue Oct 11, 2005 5:01 pm
Location: Nicaragua

Re: Program Freezing using SQLRDD

Postby sistemasit » Fri Jan 30, 2015 3:03 pm

Thank you Carlos... :)
sistemasit
 
Posts: 25
Joined: Mon Jan 26, 2015 9:53 am
Location: Belem - Brazil


Return to FiveWin for Harbour/xHarbour

Who is online

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