Subject RE: [firebird-support] Re: Creating a stored procedure in a Delphi application
Author Clay Shannon
Luis,

<< Interesting to know you write novels. If you are also the author of
the book Developer's guide to troubleshooting, I have it. Good
reference and good help book. >>

Yep, that's me. Thanks--glad you find it useful.

My current writing project is a non-fiction work: a social history/family
history, from 1620-2006.

Clay Shannon,
Dimension 4 Software

-----Original Message-----
From: lmmolinerocasares [mailto:soporte@...]
Sent: Thursday, March 03, 2005 2:32 PM
To: firebird-support@yahoogroups.com
Subject: [firebird-support] Re: Creating a stored procedure in a Delphi
application



Clay

The very first about the problem: I investigated and the IBX component
fails (also without SET TERM), but I try with FIB+ demo and it works
fine.
Moral of the story: as you said now I have the proof that "IB and FB
are diverging like the proverbial path in the woods". Because I can
create some stored procedures with IBX but not all kind of procedures.

Interesting to know you write novels. If you are also the author of
the book Developer's guide to troubleshooting, I have it. Good
reference and good help book.

Thanks

Luis Miguel Molinero
--- In firebird-support@yahoogroups.com, "Clay Shannon"
<cshannon@d...> wrote:
> Luis,
>
> << P.D. I like Cervantes very much, I have read El Quijote twice, but I
> think this year I will be tired about that all time in the media.
> Tonight the king of Spain begins the going on and on, reading the
> first ten lines of the Quijote. Great effort!>>
>
> I wrote a novel that is somewhat like an American version of Don
Quixote. I
> can't imagine Bush reading from it, though--especially in public.
>
> Clay Shannon,
> Dimension 4 Software
>
> -----Original Message-----
> From: lmmolinerocasares [mailto:soporte@a...]
> Sent: Thursday, March 03, 2005 1:35 PM
> To: firebird-support@yahoogroups.com
> Subject: [firebird-support] Re: Creating a stored procedure in a Delphi
> application
>
>
>
> Clay
>
> You are right about the possible diferences between Interbase and
> Firebird, but until now I had no problems with IBX, so I will
> investigate, and then maybe I should buy FIB+ which I know and think
> is a really good product.
> Thanks
>
> Luis Miguel
>
> P.D. I like Cervantes very much, I have read El Quijote twice, but I
> think this year I will be tired about that all time in the media.
> Tonight the king of Spain begins the going on and on, reading the
> first ten lines of the Quijote. Great effort!
> --- In firebird-support@yahoogroups.com, "Clay Shannon"
> <cshannon@d...> wrote:
> > Luis,
> >
> > I use FIB+ components with Delphi:
> >
> > http://www.devrace.com/en/fibplus/index.php
> >
> > IBeXpress is good for Delphi and IB, but "going forward," as the
> expression
> > goes, IB and FB are diverging like the proverbial path in the woods.
> The one
> > you take may make "all the difference" (apologies to Frost) as to
which
> > components you should use.
> >
> > Personally, I create the stored procedures using Database Workbench:
> >
> > http://www.upscene.com/
> >
> > (DB WB is an awesome product that makes creating StoredProcs and
> everything
> > else practically "child's play.")
> >
> > and then use the TpFIBStoredProc component like this:
> >
> > var
> > sp: TpFIBStoredProc;
> > trans: TpFIBTransaction;
> > begin
> > sp := TpFIBStoredProc.Create(nil);
> > try
> > trans := TpFIBTransaction.Create(nil);
> > try
> > sp.Database := dm.FIBDB;
> > sp.Transaction := trans;
> > trans.DefaultDatabase := dm.FIBDB;
> > trans.Active := True;
> > sp.StoredProcName := 'P_UPDATE_PHYSICIAN';
> > sp.ParamByName('FIRSTNAME').AsString := AFirstName;
> > sp.ParamByName('LASTNAME').AsString := ALastName;
> > sp.ParamByName('ADDRESS1').AsString := AAddress1;
> > sp.ParamByName('ADDRESS2').AsString := AAddress2;
> > sp.ParamByName('CITY').AsString := ACity;
> > sp.ParamByName('STATE').AsString := AState;
> > sp.ParamByName('ZIP').AsString := AZip;
> > sp.ParamByName('PHONE1').AsString := APhone1;
> > sp.ParamByName('PHONE2').AsString := APhone2;
> > sp.ParamByName('PHYSICIAN_ID').AsInteger := APhysID;
> > try
> > sp.ExecProc;
> > trans.Commit;
> > except
> > on e: Exception do begin
> > InsertExceptionData(Application.ExeName, Application.Title,
> > e.ClassName, e.Message,
> > SysErrorMessage(GetLastError),
> GetLastError,
> > TPFIBDatabase(sp.Database));
> > trans.Rollback;
> > end;
> > end;
> > finally
> > trans.Free;
> > end;
> > finally
> > sp.Free;
> > end;
> > end;
> >
> > << Las Rozas - Madrid (Spain)>>
> > Tell Miguel Cervantes "hi" for me the next time you see him.
> >
> > Clay Shannon,
> > Dimension 4 Software
> >
> > -----Original Message-----
> > From: lmmolinerocasares [mailto:soporte@a...]
> > Sent: Thursday, March 03, 2005 11:29 AM
> > To: firebird-support@yahoogroups.com
> > Subject: [firebird-support] Creating a stored procedure in a Delphi
> > application
> >
> >
> >
> > In a Delphi application I need to update some of the objects of a
> > database in the client location, I use the standar IBExpress Delphi
> > component TIBSQL, I assign the SQL property with the command, call
> > ExecQuery, and everything is almost fine. I can add new columns to an
> > existing table, I can create new tables, new foreing keys, new
> > indexes, etc.
> > But I can't create a new stored procedure. If I include the SET TERM
> > statement I got an error message 'TERM token unknown', and of course
> > if I do not include the statement I got an error -104.
> >
> > Does anyone know how can I create a new stored procedure in Delphi?
> > Which component should I use?
> >
> > Luis Miguel Molinero
> > Las Rozas - Madrid (Spain)
> >
> >
> >
> >
> >
> >
> > Yahoo! Groups Links
>
>
>
>
>
>
> Yahoo! Groups Links






Yahoo! Groups Links