Re: BizTalk 2004 :: Fact retriever :: more than 1 data connection? How?

Tech-Archive recommends: Fix windows errors by optimizing your registry




Matt,

Ha ha, I wrote out the very same code you mentioned below and scrubbed it.

I thought "no way its just the assert statement that the engine cares about"

So, in truth, it then is the assert statement which activates the facts

Thanks for the other options. I'm quite new to this so I want to sample a
few things so I can test performance.

BA


"Matt Milner" <matt.milner@m3technologypartners dot com> wrote in message
news:uL9TG9uWFHA.3320@xxxxxxxxxxxxxxxxxxxxxxx
> Simply create and assert more than one dataconnection. If you are using
> the same database, you can reuse the SqlConnection like so:
>
> DataConnection dc1 =
>> new DataConnection("foo", "fum", con1);
>> Dataconnection dc2 = new DataConnection("bar", "bum", con1);
>> engine.Assert(dc1);
> engine.Assert(dc2);
>
> It is not the return value that gets entered intot the engine for
> execution, the factsHandleOut is your handle to know whether to refresh
> the facts. This is a little confusing, I know and it is a shame that most
> samples show the connection being handed back.
>
> You can also create another sql connection, wrap it with the second data
> connection and assert that. Similarly, if you are asserting
> datatable/datarow facts, you can use the sql connection to retrieve those
> and assert them.
>
> Matt
>
>
>
> "BA" <biztalk.architect@xxxxxxxxx> wrote in message
> news:1116329399.521056.291710@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
>> Hello,
>>
>> In the code below you set a single data connection for a single DB
>> table.
>>
>> I have many data connections to add, how do you extend this sample to
>> add more than 1 data connection?
>> public class DbFactRetriever : IFactRetriever
>> {
>>
>> public object UpdateFacts(RuleSetInfo rulesetInfo,
>> Microsoft.RuleEngine.RuleEngine engine,
>> object factsHandleIn)
>>
>> {
>> object factsHandleOut;
>>
>> SqlConnection con1 = new
>> SqlConnection("Initial Catalog=foo;
>> Data Source=(local);Integrated Security=SSPI;");
>>
>> DataConnection dc1 =
>> new DataConnection("foo", "fum", con1);
>>
>> engine.Assert(dc1);
>> factsHandleOut = dc1;
>> }
>> return factsHandleOut;
>> }
>>
>>
>> I'm still learning C# so any help would be greatly appreciated.
>>
>> Thanks!
>>
>> BA
>>
>
>


.



Relevant Pages

  • Re: Adacrypt.com - Article
    ... operational for Clifford to assert it. ... They are fining via aware, ... in connection with gigantic wheats. ...
    (sci.crypt)
  • Re: BizTalk 2004 :: Fact retriever :: more than 1 data connection? How?
    ... Simply create and assert more than one dataconnection. ... DataConnection dc1 = ... You can also create another sql connection, wrap it with the second data ... > In the code below you set a single data connection for a single DB ...
    (microsoft.public.biztalk.general)
  • Re: Socket write behaviour is inconsistent?
    ... copy 1 byte to buffer, copy many bytes to buffer, copy one byte to ... You can assert that you've provided enough information 'til the cows come home, but as long as a person trying to answer the question tells you that you haven't provided enough information, you haven't. ... I have assumed in my reply that when you write "client" you are talking about your own code and when you write "host" you are talking about the remote endpoint for your connection. ... You would be able to write a small test application that acts as the specific hardware does, for the purpose of providing test code to work with. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Linux community software-update-anarchy polemic
    ... The statement "the RAMdisk connection is axiomatically reliable" ... systems are commonly presumed reliable (that is, their reliability is ... already assert the reliability of the cpuRAM connection, ... You should not trust me or my advice on technical matters or any other ...
    (comp.os.linux.misc)
  • Re: Part 2 of Short Steps Toward Generic Programming: Specification Assertions
    ... case where the procedure is external, the ASSERT statement could ... > a compile-time error for a particular call to match zero interfaces ... can the programmer be sure he's ...
    (comp.lang.fortran)