Subject | Firebird newbie |
---|---|
Author | Stephen Lee-Woolf |
Post date | 2002-02-05T16:32:08Z |
I know this isn't, strictly, an IBObjects question, but it does involve
the use of IBOQueries. I have an application written in Delphi6 using
data residing on a MySQL server which I am porting over to Firebase RC2.
The query is in the form:
SELECT count(*) AS SL
FROM logins
WHERE server=DefaultServer AND
left(login,10) = ":Search1" AND
left(login,10) = "left(logout,10)" AND
acctype="S"
I get problems with the second and third parameters. This appears to
stem from the fact that Firebird doesn't seem to support the left()
function, at least not in the way MySQL does.
Obviously I could re-write the senond condition as
where login starts with :Search1
But this doesn't solve the problem for the third condition.
Can someone tell me how to do this kind of sub-string search in Firebird
please?
Thanks
--
Steve Lee-Woolf
University of Salford
Manchester, U.K.
the use of IBOQueries. I have an application written in Delphi6 using
data residing on a MySQL server which I am porting over to Firebase RC2.
The query is in the form:
SELECT count(*) AS SL
FROM logins
WHERE server=DefaultServer AND
left(login,10) = ":Search1" AND
left(login,10) = "left(logout,10)" AND
acctype="S"
I get problems with the second and third parameters. This appears to
stem from the fact that Firebird doesn't seem to support the left()
function, at least not in the way MySQL does.
Obviously I could re-write the senond condition as
where login starts with :Search1
But this doesn't solve the problem for the third condition.
Can someone tell me how to do this kind of sub-string search in Firebird
please?
Thanks
--
Steve Lee-Woolf
University of Salford
Manchester, U.K.