Pro*C对inner join的支持情况
整理自:http://forums.oracle.com/forums/thread.jspa?threadID=664180&tstart=0
问:Is it possible to use INNER JOIN's with Pro*C? I'm currently getting this error:
INNER JOIN t_diagnosis b ON a.sak_diag = b.sak_diag
....1
PCC-S-02201, Encountered the symbol "INNER" when expecting one of the following:
; , for, union, connect, group, having, intersect, minus,
order, start, where, with,
The query runs fine via SQL Developer. My version of Pro*C is Pro*C/C++: Release 10.2.0.3.0.
Thanks,
Matthew
答:
Unfortunately the Pro*C precompiler does not understand "new"
syntax/keywords... this falls into the same category as using analytics
discussed here:
http://forums.oracle.com/forums/thread.jspa?threadID=664180&tstart=0
You would need to use dynamic sql as described in the programmer's guide to do this.
Support for all the ANSI 99 sql syntax (including joins) has been added
in 11g
w
ith
the new precompiler option common_parser. You can
precompile your proc program containig join sqls as follows:
proc common_parser=yes
proc_file.pc
For release 10.2 and earlier you would to workaround by using dynamic sqls as Mark suggested.
相关文档:
http://www.100gps.com/html/index.html 。 地图是上海 ,说明上一次定位是在上海, 或者是上海的某个强人做的 地图,正版的 凯立德第一次用, 地图应该是在深圳 c地图,你可以在功能——系统——GPS参数里面,设置端口, 一般都是com2或者是com4,波特率基本都是4800,然后你再试试能定位吗! 不行, ......
1) 什么是预编译,何时需要预编译:总是使用不经常改动的大型代码体。
程序由多个模块组成,所有模块都使用一组标准的包含文件和相同的编译选项。在这种情况下,可以将所有包含文件预编译为一个预编译头。
2) char * const p;
char const * p
const char *p ......
大家都知道在Unix/Linux中有个man命令,可以查询常用的命令,函数。可是对于我们这样只知道用"man 函数名"来查询的人来说,会遇到很多问题,比如:
man read,我想看的是ANSI C中stdio的read函数原型和说明,没想到出来的确是BASH命令的说明,这是怎么回事 ......
#include <stdio.h>
#include <stdlib.h>
#include <syslog.h>
#include <signal.h>
#include <unistd.h>
#include <string.h>
#include <getopt.h>
#define MAX_READFILE 24
#define MAX_INPUTFILE 10240
char *file ;
void time_out(){
syslog(LOG_INFO,"read inp ......