×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

SQL Database Statistics

SQL Database Statistics

SQL Database Statistics

(OP)
Hello,

    Has anyone written SQL queries to report on SQL database statistics? Like how many Sales Orders received how many sales order line items received, Purchase Orders and Purchase Order Line Item over a specific time period? These queries could get pretty involved with blankets purchase orders and invoiced sales. SQL is not my strength and would prefer to not re-invent the wheel if someone already has queries like this already.

Thank You,
Rich
 

RE: SQL Database Statistics

This will get you the order count, grouped by Order Type, in date range shown.
It queries the Consolidate OE View table, so you get open and invoiced orders.

SELECT COUNT(ord_no) AS ord_count, ord_type
FROM OEINQORD_SQL
WHERE (ord_dt >= 20120101) AND (ord_dt <= 20120531)
GROUP BY ord_type

Bart

RE: SQL Database Statistics

Orders cease to exist in the OEORDHDR_SQL table once the are fully invoiced. You'll need to query the OEINQORD_SQL table to get all orders, open, shipped or partially shipped.

SQL select queries are easy to learn, you should ask your Macola business partner or Exact regional office for about 4 hours of training on it, and you'll be good to go.

Software Sales, Training, Implementation and Support for Macola, Synergy, and Crystal Reports. Check out our Macola tools:
www.gainfocus.biz/exceladdin.html

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close