none
WCF Oracle DB Adapter Polling

    Question

  • Hi there,

    I am using pollingstatement and set pollinginterval in 3 seconds. When restart intances the process excute interval less than 3 seconds. But after polling several times is normal(pollinginterval back to 3 seconds). Why?

    Any advise.

    Regards.

     

    Tuesday, January 4, 2011 1:27 PM

All replies

  • Hi,

    You can read in detail on polling in this post (section what's going on).

    HTH

    Regards,

    Steef-Jan Wiggers
    MVP & MCTS BizTalk Server
    http://soa-thoughts.blogspot.com/
    If this answers your question please mark it accordingly


    BizTalk
    Tuesday, January 4, 2011 8:37 PM
    Moderator
  • Thanks for your reply,

    I have another question. I want to retrieve data from oracle db and update flag to  these data. Can you tell me how to do this? Any sample?

     

    Regards.

    Wednesday, January 5, 2011 9:57 AM
  • Hi

    use stored procedure to retrieve rows from Oracle/SQL

    in the same procedure you can update that rows as retrived

     

    But I will suggest also to retrive rows (update status to processing)in the same proc, complete manipulations in orchestration

    and then call another procedure from orchestration which will update status for retried rows and set to processed if orchetration was successfull

    otherwise set status of rows to failed or inquery

    you will need to add one extra column in your table for status


    Please mark this as answer if it helps.
    Microsoft Certified Trainer
    Microsoft Certified Professional Developer
    BizTalk blog: http://www.EnterpriseApplicationsDevelopment.com/
    Wednesday, January 5, 2011 10:08 AM
  • Hi Yuan,

    You can do an update in PostPollStatement, for reference see Polling Oracle Database Using Stored Procedures, Functions, or Packaged Procedures and Functions . PostPollStatement specifies a statement block that is executed after the statement specified by the PollingStatement binding property is executed. So in polling you have something like select * from tablename where flag = ‘R’ for update and post poll update tablename set flag = ‘P’.

    HTH

    Regards,

    Steef-Jan Wiggers
    MVP & MCTS BizTalk Server
    http://soa-thoughts.blogspot.com/
    If this answers your question please mark it accordingly


    BizTalk
    Wednesday, January 5, 2011 10:09 AM
    Moderator
  • Thanks for reply,

    I have one question about PollingStatement and PostPollStatement . For example, PollingStatement like "select * from tablename where flag = 'R' return 10 records. When excute PostPollStatement like "update tablename set flag = 'P' where flag = 'R'"  suppose flag = 'R' return 12 records. I may update wrong records. Could you tell me how to avoid this problem? Where can find samples about this?

    Regards.

     

    Thursday, January 6, 2011 2:08 AM
  • I am waiting for an answer to my question.

    Please help me.

    Thursday, January 13, 2011 5:48 AM
  • Hi,

    If a post-poll statement is specified, PollingInterval should be set large enough for the PL/SQL block to complete before the interval expires. This could prevent the problem you are experiencing. Setting PollingInterval to small than the update could be result of more previous polling. Samples for polling with BizTalk Oracle DB Adapter, see Microsoft BizTalk Adapter Pack Samples (section Oracle).

    HTH

    Regards,

    Steef-Jan Wiggers
    MVP & MCTS BizTalk Server
    http://soa-thoughts.blogspot.com/
    If this answers your question please mark it accordingly


    BizTalk
    Thursday, January 13, 2011 7:18 AM
    Moderator
  • Thanks for your reply,

    If I do not misunderstand what you mean. PostPollStatement will not update wrong record. Examples are as follows:

    When execute pollingStatement : select * from abc where Flag = 'N'           In this moment will return 3 records.

    Table abc

    field name

    ID           Flag

    1             N

    2             N

    3             N

    4             R

    5             R

     

    When execute postPollStatement : update tablename set flag = 'P' where flag = 'N'       In this moment, if Table abc data changed.

    Table abc

    Before execute postPollStatement                                                After execute postPollStatement

    field name                                                                                 field name

    ID           Flag                                                                            ID           Flag

    1             N                                                                                1             P

    2             N                                                                                2             P

    3             N                                                                                3             P

    4             N                                                                                4             N

    5             N                                                                                5             N

     

    Is it correct?



    Thursday, January 13, 2011 8:12 AM
  • Old post but need to have details about last question...has anyone already experienced that ?

    Does PostPollStatement update is correlated to select for update request ? What about new rows inserted after PollingStatement and before PostPollStatement ?


    Christophe BRANDO...If this answers your question, please Mark as the Answer. If this post is helpful, please vote as helpful.

    Monday, July 16, 2012 3:41 PM