If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

The Shared library was created as follows:
Create the .c file
Compile the CSSSLB19.pc to get the CSSSBLB19.c
Create the .o file-->
cc -I/oracle8/home/app/oracle/product/8.0.5/rdbms/demo
-I/oracle8/home/app/oracle/product/8.0.5/plsql/public
-I/oracle8/home/app/oracle/product/8.0.5/network/public CSSSLB19.c
Create the .so file as follows-->
make -f $ORACLE_HOME/rdbms/demo/demo_rdbms.mk extproc_with_context
SHARED_LIBNAME=CSSSLB19.so OBJS="CSSSLB19.o"

IF (cmd_out IS NULL) THEN
dbms_output.put_line('ERROR, bad command or no output returned...');
ELSE -- output one line at a time
len := length(cmd_out);
i := 1; -- start at first char
j := instr(cmd_out,cnl,i,1); -- find first newline char
LOOP
dbms_output.put_line(substr(cmd_out,i,j-i)); -- print the line
IF ( j = len ) THEN
EXIT;
END IF;
i := j + 1; -- start after last newline
j := instr(cmd_out,cnl,i,1); -- find the next newline
END LOOP;
END IF;