Subject RE: [firebird-support] Re: Equivalent of VFP6 LEFT() in FB
Author Peter Gore
Take a look at freeudflib. You can get it at
http://www.ibphoenix.com/downloads/freeudflib20010211.zip

Peter Gore
-----Original Message-----
From: kaczy27 [mailto:kaczy27@...]
Sent: 13 September 2004 09:22
To: firebird-support@yahoogroups.com
Subject: [firebird-support] Re: Equivalent of VFP6 LEFT() in FB


--- In firebird-support@yahoogroups.com, Namit Nathwani
<namitnathwani@h...> wrote:
> Hi all
>
> I have this FB table containing a BLOB (Text) field. For a remote
views
> select statement I have written this in VFP6 as below:
>
> SELECT MCUSTOMSOFFICE.*, LEFT(MCUSTOMSOFFICE.mAddress, 44) AS
cShortAddress ;
> FROM MCUSTOMSOFFICE MCUSTOMSOFFICE ;
> ORDER BY MCUSTOMSOFFICE.CNAME
>
> The LEFT() does not seem to be recognized by FB/ODBC, what is the
> equivalent of LEFT()
for varchar fields you can use
SUBSTRING(value FROM startpos [FOR length])

I don't know how this will work with blobs, but I'd try casting it
first
SUBSTRING(CAST(value) as VARCHAR(100)) FROM startpos [FOR length])


> Please advise.

HTH
>
> Regards
> Bhavbhuti
CUIN Kaczy






Yahoo! Groups Links