Precompilers, OCI & OCCI :: How To Compile Code To SO File

Nov 19, 2010

I wrote the below C code and I don't How can compile to so file

/* Include standard IO. */
#include <stdio.h>
#include <string.h>
#include <sqlca.h>
#include <stdlib.h>
[code].......

View 3 Replies


ADVERTISEMENT

Precompilers, OCI & OCCI :: Convert Compile (o) Files To C Code?

Oct 28, 2010

I compiled my c program to o file using the flowing command,

$gcc first.c -o first.o

the source code was lost.

How can I convert the o file to C code?

View -1 Replies View Related

Precompilers, OCI & OCCI :: How To Compile Simple PRO*C Code In Linux

Nov 6, 2008

Linux 2.4.21-37.ELsmp #1 SMP Wed Sep 7 13:28:55 EDT 2005 i686 i686 i386 GNU/Linux...As you'll see I do not understand anything about PRO*C. I need to compile this PRO*C code to use it to retrieve DBMS PIPES being sent.

I'm trying to compile it using the following command:
gcc -o IAPIPE IAPIPE.c

The code - file IAPIPE.c
#include <stdio.h>
#include <string.h>

EXEC SQL BEGIN DECLARE SECTION;
VARCHAR username[20];
int status;
int msg_length;
char retval[2000];
EXEC SQL END DECLARE SECTION;
[code]....

View 3 Replies View Related

Precompilers, OCI & OCCI :: Unable To Compile Pro C Code With Oracle 11g In Windows Env

Jul 15, 2010

I am trying to compile a .pc file. I am working with Oracle 11gR1 and windows env. I am able to create .c file from .pc file. I am able to produce .o file from .obj file. But i am not able to link it and produce .exe. My installation does not contain / precomp /demo folder.

View 7 Replies View Related

Precompilers, OCI & OCCI :: Compile PC File With Created Make File - No Explicit Type Given

Jan 22, 2008

I am trying to compile a .pc file with the make file which I created. But when I try to give make command I am getting following error

>make testfile
cc -o testfile testfile.c
"testfile.c", line 117: warning: no explicit type given
"testfile.c", line 119: warning: no explicit type given
"testfile.c", line 121: warning: no explicit type given
"testfile.c", line 122: warning: no explicit type given
"testfile.c", line 123: warning: no explicit type given
Undefined first referenced
symbol in file
sqlcxt testfile.o
ld: fatal: Symbol referencing errors. No output written to testfile

*** Error code 1
make: Fatal error: Command failed for target `testfile'

View 16 Replies View Related

Precompilers, OCI & OCCI :: Compile ProC File - Failed Assertion

Aug 13, 2010

I am trying to compile a pro c file. Rest of the pro c file is compiling fine. But one particular file is showing following error.

INTERNAL ERROR: Failed Assertion [Code=40706]

View 11 Replies View Related

Precompilers, OCI & OCCI :: PThreads / Pro*C Code Causes ORA-24550

May 12, 2009

I've a Pro*C program which fills various large tables (in different schemas). I am executing the procedures which fill the tables as PThreads (since I want them to run in parallel for performance reasons). When I execute all threads sequentially (pthread_join(last_thread) before every pthread_create(next_thread)) everything works fine. But when a run the threads in parallel (as they should run), I am getting: "ORA-24550: signal received: si_signo=11si_errno=0si_code=1si_addr=0x18 Aborted"

View 1 Replies View Related

Precompilers, OCI & OCCI :: Compilation Error When Compiling Code

Apr 2, 2009

I'm running a query similar to the one that I'm describing below -:

EXEC SQL INSERT INTO TABLE1
( C1
,C2
,C3
,C4 )
[code]....

Above query runs perfectly on SQL prompt.Same query, when being run in a Pro*C program gives compilation error-:

Error at specified line:

,( SELECT D.V3 FROM TABLE2 D WHERE D.V3 = C.V4)
.............................1
PCC-S-02201, Encountered the symbol "D" when expecting one of the following:
( ) * + - / . @ | at, day, hour, minute, month, second, year,

What are the possbile causes of error. I am using Oracle 10g on Unix.

View 1 Replies View Related

Precompilers, OCI & OCCI :: Pro* C Code To Fetch Cursor And Loop

Nov 18, 2009

i HAVE THE FOLLOWING CODE WRITTEN IN A *.pc FILE. I am trying to loop to fetch data from cursor. But the code exist after it fetches the first record. Let me know what is it the right way to fetch data from cursor?

EXEC SQL BEGIN DECLARE SECTION;

char str[64];

EXEC SQL END DECLARE SECTION;

/*cursor declarations*/
EXEC SQL DECLARE Get_SQLText_Cursor CURSOR FOR

[Code]....

View 6 Replies View Related

Precompilers, OCI & OCCI :: Make Files That Compile PC Files In Unix

Jul 31, 2008

I have written make files that compile .pc files in unix. This was for several projects that use an oralib source code directory.Just running proc on one target .pc file works fine on unix. I am trying to use proc - Oracle 10.2.0 - in windows and I keep getting:

Quote:unable to open include file
#include <stdio.h>
and other C library headers.

I am doing all development under cygwin, this way I can write a makefile just like under unix instead of using nmake.All C library headers are in /usr/include When I run proc on Solaris as that:

proc program.pc
No problems, and I do get program.c.

However in windows I get the previous error message. I have tried to do proc include=/user/include program.pc and proc include=/user/include parse=full program.pc but I still get the same error message.

View 3 Replies View Related

Precompilers, OCI & OCCI :: Unsatisfied Code Symbol (dladdr) In Load Module?

Jul 15, 2008

Recently, i had to restore /usr/lib folder (because some files crashes) to a previous point. This restore point is previous to Oracle client installation. Well, now, when i try to compile my Pro*C samples:

# make -u -f demo_proc32.mk sample1
/usr/ccs/bin/make -f
/oracle/oracle/product/10.2.0/client_1/precomp/demo/proc
/demo_proc32.mk OBJS=sample1.o EXE=sample1 build

[code]...

Can i fix it without re-installing Oracle client?

View 1 Replies View Related

Precompilers, OCI & OCCI :: Compiling C File (output Of PC File Precompialtion)?

May 4, 2010

after precompiling the cmpre.pc file, i got cmpre.c file. when i try compiling this .c file, am facing the following error...

servername:/.../home/usr/compile-> cc -g cmpre.c
ld: 0711-317 ERROR: Undefined symbol: .sqlorat
ld: 0711-317 ERROR: Undefined symbol: .sqlcxt
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.

View 1 Replies View Related

Precompilers, OCI & OCCI :: Convert C To PC File?

Dec 11, 2010

Can i convert a .c file to .pc file?The .c file is generated by compiling .pc file. I mistakenly deleted the .pc file. I need the original .pc file.

View 2 Replies View Related

Precompilers, OCI & OCCI :: Data Loading Of French Input File

Aug 16, 2012

I am trying to load a input flat file (french data in it) into the database using pro*c (not using sql loader because of some validations ). i am reading the line by line and populating it into the structure and then process it.

The input file is encoded in WE8ISO8895P1 , I want the records to be populated into a table. so i did set NLS_LANG=French_France.WE8ISO8895P1 and ran the pro*c program . i used character host variable in the insert query , i used data from the earlier read structure and set these character host variable.

The problem i am facing is , when i am printing the values before insert i could see correct data.

For example the printed data of variable is "pas de donné " and strlen is 14. the target table field is of varchar type
( name varchar(20 char) )

but after i insert i could see only the truncated value in the database i.e "pas de donn" in the table length is 11.

View 17 Replies View Related

Precompilers, OCI & OCCI :: Error ID 0706-006 Cannot Find Or Open Library File

Apr 1, 2010

I have 3 code files written in ProC. I have precompiled, compiled, tested them in my local environment (Windows) & they work fine. But when I try in real environment, AIX 5.3, I can precompile them. But when I try to compile & link them with the libclntsh library I get errors. I am using a Makefile but just for testing this is the command -

xlc oraProcs oraProcs.c test_curva.c lib_util.c -I $ORACLE_HOME/precomp/public -L $LIBPATH -l libclntsh.a
Error - ld: 0706-006 Cannot find or open library file: -l libclntsh.a
ld: open(): A file or directory in the pathname does not exist

where LIBPATH = $ORACLE_HOME/lib

library libclntsh.a exists in $ORACLE_HOME/lib & has the right permissions

I also tried removing the library libclntsh.a & recreating it using the command - genclntsh When I run this command I get this warning more than once -ld: 0711-783 Warning TOC overflow TOC size: 66888 Max size: 65536 genclntsh creates the library libclntsh.a, just not sure if these warnings damage the library file and are related to my link erros in some way.

View 2 Replies View Related

C++ Call Interface :: Occi 11.1 Error On Compile - Undefined Reference To Oracle?

Jul 11, 2012

I'm trying to compile an hello world example on my computer. I've read the documentation for requirements occi on the site

[URL]....

It says that the g++ compiler 3.4.6 or later is supported. I have:

Ubuntu 12.04
gcc 4.6.3
oracle instant client 11.2

g++ main.cpp -c -I/home/tim/skrivbord/bin/oracle/instantclient_11_2/include/ -D_REENTRANT -g -Wall
g++ -o pippo -L/home/tim/skrivbord/bin/oracle/instantclient_11_2/ -locci -lclntsh -lociei -lnnz11 main.o
main.o: In function `main':
/home/tim/skrivbord/dev/cpp/main.cpp:21: undefined reference to

[code]....

View 1 Replies View Related

Create Trigger To Execute A Stored Procedure During Source Code Compile?

Nov 9, 2009

I would like to create a trigger that will execute a stored procedure when a package/function/procedure is compiled. I tried creating an update trigger on user_objects, but it statues aI cannot create that trigger tyoe on views.

View 1 Replies View Related

Precompilers, OCI & OCCI :: Connectivity Between C And Oracle?

Aug 12, 2008

Is it possible to connect with Oracle using C?

View 2 Replies View Related

Precompilers, OCI & OCCI :: Keep Getting ORA-22275 From Extproc?

Sep 26, 2012

