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
ADVERTISEMENT
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
View Related
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
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
Jul 7, 2011
I found this thread, and recently i want to embedded oci in pro*c for distributed transaction reason.
can pro*c deal with distributed transaction? i want to use mts in pro*c .
View 14 Replies
View Related
May 24, 2005
I am using dynamic Pl/SQL with ProC and having problems with cursor. I've to execute stored procedure dynamically and get the result of select list into the cursor. The EXECUTE command is working fine but the FETCH gets failed with error "ORA-01002: fetch out of sequence". I've read that cursor variable can not be used with dynamic SQL.
Stored Procedure:
------------------
ROCEDURE open_mod_cur (
curs IN OUT cur_type,
module_id IN varchar2)
[Code].....
View 4 Replies
View Related
Nov 11, 2011
I am running a pro*c its working fine but my connection gets disconnect to my db server so i want to continue my proc if connection between my machine & server reestablish again weather it starts from start or from where it was stooped because of connection break
View 9 Replies
View Related
Aug 25, 2008
I Want to declare some host variables with global scope. Like this C variable:
MyFile.h
...
char str_var[20];
...
But i can't put SQL sentences in a include file. And if i do this:
MyFile.pc
...
EXEC SQL BEGIN DECLARE SECTION;
char str_var_h[20];
EXEC SQL END DECLARE SECTION;
...
... I can't see this variable from others sources, although I declare it like 'extern'.
View 1 Replies
View Related
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
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
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
Jan 24, 2011
I have to write a PL/SQL procedure, which is supposed to take an array of strings as input. This array will have simple strings as elements, like
'000887S','000780S'.
Now I have a query in the procedure, which will return a row, for each of the array elements. For example:
SELECT
su.EMPLOYEE_ID,su.FIRST_NAME,
su.LAST_NAME
FROM
USERS su,
[code]......
In the place of the '?' in the above query, the array elements have to be passed. So we will get one row from the above query for each array element.
Now we either have to loop through the array elements to fetch the result set for the above query for each array element, or we can use some other method too. Our objective is to collect all the rows of the above query for each array element as a table data and this procedure has to return this table set.
what will be the best way to pass such a set of data to the proc and best way for the proc to return this result set. Like we can use arrays, table type data,ref cursors, etc.
View 1 Replies
View Related
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
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
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
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
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
May 4, 2011
I have several forms developed in Oracle forms builder 10g version 9.0.4.0.19. It contains Hierarchical Tree items. when i run this form on this version of oracle, it's running properly. but when i compile and run it on oracle forms 10 version 10.1.2.0.2, it shows an error message stating Assertion Failed!, if I click on the Tree item. I cant find out what and where the problem is. If I build a new form with tree item, it is working properly.
View 1 Replies
View Related
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
Aug 12, 2008
Is it possible to connect with Oracle using C?
View 2 Replies
View Related
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
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
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
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
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
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
Jan 30, 2009
How to report an Oracle bug? Is there webpage or email?
View 4 Replies
View Related
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
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
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