topic
stringlengths 1
63
| text
stringlengths 1
577k
⌀ |
|---|---|
ADOXB
|
Hello,
Does anybody have latest ADOXB functions?. It seems to me an easier way to start using ADO.
Look at the commands:
[code=fw:tamfyh4n]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> #command ADO CONNECT <StrDriver> <span style="color: #000000;">[</span><disconected:<span style="color: #000000;">DISCONECTED</span>><span style="color: #000000;">]</span> => ADOCONNECT<span style="color: #000000;">(</span> <StrDriver>, <span style="color: #000000;">[</span><.disconected.><span style="color: #000000;">]</span> <span style="color: #000000;">)</span><br /> #command ADO DISCONNECT => ADODISCONNECT<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO APPEND BLANK => ADOAPPEND<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO <span style="color: #00C800;">EDIT</span> => ADOEDIT<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO COMMIT <span style="color: #000000;">[</span><save:<span style="color: #000000;">SAVE</span>><span style="color: #000000;">]</span> => ADOCOMMIT<span style="color: #000000;">(</span> <span style="color: #000000;">[</span><.save.><span style="color: #000000;">]</span> <span style="color: #000000;">)</span><br /> #command ADO SKIP => ADOSKIP<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span><br /> #command ADO SKIP <num> => ADOSKIP<span style="color: #000000;">(</span> <num> <span style="color: #000000;">)</span><br /> #command ADO DELETE => ADODELETE<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO REPLACE <f1> WITH <v1> => ADOREPLACE<span style="color: #000000;">(</span> <<span style="color: #000000;">(</span>f1<span style="color: #000000;">)</span>>, <v1> <span style="color: #000000;">)</span><br /> #command ADO GOTOP => ADOGOTOP<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO GOBOTTOM => ADOGOBOTTOM<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO SET FILTER <span style="color: #0000ff;">TO</span> => ADOSETFILTER<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO SET FILTER <span style="color: #0000ff;">TO</span> <xpr> => ADOSETFILTER<span style="color: #000000;">(</span> <xpr> <span style="color: #000000;">)</span><br /> #command ADO SAVE <<span style="color: #000000;">(</span>CfILE<span style="color: #000000;">)</span>> => ADOSAVE<span style="color: #000000;">(</span> <<span style="color: #000000;">(</span>CfILE<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #command ADO EXECUTE <*Sql*> => ADOEXECUTE<span style="color: #000000;">(</span> <<span style="color: #000000;">(</span>Sql<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #command ADO LOCATE <xpr> => ADOLOCATE<span style="color: #000000;">(</span> <xpr> <span style="color: #000000;">)</span><br /> #command ADO REGLOCK => ADOREGLOCK<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO CLOSE => ADOCLOSE<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO CLOSE ALL => ADOCLOSEALL<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO USE => ADOUSE<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> #command ADO USE <<span style="color: #000000;">(</span>StrDatabase<span style="color: #000000;">)</span>> <span style="color: #000000;">[</span><shared:<span style="color: #000000;">SHARED</span>><span style="color: #000000;">]</span> => ADOUSE<span style="color: #000000;">(</span> <<span style="color: #000000;">(</span>StrDatabase<span style="color: #000000;">)</span>>, <span style="color: #000000;">[</span><.shared.><span style="color: #000000;">]</span> <span style="color: #000000;">)</span><br /><span style="color: #B900B9;">// #command ADO SORT ON [<(cF)>][<(x)>] => ADOSORT( [<(cF)>][, <(x)>] )</span><br /> #command ADO <span style="color: #0000ff;">SELECT</span> <<span style="color: #000000;">(</span>cRecordSet<span style="color: #000000;">)</span>> => ADOSELECT<span style="color: #000000;">(</span> <<span style="color: #000000;">(</span>cRecordSet<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /><br /> #xcommand ADO SQL DELETE <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'DELETE '</span>+ <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL INSERT <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'INSERT '</span>+ <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL <span style="color: #0000ff;">UPDATE</span> <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'UPDATE '</span>+ <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL ALTER <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'ALTER '</span> + <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL CREATE <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'CREATE '</span>+ <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL DROP <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'DROP '</span> + <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL RENAME <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'RENAME '</span>+ <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL <span style="color: #0000ff;">UPDATE</span> <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'UPDATE '</span>+ <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL GRANT <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'GRANT '</span> + <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span><br /> #xcommand ADO SQL REVOKE <*cSQL*> => ADOEXECUTE<span style="color: #000000;">(</span> <span style="color: #ff0000;">'REVOKE '</span>+ <<span style="color: #000000;">(</span>cSQL<span style="color: #000000;">)</span>> <span style="color: #000000;">)</span></div>[/code:tamfyh4n]
Thank you. Best regards,
|
ADOXB
|
[url:xy06jkxc]http://www.pctoledo.com.br/forum/viewtopic.php?t=6772#p35335[/url:xy06jkxc]
|
ADOXB
|
Antonio,
Thanks but links don´t work and the code is from 2007. Now it does not work fine with latest Harbour due latest changes in ActiveX and Ole.
But it will be a great approach to have such commands. I see the idea of a full ADO/SQLRDD is hard to accomplish, but to have a set of commands as regular DBF commands will help to use ADO.
What do you think?.
Best regards,
|
ADS
|
I recently downloaded a sample app from René's web site. When executed it connects to remote dbfs and allows add/edit/view/browse of tables (DBFs). It is a very convinient solution to provide clients access to one common database from many remote work stations via a fast web connection, and still use the same xbase we know. It uses the ADS client-server add-on which is not exactly inexpensive, but seems to works great nevertheless.
I thought it would make great sense to gear my apps towards using the ADS drivers so that whenever remote access is needed, it will only be a matter of purchasing and installing the ADS server at the customer's server where the dbfs are stored. We must admit that it is becomming increasingly more crucial to have web/enabled or remotely/web accessed apps now days.
In order to have one and only one set of source code to work with the local server as well as with the commercial n users server stuff, I thought of placing a flag on a .ini file that will decide wheather the app is to work with a local or remote server. Something sort of like this:
INI oIni FILE ".\MyApp.ini"
Get xRDD SECTION "RDD" ENTRY "RDD-VERSION" OF oIni DEFAULT "LOCAL"
ENDINI
rddsetdefault( "ADS" )
rddRegister ( "ADS", 1 )
SET FILETYPE to NTX
IF upper( xRDD ) <> "LOCAL"
SET SERVER REMOTE
cADS := " Remote 32 bit -b"
ELSE
cADS := " Local 32 bit -b"
SET SERVER LOCAL
ENDIF
and always link the ads RDDs.
Questions:
1. Will this work?
2. Is there a better way?
3. Exactly what files must be linked?
4. I once read that there is a free ADS 2 user full version available. How can it be obtained?
BTW; Last night I accidentally also came across a web-radio transmission via a posting about radio creswin from Méjico. René was on the air speaking about ADS. It was a very pleasant converstion. Congratulations on the radio program. I'm only sory I was late on it and did not get to listen to the whole transmission. Does any body know the scheduling of this program on the air? I'm looking forward to listening anytime I'm able to.
Best,
Reinaldo Crespo-Bazán
|
ADS
|
Good to know you have tested our programs.
And since you liked the talk about ADS, you can download some other interviews regarding MySQL, xHarbour.com, 32 bits migration, from here:
<!-- w --><a class="postlink" href="http://www.listoelpollo.blogspot.com">www.listoelpollo.blogspot.com</a><!-- w -->
All the interviews are recorded in MP3 format so you can download them and listen anytime you want.
Now let's go to ADS:
you will need the following DLLs <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: -->
AXWCS32.DLL : ADS client
ACE32.DLL : DLL with all the ADS functions.
Optional:
ADSLOC32.DLL for you to use the "local Server".
These DLLs are provided by Advantage in its programa Advantage Data Architech, you can download the ARC from our website:
<!-- w --><a class="postlink" href="http://www.google.d2g.com/ads/arc32.exe">www.google.d2g.com/ads/arc32.exe</a><!-- w -->
If using a remote server or the internet server you will need:
ADS.INI
If using local server you will also need :
ADSLOC.CFG
For the source code you will need:
RDDADS.LIB
ACE32.LIB.
Now, let's go piece by piece.
(x)Harbour provides you with the RDDADS.LIB (it's in the contributions section), this file contains wrappers to the most common used ADS functions. These functions are stored in a DLL called ACE32.DLL (Advantage Client Engine), the fastest way to use the ACE32 is to "export" all the functions into a LIB file, this can be done using a program included in the Borland C++ compiler called IMPLIB.EXE, you simply do:
IMPLIB ACE32.LIB ACE32.DLL
this will convert the DLL into a harbour linkable LIB. however there are certain resources in the DLL that cannot be exported into a lib, so you will need to distribute the ACE32.DLL no matter that you have converted it into a lib.
You must link these both files in your (x)harbour program.
Along with this, you should include the ADS client itself, which is: AXWCS32.DLL this client is used to log into the 3 servers, Remote, local and internet. This file requieres the ADS.INI file to define the LAN IP for the remote server and the WAN IP for the internet conection.
In your code, there's no need to do much things, instead choosing the server by hand, simply:
AdsSetServerType(7)
This will "activate" the "smart server searching", this means that you programa automatically detect what kind of server you are using, and will connect to it with no intervention at all. However, the parameter in the AdsSetServerType() defines what kind of server you will use
1 - Local Server
2 - Remote Server
4 - Internet Server
You can add the values to make different server combinations, for example:
3 - Local and Remote Server
5 - Local and Internet Server
6 - Remote and Internet Server
7 - Local, Remote and Internet Server
so, theres no need to have anything extra. <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: -->
|
ADS
|
Rene;
Thank you very much for your answer and quick guide. I think that you and "listoelpollo" with the radio program do a great service. I continue to write English for the benefit of the rest of the ng.
I did as you said. It all went well. I got one of my apps to work with the ADS RDDs LOCAL server and still use the same sets of DBF-NTX files. Up to this point I encountered no problems and the app works as expected. I'm wound up about it.
So I decided to download the free trial ADS version for Linux. I'm using SAMBA services to access the data from windows XP workstations. I installed it and changed the directory where the data is stored ownership as performed by the installation routine. But now my app does not have access to the data. It stoped working. I know I could chmod and chown back to what it was and my app will again have access to the files, but I'm afraid it would not be working with the REMOTE server. AMOF, by leaving the permissions as set to "advantage.users" rwxr--r--, is the only way I know for sure that the application is working with the remote server. --Right?
Below is the piece of code where the SET SERVER happens:
INI oIni FILE ".\MyApp.ini"
Get xRDD SECTION "RDD" ENTRY "RDD-VERSION" OF oIni DEFAULT "LOCAL"
...
rddsetdefault( "ADS" )
SET FILETYPE to NTX
rddRegister ( "ADS", 1 )
AdsSetServerType( 7 ) //iif( xRDD == "REMOTE", 2, 1 ) )
I thought with AdsSetServerType( 7 ) it would automatically connect to the REMOTE server if found. Well..., it did not.
The ADS deamon is up and running. I confirmed this with ps -aux. It has a ps ID of 556.
I'm stuck at this point. Please help!
Again, thank you very much.
Reinaldo.
|
ADS
|
Reinaldo:
ADS daemon for Linux has a great misadvantage.... is a real PITA (pain in the....ss) to get it configured correctly.
The last ADS for linux I installed took me over 3 days making tests until I dunno what I did that it started working under samba.
You may check if you have a successful installation if you install the ARC and using the tools included in the main menu you can check that you have a response of the Linux server.
If so... let us know what you did to install the server <!-- s:wink: --><img src="{SMILIES_PATH}/icon_wink.gif" alt=":wink:" title="Wink" /><!-- s:wink: -->
|
ADS
|
Reinaldo,
I am working with ADS over LInux, and I don't have any problem, you don't need samba, only if you want to work with ARC remotly. you can work with ARC for Linux and get access from Remote Xterminal or Local Xterminal Console.
Regards
Marcelo
|
ADS
|
I got it to work! Yea!
Don't ask me how. I'm too new at the ADS matter to know exactly what did the trick. Perhaps it is too simple to even discuss it here. But the important thing is that I got it work. Now I move into more and more tests...
Marcelo;
You make quite an interesting point. As I think about it; hum..., I realize that indeed we should not really need SAMBA after all. I'll be testing this also. But first, there are too many other things to do. To start with, I'm going to have to change all my file names (hundreds) to lowercase (will probably write a script to do so). After this I'll be testing with AIS connection and speed of transactions. Allowing access to the dbfs from anywhere via a web connection is very important to me.
I'll keep you all informed. Thank you for all your comments and help.
|
ADS
|
Reinaldo,
I am happy that is working for you, I recomend to you to port your DBF file to ADT, with ADS ADT is more stable. Another good think, is that you can mix SQL with traditional dbf table navegation, yes this is possible with DBF too <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->.
You don't have problems to work with AIS from ADS/Linux, I made some test to connect to my Linux server from Mexico (Mauricio Bernal) and this work, I have a PHP interface too, but configure and compile the PHP was hard, I hope Extend System change this in the new version (8.0)
Regards
Marcelo
P.D. a stupid script to change files in the current directory lo lowercase
#!/bin/sh
for i in `ls`
do
lc=`echo $i | tr A-Z a-z`
mv $i $lc
done
|
ADS
|
Marcelo;
I call that a very smart script. :-)
Thank you.
|
ADS
|
saludos , tengo el ADS instalado en mi Servidor Linux y todos las pruebas de conexion funcionan perfecto pero..
cuando intento conectarme desde mi programa me marca error que no encuentra la dbf...
alguna sugerencia.
saludos
Maximus
|
ADS
|
Maximus,
tienes tomar en cuenta que para conectarte a una tabla que esta en linux, debes de colocar todo el path, es decir si tienes corriendo ADS en una maquina con IP 192.168.1.10 en el puerto 3000 y tus archivos estas en /var/ads/data, entonces podrias poner
SET DEFAULT TO \\192.168.1.10:3000\var/ads/data
Espero te sirva.
saludos
Marcelo
[quote="Maximus":jwqzwupd]saludos , tengo el ADS instalado en mi Servidor Linux y todos las pruebas de conexion funcionan perfecto pero..
cuando intento conectarme desde mi programa me marca error que no encuentra la dbf...
alguna sugerencia.
saludos
Maximus[/quote:jwqzwupd]
|
ADS
|
Maximus,
pero lo mejor que puedes hacer para evitarte problemas es definir un Diccionario, Advantage Data Dictionary, lo puedes hacer localmente, y luego lo copias al servifdor con Linux con todas las tablas e indices
saludos
Marcelo
|
ADS ?
|
Un saludo al foro, utilizo Fw 2.4 y xHarbour, hago ejecutables con AjMake 3.0 y tengo un sistema para red local pero necesito seguridad en dbf y subirlo a la web para que usuarios finales hagan transacciones como pedidos etc. Por donde empiezo?
Por otro lado quiero que me aclaren algo, continuamente recibo publicidad sobre xalier y al principio me descontrole porque pense que Fivewin venia en decadencia pero oh sorpresa al recien ingresar a este foro apenas hace unos dias y observo contundencia y eso me alienta porque deje de programar por 3 años y de repente me encuentro con este escenario de nuevas herramientas y no quiero dejar de utilizar Fw ; he leido en este foro de ADS , ADORDD, hablan de interactuar con SQL y massss.....
Cual es el rumbo ?
|
ADS ?
|
Andres,
Desde mi punto de vista existen varias opciones puedes escoger la que mas te acomode :
opcion 1 : FWH + xHarbour + Tmysql + MySql
opcion 2 : FWH + ADO + xHabrour + Mysql ( o Sql en cualquiera de sus variantes )
mi humilde opinion
Saludos desde Managua, Nicaragua
Ramon Paredes
|
ADS ?
|
Hola,,, echale un ojo a:
<!-- m --><a class="postlink" href="http://wmormar.blogspot.com/">http://wmormar.blogspot.com/</a><!-- m -->
Salu2
|
ADS ?
|
Gracias por sus sugerencias Ramon y Willy, creo que el tiempo no pasa de valde.
Tengo la version 2.4 de Fivewin y la version de xHarbour 0.92.0 y utilizo AJMAKE version 3.00 para instegrar mis proyectos; con esto puedo iniciar o que necesito?
|
ADS con servidor
|
Consulta
Tengo que hacer otro sistema, pero requiero conectarme a otro que ya esta en funcionamiento
mi pregunta es la siguiente:
¿Se puede hacer otro diccionario de datos y conectarse a otro diccionario para modificar datos?
o hay que hacerlo en un solo diccionariode datos y agregar todas las tablas ...
saludos
Patricio
|
ADS con servidor
|
Precisamente acabo de terminar una aplicacion que hace justo eso.
Se conecta a 2 diccionarios de datos remotos por medio del AIS, lee datos de 2 tablas distintas de los 2 diccionarios y luego se conecta a un tercer diccionario en otro servidor ADS en una lan y vuelca los datos ahi.
Un Simple AdsConnect60() para cada diccionario hace la magia
|
ADS missing in latest Harbour build from Fivetech
|
Antonio,
In Harbour 3.1 build there are not ADS libs and ADS.CH.
Thanks.
|
ADS missing in latest Harbour build from Fivetech
|
up.
|
ADS missing in latest Harbour build from Fivetech
|
John,
[url:7oevoo39]http://code.google.com/p/harbour-and-xharbour-builds/downloads/detail?name=rddads.lib&can=2&q=[/url:7oevoo39]
|
ADS missing in latest Harbour build from Fivetech
|
Antonio,
Thank you very much.
For future builds of Harbour, could you please always include and also and ADS.CH?.
Thanks.
|
ADS missing in latest Harbour build from Fivetech
|
John,
There is no need to rebuikd it for each Harbour build unless there is a main change in Harbour that forces to rebuild it, like pcode change, change in RDDs architecture, change in Extend API, etc. changes that are very unprobable.
|
ADS & PHP
|
Hello,Is it possible to connect to an ADS DBFCDX database via PHP? If so, does anyone have sample code they can provide?
|
ADS & PHP
|
hey there friendi work with PHP long time and php no is compatible with dbfcdxu can use mysql or sqlitei recoment mysql is more speed and easy to use
|
ADS & PHP
|
other alterenative is u use wepwap that u make urweb with how u make progman with xharbour, in the really is a xharbour that u make a file page.exe "CGI" that make connection with dbfthanks <!-- s;) --><img src="{SMILIES_PATH}/icon_wink.gif" alt=";)" title="Wink" /><!-- s;) -->
|
ADS & PHP
|
yes<!-- m --><a class="postlink" href="http://www.renet.com.br/RenetHome/ads.aspx?content=ads_php_client_intro">http://www.renet.com.br/RenetHome/ads.a ... ient_intro</a><!-- m -->
|
ADS & PHP
|
This is a late answer, but I just read the post. Yes you can read dbf/cdx, adt/adi, and dbf/ntx with PHP + ADS. But you must be using ADS Data Dictionaries and all data access must be using SQL statements.Here are some PHP sample code working with DBF/CDX and DBF/NTXs. First how to connect to the data dictionary and appending some info to log.dbf table:[code:28t2o18e]
//sample appending records to a dbf/ntx table:
if ( !DDconnect( _DATA_DICT, $rConn ) ) die( "<br> Error connecting to Database.<br>" ) ;
$rStmt = ads_prepare( $rConn, "INSERT INTO log ( [UserId], [login_date], [ip] ) VALUES( ?, now(), ? )" );
$aParms = array( 1 => $user, 2 => $_SERVER[ 'REMOTE_HOST' ].$_SERVER[ 'REMOTE_ADDR' ] );
$rResult = ads_execute( $rStmt, $aParms );
ads_close( $rConn );
//----------------------------------------------------------------------------------------------------------------------
function DDconnect( $db, &$rConn ) {
$user = $_SESSION[ 'userid' ];
$pass = $_SESSION[ 'password' ];
$rConn = ads_connect( $db, $user, $pass, SQL_CURSOR_DYNAMIC );
return is_resource( $rConn );
}
[/code:28t2o18e]
Trying to keep it simple, below is code for updating cases.dbf/cdx table:
[code:28t2o18e]
$aParms= array( 1 => "[Save Command]:<".date("M-d-y h:m:sa").">\n".$_POST[ 'solution' ],
2 => $user,
3 => $_POST[ 'status' ] == "Open" ? FALSE :TRUE ,
4 => $case,
5 => $isTech );
$query = "UPDATE cases SET [Solution] = ?, [Solution_date] = now(),
[Tech] = ?, [Status] = ? WHERE [Case_no] = ? AND ? = TRUE" ;
$rStmt = ads_prepare( $rConn, $query );
$rResult = ads_execute( $rStmt, $aparms ) ;
[/code:28t2o18e]
Finally some code quering ticket_feedback.adt:
[code:28t2o18e]
$query = "SELECT [comments], [time_stamp], [sequence] FROM ticket_feedback ".
"WHERE Case_no = ? ORDER BY [sequence]" ;
$rStmt = ads_prepare( $rConn, $query );
$aparms = array( 1 => $_GET[ 'case' ] );
$rResult = ads_execute( $rStmt, $aparms ) ;
[/code:28t2o18e]I hope this clarifies that indeed you can use dbf-cdx/ntx/adt-adi with PHP. Might I add; IT WORKS GREAT! All this data is maintain from a fwh win32 application. The PHP web app is mostly used for quering from remote locations. It is easy, it is fast, and it is save. But, you must be using ADS data dictionaries... (also simple).Reinaldo.
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
Hello!
I want to use ADS 8 with my FWH application. According to
the documentation at <!-- m --><a class="postlink" href="http://www.fivetechsoft.com/english/fwh.html">http://www.fivetechsoft.com/english/fwh.html</a><!-- m -->
[quote:2cw3bp4y]The link where you can find all the needed DLLs is on Advantage web site , developers resources section. Once there, you will need to register yourself, then you will have access to the Advantage Solutions web site. Then go the download area and select the 5.7/2.7 release section and click to download the file arc.exe. This software includes all the needed libraries which are:
ACE23.DLL: The 32-bit Advantage Client Engine.
AXCWS32.DLL: The Advantage 32-bit communication layer for client/server access.
ADSLOC32.DLL: The 32-bit Advantage Local Server.
EXTEND.CHR: OEM collation sequences. This file is needed if OEM character sets are to be used with Advantage Local Server.
ANSI.CHR: ANSI collation sequences. This file may be needed if ANSI character sets are to be used with Advantage Local Server.
ADSLOCAL.CFG: The configuration file for Local Server.
All these files should be placed on the \WINDOWS\SYSTEM directory. In case you have a Advantage Database server then you will only need ACE32.DLL and AXCWS32.DLL
To use the Advantage RDD from your Harbour applications you just need to do the following:
Make a reference to file 'ADS.CH' on your PRG files when needed
Include in the link file the libraries [b:2cw3bp4y]rddads.lib and ace32.lib[/b:2cw3bp4y] that came with fw for Harbour package
Request the Advantage RDD at the beginning of your application[/quote:2cw3bp4y]
I need rddads.lib & ace32.lib, but there is only rddads.lib in my Harbour(MS) folder.
I found ace32.lib in aceapi.exe at <!-- m --><a class="postlink" href="http://devzone.advantagedatabase.com/">http://devzone.advantagedatabase.com/</a><!-- m -->
Is it ok to use that file?
Regards, Roman
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
Roman,
ace32.lib is just an import library (it has no code) and should be created from the ace32.dll version that you are using.
To generate such ace32.lib file you may do:
impdef.exe ace32.def ace32.dll
lib.exe /def:ace32.def /out:ace32.lib
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
Antonio
I think Roman is looking for the Microsoft MSVC lib to dll conversion .. and I don't think there is one.. your solution is from the Borland compiler and will not work if Roman is compiling with MSVC ????
Rick Lipkin
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
Hello!
I generated ace32.lib according to your instructions,
but it does not work. When I link resulting library
with my app, I receive more than 100 unresolved externals
like:
[quote:38onc72g]rddads.lib(adsfunc.obj) : error LNK2019: unresolved external symbol _AdsRollbackTransaction@4 referenced in function "void __cdecl HB_FUN_ADSROLLBACK(void)" (?HB_FUN_ADSROLLBACK@@YAXXZ)[/quote:38onc72g]
Library ace32.lib, which I found in aceapi.exe, works OK.
Regards, ROman
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
Roman,
have you used Microsoft LIB.exe or Borland TLib.exe ?
> Library ace32.lib, which I found in aceapi.exe, works OK
good! <!-- s:) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":)" title="Smile" /><!-- s:) -->
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
Hello!
I used MS LIB - how can I use Borland TLIB?
Roman
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
(message deleted)
|
ADS (Advantage Database Server) 8 and FWH (Microsoft)
|
Hello!
I noticed that Advantage uses its own Upper()/Lower() implementation
(Advantage Expression Engine), which is different than Harbour's.
Advantage takes into account 'Windows Locale" setting
<!-- m --><a class="postlink" href="http://www.cryer.co.uk/brian/windows/info_windows_locale_table.htm">http://www.cryer.co.uk/brian/windows/in ... _table.htm</a><!-- m -->
while Harbour behaves like old 16-bit Clipper. Is it possible to
change behaviour of Upper/Lower in Harbour (something like SET
CODEPAGE TO WIN1250, for example)?
Roman
|
ADS + ADI - SCOPE - DATA VAZIA
|
Alguem poderia me ajudar com ADS e ADT
Tenho um arquivo indexado desta FORMA
//-----------------------------------------------------------------------------------------
IF ! File( DIRDBF + "SLBDPLOJ"+EXT )
IF !myUSE(DIRDBF+"SLBDPLOJ" , "LOJAS" ,.T. ,3,,xRdd )
RETURN .F.
ENDIF
oText:SetText( "Indexando Arquivo " + Alias() )
oMeter2:Setpos( LastRec() * 4)
NREG := 0
index on LOJAS->PRODUTO + LOJAS->LOJA TAG SLBDPLO1
index on LOJAS->LOJA + LOJAS->PRODUTO TAG SLBDPLO2
index on (DToS( LOJAS->DT_ENTRA )) TAG SLBDPLO3
index on (DToS( LOJAS->DT_MOVIM )) TAG SLBDPLO4
ENDIF
//-----------------------------------------------------------------------------------------
e possuo um SCOPO
dbselectarea( "LOJAS" )
dbsetorder(3)
LOJAS->(ordscope(0, SPACE( 8 ) ))
LOJAS->(ordscope(1, SPACE( 8 ) ))
LOJAS->(dbgotop())
EM ADSCDX / funciona perfeitamente mostrando os registro que não possuem DATA
MAS COM ADT ELES NAO APARECEM !!!!
|
ADS + ADI - SCOPE - DATA VAZIA
|
1. Don't use the "alias" into the index
Lojas->producto is not a valid index expresion, use only the field name.
2. Set Order is not a valid command for ADT tables, you need to use the OrdSetfocus() function instead of dbsetorder().
|
ADS + ADI - SCOPE - DATA VAZIA
|
thanks Rene...
already I made the changes… but exactly thus, it continues not accepting empty date in scope using ADT
USE "LCTO" ALIAS LANC
index on TIPO+DTOS(DATA_PAG) TAG DTPAG
// TIPO = D-debit OR C-Credit
LANC->(ordsetfocus(1))
LANC->(ordscope(0, "C" + SPACE(8) ))
LANC->(ordscope(1, "C" + SPACE(8) ))
LANC->(DBGOTOP())
it makes a test with the ARC!!!
|
ADS + CDX no refresca
|
Compañeros,
Trabajo en un entorno de red local con ADS e indices CDX con un programa de gestión empresarial. Todo bien y corriendo rápido. El problema está en que observo que si el "usuario1" está introduciendo facturas, estas NO se refrescan en el listbox del "usuario2", a pesar de tener un timer con un refresh. El "usuario1" tiene que cerrar el dialog de introducir facturas y abrir el dialog del listbox, para que automáticamente al usuario2 se le refresque su listbox.
Investigando, me he dado cuenta que si abro externamente la DBF facturas en ese momento, los registros se crean pero "en blanco", y justo cuando el "usuario1" cierra el dialog de introducir facturas y abre el dialog de listbox, los campos de la DBF se cumplimentan automáticamente y al "usuario2" le aparece en su listbox.
La DBF no tiene SCOPE (filtros) activado.
¿Cómo es posible?
Mil gracias.
Un saludo.
Lorenzo
desde Cádiz, España
|
ADS + CDX no refresca
|
cuando agregues un registro
dbappend()
rlock()
....
dbunlock()
dbcommit()
dbskip( 0 ) //esto es lo que hace que se vea en las demas pcs.
saludos..
|
ADS + CDX no refresca
|
Holá, el más indicado, és que uses un DEFINE TIMER oTimer para refrescar el LISTBOX en tiempo real, desde el ACTIVATE DIALOG.
Salu2
|
ADS + CDX no refresca
|
sysctrl2, probaré tu sugerencia aunque ahora estoy fuera y no podré retomar el proyecto hasta el Lunes.
Karinha, ya tengo implantado un TIMER, de hecho, lo digo en mi post.
Lo curioso es que este sistema lo tenía implantado con indices NTX y funcionaba perfectamente y se refrescaba bien.
Gracias a todos.
LOREN.
|
ADS + CDX no refresca
|
Compañeros,
No pude contenerme y apañé provisionalmente una red local con 2 equipos... añadí al código fuente "skip( 0 )" despues de cada append, compilé y listo.
... Y la flauta sonó!!
Ahora todos los equipos se refrescan perfectamente.
Mil gracias.
LORENZO.
|
ADS + harbour
|
Olá,
Não estou conseguindo gerar a rddads.lib para harbour + bcc55, está me gerando estes erros de compilação:
[code=fw:38inrf6m]<div class="fw" id="{CB}" style="font-family: monospace;"><br />Borland <span style="color: #0000ff;">Resource</span> Compiler Version <span style="color: #000000;">5.40</span><br />Copyright <span style="color: #000000;">(</span>c<span style="color: #000000;">)</span> <span style="color: #000000;">1990</span>, <span style="color: #000000;">1999</span> Inprise Corporation. All rights reserved.<br />Turbo Incremental Link <span style="color: #000000;">5.00</span> Copyright <span style="color: #000000;">(</span>c<span style="color: #000000;">)</span> <span style="color: #000000;">1997</span>, <span style="color: #000000;">2000</span> Borland<br />Error: <span style="color: #000000;">Unresolved</span> external <span style="color: #ff0000;">'_HB_FUN_ADS'</span> <br />Error: <span style="color: #000000;">Unresolved</span> external <span style="color: #ff0000;">'_hb_adsCloseCursor'</span><br />FUNC.OBJ<br />Error: <span style="color: #000000;">Unresolved</span> external <span style="color: #ff0000;">'_hb_adsGetWorkAreaPointer'</span> <br /> </div>[/code:38inrf6m]
Alguém sabe gerar esta lib ?
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
Antonio, hasta ahora nuestras aplicaciones usaban el RDD de ADS para trabajar las DBF, creabamos una ADSCONNECT al server poniamos SET REMOTE SERVER abriamos las bases , ademas usabamos SET SERVER LOCAL para abrir las bases que la terminal usa localmente y funcionanba bien usando siempre el driver de ADS, pues ahora es como que el SET SERVER LOCAL ya no funciona si antes abrimos una conexion al server, nos arroja el siguiente error ADSCDX/5024 AE_INVALID_CONNECTION_HANDLE - Advantage does not have a connection open with the specified handle, por ende la unica solucion posible es abrir las locales haciendo VIA "DBFCDX", porque ?? , de la forma anterior siempre usabamos el mismo driver para abrir bases local como remotas al mismo tiempo que cambio en esta version ??,
Compilacion anterior driver:
Linked RDDs
===========
DBF
DBFDBT
DBFNTX
DBFCDX
ADS
Compilacion nueva:
Linked RDDs
===========
ADS
ADT
ADSCDX
ADSNTX
DBF
DBFFPT
DBFBLOB
DBFNTX
DBFCDX
Código Usado al inicio:
[code:27hhxqr9]
RDDREGISTER ( "ADS", 1 )
RDDSETDEFAULT( "ADS" )
SET FILETYPE TO CDX
cr_modo:=AdsConnect(ud)
IF cr_modo
SET SERVER REMOTE
cr_conx:="Cs"
ELSE
SET SERVER LOCAL
cr_conx:="Di"
ENDIF
[/code:27hhxqr9]
Codigo para abrir las bases locales y remotas:
[code:27hhxqr9]
//----------------------------------------------------------------------
// FUNCIONES DE RED //
//----------------------------------------------------------------------
FUNCTION abrir_dbf(base)
LOCAL ali:="GR"+c_taba(), cind:=""
IF cr_modo .AND. LEFT(UPPER(base),3)!="GRP"
SET SERVER REMOTE
ELSE
SET SERVER LOCAL
ENDIF
USE (base) ALIAS (ali) NEW SHARED
IF NETERR()
MSGALERT("ERROR BASE: "+base+" OCUPADA POR OTRO USUARIO!!","ATENCION!!")
DO WHILE .T.
USE (base) ALIAS (ali) NEW SHARED
IF NETERR()
MSGALERT("ERROR BASE: "+base+" OCUPADA POR OTRO USUARIO!!","ATENCION!!")
ELSE
EXIT
ENDIF
ENDDO
ENDIF
IF FILE(cind+base+".CDX")
SET INDEX TO (cind+base+".CDX")
ENDIF
DBSELECTAR (ali)
GO TOP
RETURN(ali)
[/code:27hhxqr9]
ALGUNA AYUDA POR FAVOR !!
GRACIAS,
SALUDOS,
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
Gustavo,
Me alegro que por lo menos ya sepamos de donde viene el problema <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
Debe haberse modificado algo en el RDD de ADS o en el propio ADS. FWH no interviene en esos procesos para nada.
Has buscado en google por ese codigo de error por si alguien mas comenta algo acerca de el ?
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
Antonio, me canse realmente, 5 días ya, el problema esta en el RDDADS.LIB de xharbour que algo a cambiado de eso estoy seguro, para no seguir perdiendo tiempo PREGUNTA, PUEDO USAR EL RDDADS.LIB de un xharbur viejoi que se que anda ?? como lo compilo para que sea compatible a la version que vino con fwh 8_12 y no tire PCODE error ???
Garcias
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
Gustavo,
Mi consejo es que revises esta pagina:
<!-- m --><a class="postlink" href="http://xharbour.cvs.sourceforge.net/viewvc/xharbour/xharbour/contrib/rdd_ads/">http://xharbour.cvs.sourceforge.net/vie ... b/rdd_ads/</a><!-- m -->
y que le comentes el problema a cualquiera de los que estan modificando el RDD de ADS, por ejemplo, a Miguel Angel Marchuet o a Luis Krause. En esa pagina estan sus emails.
Seguro que pueden darte una solucion rapida y de paso quedara solucionado para futuras versiones <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) -->
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
GRACIAS ANTONIO ESO HARE, POR AHORA VULVO TODO PARA ATRAS
SALUDOS,
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
Antonio el link que me diste, no funciona,
An Exception Has Occurred
The root "harbour" is unknown. If you believe the value is correct, then please double-check your configuration.
HTTP Response Status
404 Repository not found
saludos,
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
Gustavo,
Prueba con este enlace:
<!-- m --><a class="postlink" href="http://xharbour.cvs.sourceforge.net/xharbour/">http://xharbour.cvs.sourceforge.net/xharbour/</a><!-- m -->
Miguel Angel ha modificado el RDD de ADS hace dos meses:
2008-10-22 10:30 UTC+0100 Miguel Angel Marchuet <miguelangel@marchuet.net>
Luis Krause lo hizo hace seis meses:
2008-06-09 16:07 UTC-0800 Luis Krause Mantilla <lkrausem /*at*/ shaw /*dot*/ ca>...
<!-- m --><a class="postlink" href="http://xharbour.cvs.sourceforge.net/viewvc/xharbour/xharbour/contrib/rdd_ads/">http://xharbour.cvs.sourceforge.net/vie ... b/rdd_ads/</a><!-- m -->
Mi consejo: Antes de modificar nada, o volver atras, enviales un email y comentales el problema. Ambos hablan espanol
Quedarte en una version antigua solo te traera mas problemas con el paso del tiempo...
|
ADS - FWH_812 Y xHAR ( LOCAL REMOTO)
|
Gracias Anotnio ya pude entrar, pero no veo nada, ahora les escribiré,
Saludos,
|
ADS - Question
|
Hi Everybody,
I've seen alot of posts over the years about ADS (Advantage Database Server).
If I am correct, the ADS "Server" program allows you to have one computer (server) handle the database files / searches etc... This one is not free but the "local" server is ... so, what exactly does the "Local" server do?
Thanks in advance,
Jeff B
|
ADS - Question
|
Jeff:
If you have Advantage Database Server installed the dbfs are managed in the server (client/server architecture) as you said.
If you use Advantage Local Server client/server architecture is not supported and the dbfs are managed as usual, the utility of using Local Server is only for programing the aplication without a server or the posibility to use advantage rdd without a server. Then, if you have a server you have to do almost no changes to the application.
Regards,
[quote="Jeff Barnes":1vsmi701]Hi Everybody,
I've seen alot of posts over the years about ADS (Advantage Database Server).
If I am correct, the ADS "Server" program allows you to have one computer (server) handle the database files / searches etc... This one is not free but the "local" server is ... so, what exactly does the "Local" server do?
Thanks in advance,
Jeff B[/quote:1vsmi701]
|
ADS - Question
|
Jeff:
The ADS local server has all the features of the remote server except: Internet data access, Client/server technology and Transaccions.
The local server supports up to 5 concurrent users and it was though for development propouses only, so you can to have all the features of the remote server, but installed in a single PC when you app need to move into the real Client/Server world, you don't have make any mod into the source code, simply install the remote server, and you app will become into a powerful client/server app, even letting you to have internet access to you dbfs.
[quote="Jeff Barnes":2jvj6x2d]Hi Everybody,
I've seen alot of posts over the years about ADS (Advantage Database Server).
If I am correct, the ADS "Server" program allows you to have one computer (server) handle the database files / searches etc... This one is not free but the "local" server is ... so, what exactly does the "Local" server do?
Thanks in advance,
Jeff B[/quote:2jvj6x2d]
|
ADS - SQL ( Solucionado )
|
Estimados, para los usuarios de ADS - SQLTengo la siguiente situacion que no he podido resolverlanecesito a travez de SQL crear undices pero uno de estos tiene una funcion,al hacerlo por ARC y exportar este a codigo fuente no lo genera, lo deja en blancoejemplo[code:nt2x0x0a]la base de datos DOCU_DPR
INDICE
FOLIO
TIPDOC
FECEMI
Create Index "FOLIO" on DOCU_DPR( FOLIO_DPR );
Create Index "TIPDOC" on DOCU_DPR( TIP_DOC, NUM_DOC );
Create Index "FECEMI" on DOCU_DPR( FEC_EMI );
Lo que necesito es usar la funcion DTOS y STR
Create Index "FECEMI" on DOCU_DPR( DTOS(FEC_EMI) );
Pero no funciona, hay alguna manera de como hacer sin la necesidad de
usar el ARC
[/code:nt2x0x0a]
//Solucion
[code:nt2x0x0a]
EXECUTE PROCEDURE sp_CreateIndex(
'DOCU_DPR',
'DOCU_DPR.adi',
'FECEMI',
'DTOS(FEC_EMI)',
'',
2,
512 );
[/code:nt2x0x0a]
|
ADS - Saber si el server está activo
|
Buenas Tardes,
Estoy comenzando con ADS local.
Necesito que al iniciar mi aplicación, verifique que el servidor está "activo". ¿Como se hace?
Gracias.
Rolando <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
|
ADS - Saber si el server está activo
|
Ya lo encontré, agrego la función para quién no la conozca.
[code=fw:26d8nctb]<div class="fw" id="{CB}" style="font-family: monospace;"><span style="color: #00C800;">IF</span> !AdsConnect60<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">msginfo</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"El Server no está Activo"</span>+renglon+<span style="color: #ff0000;">"el sistema se cerrará"</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span><br /><span style="color: #00C800;">endif</span></div>[/code:26d8nctb]
Suerte
Rolando <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
|
ADS - The future is <sadly> now so where do you go ?
|
Hi Tim, This motto I will also face. I use ads with data dictionary and ADT tables. I have LINKS, FUNCTIONS, PROCEDURES in the data dictionary. Builds the tAds class to transform each connection, resources and tables into objects. Today I'm studying Mod_harbour, I've already converted my tAds class to Mod_harbour and so the remote ads system will no longer be necessary. The advantage of using ads at the moment is that I have RDD and SQL commands together, but this only with Data Dictionary. My tables have complex division schemes as they use many blobs/binarys fields. I've studied other databases, and to do what I already have in operation will be very difficult. The hope of ads is that a dis he can be open source since I read in a forum years ago this possibility. For the time being I will take some action only after the bankruptcy of ads. From the current situation that ads are in, we still have a few years before we drown.
|
ADS - The future is <sadly> now so where do you go ?
|
For many years I have used ADS as a Client Server option for my customers. It is expensive but serves them well. However the last build was in 2015.
Although they advertise it still as a product they sell, I have finally confirmed that they effectively have set it for End of Life for December of this year. I have tried to get information from them about effective options for increasing the number of seats in the future, or making it available to new clients, but they have not been responding. All they have confirmed so far is that it is slated for maintenance termination on 12/31/2022, although there have been no updates for many years.
At this point I am facing the dilemma of modifying tens of thousands of lines of code to SQL, or simply sticking with DBFCDX peer to peer ( which is not good when some clients have 10-20 workstations ). NO, a web based solution will NOT work for my clients. Most do not have sufficient internet capabilities to perform their daily work, so it must be a local server setup.
I would like to hear of solutions others may have found for client server operations, or to efficiently handle a larger number of workstations on a network without failures. I do know some might recommend remote desktop but that is also not a preferred option.
I'm looking forward to hearing from those who may also be needing to embark on a change from ADS.
Tim
|
ADS - The future is <sadly> now so where do you go ?
|
>My tables have complex division schemes as they use many blobs/binarys fields.
Hi Giovany,
can you please explain what you are doing exactly. Can't you use the file system instead?
Best regards,
Otto
|
ADS - The future is <sadly> now so where do you go ?
|
Tim
ADO and Sql ( ms sql server, ms access ) is the database mechanism I have used for over 10 years .. 32 and 64 bit are both supported and is perfectly integrated into FiveWin .. the only difference is that you have to think of ADO in terms of an Objected oriented class and methods.
Rao has simplified much of the ADO syntax with many FiveWin wrappers .. Look in the \source\functions\adofuncs.prg ..
I use Sql Server for large corporate databases and MS Access as a local solution much like dbf\cdx. Have a look at the \samples folder and compile AdoRick.prg . be glad to help you ..
Rick Lipkin
|
ADS - The future is <sadly> now so where do you go ?
|
[quote="Otto":5txokkn7]>My tables have complex division schemes as they use many blobs/binarys fields.
Hi Giovany,
can you please explain what you are doing exactly. Can't you use the file system instead?
Best regards,
Otto[/quote:5txokkn7]
Otto, I'm going to explain a case here. I have an agent table that has 320,000 names. The notary has to digitize the personal documents of each one. If I put it in just one table, this table will have a size of 60 gb. To solve the problem I had to separate the tables from 40 thousand to 40 thousand agents so that the tables were at most 10 gb.
Let's go to this table of documents of the agents I work with classes.
Class DB_AGE_DOCIMGS
[code=fw:5txokkn7]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">//Classe gerada por TAds 13/08/2018 - 13:19:59</span><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"Fivewin.ch"</span><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"TAds.ch"</span><br /><br /><span style="color: #00C800;">CLASS</span> DB_N_AGE_DOCIMGS <span style="color: #0000ff;">from</span> TAds<br /><br /> <span style="color: #00C800;">Data</span> cTableName <span style="color: #0000ff;">Init</span> <span style="color: #ff0000;">"N_AGE_DOCIMGS001"</span><br /> <span style="color: #00C800;">Data</span> nCache<br /> <span style="color: #00C800;">Data</span> lConnected <span style="color: #0000ff;">Init</span> .F.<br /><br /> <span style="color: #00C800;">Method</span> <span style="color: #00C800;">New</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">Inline</span> <span style="color: #00C800;">Self</span> Constructor <br /><br /> <span style="color: #00C800;">METHOD</span> OpenRdd<span style="color: #000000;">(</span>f_nSequencia,; <span style="color: #B900B9;">// Numero de sequencia de F_LANDES->SEQ_LANCA </span><br /> f_nConexao,; <span style="color: #B900B9;">// Numero da Conexão - Default tAds_GetConnectionDefault()</span><br /> f_nCache,; <span style="color: #B900B9;">// Numero de registros em Cache - Default nCacheAds()</span><br /> f_lExclusive,;<br /> f_lDataLoadOnSkip<span style="color: #000000;">)</span> ;<br /> Constructor <br /><br /> <span style="color: #00C800;">METHOD</span> End<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">Method</span> DB_N_AGE_DOCIMGS_TableInUse<span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">Method</span> DB_N_AGE_DOCIMGS_FilterAgenteSeqAuto<span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">Method</span> DB_N_AGE_DOCIMGS_SeekSeqAuto<span style="color: #000000;">(</span>f_nSequencia<span style="color: #000000;">)</span><br /><br /><br /><span style="color: #00C800;">ENDCLASS</span><br /><span style="color: #B900B9;">//-----------------------------------------------------------------------------</span><br /><span style="color: #00C800;">METHOD</span> OpenRdd<span style="color: #000000;">(</span>f_nSequencia,f_nConexao,f_nCache,f_lExclusive,f_lDataLoadOnSkip<span style="color: #000000;">)</span> <span style="color: #00C800;">Class</span> DB_N_AGE_DOCIMGS<br /> <span style="color: #00C800;">Local</span> lc_aStructTmp := <span style="color: #000000;">{</span><span style="color: #000000;">}</span><br /> <span style="color: #00C800;">Local</span> lc_iFor := <span style="color: #000000;">0</span>, lc_nSeqsQta := <span style="color: #000000;">42000</span>, lc_nSeqsCount := <span style="color: #000000;">1</span> <br /><br /> <span style="color: #00C800;">Default</span> f_nCache := <span style="color: #000000;">16</span><br /> <br /> <span style="color: #00C800;">if</span> f_nSequencia == <span style="color: #000000;">0</span><br /> f_nSequencia := <span style="color: #000000;">1</span><br /> <span style="color: #00C800;">EndIf</span><br /><br /> ::<span style="color: #000000;">nCache</span> := f_nCache<br /> ::<span style="color: #000000;">nTpCallRdd</span> := <span style="color: #000000;">2</span><br /> <br /> <span style="color: #00C800;">For</span> lc_iFor := <span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> <span style="color: #000000;">500</span> <span style="color: #B900B9;">// qta de arquivos binarios</span><br /> <span style="color: #00C800;">if</span> f_nSequencia >= lc_nSeqsCount ;<br /> .and. f_nSequencia <= <span style="color: #000000;">(</span>lc_nSeqsCount+lc_nSeqsQta<span style="color: #000000;">)</span><br /> ::<span style="color: #000000;">cTableName</span> := <span style="color: #ff0000;">"N_AGE_DOCIMGS"</span>+StrZero<span style="color: #000000;">(</span>lc_iFor,<span style="color: #000000;">3</span><span style="color: #000000;">)</span> <br /> exit<br /> <span style="color: #00C800;">Else</span><br /> lc_nSeqsCount += lc_nSeqsQta<br /> <span style="color: #00C800;">EndIf</span><br /> <span style="color: #00C800;">Next</span><br /><br /> <span style="color: #00C800;">IF</span> !ADSCHECKEXISTENCE<span style="color: #000000;">(</span>::<span style="color: #000000;">cTableName</span>,tAds_GetConnectionHandle<span style="color: #000000;">(</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span><br /><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"nSeqAuto"</span>,<span style="color: #ff0000;">"AutoInc"</span>,<span style="color: #000000;">2</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">1</span>,<span style="color: #ff0000;">"Sequencia de inclusao da imagem"</span>,<span style="color: #00C800;">Nil</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"nAgenteSeqAuto"</span>,<span style="color: #ff0000;">"Integer"</span>,<span style="color: #000000;">2</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">1</span>,<span style="color: #ff0000;">"Sequencia automatica de cadastro do Agente"</span>,<span style="color: #000000;">0</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"nAgenteCodigo"</span>,<span style="color: #ff0000;">"Integer"</span>,<span style="color: #000000;">2</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">1</span>,<span style="color: #ff0000;">"Codigo de ficha do Agente"</span>,<span style="color: #000000;">0</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"cNomeFuncionario"</span>,<span style="color: #ff0000;">"C"</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #ff0000;">"Nome do funcionario que digitalizou o documento"</span>,<span style="color: #00C800;">Nil</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"dImagemData"</span>,<span style="color: #ff0000;">"Date"</span>,<span style="color: #000000;">8</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">1</span>,<span style="color: #ff0000;">"Data da criacao da imagem"</span>,<span style="color: #00C800;">Nil</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"lCCN_Enviar"</span>,<span style="color: #ff0000;">"L"</span>,<span style="color: #000000;">1</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #ff0000;">"Se é para enviar a foto para o CCN"</span>,.F.<span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"nCCN_EnvioStatus"</span>,<span style="color: #ff0000;">"Short"</span>,<span style="color: #000000;">2</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #ff0000;">"0-Nunca Enviado 1-Preparado para enviar 2-Enviado por ultimo"</span>,<span style="color: #000000;">0</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"dCCN_Enviado"</span>,<span style="color: #ff0000;">"Date"</span>,<span style="color: #000000;">8</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">1</span>,<span style="color: #ff0000;">"Data do envio da Imagem"</span>,<span style="color: #00C800;">Nil</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /> aadd<span style="color: #000000;">(</span>lc_aStructTmp,<span style="color: #000000;">{</span><span style="color: #ff0000;">"bImgFileBlob"</span>,<span style="color: #ff0000;">"blob"</span>,<span style="color: #000000;">8</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #ff0000;">"Bytes do arquivo imagem"</span>,<span style="color: #00C800;">Nil</span><span style="color: #000000;">}</span><span style="color: #000000;">)</span><br /><br /> TAds_CreateTableFromCode<span style="color: #000000;">(</span> f_nConexao,::<span style="color: #000000;">cTableName</span>,;<br /> lc_aStructTmp,;<br /> <span style="color: #ff0000;">"Tabela das imagens dos documentos dos agentes"</span><span style="color: #000000;">)</span><br /> <br /><br /> <span style="color: #00C800;">EndIf</span><br /><br /> ::<span style="color: #000000;">nCache</span> := f_nCache<br /> ::<span style="color: #000000;">nTpCallRdd</span> := <span style="color: #000000;">2</span><br /> ::<span style="color: #000000;">NewRdd</span><span style="color: #000000;">(</span>::<span style="color: #000000;">cTableName</span>,f_nConexao,::<span style="color: #000000;">nCache</span>,f_lExclusive,f_lDataLoadOnSkip<span style="color: #000000;">)</span><br /> <span style="color: #00C800;">If</span> ::<span style="color: #000000;">nOpenStatus</span> == <span style="color: #000000;">0</span> <br /> ::<span style="color: #000000;">lConnected</span> := .T.<br /> <span style="color: #00C800;">EndIf</span><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">Self</span><br /><span style="color: #B900B9;">//-----------------------------------------------------------------------------</span><br /><span style="color: #00C800;">METHOD</span> End<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #00C800;">Class</span> DB_N_AGE_DOCIMGS<br /><br /> <span style="color: #00C800;">If</span> ::<span style="color: #000000;">lConnected</span><br /> ::<span style="color: #00C800;">Super</span>:<span style="color: #000000;">End</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">EndIf</span><br /><br /> <span style="color: #00C800;">Self</span> := <span style="color: #00C800;">Nil</span><br /><br /><span style="color: #00C800;">RETURN</span> <span style="color: #00C800;">Nil</span><br /><span style="color: #B900B9;">//-----------------------------------------------------------------------------</span><br /><span style="color: #00C800;">Method</span> DB_N_AGE_DOCIMGS_TableInUse<span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span> <span style="color: #00C800;">Class</span> DB_N_AGE_DOCIMGS<br /> <span style="color: #00C800;">Local</span> lc_iFor := <span style="color: #000000;">0</span>, lc_nSeqsQta := <span style="color: #000000;">42000</span>, lc_nSeqsCount := <span style="color: #000000;">1</span> <br /><br /> <span style="color: #00C800;">if</span> f_nAgenteSeqAuto == <span style="color: #000000;">0</span><br /> f_nAgenteSeqAuto := <span style="color: #000000;">1</span><br /> <span style="color: #00C800;">EndIf</span><br /><br /> <span style="color: #00C800;">For</span> lc_iFor := <span style="color: #000000;">1</span> <span style="color: #0000ff;">to</span> <span style="color: #000000;">500</span> <span style="color: #B900B9;">// qta de arquivos binarios</span><br /> <span style="color: #00C800;">if</span> f_nAgenteSeqAuto >= lc_nSeqsCount ;<br /> .and. f_nAgenteSeqAuto <= <span style="color: #000000;">(</span>lc_nSeqsCount+lc_nSeqsQta<span style="color: #000000;">)</span><br /> ::<span style="color: #000000;">cTableName</span> := <span style="color: #ff0000;">"N_AGE_DOCIMGS"</span>+StrZero<span style="color: #000000;">(</span>lc_iFor,<span style="color: #000000;">3</span><span style="color: #000000;">)</span> <br /> exit<br /> <span style="color: #00C800;">Else</span><br /> lc_nSeqsCount += lc_nSeqsQta<br /> <span style="color: #00C800;">EndIf</span><br /> <span style="color: #00C800;">Next</span><br /><br /> <span style="color: #00C800;">If</span> ADSCHECKEXISTENCE<span style="color: #000000;">(</span>::<span style="color: #000000;">cTableName</span>,tAds_GetConnectionHandle<span style="color: #000000;">(</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span><br /> ::<span style="color: #000000;">cTableName</span> := <span style="color: #ff0000;">"N_AGE_DOCIMGS"</span>+StrZero<span style="color: #000000;">(</span><span style="color: #000000;">1</span>,<span style="color: #000000;">3</span><span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">EndIf</span><br /><br /><span style="color: #00C800;">Return</span> ::<span style="color: #000000;">cTableName</span><br /><span style="color: #B900B9;">//-----------------------------------------------------------------------------</span><br /><span style="color: #00C800;">Method</span> DB_N_AGE_DOCIMGS_FilterAgenteSeqAuto<span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span> <span style="color: #00C800;">Class</span> DB_N_AGE_DOCIMGS<br /> <br /> ::<span style="color: #000000;">SetOrder</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"nSeqAuto"</span><span style="color: #000000;">)</span><br /> <br /> ::<span style="color: #000000;">Filter</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"nAgenteSeqAuto == "</span>+m_Str<span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span> ::<span style="color: #000000;">KeyCount</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /><span style="color: #B900B9;">//-----------------------------------------------------------------------------</span><br /><span style="color: #00C800;">Method</span> DB_N_AGE_DOCIMGS_SeekSeqAuto<span style="color: #000000;">(</span>f_nSequencia<span style="color: #000000;">)</span> <span style="color: #00C800;">Class</span> DB_N_AGE_DOCIMGS<br /> <span style="color: #00C800;">Local</span> lc_lFound := .F.<br /><br /> lc_lFound := ::<span style="color: #000000;">Seek</span><span style="color: #000000;">(</span>f_nSequencia,<span style="color: #ff0000;">"nSeqAuto"</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Return</span> lc_lFound<br /> </div>[/code:5txokkn7]
Now in practice I use it like this:
[code=fw:5txokkn7]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00C800;">Method</span> N_AgentesCadPf_DocImgs_Gravar<span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span> <span style="color: #00C800;">Class</span> N_AgentesCadPf_DocImgs<br /> <span style="color: #00C800;">Local</span> lc_oDbTmp_AgenteDocImgs<br /> <span style="color: #00C800;">Local</span> lc_lAppend := .F.<br /><br /> lc_oDbTmp_AgenteDocImgs := DB_N_AGE_DOCIMGS<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">OpenRdd</span><span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span><br /> lc_oDbTmp_AgenteDocImgs:<span style="color: #000000;">DB_N_AGE_DOCIMGS_FilterAgenteSeqAuto</span><span style="color: #000000;">(</span>f_nAgenteSeqAuto<span style="color: #000000;">)</span><br /><br />bla bla bla<br /> </div>[/code:5txokkn7]
In SQL commands:
[code=fw:5txokkn7]<div class="fw" id="{CB}" style="font-family: monospace;"><br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span> := tAds<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">DsNew</span><span style="color: #000000;">(</span><span style="color: #000000;">1</span><span style="color: #B900B9;">/*Select*/</span>, <span style="color: #000000;">1</span><span style="color: #000000;">)</span><br /> <span style="color: #0000ff;">Text</span> Into ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">cQrySql</span> <br /> <span style="color: #0000ff;">Select</span> <span style="color: #000000;">{</span><span style="color: #00C800;">static</span><span style="color: #000000;">}</span> <br /> Tb01.* ,<br /> Tb02.* <br /> <span style="color: #0000ff;">from</span> N_AGENTES As Tb01<br /> Inner <span style="color: #0000ff;">Join</span> _!DataBaseAgentesImgs_ AS Tb02 <span style="color: #0000ff;">ON</span> Tb02.nAgenteCodigo = Tb01.nCodigoAgente<br /> __WHERE__ __ORDER_BY__ ;<br /> EndText<br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">nCacheDefault</span> := <span style="color: #000000;">100</span> <span style="color: #B900B9;">//Page</span><br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">lDataLoadOnSkip</span> := .T. <br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">lDataLoadBinaryField</span> := .F. <br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">lDsCursorsToTemp</span> := .F.<br /> <span style="color: #0000ff;">Text</span> Into ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">cDsWhere</span> <br /> <span style="color: #0000ff;">Where</span> Tb01.nCodigoAgente = _nAgenteCodigo_ <br /> EndText<br /> <span style="color: #0000ff;">Text</span> Into ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">cDsOrderBy</span> <br /> <span style="color: #0000ff;">Order By</span> Tb02.dImagemData <br /> EndText<br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">DsAddVar</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"_!DataBaseAgentesImgs_"</span>,DB_N_AGE_DOCIMGS<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">DB_N_AGE_DOCIMGS_TableInUse</span><span style="color: #000000;">(</span>f_nCodigoAgente<span style="color: #000000;">)</span><span style="color: #000000;">)</span><br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">DsAddVar</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"_nAgenteCodigo_"</span>,f_nCodigoAgente<span style="color: #000000;">)</span><br /> ::<span style="color: #000000;">oDs_AgenteDocsImgs</span>:<span style="color: #000000;">DsExecute</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /><br /> </div>[/code:5txokkn7]
|
ADS - The future is <sadly> now so where do you go ?
|
Tim:
I support the rick advise, Here you can found much support
Regrads
|
ADS - The future is <sadly> now so where do you go ?
|
Hello Giovany,
> aadd(lc_aStructTmp,{"bImgFileBlob","blob",8,0,0,"Bytes do arquivo imagem",Nil})
I mean can't you use a file for each record instead of the blob field?
I used to have that problem too.
But it seems now that you can store as many files as you want in a directory.
Before (WINDOWS 2000!!! server), it was about 20000.
I do it this way with my document management.
[b:1o0nndkt]My view - very personal[/b:1o0nndkt]
I think the file system is better than any database.
And now with mod harbour, if you have all the data on the same hard drive, you have all the possibilities.
And with the GOP you can handle the rights very well.
I have just started to develop an appointment management system for us in the company.
It is file based - no database!
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=41516&p=249036&hilit=time&sid=b1726e0c17bc7432904f164ad2b0b6d3#p249036">viewtopic.php?f=3&t=41516&p=249036&hilit=time&sid=b1726e0c17bc7432904f164ad2b0b6d3#p249036</a><!-- l -->
If you're interested, I'll send you the download link.
Best regards,
Otto
|
ADS - The future is <sadly> now so where do you go ?
|
[quote="Otto":1a9iwpb0]
> aadd(lc_aStructTmp,{"bImgFileBlob","blob",8,0,0,"Bytes do arquivo imagem",Nil})
I mean can't you use a file for each record instead of the blob field?
[/quote:1a9iwpb0]
In the agent register from code 1 to 42000 the table with the images is N_AGE_DOCIMGS001, after 42001 to 84000 the table is N_AGE_DOCIMGS002 and so on.
Scanned documents, images, pdfs, biometric templates, digital certificates and other things are in the tables because the server does not have active sharing of folders. Nobody accesses the server, only the program using ads server. And some employees work on their laptops outside the company, in their homes. It would be difficult for them to access a pdf document and digitally sign it by recording in folders. Now with mod_harbour this type of resource would no longer be necessary, however there is still a lot to be done on the web. The program has many modules.
Let's stay optimistic thanks to mod_harbour.
|
ADS - The future is <sadly> now so where do you go ?
|
Hello Giovany,
I understand. And yes.
[quote:2z4f4d8z]
Scanned documents, images, pdfs, biometric templates, digital certificates and other things are in the tables because the server does not have active sharing of folders.
Nobody accesses the server, only the program using ads server. And some employees work on their laptops outside the company, in their homes.
It would be difficult for them to access a pdf document and digitally sign it by recording in folders. Now with mod_harbour this type of resource would no longer be necessary,[/quote:2z4f4d8z]
That's why I'm lucky that I switched my clients to RDP a long time ago.
Now it makes it much easier for me.
Best regards,
Otto
Full text search with mod harbour
[img:2z4f4d8z]https://mybergland.com/fwforum/ftsmod.jpg[/img:2z4f4d8z]
Here is a screenshot of my DMS on the web with mod harbour.
[img:2z4f4d8z]https://mybergland.com/fwforum/dmsmod.jpg[/img:2z4f4d8z]
|
ADS - The future is <sadly> now so where do you go ?
|
RDP for me does not work. The terminals have A3 digital certificates (card), scanners, WebCams and biometric readers. Getting this to work in RDP is not easy.
|
ADS - The future is <sadly> now so where do you go ?
|
Hello Giovany,
We need smartcards to sign the invoices. We also have many connections such as dispensing systems, telephone systems, etc.
We use USB2NET and COM2NET adapters.
It works well.
Best regards,
Otto
|
ADS - The future is <sadly> now so where do you go ?
|
Giovanni,
Right now I have ongoing, daily, contact with SAP ( the owners of ADS ). This is not bankruptcy. They took away resources for further development apparently in 2015 ( the last release of ADS 12 ). Now they have used a funny term, but it is End of Life for 12/31/2022.
I have asked directly if they will release it to public domain, or give us access to update existing keys for more seats ( at no charge ). The problem is they can't even seem to find anyone in the company (SAP) who handles responsibility for this product even though their website says it is still available for sale. If you fill out a form as if you are a new client, no one will even respond, even though the form is still online.
It was my intention to convert to SQL and FWH has ample assistance, and samples, for doing this. My whole program is object oriented and perhaps once I start working with it, I will have success and move quickly through the process. I did use the FWH functions to actually convert my existing data files ( about 130 ) into a MySQL database, and that will be very helpful because the process is so simple. Now it is a matter of moving forward on implementing it within this massive application.
I am using FWH, Harbour, and MSVC ( Visual Studio Community 2022, and the latest builds of FWH and Harbour ). I am also fully focused on doing this in 64 bit ( and my application is fully running now as both 32 bit and 64 bit ) and all 3rd party libraries are updated.
So I will see how it goes. However, I can wait no longer to this conversion because we have no idea what will happen with ADS ... and it might even have some built in code that is date sensitive and it will stop working.
Tim
|
ADS - The future is <sadly> now so where do you go ?
|
hi Tim,
Alaska have made PgDBE using PostgreSQL
PgDBE does have ISAM "Emulation" so you "only" change DBE ( = RDD)
that is what Advertising say ... <!-- s:roll: --><img src="{SMILIES_PATH}/icon_rolleyes.gif" alt=":roll:" title="Rolling Eyes" /><!-- s:roll: -->
---
even when change from NTX to CDX it was a lot of Work.
ADO seem a Solution as ActiveX "Layer" to Backend and it is OOP
but as long your ADS Server work there is no need to change a "running System" ...
p.s. Mod_harbour also can use ADS
|
ADS - The future is <sadly> now so where do you go ?
|
Gentleman ... for those who want to see what ADO is like ... here is the adorick.prg ... notice also .. incorporated into the program is a integrated xbrowse incremental search using filters ( very fast ) .. also as you can see you can use plain old ansi Sql .. see how I create a new .mdb from scratch using code ..
Code ....
[code=fw:2espkrjk]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">// Incremental Search</span><br /><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"FiveWin.ch"</span><br /><span style="color: #00D7D7;">#Include</span> <span style="color: #ff0000;">"Xbrowse.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"dtpicker.ch"</span><br /><br /><br /><span style="color: #00C800;">STATIC</span> oWnd,oBar,lOK,lOk1,oWndChild,oLbx<br /><span style="color: #00C800;">STATIC</span> cLname,oLname,oFname,cFname,oFontB<br /><br /><span style="color: #00C800;">Static</span> dDatePur,oDatePur<br /><span style="color: #B900B9;">//-------------</span><br />Func Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><span style="color: #00C800;">Local</span> catNewDB,cFile,aDir,dExe,cDefa,mStart<br /><span style="color: #00C800;">Local</span> oCn,cSql,oErr,oRsCust,cLOGIN,Saying,xLogin,cRights<br /><span style="color: #00C800;">Local</span> cTitle,oButt1,oButt2,nYear,nScr1,nScr2,xMessage,cRdd<br /><br /><span style="color: #00C800;">PUBLIC</span> xCONNECT,xSource,xProvider<br /><br />lOK := .F.<br /><br /><br /><span style="color: #B900B9;">//-- get timestamp on .exe //</span><br /><br />cFILE := GetModuleFileName<span style="color: #000000;">(</span> GetInstance<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br />aDIR := DIRECTORY<span style="color: #000000;">(</span> cFILE <span style="color: #000000;">)</span><br />dEXE := aDIR<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span> <span style="color: #000000;">[</span><span style="color: #000000;">3</span><span style="color: #000000;">]</span><br /><br /><span style="color: #B900B9;">// where .exe started from is default directory //</span><br /><br />mSTART := RAT<span style="color: #000000;">(</span> <span style="color: #ff0000;">"<span style="color: #000000;">\"</span>, cFILE )<br />cDEFA := SUBSTR(cFILE,1,mSTART-1)<br /><br />aDIR := NIL<br />SET DEFA to ( cDEFA )<br /><br />SET DELETED on<br />SET CENTURY on<br />SET 3DLOOK on<br /><br />nYEAR := ( year( DATE() )-30 )<br />SET EPOCH to ( nYEAR )<br /><br />REQUEST DBFCDX<br />rddsetdefault ( "</span>DBFCDX<span style="color: #ff0000;">" )<br /><br />nSCR1 := GetSysMetrics(0)<br />nSCR2 := GetSysMetrics(1)<br /><br />xPROVIDER := "</span>Microsoft.Jet.OLEDB<span style="color: #000000;">.4</span><span style="color: #000000;">.0</span><span style="color: #ff0000;">"<br />xSOURCE := cDEFA+"</span>\Rick.mdb<span style="color: #ff0000;">"<br />cRDD := xPROVIDER+"</span> -- <span style="color: #ff0000;">"+xSOURCE<br /><br /> // global connection string<br />xCONNECT := 'Provider='+xPROVIDER+';Data Source='+xSOURCE<br /><br />If .not. File( cDefa+"</span>\Rick.mdb<span style="color: #ff0000;">" )<br /><br /> Ferase( cDefa+"</span>\Rick.mdb<span style="color: #ff0000;">" )<br /><br /> // create the adox object<br /> Try<br /> catNewDB := CreateObject("</span>ADOX.Catalog<span style="color: #ff0000;">")<br /> Catch<br /> MsgInfo( "</span>Could not Create ADOX object<span style="color: #ff0000;">")<br /> Return(.f.)<br /> End try<br /><br /> // create the table Rick.mdb<br /> Try<br /> catNewDB:Create('Provider='+xProvider+';Data Source='+xSource+';Jet OLEDB:Engine Type=5' )<br /> Catch<br /> MsgInfo( "</span>Could not create the table <span style="color: #ff0000;">"+xSource )<br /> Return(.f.)<br /> End Try<br /><br /> Try<br /> oCn := CREATEOBJECT( "</span>ADODB.Connection<span style="color: #ff0000;">" )<br /> Catch<br /> MsgInfo( "</span>Could not create the ADO object <span style="color: #00C800;">for</span> connection<span style="color: #ff0000;">")<br /> End Try<br /><br /> TRY<br /> oCn:Open( xCONNECT )<br /> CATCH oErr<br /> MsgInfo( "</span>Could not open a Connection <span style="color: #0000ff;">to</span> Database <span style="color: #ff0000;">"+xSource )<br /> RETURN(.F.)<br /> END TRY<br /><br /><br /> cSQL := "</span>CREATE TABLE CUSTOMER<span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">(</span> <span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">[</span>CUSTOMEREID<span style="color: #000000;">]</span> char<span style="color: #000000;">(</span><span style="color: #000000;">18</span><span style="color: #000000;">)</span> NOT <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">[</span>LAST <span style="color: #0000ff;">NAME</span><span style="color: #000000;">]</span> char<span style="color: #000000;">(</span><span style="color: #000000;">30</span><span style="color: #000000;">)</span> <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">[</span>FIRST <span style="color: #0000ff;">NAME</span><span style="color: #000000;">]</span> char<span style="color: #000000;">(</span><span style="color: #000000;">30</span><span style="color: #000000;">)</span> <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">[</span>MID <span style="color: #0000ff;">INIT</span><span style="color: #000000;">]</span> char<span style="color: #000000;">(</span><span style="color: #000000;">30</span><span style="color: #000000;">)</span> <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">[</span>ADDRESS1<span style="color: #000000;">]</span> char<span style="color: #000000;">(</span><span style="color: #000000;">30</span><span style="color: #000000;">)</span> <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">[</span>CITY<span style="color: #000000;">]</span> char<span style="color: #000000;">(</span><span style="color: #000000;">30</span><span style="color: #000000;">)</span> <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSQL += "</span><span style="color: #000000;">[</span>STATE<span style="color: #000000;">]</span> char<span style="color: #000000;">(</span><span style="color: #000000;">30</span><span style="color: #000000;">)</span> <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSql += "</span><span style="color: #000000;">[</span>MEMO<span style="color: #000000;">]</span> LONGBINARY <span style="color: #00C800;">NULL</span>,<span style="color: #ff0000;">"<br /> cSql += "</span><span style="color: #000000;">[</span>DATEPUR<span style="color: #000000;">]</span> DateTime <span style="color: #00C800;">NULL</span>, <span style="color: #ff0000;">"<br /> cSQL += "</span>CONSTRAINT PK_USERINFO PRIMARY KEY <span style="color: #000000;">(</span> CUSTOMEREID <span style="color: #000000;">)</span><span style="color: #ff0000;">"<br /> cSQL += "</span> <span style="color: #000000;">)</span><span style="color: #ff0000;">"<br /><br /> Try<br /> oCn:Execute( cSQL )<br /> Catch<br /> MsgInfo( "</span>Table CUSTOMER Failed<span style="color: #ff0000;">" )<br /> Return(.f.)<br /> End try<br /><br /> oCn:Close()<br /> oCn := nil<br /><br />Endif<br /><br />xLOGIN := UPPER( WNetGetuser() )+space(8) // fivewin<br />xLOGIN := SUBSTR(xLOGIN,1,8)<br /><br />oRsCust := TOleAuto():New( "</span>ADODB.Recordset<span style="color: #ff0000;">" )<br />oRsCust:CursorType := 1 // opendkeyset<br />oRsCust:CursorLocation := 3 // local cache<br />oRsCust:LockType := 3 // lockoportunistic<br /><br />// check for very first user<br /><br />cSQL := "</span><span style="color: #0000ff;">SELECT</span> * <span style="color: #0000ff;">FROM</span> CUSTOMER<span style="color: #ff0000;">"<br />TRY<br /> oRsCust:Open( cSQL, xCONNECT )<br />CATCH oErr<br /> MsgInfo( "</span>Error in Opening CUSTOMER table here<span style="color: #ff0000;">" )<br /> RETURN(.F.)<br />END TRY<br /><br />If oRsCust:eof<br /><br /> oRsCust:AddNew()<br /> oRsCust:Fields("</span>CustomerEid<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">011111111111111111</span><span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Last <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Lipkin<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>First <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Richard<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Mid <span style="color: #0000ff;">Init</span><span style="color: #ff0000;">"):Value := "</span>M<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Address1<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">123</span> Anywhere<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>City<span style="color: #ff0000;">"):Value := "</span>Columbia<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>State<span style="color: #ff0000;">"):Value := "</span>SC<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>DatePur<span style="color: #ff0000;">"):Value := Date()<br /> oRsCust:Update()<br /><br /> oRsCust:AddNew()<br /> oRsCust:Fields("</span>CustomerEid<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">011111111111111112</span><span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Last <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Lipinsky<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>First <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Jason<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Mid <span style="color: #0000ff;">Init</span><span style="color: #ff0000;">"):Value := "</span>S<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Address1<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">123</span> Arborgate<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>City<span style="color: #ff0000;">"):Value := "</span>Columbia<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>State<span style="color: #ff0000;">"):Value := "</span>SC<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>DatePur<span style="color: #ff0000;">"):Value := Date()<br /> oRsCust:Update()<br /><br /> oRsCust:AddNew()<br /> oRsCust:Fields("</span>CustomerEid<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">011111111111111113</span><span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Last <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Lipkin<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>First <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Beth<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Mid <span style="color: #0000ff;">Init</span><span style="color: #ff0000;">"):Value := "</span> <span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Address1<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">123</span> Lake Murray Blvd<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>City<span style="color: #ff0000;">"):Value := "</span>Lexington<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>State<span style="color: #ff0000;">"):Value := "</span>SC<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>DatePur<span style="color: #ff0000;">"):Value := Date()<br /> oRsCust:Update()<br /><br /> oRsCust:AddNew()<br /> oRsCust:Fields("</span>CustomerEid<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">011111111111111114</span><span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Last <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Lizzarous<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>First <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value := "</span>Tim<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Mid <span style="color: #0000ff;">Init</span><span style="color: #ff0000;">"):Value := "</span>J<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>Address1<span style="color: #ff0000;">"):Value := "</span><span style="color: #000000;">456</span> Broad River<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>City<span style="color: #ff0000;">"):Value := "</span>Irmo<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>State<span style="color: #ff0000;">"):Value := "</span>SC<span style="color: #ff0000;">"<br /> oRsCust:Fields("</span>DatePur<span style="color: #ff0000;">"):Value := Date()<br /> oRsCust:Update()<br /><br /><br />Endif<br /><br />oFontB := TFont():New("</span>Ms Sans Serif<span style="color: #ff0000;">",,-6,.F.,.T. ,,,,.F. )<br />cRIGHTS := "</span><span style="color: #000000;">(</span>RWS<span style="color: #000000;">)</span><span style="color: #ff0000;">"<br /><br />xMESSAGE := "</span>User <span style="color: #ff0000;">"+xLOGIN+"</span> Rights <span style="color: #ff0000;">"+cRIGHTS+ ;<br /> "</span> <span style="color: #00C800;">Default</span>= <span style="color: #ff0000;">"+cDEFA+"</span> Rdd= <span style="color: #ff0000;">"+cRDD+ ;<br /> "</span> Revision <span style="color: #ff0000;">"+DTOC(dEXE)+;<br /> "</span> -r<span style="color: #ff0000;">"+str(nSCR1,4)+"</span> x <span style="color: #ff0000;">"+STR(nSCR2,4)<br /><br />cTitle := "</span>Test Incremental Search with <span style="color: #0000ff;">ON</span> <span style="color: #0000ff;">CHANGE</span><span style="color: #ff0000;">"<br /><br />DEFINE WINDOW oWnd ;<br /> TITLE cTITLE ;<br /> MENU _BuildMenu();<br /> MDI<br /><br />DEFINE BUTTONBAR oBar OF oWnd SIZE 65,70 3DLOOK 2007<br />oBar:SetColor(0)<br /><br />DEFINE BUTTON oButt1 OF oBar ;<br />MESSAGE "</span>Customer Information<span style="color: #ff0000;">" ;<br />ACTION _Custview( "</span>A<span style="color: #ff0000;">",oWnd,oButt1,oButt2 ) ;<br />PROMPT "</span>Customer Info<span style="color: #ff0000;">"<br /><br /><br />DEFINE BUTTON oButt2 OF oBar ;<br />MESSAGE "</span>Close Application<span style="color: #ff0000;">" ;<br />ACTION ( oWnd:End() ) ;<br />PROMPT "</span>Quit<span style="color: #ff0000;">"<br /><br /><br />SET MESSAGE OF oWnd ;<br /> to xMESSAGE CLOCK 2007<br /><br />ACTIVATE WINDOW oWnd MAXIMIZED ;<br />VALID ( IIF( !lOK, _ExitPgm(.T.), .F. ))<br /><br />RETURN( NIL )<br /><br />//---------------------------<br />Static FUNCTION _BuildMenu()<br /><br />LOCAL oMENU, cDEFA<br /><br />cDEFA := SET(7)<br /><br /><br />MENU oMenu 2007<br /><br /> menuitem "</span>Login...<span style="color: #ff0000;">" ;<br /><br /> MENUITEM "</span>&About...<span style="color: #ff0000;">"<br /><br /> MENUITEM "</span>&Quit<span style="color: #ff0000;">" ;<br /> MESSAGE "</span>Close this program<span style="color: #ff0000;">";<br /> ACTION oWND:END()<br /><br />ENDMENU<br /><br />RETURN( oMenu )<br /><br /><br />//-----------------------<br />Static FUNCTION _ExitPgm( lCLEAN )<br /><br />LOCAL lOK3<br /><br />lOK3 := .F.<br /><br />IF lCLEAN = .T.<br /> lOK3 := .T.<br /> lOK := .T.<br /> SET RESOURCES to<br /><br />ENDIF<br /><br />RETURN( lOK3 )<br /><br />//-------------------------------<br />Static FUNC _Custview( cMODE,oWnd,oBtn1,oBtn2 )<br /><br /><br />LOCAL SAYING,cDEFA<br />LOCAL cTITLE<br />LOCAL oIco,oFld,oCust<br />LOCAL oRsCust,cSql<br /><br />lOK1 := .F.<br /><br />cSQL := "</span><span style="color: #0000ff;">SELECT</span> * <span style="color: #0000ff;">from</span> CUSTOMER <span style="color: #0000ff;">order by</span> <span style="color: #000000;">[</span>Last <span style="color: #0000ff;">Name</span><span style="color: #000000;">]</span><span style="color: #ff0000;">"<br /><br />oRsCust := TOleAuto():New( "</span>ADODB.Recordset<span style="color: #ff0000;">" )<br />oRsCust:CursorType := 1 // opendkeyset<br />oRsCust:CursorLocation := 3 // local cache<br />oRsCust:LockType := 3 // lockoportunistic<br /><br />TRY<br /> oRsCust:Open( cSQL,xCONNECT )<br />CATCH oErr<br /> MsgInfo( "</span>Error in Opening CUSTOMER table<span style="color: #ff0000;">" )<br /> RETURN(.F.)<br />END TRY<br /><br />SysReFresh()<br /><br />cTITLE := "</span>Customer Maintenance<span style="color: #ff0000;">"<br /><br />DO CASE<br />CASE cMODE = "</span>E<span style="color: #ff0000;">"<br /> cTITLE := "</span>Customer Maintenance <span style="color: #00C800;">EDIT</span><span style="color: #ff0000;">"<br />CASE cMODE = "</span>A<span style="color: #ff0000;">"<br /> cTITLE := "</span>Customer Maintenance ADD<span style="color: #ff0000;">"<br />CASE cMODE = "</span>V<span style="color: #ff0000;">"<br /> cTITLE := "</span>Customer Maintenance VIEW<span style="color: #ff0000;">"<br />ENDCASE<br /><br />oBtn1:Disable()<br />oBtn2:Disable()<br /><br /><br />DEFINE WINDOW oWndChild ;<br /> MDICHILD ;<br /> FROM 0,0 to 32,100 ;<br /> OF oWnd ;<br /> TITLE cTITLE<br /><br />DEFINE DIALOG oCust RESOURCE "</span>CUSTOMER<span style="color: #ff0000;">" of oWndChild<br /><br /><br /> REDEFINE FOLDEREX oFld ID 109 of oCust PROMPT "</span>Billing Information<span style="color: #ff0000;">", "</span>Service Address<span style="color: #ff0000;">";<br /> DIALOGS "</span>CUSTVIEW<span style="color: #ff0000;">", "</span>SERVVIEW<span style="color: #ff0000;">"<br /><br /> _Folder_1( cMode, oWnd, oRsCust, oFld ) // Custview folder<br /><br /><br />ACTIVATE DIALOG oCust NOWAIT ;<br /> ON INIT ( oCust:Move( 0, 0 ));<br /> VALID(!GETKEYSTATE( 27 ))<br /><br /><br />ACTIVATE WINDOW oWndChild ;<br /> ON INIT oWndChild:SetSize( oCust:nWidth, oCust:nHeight, .T. );<br /> VALID ( IIF( !lOK1, _ExitPgm1(.T.,oWndChild,oRsCust,oBtn1,oBtn2), .F. ))<br /><br /><br />RETURN( NIL )<br /><br />// ---------- FOLDER-PAGE 1<br />Static FUNC _Folder_1( cMode, oWnd, oRsCust, oFld )<br /><br />Local oSay1,oSay2,oSay3,oSay4,oSay5<br /><br />cLname := space(50)<br />cFname := space(50)<br /><br />dDatePur := if(empty(oRsCust:Fields("</span>datePur<span style="color: #ff0000;">"):Value), Date(),;<br /> _TtoDate(oRsCust:Fields("</span>datePur<span style="color: #ff0000;">"):Value ))<br /><br />*msginfo( dDatePur )<br /><br />REDEFINE SAY oSay1 PROMPT "</span>Customer Type<span style="color: #ff0000;">" ID 110 OF oFld:aDialogs[1] UPDATE<br />oSay1:SetFont( oFontB )<br /><br />REDEFINE SAY oSay2 PROMPT "</span>Customer <span style="color: #0000ff;">Id</span><span style="color: #ff0000;">" ID 111 OF oFld:aDialogs[1] UPDATE<br />oSay2:SetFont( oFontB )<br /><br />REDEFINE SAY oSay3 PROMPT "</span>Company or Last <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">" ID 112 OF oFld:aDialogs[1] UPDATE<br />oSay3:SetFont( oFontB )<br /><br />REDEFINE SAY oSay4 PROMPT "</span>First <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">" ID 113 OF oFld:aDialogs[1] UPDATE<br />oSay4:SetFont( oFontB )<br /><br />REDEFINE SAY oSay5 PROMPT "</span>Date Purchased<span style="color: #ff0000;">" ID 163 OF oFld:aDialogs[1] UPDATE<br />oSay4:SetFont( oFontB )<br /><br /><br />REDEFINE GET oLname var cLname ID 153 of oFld:aDialogs[1] ;<br /> ON CHANGE ( _Isearch( oLname, cLname, oLbx, oRsCust )) UPDATE<br /><br />REDEFINE GET oFname var cFname ID 154 of oFld:aDialogs[1] UPDATE<br /><br />REDEFINE DTPICKER oDatePur VAR dDatePur ID 164 OF oFld:aDialogs[1] UPDATE //PICTURE '@D' UPDATE // ;<br /> * When cMode <> "</span>V<span style="color: #ff0000;">" UPDATE<br /><br /><br />REDEFINE xBROWSE oLBX ;<br /> RECORDSET oRsCust ;<br /> COLUMNS "</span>CUSTOMEREID<span style="color: #ff0000;">" ;<br /> COLSIZES 50 ;<br /> HEADERS "</span>Cust <span style="color: #0000ff;">Id</span><span style="color: #ff0000;">" ;<br /> ID 172 of oFld:aDialogs[1] ;<br /> AUTOCOLS LINES<br /><br /> ADD oCol TO oLbx AT 1 DATA {|x| x := _ChkName(oRsCust:Fields("</span>Last <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value,;<br /> oRsCust:Fields("</span>First <span style="color: #0000ff;">Name</span><span style="color: #ff0000;">"):Value,;<br /> oRsCust:Fields("</span>Mid <span style="color: #0000ff;">Init</span><span style="color: #ff0000;">"):Value) };<br /> HEADER "</span>Last <span style="color: #0000ff;">Name</span> or Company<span style="color: #ff0000;">" size 190<br /><br /><br /> ADD oCol TO oLbx AT 2 DATA {|x| x := _ChkAdd(oRsCust:Fields("</span>Address1<span style="color: #ff0000;">"):Value,;<br /> oRsCust:Fields("</span>City<span style="color: #ff0000;">"):Value,;<br /> oRsCust:Fields("</span>State<span style="color: #ff0000;">"):Value) };<br /> HEADER "</span>Address<span style="color: #ff0000;">" size 200<br /><br /><br />RETURN( nil )<br /><br />//--------------------------<br />Static Function _TtoDate( tDate )<br /><br />If empty( tDate)<br /> Return( ctod("</span><span style="color: #000000;">00</span>/<span style="color: #000000;">00</span>/<span style="color: #000000;">00</span><span style="color: #ff0000;">"))<br />Endif<br /><br />If ValType( tDate ) = "</span>D<span style="color: #ff0000;">"<br /> Return(tDate )<br />Endif<br /><br />Return( stod( substr( ttos( tDate ), 1, 8 ) ))<br /><br /><br />//----------------------------<br />Static Func _ChkName( cLast,cFirst,cMiddle )<br /><br />Local cName<br /><br />cName := substr("</span>Unk<span style="color: #ff0000;">"+space(45),1,45)<br /><br />If cMiddle = "</span> <span style="color: #ff0000;">"<br /> If cFirst = "</span> <span style="color: #ff0000;">" .or. empty( cFirst )<br /> cName = substr( alltrim( cLast)+space(45),1,45)<br /> Else<br /> cName := substr(alltrim(cLast)+"</span>, <span style="color: #ff0000;">"+alltrim(cFirst)+space(45),1,45)<br /> Endif<br />Else<br /> If cFirst = "</span> <span style="color: #ff0000;">" .or. empty( cFirst )<br /> cName = substr( alltrim( cLast)+space(45),1,45)<br /> Else<br /> cName := substr(alltrim(cLast)+"</span>, <span style="color: #ff0000;">"+alltrim(cFirst)+"</span> <span style="color: #ff0000;">"+;<br /> alltrim(cMiddle)+space(45),1,45)<br /> Endif<br />Endif<br /><br />Return( cName )<br /><br /><br />//-------------------------------<br />Static Func _ChkAdd( cAddress, cCity, cState )<br /><br />LOCAL cName<br /><br />cName := if( cAddress = "</span> <span style="color: #ff0000;">" .or. empty( cAddress ), "</span> <span style="color: #ff0000;">", alltrim( cAddress ))+"</span> <span style="color: #ff0000;">"+;<br /> if( cCity = "</span> <span style="color: #ff0000;">" .or. empty( cCity), "</span> <span style="color: #ff0000;">", alltrim(cCity))+"</span> <span style="color: #ff0000;">"+;<br /> if( cState = "</span> <span style="color: #ff0000;">" .or. empty( cState), "</span> <span style="color: #ff0000;">", alltrim(cState))<br /><br />cName := substr( alltrim( cName ) +space(45),1,45)<br /><br />Return( cName )<br /><br />//-------------<br /><br />Static Func _Isearch( oLname1, cLname1, oBrw, oRsCust )<br /><br /> cLname1 = Alltrim( oLName1:GetText() )<br /><br /> if Empty( cLname1 )<br /> return .T.<br /> endif<br /><br /> oRsCust:Filter := "</span><span style="color: #000000;">[</span>Last <span style="color: #0000ff;">Name</span><span style="color: #000000;">]</span> <span style="color: #0000ff;">like</span> <span style="color: #ff0000;">'"+cLname1+"%'</span><span style="color: #ff0000;">"<br /><br /> oBrw:ReFresh()<br /><br />Return .T.<br /><br />//-------------------------------<br />Static FUNCTION _ExitPgm1( lCLEAN,oWndchild,oRsCust,oBtn1,oBtn2 )<br /><br />LOCAL cDEFA, lOK3<br /><br />cDEFA := SET(7)<br /><br />IF lCLEAN = .T.<br /> lOK1 := .T.<br /><br /> oRsCust:CLose()<br /> oWndChild:End()<br /><br /> oBtn1:Enable()<br /> oBtn2:Enable()<br /><br />ENDIF<br /><br />RETURN( lOK1 )<br /><br /> // -- end<br /></span></div>[/code:2espkrjk]
here is the .rc
[code=fw:2espkrjk]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #B900B9;">// Generated by ResEdit 1.6.6</span><br /><span style="color: #B900B9;">// Copyright (C) 2006-2015</span><br /><span style="color: #B900B9;">// <!-- m --><a class="postlink" href="http://www.resedit.net">http://www.resedit.net</a><!-- m --></span><br /><br /><span style="color: #00D7D7;">#include</span> <windows.h><br /><span style="color: #00D7D7;">#include</span> <commctrl.h><br /><span style="color: #B900B9;">//#include "resource.h"</span><br /><br />#ifndef WC_STATIC<br /><span style="color: #00D7D7;">#define</span> WC_STATIC L<span style="color: #ff0000;">"Static"</span><br />#endif<br /><br />#ifndef MONTHCAL_CLASS<br /><span style="color: #00D7D7;">#define</span> MONTHCAL_CLASS <span style="color: #ff0000;">"SysMonthCal32"</span><br />#endif<br /><br />#ifndef DATETIMEPICK_CLASS<br /><span style="color: #00D7D7;">#define</span> DATETIMEPICK_CLASS <span style="color: #ff0000;">"SysDateTimePick32"</span><br />#endif<br /><br /><span style="color: #B900B9;">//</span><br /><span style="color: #B900B9;">// Dialog resources</span><br /><span style="color: #B900B9;">//</span><br />LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL<br />CUSTOMER <span style="color: #0000ff;">DIALOG</span> <span style="color: #000000;">3</span>, <span style="color: #000000;">13</span>, <span style="color: #000000;">538</span>, <span style="color: #000000;">356</span><br /><span style="color: #0000ff;">STYLE</span> DS_SETFONT | WS_CHILDWINDOW<br /><span style="color: #0000ff;">FONT</span> <span style="color: #000000;">8</span>, <span style="color: #ff0000;">"Arial"</span><br /><span style="color: #000000;">{</span><br /> CONTROL <span style="color: #ff0000;">""</span>, <span style="color: #000000;">109</span>, <span style="color: #ff0000;">"TFolderex"</span>, 0x50010000, <span style="color: #000000;">3</span>, <span style="color: #000000;">4</span>, <span style="color: #000000;">524</span>, <span style="color: #000000;">308</span>, 0x00000000<br /><span style="color: #000000;">}</span><br /><br /><br /><br />LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL<br />CUSTVIEW <span style="color: #0000ff;">DIALOG</span> <span style="color: #000000;">12</span>, <span style="color: #000000;">11</span>, <span style="color: #000000;">513</span>, <span style="color: #000000;">311</span><br /><span style="color: #0000ff;">STYLE</span> DS_SETFONT | WS_CHILDWINDOW<br /><span style="color: #0000ff;">FONT</span> <span style="color: #000000;">6</span>, <span style="color: #ff0000;">"MS Sans Serif"</span><br /><span style="color: #000000;">{</span><br /> LTEXT <span style="color: #ff0000;">"Date Purchased"</span>, <span style="color: #000000;">163</span>, <span style="color: #000000;">16</span>, <span style="color: #000000;">103</span>, <span style="color: #000000;">81</span>, <span style="color: #000000;">12</span>, SS_LEFT | SS_NOPREFIX, WS_EX_LEFT<br /> CONTROL <span style="color: #ff0000;">""</span>, <span style="color: #000000;">164</span>, DATETIMEPICK_CLASS, WS_TABSTOP | DTS_SHOWNONE, <span style="color: #000000;">101</span>, <span style="color: #000000;">101</span>, <span style="color: #000000;">83</span>, <span style="color: #000000;">13</span>, WS_EX_LEFT<br /> LTEXT <span style="color: #ff0000;">"Customer Type"</span>, <span style="color: #000000;">110</span>, <span style="color: #000000;">8</span>, <span style="color: #000000;">8</span>, <span style="color: #000000;">37</span>, <span style="color: #000000;">22</span>, SS_LEFT | SS_NOPREFIX, WS_EX_LEFT<br /> AUTORADIOBUTTON <span style="color: #ff0000;">" Individual "</span>, <span style="color: #000000;">150</span>, <span style="color: #000000;">46</span>, <span style="color: #000000;">10</span>, <span style="color: #000000;">63</span>, <span style="color: #000000;">12</span>, <span style="color: #000000;">0</span>, WS_EX_LEFT<br /> AUTORADIOBUTTON <span style="color: #ff0000;">" Commercial"</span>, <span style="color: #000000;">151</span>, <span style="color: #000000;">46</span>, <span style="color: #000000;">24</span>, <span style="color: #000000;">63</span>, <span style="color: #000000;">12</span>, <span style="color: #000000;">0</span>, WS_EX_LEFT<br /> CTEXT <span style="color: #ff0000;">"Customer Id"</span>, <span style="color: #000000;">111</span>, <span style="color: #000000;">112</span>, <span style="color: #000000;">11</span>, <span style="color: #000000;">94</span>, <span style="color: #000000;">10</span>, WS_BORDER | SS_CENTER | SS_NOPREFIX, WS_EX_LEFT<br /> EDITTEXT <span style="color: #000000;">152</span>, <span style="color: #000000;">112</span>, <span style="color: #000000;">23</span>, <span style="color: #000000;">94</span>, <span style="color: #000000;">12</span>, NOT WS_TABSTOP | ES_AUTOHSCROLL, WS_EX_LEFT<br /> LTEXT <span style="color: #ff0000;">"Company or Last Name"</span>, <span style="color: #000000;">112</span>, <span style="color: #000000;">7</span>, <span style="color: #000000;">39</span>, <span style="color: #000000;">105</span>, <span style="color: #000000;">10</span>, SS_LEFT | SS_NOPREFIX, WS_EX_LEFT<br /> LTEXT <span style="color: #ff0000;">"First Name"</span>, <span style="color: #000000;">113</span>, <span style="color: #000000;">119</span>, <span style="color: #000000;">39</span>, <span style="color: #000000;">73</span>, <span style="color: #000000;">10</span>, SS_LEFT | SS_NOPREFIX, WS_EX_LEFT<br /> EDITTEXT <span style="color: #000000;">153</span>, <span style="color: #000000;">7</span>, <span style="color: #000000;">50</span>, <span style="color: #000000;">105</span>, <span style="color: #000000;">12</span>, ES_AUTOHSCROLL, WS_EX_LEFT<br /> EDITTEXT <span style="color: #000000;">154</span>, <span style="color: #000000;">117</span>, <span style="color: #000000;">50</span>, <span style="color: #000000;">76</span>, <span style="color: #000000;">12</span>, ES_AUTOHSCROLL, WS_EX_LEFT<br /> GROUPBOX <span style="color: #ff0000;">""</span>, <span style="color: #000000;">196</span>, <span style="color: #000000;">2</span>, <span style="color: #000000;">4294967294</span>, <span style="color: #000000;">213</span>, <span style="color: #000000;">304</span>, <span style="color: #000000;">0</span>, WS_EX_LEFT<br /> CONTROL <span style="color: #ff0000;">"Customer Info"</span>, <span style="color: #000000;">172</span>, <span style="color: #ff0000;">"TXBrowse"</span>, 0x50A10000, <span style="color: #000000;">221</span>, <span style="color: #000000;">1</span>, <span style="color: #000000;">290</span>, <span style="color: #000000;">215</span>, 0x00000000<br /><span style="color: #000000;">}</span><br /><br /><br /><br />LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL<br />SERVVIEW <span style="color: #0000ff;">DIALOG</span> <span style="color: #000000;">12</span>, <span style="color: #000000;">11</span>, <span style="color: #000000;">436</span>, <span style="color: #000000;">311</span><br /><span style="color: #0000ff;">STYLE</span> DS_SETFONT | WS_CHILDWINDOW<br /><span style="color: #0000ff;">FONT</span> <span style="color: #000000;">6</span>, <span style="color: #ff0000;">"MS Sans Serif"</span><br /><span style="color: #000000;">{</span><br /> LTEXT <span style="color: #ff0000;">"Company or Last Name"</span>, <span style="color: #000000;">-1</span>, <span style="color: #000000;">24</span>, <span style="color: #000000;">58</span>, <span style="color: #000000;">105</span>, <span style="color: #000000;">10</span>, SS_LEFT | SS_NOPREFIX, WS_EX_LEFT<br /> EDITTEXT <span style="color: #000000;">120</span>, <span style="color: #000000;">24</span>, <span style="color: #000000;">70</span>, <span style="color: #000000;">105</span>, <span style="color: #000000;">12</span>, ES_AUTOHSCROLL, WS_EX_LEFT<br /><span style="color: #000000;">}</span><br /><br /><br /> </div>[/code:2espkrjk]
here is the wiki
<!-- m --><a class="postlink" href="https://wiki.fivetechsoft.com/doku.php?id=ado-related_stuffs">https://wiki.fivetechsoft.com/doku.php? ... ted_stuffs</a><!-- m -->
Rick Lipkin
|
ADS - The future is <sadly> now so where do you go ?
|
[quote="TimStone":1d2rzf7c]Giovanni,
Right now I have ongoing, daily, contact with SAP ( the owners of ADS ). This is not bankruptcy. They took away resources for further development apparently in 2015 ( the last release of ADS 12 ). Now they have used a funny term, but it is End of Life for 12/31/2022.
I have asked directly if they will release it to public domain, or give us access to update existing keys for more seats ( at no charge ). The problem is they can't even seem to find anyone in the company (SAP) who handles responsibility for this product even though their website says it is still available for sale. If you fill out a form as if you are a new client, no one will even respond, even though the form is still online.
It was my intention to convert to SQL and FWH has ample assistance, and samples, for doing this. My whole program is object oriented and perhaps once I start working with it, I will have success and move quickly through the process. I did use the FWH functions to actually convert my existing data files ( about 130 ) into a MySQL database, and that will be very helpful because the process is so simple. Now it is a matter of moving forward on implementing it within this massive application.
I am using FWH, Harbour, and MSVC ( Visual Studio Community 2022, and the latest builds of FWH and Harbour ). I am also fully focused on doing this in 64 bit ( and my application is fully running now as both 32 bit and 64 bit ) and all 3rd party libraries are updated.
So I will see how it goes. However, I can wait no longer to this conversion because we have no idea what will happen with ADS ... and it might even have some built in code that is date sensitive and it will stop working.
Tim[/quote:1d2rzf7c]
Some years ago I moved from ADS to MySql. This was the best thing I did. Mr Rao did a great job with FWH MySQL/MariaDB native support, the migration from ADS was very easy and his support is fast and perfect!
|
ADS - The future is <sadly> now so where do you go ?
|
I went to look at some examples in MySql. I will explain a situation.
1-Open the data dictionary of the present registry office. Ex: \\Server\UNC\Folder\MyDictionary.add
2-I'm going to UNION the AGENT's Document linking it to another data dictionary that is in the central registry office on the internet. Ex: \\201.64.98.121:2660\UNC\Folder\DictionaryCenter.add
This is to record in a temporary table that will be merged with two more tables later for reporting purposes.
How would you do this in MySql ?
Here's a simple example I use.
[code=fw:1vjtmc9w]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #0000ff;">Select</span> <br /> Tb01.cAgeCompareceuDoc ,<br /> Tb01.nAtoNumero ,<br /> Tb01.nAtoLivro ,<br /> Tb01.nAtoFolha <span style="color: #0000ff;">FROM</span> N_AUT_DOCUMENTOS AS Tb01 <br /> <span style="color: #0000ff;">Where</span> Tb01.nAtoLivro = _nLivro_Lanca_ and Tb01.cAgeCompareceuNome <> <span style="color: #ff0000;">''</span> <br />Union <span style="color: #0000ff;">Select</span> <br /> Tb02.cAgeCompareceuDoc ,<br /> Tb02.nAtoNumero ,<br /> Tb02.nAtoLivro ,<br /> Tb02.nAtoFolha <span style="color: #0000ff;">FROM</span> CartDistribuidor.N_AUT_DOCUMENTOS AS Tb02<br /><span style="color: #0000ff;">Where</span> Tb02.nAtoLivro = _nLivro_Lanca_ and Tb02.cAgeCompareceuNome <> <span style="color: #ff0000;">''</span> <br /> __ORDER_BY__ ;<br /> </div>[/code:1vjtmc9w]
From CartDistribuidor is a LINK referring to the address \\201.64.98.121:2660\UNC\Folder\DictionaryCenter.add recorded in the ad data dictionary for direct targeting by SQL commands.
|
ADS - The future is <sadly> now so where do you go ?
|
[b:1aextox8]Another example:[/b:1aextox8]
[code=fw:1aextox8]<div class="fw" id="{CB}" style="font-family: monospace;"><br />Servidor01 > DicCentral = \<span style="color: #000000;">201.100</span><span style="color: #000000;">.10</span><span style="color: #000000;">.10</span>\UNC\Carpeta\DicCentral.add <span style="color: #B900B9;">//Central</span><br />Servidor02 > Cartorio01 = \<span style="color: #000000;">201.100</span><span style="color: #000000;">.10</span><span style="color: #000000;">.11</span>\UNC\Carpeta\Diccionario.add <span style="color: #B900B9;">// Notario 01</span><br />Servidor03 > Cartorio02 = \<span style="color: #000000;">201.100</span><span style="color: #000000;">.10</span><span style="color: #000000;">.12</span>\UNC\Carpeta\Dicionario.add<span style="color: #B900B9;">// Notario 02</span><br /><br /><span style="color: #0000ff;">Select</span> Tb01., Tb02., Tb03.*<br /><span style="color: #0000ff;">From</span> Tb01 AS DicCentral.AGENTES<br />Inner <span style="color: #0000ff;">Join</span> Tb02 AS Cartorio01.PROTESTO <span style="color: #0000ff;">ON</span> cDocument = DicCentral.cDocRecent<br />Inner outher <span style="color: #0000ff;">Join</span> Tb03 AS Cartorio02.PROTESTO <span style="color: #0000ff;">ON</span> cDocument = DicCentral.cDocRecent<br /> </div>[/code:1aextox8]
|
ADS - The future is <sadly> now so where do you go ?
|
I have finally obtained OFFICIAL answers regarding ADS, and it's future:
1). Advantage Database Server reached End of Life on December 31, 2021.
2). The product will be user supported only starting 1/1/2023. Until then, individual questions will be answered ( if you can find someone to do so ).
3). ADS will NOT, repeat, NOT be released into open source, nor will the source code be made available to any other parties.
4). Though it is officially ended, additional seats can still be purchased for the last release ( dated 2015, v. 12 ). They are available on the portal at full price.
5). If Microsoft makes changes to the OS that would render ADS unusable ( without modification ), SAP will NOT modify the software in any way.
As a software developer/publisher for 40 years ( starting in 1982 with dBase II ), I would never consider selling my clients an expensive piece of software that was this dated, and had absolutely no guarantee it would be usable in even the near future.
So, it is absolutely time to move away from this product. Though I'm not happy to be spending the time to modify a very large, and intricate, application, fairness to my clients will require this change.
I'm disappointed, but not surprised.
|
ADS - The future is <sadly> now so where do you go ?
|
Dear Tim,
Every app has a deadline, everyone. this is the truth. We have to be aware of this in order to move ahead of this moment. What is the solution? Stop or evolve? And in most cases, how? Technology goes faster than us...
C.
|
ADS - The future is <sadly> now so where do you go ?
|
Carles,
I've been doing this for the past 40 years, so I have evolved. However, at my age, I just want to keep my clients happy with updates, and I'm not trying to compete in the newest programming styles and languages.
Frankly, the reason I don't "stop" is because clients actually have called me and asked me to not do that. So I do continue, but I also focus my time with family, my garden, travel, and hobbies.
Tim
|
ADS - The future is <sadly> now so where do you go ?
|
Tim,
Then you have your paradigm solved... <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
|
ADS - The future is <sadly> now so where do you go ?
|
Hello Tim,
it is good that you mention that ADS might have a problem with a later version of Windows.
I am sure Antonio and the FIVEWIN team will provide us with a solution for this as well.
Fivetech has always had solutions.
CLIPPER->HARBOUR,
DOS->WINDOWS,
WINDOWS METROSTYLE we had no problems,
now WINDOWS 11 everything works.
Remember PoketPC for WINDOWS. Fivetech also had a solution for this problem.
[b:1exf5fsf]Latest innovation from FIVETECH is mod harbour![/b:1exf5fsf]
And if your software is used professionally, you can switch to WINDOWS Server and RDP.
We still have WINDOWS Server 2008 in production. So, you will not have any problems in the next decade.
Have a nice Sunday and best regards,
Otto
|
ADS - The future is <sadly> now so where do you go ?
|
Otto,
A few years back, Microsoft turned off their Network Discovery feature that allowed ADS to query if a server existed. Suddenly, all installs failed. It also created massive problems for other Client Server systems.
Then, Five Tech could have done nothing to resolve the problem. However, at the time, Advantage was still receiving support, and we discovered that we could hardcode the server IP address ( which was done with an IP address ) and restore the connection.
While this may seem simple, it requires a static IP for the server. You might reply that should be a normal setup, but small businesses often were using the default IP address ( dynamic ) that was provided by their router, and had no idea how to setup their computer with a static IP.
So, yes, Microsoft does make changes in their Windows system that may well create problems with ADS and I imagine some people will appreciate the heads up now so they can also plan for their transition. With all the production efforts that the FiveWin team have going now, I would prefer they complete existing projects rather than have new problems to tackle. I've been waiting for 8 months for the completion of the RTF printing integration into the Printer class. It's part way there, but not complete.
As for mod harbour ... that is another project ... but Antonio did share a different approach is already under development by the team.
You also mention RDP. My clients have small networks, and many use a Windows 11 computer as the "server". I use Windows Remote Desktop from my iMac 27 to my Dell AIO where my programming resides. It works fine. However, it appears to me in this sitution, Win 11 will only support a single RDP session at a time, so how does that work for 4 workstations ? Also, 4 concurrent users would need 4 separate programs running on the server if I understand the process.
Tim
|
ADS - The future is <sadly> now so where do you go ?
|
Tim,
>I've been waiting for 8 months for the completion of the RTF printing integration into the Printer class.
I have posted in 2018 here how to print RTF with EasyReport.
We use this for our registration forms daily.
<!-- l --><a class="postlink-local" href="http://forums.fivetechsupport.com/viewtopic.php?f=3&t=35741&p=212968&hilit=EasyReort+and+RTF+opens+much+report+design+options&sid=6fa22b64dc19f7ba67e72207fe952e2a#p212968">viewtopic.php?f=3&t=35741&p=212968&hilit=EasyReort+and+RTF+opens+much+report+design+options&sid=6fa22b64dc19f7ba67e72207fe952e2a#p212968</a><!-- l -->
RDP
Yes, you need WINDOWS server, and you need RDP calls.
Such an RDP call is around 150€. I think if someone uses a workstation for a business, this is affordable.
Best regards,
Otto
[img:3eb2l8qo]https://mybergland.com/fwforum/er_rtf.jpg[/img:3eb2l8qo]
|
ADS - The future is <sadly> now so where do you go ?
|
Otto,
RE: RTF
First, ALL of my reports are complex and coded directly using the Printer class in FWH. I've never gotten Easy Report to function properly in my application anyway, so rewriting reports is not a practical idea.
Secondly, you have a fixed output. You essentially have a form, and then RTF text, all on one page. My situation is different:
1). The amount of output prior to the RTF section will vary. For example, the invoice includes parts, and labor, and the space that uses will change with every invoice.
2). The RTF section can start at the top of a page, or near the bottom, and it's length will vary.
3). In the current implementation ( latest FWH version ), we could output a fixed space for the RTF. However, after each line is printed, we need to know the postion it takes on the page ( line count ), and as it nears the bottom, we will then need to eject that page, start a new one, print the header information, and then resume the printing of the RTF. This option is not possible.
4). After the RTF is output, we may have further information to print, so we need to know the exact row position where the RTF ends. Again, this is not possible in the current version.
SO ... if your solution can provide for these two needs, thus allowing for in-line RTF printing within the Printer class, please immediately share that information with the developers so RTF can truly be supported.
AS for RDP ... my clients paid a significant amount of money for ADS which they can use in their small shops with Win 11 computers. It works beautifully. To suggest they should now get a new computer with WINDOWS SERVER software, and RDP licenses, to replace something that is still working for them ( but may fail in the future with no support available ) is something I would find hard to do. It would not be an easy thing for them to afford, especially now.
TIm
|
ADS - The future is <sadly> now so where do you go ?
|
Tim,
I just wanted to let you know that there are workarounds.
Unfortunately, I have shifted my focus to HTML reporting.
With that being said, none of these is an issue.
EasyReport.
Have please a look at the source code. EasyReport and TPrinter work on the same object. You can use them at the same time.
Your requirement is exactly the demo program of EasyReport, which is already available in the original version of Timm.
With EASYREPORT is here in our community much ignorance.
There are 2 parts there - that is the designer and the VRD.prg class.
With vrd.prg the report definition - it is an INI file - is processed and passed to the printer object, same (self) with which you work.
You do not need essentialy the designer. You can edit the ini-file with every texteditor. Same you do with your hard coded reports.
Best regards,
Otto
|
ADS - The future is <sadly> now so where do you go ?
|
[quote:2dfuximx]
Select
Tb01.cAgeCompareceuDoc ,
Tb01.nAtoNumero ,
Tb01.nAtoLivro ,
Tb01.nAtoFolha FROM N_AUT_DOCUMENTOS AS Tb01
Where Tb01.nAtoLivro = _nLivro_Lanca_ and Tb01.cAgeCompareceuNome <> ''
Union Select
Tb02.cAgeCompareceuDoc ,
Tb02.nAtoNumero ,
Tb02.nAtoLivro ,
Tb02.nAtoFolha FROM CartDistribuidor.N_AUT_DOCUMENTOS AS Tb02
Where Tb02.nAtoLivro = _nLivro_Lanca_ and Tb02.cAgeCompareceuNome <> ''
__ORDER_BY__ ;
[/quote:2dfuximx]
Yes, I use Unions as well. Very powerful. Especially across data dictionaries. The convenience of DD is not appreciated unless you've used them. Having Data Integrity rules, User logins, Stored Procedures, Functions, Replication, etc... is all foreign to most xbase developers. Having files on a file system does not protect or keep data private and secured the way you can with a DD. Files on a share can be deleted/stolen/corrupted by any user, either by accident or malice. Having orphan records is accepted as common as it is almost impossible to avoid it without integrity rules. The list goes on...
However, I don't think UNIONS are specific to ADS. All SQLs will have the same capability and similar syntax. Including Integrity rules, Stored Procedures, user logins with rights ...
If I were to re-write my apps (which I don't think I will), I would go MS-SQL or Mongo-DB this time. I don't think MS is going away and the user base is too big to fail.
Just my 2 cents,
Reinaldo.
|
ADS - converter campo criptografado
|
Ola amigos,
estou convertendo uma base DBF para ADS. Em uma destas tabelas existe um campo CRIPTOGRAFADO(um dos caracteres é chr(0)).
Ao tentar converter esta ocorrendo o seguinte erro:
ADS Error: 7200: AQE Error: State = 42000; NativeError = 2113; [SAP][Advantage SQL Engine]Unexpected end of SQL statement
Alguém sabe como contornar o problema?
|
ADS - converter campo criptografado
|
[url:26mnxh13]http://nntp-archive.sybase.com/nntp-archive/action/article/%3C46f7d864$1@192.168.0.1%3E[/url:26mnxh13]
|
ADS - converter campo criptografado
|
obrigado pela resposta,
resolvido tirando a criptografia do campo e criptografando a tabela(usando recursos do ADS.)
|
ADS - recno() con query SQL SOLUCIONADO
|
Buenas tardes,
Necesito saber si es posible usando ADS Server, implementar un query que me devuelva el recno() de cada registro que cumpla la condición de un select where.
Gracias.
Rolando <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
|
ADS - recno() con query SQL SOLUCIONADO
|
Rolando,
de memoria de contesto, no lo he probado, pero si la consulta SQL no implica un JOIN, es decir que solo seria de una tabla,
no veo por que no el RECNO() no te devuelva el valor correcto, es decir el numero de registro fisico
saludos
Marcelo
|
ADS - recno() con query SQL SOLUCIONADO
|
Marcelo,
Gracias por responder pero te pediría me pongas un ejemplo ya que no lo he podido lograr.
Obvio que el recno() del "Alias" resultante del query lo puedo visualizar pero l[b:1d713itl]o que me interesa es tener en ese "Alias" resultante, el recno() original del registro de la DBF a la que se le hace el query.[/b:1d713itl]
Por favor publica un ejemplo de como puedo lograrlo.
Gracias.
Rolando <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
|
ADS - recno() con query SQL SOLUCIONADO
|
Hola,
bueno si no estuvo claro, espero que este ejemplo si (el customer.dbf es el de siempre)
[code=fw:2461wf3p]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivewin.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"ads.ch"</span><br /><br /><br /><span style="color: #00C800;">FUNCTION</span> main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><span style="color: #00C800;">LOCAL</span> cAlias := <span style="color: #ff0000;">"sql"</span>, cRec := <span style="color: #ff0000;">""</span><br /><br /> rddRegister<span style="color: #000000;">(</span> <span style="color: #ff0000;">"ADS"</span>, <span style="color: #000000;">1</span> <span style="color: #000000;">)</span><br /> rddsetdefault<span style="color: #000000;">(</span> <span style="color: #ff0000;">"ADS"</span> <span style="color: #000000;">)</span><br /><br /> AdsSetFileType<span style="color: #000000;">(</span> ADS_CDX <span style="color: #000000;">)</span><br /> <br /> SET <span style="color: #00C800;">SERVER</span> <span style="color: #00C800;">LOCAL</span><br /> adsConnect<span style="color: #000000;">(</span><span style="color: #ff0000;">"."</span><span style="color: #000000;">)</span><br /><br /> adsRightsCheck<span style="color: #000000;">(</span> .F. <span style="color: #000000;">)</span><br /> <br /> <span style="color: #B900B9;">//ADSSETDATEFORMAT("DD/MM/YYYY")</span><br /><br /> <span style="color: #0000ff;">SELECT</span> <span style="color: #000000;">0</span><br /> ADSCreateSQLStatement<span style="color: #000000;">(</span> cAlias, <span style="color: #000000;">2</span> <span style="color: #000000;">)</span><br /> ADSPREPARESQL<span style="color: #000000;">(</span> <span style="color: #ff0000;">"select * from customer where state = 'NY'"</span> <span style="color: #000000;">)</span><br /> ADSEXECUTESQL<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <br /> ? <span style="color: #000000;">(</span>cAlias<span style="color: #000000;">)</span> -> <span style="color: #000000;">(</span> lastrec<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> <span style="color: #000000;">(</span>cAlias<span style="color: #000000;">)</span> -> <span style="color: #000000;">(</span> DBGOTOP<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">DO</span> <span style="color: #00C800;">WHILE</span> ! <span style="color: #000000;">(</span>cALias<span style="color: #000000;">)</span> -> <span style="color: #000000;">(</span> EOF<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> cRec += STR<span style="color: #000000;">(</span> <span style="color: #000000;">(</span>cAlias<span style="color: #000000;">)</span>-><span style="color: #000000;">(</span>RECNO<span style="color: #000000;">(</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <br /> <span style="color: #000000;">(</span>cAlias<span style="color: #000000;">)</span> -> <span style="color: #000000;">(</span> DBSKIP<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">ENDDO</span><br /><br /> ? cRec<br /><br /> BROWSE<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> DBCLOSEALL<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">NIL</span><br /><br /> </div>[/code:2461wf3p]
|
ADS - recno() con query SQL SOLUCIONADO
|
Marcelo,
Lo que propones entrega el recno() del cAlias que es la DBF "virtual" que crea el query, es decir que si hago una consulta a una DBF con 40000 registros y encuentra dos coincidencias solamente, el cAlias->recno() va a dar valores 1 ó 2 y eso no me sirve.
Como expliqué antes, lo que necesito son los recno() que tenían esos registros en los que se encontró lo buscado pero en la DBF de los 40000 registros.
Por ej. busco "TALLER" y lo encontró en el registro 4000 y 35000. Esos recno() son los que quiero guardar en la consulta.
Saludos
Rolando <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
|
ADS - recno() con query SQL SOLUCIONADO
|
Rolando,
no se si hiciste correr o no el ejemplo que publique con el DBF customer.dbf, este DBF tiene cientos de registros y la consulta solo devuelve 13 y los recno de estos trece se imprimen, y si tu tuvieras razon (no la tienes), lo que se deberia ver son los registros 1,2,3...13, pero no es asi, corre el ejemplo.
Ahora como dije en el primer post, si la consulta SQL solo es sobre una tabla (DBF,ADT) el resultado lo dara en un cursor dinamico, que es simplemente la misma tabla pero con un filtro aplicado, es decir no hay una DBF virtual, por lo que el recno() alli, devolvera el numero de registro fisico. Otra cosa importante, al ser un cursor dinamico, inclusive podrias cambiar informacion sobre este y este cambio se reflejara en la tabla, ya que es un subconjunto de la misma con un filtro aplicado.
Ahora si la consulta implica mas de una tabla, alli si, el cursor es estatico y obviamente lo descrito anteriormente no pasara.
Espero ser mas claro ahora, por favor corre el ejemplo y avisanos si funciono como se prevee, o realmente no estoy entendiendo lo que necesitas.
saludos
Marcelo
|
ADS - recno() con query SQL SOLUCIONADO
|
Rolando,
prueba en modo remoto, deberia ser exactamente igual, no lo probe,
saludos
Marcelo
|
ADS - recno() con query SQL SOLUCIONADO
|
MArcelo,
Parece ser que funcionara diferente en modo SERVER, ya probé tu ejemplo y no funciona igual en modo SERVER, no entrega los recno() de la DBF original sino como comenté al comienzo de este post.
Saludos
Rolando
|
ADS - recno() con query SQL SOLUCIONADO
|
Marcelo,
Probé tu ejemplo y efectivamente funciona.
La única diferencia es que yo lo uso ADS en modo remote y tu ejemplo es en modo local y ahí me parece que está la cuestión.
Gracias.
Rolando
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.