From: Геннадий З. <zab...@gm...> - 2015-06-16 06:25:15
|
you can also add helper method "Add(FbScript scrip)" to support current ctor. On Tue, Jun 16, 2015 at 7:57 AM, Jiří Činčura <ji...@ci...> wrote: > Thinking more about it. Maybe the ctor should be only with optional FbConnection and the rest can be done via SqlStatements property. Then it's not tied to FbScript at all. > > Maybe then the FbStatementCollection can have a simple "helper" method "Add(FbStatementCollection)" (or something like that). Then it would look like: > > var batchExecution = new FbBatchExceution(); > batchExecution.Statements.Add(script.Results); //maybe rename Results > Statements??? > batchExecution.Execute(); > > Looks good to me. > > -- > Mgr. Jiří Činčura > Independent IT Specialist > >> -----Original Message----- >> From: Jiří Činčura >> Sent: Wednesday, June 10, 2015 3:36 PM >> To: fir...@li... >> Subject: FbBatchExecution >> >> Hi guys, >> >> Looking at FbBatchExecution's ctor I don't see a reason why it takes >> FbScript. It should rather be FbStatementCollection I think. The >> FbBatchExecution is doing nothing with the FbScript. It just needs >> commands. >> >> What do you think? I would add another overload to ctor and make the one >> with FbScript obsolete. >> >> -- >> Mgr. Jiří Činčura >> Independent IT Specialist > > ------------------------------------------------------------------------------ > _______________________________________________ > Firebird-net-provider mailing list > Fir...@li... > https://lists.sourceforge.net/lists/listinfo/firebird-net-provider |