From: Mike A. <mik...@us...> - 2010-09-21 06:28:44
|
Update of /cvsroot/aubit4gl/aubit4glsrc/compilers/ace In directory sfp-cvsdas-4.v30.ch3.sourceforge.com:/tmp/cvs-serv8385/compilers/ace Modified Files: a4gl_ace_int.h ace.yacc data.c Log Message: . Index: a4gl_ace_int.h =================================================================== RCS file: /cvsroot/aubit4gl/aubit4glsrc/compilers/ace/a4gl_ace_int.h,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** a4gl_ace_int.h 10 Sep 2010 18:49:03 -0000 1.14 --- a4gl_ace_int.h 21 Sep 2010 06:28:36 -0000 1.15 *************** *** 24,28 **** void add_inputs (char *prompt, char *variable); void add_function (char *name); ! void add_select (char *sql, char *sql_no_where, char *temptabname,char *into_portion); void execute_selects (void); void print_lexpr (struct expr_list *l); --- 24,28 ---- void add_inputs (char *prompt, char *variable); void add_function (char *name); ! void add_select (char *sql, char *sql_no_where, char *temptabname,char *into_portion,char *group_by_portion); void execute_selects (void); void print_lexpr (struct expr_list *l); Index: ace.yacc =================================================================== RCS file: /cvsroot/aubit4gl/aubit4glsrc/compilers/ace/ace.yacc,v retrieving revision 1.62 retrieving revision 1.63 diff -C2 -d -r1.62 -r1.63 *** ace.yacc 10 Sep 2010 18:49:03 -0000 1.62 --- ace.yacc 21 Sep 2010 06:28:36 -0000 1.63 *************** *** 807,813 **** { char buff[100000]; ! SPRINTF5(buff,"%s %s %s %s %s",$<str>1,$<str>3,$<str>4,$<str>5,$<str>7); SPRINTF9($<str>$,"%s %s %s %s %s %s %s %s %s",$<str>1,$<str>3,$<str>4,$<str>5,$<str>6,$<str>7,$<str>8,$<str>9,$<str>10); ! add_select($<str>$,buff, temp_tab_name,$<str>10); } ; --- 807,813 ---- { char buff[100000]; ! SPRINTF4(buff,"%s %s %s %s",$<str>1,$<str>3,$<str>4,$<str>5); SPRINTF9($<str>$,"%s %s %s %s %s %s %s %s %s",$<str>1,$<str>3,$<str>4,$<str>5,$<str>6,$<str>7,$<str>8,$<str>9,$<str>10); ! add_select($<str>$,buff, temp_tab_name,$<str>10,$<str>7); } ; Index: data.c =================================================================== RCS file: /cvsroot/aubit4gl/aubit4glsrc/compilers/ace/data.c,v retrieving revision 1.51 retrieving revision 1.52 diff -C2 -d -r1.51 -r1.52 *** data.c 10 Sep 2010 18:49:03 -0000 1.51 --- data.c 21 Sep 2010 06:28:36 -0000 1.52 *************** *** 340,344 **** */ void ! add_select (char *sql, char *sql_no_where, char *temptabname, char*into_portion) { struct select_stmts *ptr; --- 340,344 ---- */ void ! add_select (char *sql, char *sql_no_where, char *temptabname, char*into_portion,char *group_by_portion) { struct select_stmts *ptr; *************** *** 389,392 **** --- 389,393 ---- ptr->whereless_statement.select_portion=acl_strdup(sql_no_where); ptr->whereless_statement.into_portion=acl_strdup(into_portion); + ptr->whereless_statement.group_by_portion=acl_strdup(group_by_portion); buff = acl_strdup (sql); *************** *** 554,558 **** buff = acl_malloc2 (strlen (ptr->whereless_statement.select_portion) + 200); /* We need a little extra space... */ ! sprintf(buff,"%s WHERE (1=0) %s", ptr->whereless_statement.select_portion, ptr->whereless_statement.into_portion); for (a=0;a<strlen(buff);a++) { --- 555,559 ---- buff = acl_malloc2 (strlen (ptr->whereless_statement.select_portion) + 200); /* We need a little extra space... */ ! sprintf(buff,"%s WHERE (1=0) %s %s", ptr->whereless_statement.select_portion, ptr->whereless_statement.group_by_portion, ptr->whereless_statement.into_portion); for (a=0;a<strlen(buff);a++) { |