Skip to Content
avatar image
Former Member

User defined scalar function returns zero rows

Hi,

I have created the following simple function.

CREATE FUNCTION FUNCTION_MUL(IN_VAR INT)

RETURNS RESULT INT LANGUAGE SQLSCRIPT

AS

BEGIN

RESULT := :IN_VAR * :IN_VAR;

END;

I call this function as  SELECT FUNCTION_MUL(2) as RESULT FROM DUMMY;

I always get zero errors returned.

Kindly help me in resolving it.

Thanks & Regards,

Monissha

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Jan 19, 2015 at 02:31 PM

    Well, I'd say that

    I always get zero errors returned.

    is good, isn't it? 😊

    I assume you meant that you get the message "Fetched 0 row(s)", didn't you?

    If that's the case, please make sure that there is actually a record present in your DUMMY table and that you are not using e.g. a copy of the DUMMY table that happens to be empty...

    - Lars

    Add comment
    10|10000 characters needed characters exceeded