Subject Re: [firebird-support] UDF / SP functions
Author agung wibowo
no, you can't do that. sysleft is stored procedure and cannot execute like that.stored procedure can call by execute or select statement, and cannot call like udf. you can use freeudflib.dll that contain external function like your sysleft procedure

with regards
----- Original Message -----
From: yartax1
To: firebird-support@yahoogroups.com
Sent: Thursday, December 02, 2004 9:37 PM
Subject: [firebird-support] UDF / SP functions




Hi,

I need to do next query:

Select a.* from no_nomina a
inner join no_contrato b on a.empleado = b.empleado and a.orden =
b.orden and a.empresa = b.empresa
inner join usuario_centro c on sysleft(destcon,2) = sysright(c.centro,2)
where c.idusuario = 1

------------------------

Where sysleft and sysright are SP like:

SET TERM ^ ;

CREATE PROCEDURE SYSLEFT (
CADENA VARCHAR(255),
LEN INTEGER)
RETURNS (
OUT VARCHAR(255))
AS
begin
if ( LEN = 0) then BEGIN
EXIT;
END
OUT = substr(CADENA,1,len);
suspend;
end
^

SET TERM ; ^

-------------

When I do Select * from sysleft('hello',2) works perfectly but in my
first query didn't. How can I do that kind of query?

Thanks.
Julian.







Yahoo! Groups Sponsor
ADVERTISEMENT





------------------------------------------------------------------------------
Yahoo! Groups Links

a.. To visit your group on the web, go to:
http://groups.yahoo.com/group/firebird-support/

b.. To unsubscribe from this group, send an email to:
firebird-support-unsubscribe@yahoogroups.com

c.. Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.




[Non-text portions of this message have been removed]