on 10-21-2012 7:07 AM
Dear Experts,
I need To Schedule My JDBC Sender channel needs to run for every 5 minutes. once the channel is picking the data it needs to be stop and again starts poing after 5 min. i checked the avaliabilty times in the CC monitoring. i don't find the minutes & hours option.
plrease guide me
Regards,
pavan
hi Pavan,
If i understand your requirement, we can implement this
Include a "Flag" column in your oracle table and ask the database team to set the value to "not pulled".
Schedule your channel polling interval to 600 sec.
Include the "Flag" condition equals "not pulled" along with your 200 records in your select query.
In the Update query set the "Flag" values to "pulled".
This will insure that every time your channel will run every 10 mins and pulls only 200 records ignoring the 200 already pulled in the previous run.
Thanks
Abhishek
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
channel will not be stopped, it will wait for 10 mins to do another transaction,if you keep 600 as poll interval, the channel will process 200 records and will wait for 600 sec / 10 mins to process another 200 records.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pavan,
As Abhishek said , it would solve your problem, in your query select top 200 records with not pulled status and update top 200 records as pulled status.
regards,
baskar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI Avinash, Baskar
This Is My select query
SELECT ORDER_NO, ORDER_STRING, EMP_ID, SDEPOT_CODE, SDIVI_CODE, SORGA_CODE, COMPANY_CODE FROM (SELECT ORDER_NO, EMP_ID, ORDER_STRING, SDEPOT_CODE, SDIVI_CODE, SORGA_CODE, COMPANY_CODE, ORDER_COUNT, ORDER_STATUS FROM SAP_ORDER_SERVER WHERE ORDER_STATUS IN ('N','F') AND ORDER_COUNT<=2 ORDER BY ORDER_NO) WHERE ROWNUM <=200
&
UPDATE Query
UPDATE SAP_ORDER_SERVER SET ORDER_STATUS='P', ORDER_COUNT=NVL(ORDER_COUNT,0)+1 WHERE ORDER_STATUS IN ('N','F') AND ORDER_NO IN (SELECT ORDER_NO FROM ( SELECT * FROM SAP_ORDER_SERVER WHERE ORDER_STATUS IN ('N','F') AND ORDER_COUNT<=2 ORDER BY ORDER_NO) WHERE ORDER_COUNT<=2 AND ROWNUM <=3)
Initially the select query will pick the 200 records with ORDER_STATUS IN ('N','F'). then update query will set the flag to P.
the query is working fine.
i mentioned poll interval as 60 secs . if i mentioned 600 sec poll interval. was my cahnnel will pick 200 records & stop for 10 mins and again process 200 records & stop so on na?
because in the table daily around 30000 sales orders records will come. status of all records will be N,F by defalult. we need to pick only 200 records for very 10 mins(i.e in a single call 200 only & stop)
Please Guide me. Thanks in advanse
Pavan
Hi,
- sender JDBC channel
- "Processing" tab
- field - "poll inverval" - put 300 seconds and you're done
is that what you needed ?
Regards,
Michal Krawczyk
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Michal,
I'll explain about my requirement in breif. i have one scenario from Orcale we will pick 200 sales orders(i maintained in my query) in each record. then it has to be stop. after 10 mins it needs to start and pick the next 200 saleorders. for that i need to schedule my channel to run for every 10 mins.please help me.
Regards,
Pavan
Hi,
>>>>channels need to Pick 200 records and needs to stops for 10 Mins & agian pic another 200 records.
an idea - change the status of records in the your table to for "to be pulled" every 10 mins
and PI will only pull those that have the changed status (so every 10 mins change the status of a 200 records)
Regards,
Michal Krawczyk
User | Count |
---|---|
88 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.