From 0229eff83c859c3ca0177a51b10596149832a17f Mon Sep 17 00:00:00 2001 From: Lester Caine Date: Tue, 29 Jul 2008 06:23:50 +0000 Subject: Add correct SQL for oracle when using SUBSTR This should use the ADOdb $substr variable - but even that is not totally correct as Firebird requires SQL2003 format (x FROM s FOR l) so this should probably be a function in ADOdb to return the correct layout. --- BitBoardTopic.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/BitBoardTopic.php b/BitBoardTopic.php index bde7223..82f5e41 100644 --- a/BitBoardTopic.php +++ b/BitBoardTopic.php @@ -1,13 +1,13 @@ - * @version $Revision: 1.48 $ $Date: 2008/06/05 22:21:18 $ $Author: wjames5 $ + * @version $Revision: 1.49 $ $Date: 2008/07/29 06:23:50 $ $Author: lsces $ * @package boards */ @@ -332,6 +332,8 @@ class BitBoardTopic extends LibertyMime { if ( $this->mDb->mType == 'firebird' ) { $substrSql = "SUBSTRING(s_lcom.`thread_forward_sequence` FROM 1 FOR 10) LIKE SUBSTRING(lcom.`thread_forward_sequence` FROM 1 FOR 10)"; + } elseif ( $this->mDb->mType == 'oci8' ) { + $substrSql = "SUBSTR(s_lcom.`thread_forward_sequence`, 1, 10) LIKE SUBSTR(lcom.`thread_forward_sequence`, 1, 10)"; } else { $substrSql = "SUBSTRING(s_lcom.`thread_forward_sequence`, 1, 10) LIKE SUBSTRING(lcom.`thread_forward_sequence`, 1, 10)"; } -- cgit v1.3