Subject Re: [firebird-support] Invalid argument in EXECUTE STATEMENT - cannot convert to string
Author Thomas Beckmann
userClause is probably null. Then the entire string will be null.

Am 25.06.2014 16:08, schrieb Tim Ward tdw@... [firebird-support]:
>
>
> Anyone know what this error message actually means?
>
> Yes I am trying to run an EXECUTE STATEMENT, but it's not clear to me
> what an "argument" means in this context, or what it is that something
> is trying to convert to a string, or why it's trying to do so, or why it
> can't be done.
>
> execute statement
>
> 'select first 1 MODULEID, ELEMENTID from TBLMODULE' ||
> :tableType || ' ' ||
> 'where ELEMENTID = ' ||:ELEMENTID || :userClause || '
> order by 1 ASC'
>
> into :nModuleId, :nElementId;
>
> tableType is a varchar
> elementid is a bigint
> userclause is a varchar
>
> nmoduleid is a bigint
> nelementid is a bigint
>
> The only thing I can think of, after struggling for some time to
> understand the message, is that the thing between "statement" and "into"
> is the "argument", and the only reason I can think of that it might not
> be a string - despite obviously looking like one!! - is that elementId
> is null (neither of the other variables can ever be null). Does that
> make sense?
>
> --
> Tim Ward
>
>

--
Mit freundlichen Grüßen,

Thomas Beckmann
Diplom-Informatiker


Wielandstraße 14c • 23558 Lübeck
Tel +49 (22 25) 91 34 - 545 • Fax +49 (22 25) 91 34 - 604
Mail thomas.beckmann@... <mailto:thomas.beckmann@...>

ASSFINET-Logo

*ASSFINET Dienstleistungs-GmbH*
Max-Planck-Straße 14 • 53501 Grafschaft bei Bonn
info@... <mailto:info@...> • www.assfinet.de
<http://www.assfinet.de/>

Geschäftsführer: Dipl. Wirtschaftsinformatiker Marc Rindermann
Registergericht Koblenz HRB 23331

Diese E-Mail enthält vertrauliche Informationen. Wenn Sie nicht der
richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben,
informieren Sie bitte sofort den Absender und vernichten Sie diese Mail.
Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail ist
nicht gestattet.