Re: WHEN? PL/SQL C struct support
Date: 1995/06/13
Message-ID: <3rkr0b$pjd_at_inet-nntp-gw-1.us.oracle.com>#1/1
atkins_at_fc.hp.com (Brian Atkins) wrote:
>I have several places in my C app where a PL/SQL block would go nicely.
>The problem is, PL/SQL doesn't support C structures (ProC 2.0 does).
>
>Any idea on when this might be available? Ever?
>
>Thanks!
>
>Brian
>
>------------------------------------------------------------------------------
>Brian Atkins atkins_at_cnd.hp.com (970) 229-2114
>Hewlett-Packard (MS A2-1LP4) 3404 E. Harmony Road, Ft. Collins, CO 80525-9599
PL/SQL does have a record type, which is similar to C structures. But I suspect your question is really, "How can I bind a C structure to a PL/SQL record?" This you can't do yet. I don't know when it will be available, either. But you can workaround this, by assigning to individual fields within embedded blocks. For example:
EXEC SQL EXECUTE
declare
rec emp%rowtype; -- A record
begin
rec.ename := :emp_name; -- A host variable
rec.empno := :emp_number; -- Another host variable
...
end;
END-EXEC;
Hope this helps.
Received on Tue Jun 13 1995 - 00:00:00 CEST
