Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 513
  • Last Modified:

Count of rows being inserted per minute

Hi Gurus,

I'm trying to get the countof rows inserted in per minute while data load is happening. Please help.
Count-of-rows-per-min.sql
0
loginboy
Asked:
loginboy
1 Solution
 
slightwv (䄆 Netminder) Commented:
>>while data load is happening.

What is loading the data?
If it isn't committing then you will be unable to query the table while some other process is loading the data.

Based on the test sample you provided:  What are your expected results?

First guess is something like this should count and group by the minute:
select to_char(ins_dt,'MM/DD/YYYY HH24:MI'), count(*) from test_tab group by to_char(ins_dt,'MM/DD/YYYY HH24:MI');
0
 
Gerwin Jansen, EE MVETopic Advisor Commented:
If the table has a date field, just count the number of rows per minute (see above suggestion).

If table is not having a date field, you could write a trigger 'before insert' that is updating a counter in another table for each minute. What are you after exactly?
0
 
loginboyAuthor Commented:
Perfect. Sorry for the delayed update!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now