I am trying to give back data from a stored procedure written in C. I registered the functions as follows:create or replace procedure version(versioninfo OUT clob) as external name "version" library myLib language c with context parameters (context, versioninfo, versioninfo INDICATOR SB4); It compiles fine. The function being called look like this:

extern "C" DLLEXPORT
void version(OCIExtProcContext* context, OCILobLocator **out, sb4 *ind_out){
OCIEnv* envh;
OCISvcCtx* svch;
OCIError* errh;
OCIExtProcGetEnv (context, &envh, &svch, &errh);

std::string versioninfo = "104";
oraub8 maxChar = 10;

[code]...

If I execute the procedure with SQLDeveloper by pressing "play" it is getting executed but there is no result. If I try to execute it from an anonymous block it results in ORA-22275 instead of doing anything.

declare
res clob;
begin
-- the following doesn't work much
--dbms_lob.createtemporary(res,true);
version(res);
dbms_output.put_line(res);
end;

Actually I have to questions:
1.) Why does Oracle give me the error? In my opinion all requirements mentioned by the error description are met.
2.) Why is there no output when executing the function via SQL Developer? Is the usage of OCILobWrite wrong?

View 2 Replies View Related

Precompilers, OCI & OCCI :: Describe STP In Package

Nov 26, 2009

I am trying to describe an STP in a package, but it gives me an error.

e.g. In package ABC suppose there is an STP XYZ, I am trying to describe ABC.XYZ function but it gives me an error code 4043 and error message object XYZ.ABC does not exist.

View 2 Replies View Related

Precompilers, OCI & OCCI :: 11g Pro*C Application Crashes While 10g Is OK

Jan 24, 2009

My 10g pro*c application works perfectly, recently I upgraded it to 11g, but it keep crashing, why?

View 10 Replies View Related

Precompilers, OCI & OCCI :: Proc Compilation?

Mar 31, 2010

i need to compile a proc program, say prog.pc.have oracle 10g in my system. Since i am new to proc programming, me on the steps to compile the proc program in oracle proc compiler.

View 2 Replies View Related

Precompilers, OCI & OCCI :: How To Get Columns As NUMBER(30)

Aug 13, 2008

in my oci applications,if i get a column of number that is in the scope of int,i can use value = *(int *)field.data; get the value,but if the column size is larger than 10,the code can't be available,how can i get the value.

View 6 Replies View Related

Precompilers, OCI & OCCI :: Calling Procedure From PRO C?

Nov 26, 2012

I am trying to call procedure from PRO C Procedure has many parameters and I do not need to put all of them when I call procedure. Is there way to make the same way as in PL/SQL

like this

my_procedure( q=>a1 , b=>'abc )

View 1 Replies View Related

Precompilers, OCI & OCCI :: How To Connect To Two Databases

Aug 25, 2009

My program needs to connect to two databases and make operations in both databases:

Quote:connect to db1;
connect to db2;

select from table in db1;
update table in db2;

i would like to know whether it's possible, and how to do it ? how to specify for each query the database connection to use?

note that I can't use dblinks as i don't have enough access rights and privileges on neither of the databases.

View 2 Replies View Related

Precompilers, OCI & OCCI :: How To Report Oracle Bug

Jan 30, 2009

How to report an Oracle bug? Is there webpage or email?

View 4 Replies View Related

Precompilers, OCI & OCCI :: How To Connect C++ And Oracle

Sep 17, 2008

My OS is Linux and I installed Oracle 10.2. Everything is fine.I can use sqlplus, exp, imp etc with no problem.Now I have created another linux user test in /home/test. I unzipped basic-10.2xxxxxx.zip (/home/test/instantclient_10_2) and exported LD_LIBRARY_PATH.I guess I have installed instant client in this way.

My testOra.cpp:

#include <occi.h>
int main()
{
return 0;
}

This test.cpp would not compile. It cannot find occi.

View 8 Replies View Related

Precompilers, OCI & OCCI :: Using Cursor In Pro Cobol

Oct 7, 2010

I declare a cursor for a table with 8000 records, when I fetch the cursor this message appear ORA-03113: end-of-file on communication channels when the fetch reach the 6500 element, What is the problem here?. All data are ok, not null fields.

other problem

How I can reuse a cursor, I declare a cursor for a table where code_part = 300, then I fetch all elements until end cursor, then I close the cursor, Then I declare the same cursor again for the same table where code_part = 359, but it is not successful, when I tried to fetch the cursor again the cobol program show me the last record for the first code, How I can restart the cursor or delete it or freed the cursor position?

View 1 Replies View Related

Precompilers, OCI & OCCI :: Print Run Time Value?

Apr 26, 2012

I am inserting empno in a table1 and updating another table2 using table1 empno and getting ora-01427 error. I want to print empno for whis this error is coming. How to print that value?

View 1 Replies View Related

Precompilers, OCI & OCCI :: How To Integrate SQLnet

Apr 17, 2009

how to integrate SQLnet & c and I'm quite losted at the moment.

Searching with google gives some random stuff, which does seems to be irrelevant.some oracle db somewhere and need for good way to use that remote db (one solution seems to be using SQLnet).

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved