473,738 Members | 9,555 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Pro*C and nested tables compiler error

1 New Member
Hello,

I'm attempting to use Pro*C to create a nested table and send that data
to a stored procedure as a parameter. However, I'm getting a Pro*C compiler
error that I'll describe below. I'm using Oracle 10.2 on Unix.

1. First I created a nested table type in the database:

CREATE TYPE varchar2_list AS TABLE OF VARCHAR2(15);
2. Then I created the input file for "ott", called "acttest.ty p":

CASE=LOWER
TYPE activity.varcha r2_list

3. Next I used "ott" to generate the header file needed in my .pc file:

ott userid=[user]/[pass]@[tns_name] intype=acttest. typ outtype=out.typ code=c hfile=acttype.h

This command was successful.

4. Then I attempted to declare a variable of type "varchar2_l ist" in my source file, "acttest.pc ":

#include <sqlca.h>
#include "acttype.h"
...
EXEC SQL BEGIN DECLARE SECTION;
...
varchar2_list *vclProductCode List;
...
EXEC SQL END DECLARE SECTION;

When I compile with "proc", I get the following compiler error:

Syntax error at line 894, column 7, file acttest.pc:
Error at line 894, column 7 in file acttest.pc
varchar2_list *vclProductCode List;
......1
PCC-S-02201, Encountered the symbol "varchar2_l ist" when expecting one of the fo
llowing:

auto, char, const, double, enum, extern, float, int, long,
ulong_varchar, OCIBFileLocator OCIBlobLocator,
OCIClobLocator, OCIDateTime, OCIExtProcConte xt, OCIInterval,
OCIRowid, OCIDate, OCINumber, OCIRaw, OCIString, register,
short, signed, sql_context, sql_cursor, static, struct,
typedef, union, unsigned, utext, uvarchar, varchar, void,
volatile, a typedef name, a precompiled header, exec oracle,
exec oracle begin, exec, exec sql, exec sql begin,
exec sql end, exec sql type, exec sql var, exec sql include,
The symbol "enum," was substituted for "varchar2_l ist" to continue.

Why can't Pro*C recognize my new "varchar2_l ist" type? Does it matter if the DB user used in the Pro*C application doesn't own the nested table object? I have included my command line:

proc code=cpp sys_include='(/opt/SUNWspro/prod/include/CC,/opt/SUNWspro/prod/include/CC4,/usr/include,/u01/app/oracle/product/10.2.0/rdbms/public,.)' sqlcheck=semant ics userid=[user]/[password]@[tns] include='(/u01/app/oracle/product/10.2.0/rdbms/public,.)' intype=out.typ acttest.pc

Thanks in advance for any helpful information.
Jun 19 '07 #1
0 1510

Sign in to post your reply or Sign up for a free account.

Similar topics

2
3655
by: Robert M. Gary | last post by:
I'm curious what the ANSI C++ standard says about nested classes. I'm not able to find where in the ANSI C++ standard this is addressed. The issue is the accessibility of sibling nested classes. Example... class A{ private: class B{ }; class C{
8
3944
by: CoolPint | last post by:
I read in books that nested class cannot access private members of nesting class and vice versa unless they are made friends. Somehow, my compiler is letting my nested class member functions access private members of nesting class. template <typename T> class Container { // NO friendship given to any other public: class ContainerIterator;
10
3241
by: nimmi_srivastav | last post by:
Below you will see an example of a nested conditional expression that this colleague of mine loves. He claims that it is more efficient that a multi-level if-else-if structure. Moreover, our complexity analyzer tool supposedly does not pick it up. Is it really more efficient? Personally I find this coding style extremely cryptic, misleading and error-prone. I believe that I have removed all traces of proprietary-ness from this coding...
3
1321
by: Luis Diego Fallas | last post by:
Hi everyone , I'm having a problem when trying to compile code that contains the following pattern: using System; public class A { public class B : Inn.C { }
17
3033
by: Peter Olcott | last post by:
http://www.tommti-systems.de/go.html?http://www.tommti-systems.de/main-Dateien/reviews/languages/benchmarks.html Why is C# 500% slower than C++ on Nested Loops ??? Will this problem be solved in the future???
1
2078
by: Thu | last post by:
Hi, I create a Dataset to link three tables in my Access database. E.g. The three tables are , , . I then create 2 DataRelations, 1st relation (Order_Cust_Rel) links and using CustomerID field that exists in both tables and 2nd relation (Order_Product_Rel) links and using ProductID field. I set the nested property of the relations to True so that the output will be nested. I then use WriteXML to output the dataset to a StreamWriter.
4
3019
by: rach | last post by:
I just started to learn C++. I copied the following code from a data structure textbook to a ".h" file and couldn't compile it. The code contains three template interfaces. One inherits another. The functions in the interfaces are defined in book, while the nested-class part is added by me. The reason is that if I don't declare a nested class, say Position, how could it be passed as arguments to those defined functions? However, it seems that...
0
2090
by: rupalirane07 | last post by:
Both grids displays fine. But the problem is only parent datagrid sorting works fine but when i clik on child datagrid for sorting it gives me error: NullReferenceException error Any help........pls urgent ========================================================= <%@ Page Language="vb" AutoEventWireup="false" Codebehind="WebForm3.aspx.vb" Inherits="TestDatagrids.WebForm3"%> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">...
3
3882
by: jdurancomas | last post by:
Dear all, I'm trying to declare the operator++ to a nested class. The nested class is not template but the container it is. The code used in teh sample program is included bellow: #include <iostream>
0
8969
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9335
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9263
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
6053
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4570
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4825
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3279
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2745
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2193
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.