Hello Claudio,

A framework should do that kind of work... but not the sql statements:-)

SAP&&Oracle is sometimes a lucky marriage for management using
big-shoes-management.
Really, I have no idea how many hospitals are setting up the requirement
that there must be Oracle or MS-SQL. 

The adoDB what is currently used is compatible to the mostly used DBMS, that
is not really an issue. More issue and work is that the SQL syntax is quite
different. There are mostly no similar datatypes, not even VARCHAR. There is
no way out, just one and this is the way Elpidio showed us in the
class_core... we need so called bridge-pattern to encapsulate queries to
persistent classes: 
        $this->Transact($sql) 
instead of using 
        $db->Execute($sql)

So the issue is the SQL statement. There must be this internal persistent
class what will transform the sql statements to the DBMS what is used.
Something like that... and this needs a high discipline for developers and
quality control, because not all will have all common databases for testing
own applications.
Look at this:
mysql> SELECT * FROM foo WHERE bar LIKE '%foobar%';
pgsql> SELECT * FROM foo WHERE bar ILIKE '%foobar %';
db2> SELECT * FROM foo WHERE LOWER(bar) LIKE '%foobar%';
oracle> SELECT * FROM foo WHERE NLS_LOWER(bar) LIKE '%foobar%';

All results are the same, but sql is not standardized whatever they want to
tell us :-)

Robert

P.S. On Monday I will also try to set it up under ubuntu with the php
version available at cannoncial and, if possible, I will look for opensuse
what's installed on another test survey. 

> -----Ursprüngliche Nachricht-----
> Von: [EMAIL PROTECTED] [mailto:care2002-
> [EMAIL PROTECTED] Im Auftrag von Claudio Giulio
> Torbinio - Email
> Gesendet: Samstag, 18. August 2007 16:07
> An: care2002-developers@lists.sourceforge.net
> Betreff: Re: [Care2002-developers] Why not Php5 and beyond?
> 
> Hi Robert
> 
> As you have experimented, care2x works under php 5.1
> I the reason that maked me delete the php5 compatibility SVN...
> Moreover, due to my clients OS, i must work on Win platforms, and on Vista
> with WAMP, i have no problems.
> I can swith between both parsers (4 and 5), but care2x works good anyway.
> @ this moment i am trying to test care2x on Ubuntu with LAMP (parser 5.1)
> Think we can release it as "4 and latest version compatibile.
> The restrictions to PHP 5.2
> 
> Currently, i have a care2x version running under MSSQL by using this
> class:
> --------------------------------------------------------------
> <?php
> //sql server data access class
> 
> //common class name for all database types..
> //thats the first criteria.
> //you will notice that the name "SampleDataAccess" is common in the SQL
> and
> MySQL class files...
> //there won't be a collision as only the proper file will be loaded based
> on
> the DB
> class SampleDataAccess{
> 
> 
> 
>     //member function to return all data.
>     //our example is to return all base table entries
>     //and ONLY the LAST entered financial data value..
> 
>     function GetAllData($orderby='', $dir){
>         global $_TABLES;
>             //this is a nice example of a sql call that works flawlessly
> in
> SQL server,
> 
>         $x=array();
>         $sql="select a.id, a.name, a.descr, ";
>         $sql.="(select top 1 b.dollarAmount ";
>         $sql.="from {$_TABLES['encounter']} b ";
>         $sql.="where b.base_id=a.id ";
>         $sql.="order by b.dateEntered desc) ";
>         $sql.="from ";
>         $sql.="{$_TABLES['base']} a ";
>         if($orderby!=''){
>             $sql .="order by {$orderby} {$dir}";
>             }
> 
>         $res=DB_query($sql);
>         $nrows=DB_numRows($res);
>         if($nrows>0){
>             for($cntr=0;$cntr<$nrows;$cntr++){
>                 $thisRow= DB_fetchArray($res);
> 
> array_push($x,array($thisRow[0],$thisRow[1],$thisRow[2],$thisRow[3]));
>                 }
>             return $x;
>             }
>         else{
>             return FALSE;
>             }
>         }
> 
> 
> 
>     //thanks to php.net for this
>     function array_push_associative(&$arr) {
>       $args = func_get_args();
>       foreach ($args as $arg) {
>           if (is_array($arg)) {
>               foreach ($arg as $key => $value) {
>                   @$arr[$key] = $value;
>                   $ret++;
>               }
>           }else{
>               @$arr[$arg] = "";
>           }
>       }
>       return $ret;
>     }
> 
>     }//end class
> ?>
> ---------------------------------------------
> Is just a suggestion, but we must begin to think @ the more used DataBases
> in Healtcare (Oracle, MSSQL), as soon on an incoming release.
> 
> B. Claudio
> 
> 
> 
> ----- Original Message -----
> From: "Robert Meggle" <[EMAIL PROTECTED]>
> To: <care2002-developers@lists.sourceforge.net>
> Sent: Saturday, August 18, 2007 12:59 PM
> Subject: Re: [Care2002-developers] Why not Php5 and beyond?
> 
> 
> .
> 
> 
> 
> 
> 
>  --
>  Email.it, the professional e-mail, gratis per te: http://www.email.it/f
> 
>  Sponsor:
>  In REGALO 'All the Good Thing' di NELLY FURTADO
>  Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=6617&d=18-8
> 
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc.
> Still grepping through log files to find problems?  Stop.
> Now Search log events and configuration files using AJAX and a browser.
> Download your FREE copy of Splunk now >>  http://get.splunk.com/
> _______________________________________________
> Care2002-developers mailing list
> Care2002-developers@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/care2002-developers


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Care2002-developers mailing list
Care2002-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/care2002-developers

Reply via email to