Re: SPL problem
Posted in 1999
Hi,
The error message is missleading. Change the line
> insert into mytable ( p_pro_ref, TODAY );to
> insert into mytable values ( p_pro_ref, TODAY );
Of course another problem would be that you are running the sql script
from isql (not dbaccess).
Best Regards,
Octav
On Mon, Sep 27, 1999 at 03:49:01PM +0100, Surfer! wrote:
>
> Can anyone point out the undoubtedly silly mistake in the following code
> snippet. 'mytable' was created correctly:
>
> =======================================================================
> create table mytable(
> pro_ref char( 16 ),
> app_reg_no integer,
> total_pts integer,
> local_pts integer );>
>
> create procedure upd_prop(
> p_pro_ref like property.pro_ref,
> p_stat like property.stat,
> p_fut_st like property.fut_st )>
> delete from mytable where pro_ref = p_pro_ref;> # ^
> # 201: A syntax error has occurred.
> #
>
> if ( p_stat = "2" and p_fut_st is NULL )
> or p_fut_st = "4" then
> insert into mytable ( p_pro_ref, TODAY );> end if
> end procedure
> ========================================================================
>
> TIA!
>
> --
> Surfer!
--
Octav Chiriac Phone: (373) 2 22 99 67
NetInfo S.R.L. Fax: (373) 2 21 36 59
Chisinau (373) 2 22 84 88
Moldova, Republic of mailto:com@netinfo-moldova.com