🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.dbexpress
Article #17

creating 2 storedprocs

#17
From: Alex Liu
Date: Wed, 28 Dec 2005 02:06
28 lines
1662 bytes
Hi,

I want to create 2 store proc at run-time using TSQLStoredProc and found 
something "interesting":

[CASE 1]
TSQLStoredProc *sp_A, *sp_B;
sp_A = new TSQLStoredProc(App->mainform);
sp_A->SQLConnection = my_SQL_Conn;
sp_A->StoredProcName = "Proc_A";
sp_B = new TSQLStoredProc(App->mainform);
sp_B->SQLConnection = my_SQL_Conn;            <== EA occurs here
sp_B->StoredProcName = "Proc_B";

[CASE 2]
TSQLStoredProc *sp_A, *sp_B;
sp_A = new TSQLStoredProc(App->mainform);
sp_B = new TSQLStoredProc(App->mainform);
sp_A->SQLConnection = my_SQL_Conn;
sp_B->SQLConnection = my_SQL_Conn;
sp_A->StoredProcName = "Proc_A";
sp_B->StoredProcName = "Proc_B";
// OK no EA

I dont know why it is so... any idea please?
should i HAVE to use implementation of case 2?

Thanks in advance. 
Technical Details
Message-ID: <43b1f2e8@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news2.google.com!proxad.net!212.101.4.254.MISMATCH!solnet.ch!solnet.ch!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: fb4e2,e82171cb8f6636e2,start
X-Google-Attributes: gidfb4e2,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Alex Liu" <alexliu@hket.com>
Newsgroups: borland.public.cppbuilder.database.dbexpress
Subject: creating 2 storedprocs
Date: Wed, 28 Dec 2005 10:06:03 +0800
Lines: 30
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
NNTP-Posting-Host: 218.189.206.62
Message-ID: <43b1f2e8@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1135735528 218.189.206.62 (27 Dec 2005 18:05:28 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news2.google.com!proxad.net!212.101.4.254.MISMATCH!solnet.ch!solnet.ch!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail