Results 1 to 10 of 10
  1. #1
    Join Date
    Feb 2004
    Posts
    193

    Unanswered: How do you automate reports in SQL Server?

    Is there a way to generate reports every 15 minutes for example?

    ddave

  2. #2
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    Schedule a job to call a sproc that executes a bcp out?

    Or schedule a DTS job?
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  3. #3
    Join Date
    Feb 2004
    Posts
    193
    Damn, you're fast. Don't you have a job?

    Just kidding. Thanks again. I thought it may be through DTS. I will set coordinates and start heading that way. Da ta dahhhh(Star Trek theme song).

    ddave

  4. #4
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    You still have to execute the DTS package with a Job...
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  5. #5
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    Generate what kind of reports? Are you talking something done with Reporting Services, Crystal, brute force text files, or something completely different?

    -PatP

  6. #6
    Join Date
    Feb 2004
    Posts
    193
    I am still gathering info on the type of reports. I am looking as some print outs from my manager and it acutally looks like they imported data into Access and used Access to format the reports.

    ddave

  7. #7
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    Originally posted by Pat Phelan
    brute force text files
    -PatP
    Lot to be said for that....

    DTS for Excel?
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  8. #8
    Join Date
    Feb 2004
    Location
    San Antonio, TX
    Posts
    565
    I know this doesnt have anything to do with scheduling but just the same
    FYI:::: SQL Has some interesting reporting operators (used with group by) I dont think to use them often but they are relatively funky anyway.
    with ROLLUP(the nulls indicate the column not being summarized)
    use Northwind
    select orderid , productid, sum(unitprice)
    from [order details]
    group by orderid , productid
    with rollup


    with CUBE like ROLLUP but summarizes the other columns in the grouping.... nulls indicate the column not being summarized)
    Use Northwind
    select orderid ,productid , sum(unitprice)
    from [order details]
    group by orderid , productid
    With Cube
    order by Orderid , productid

    Grouping(if you contain nulls, you can use the programmatic inclusion of 1's and 0's to search through.... the column that is summarized contains a 0 in it's grouping column)
    Use Northwind
    select
    orderid, Grouping(orderid) ,productid
    ,grouping(productid), sum(unitprice)as total
    from [order details]
    group by orderid , productid
    With Cube
    order by Orderid , productid

    Compute [by] computes based on the columns indicated in the compute clause and groups based on the [by] argument
    select
    orderid,productid, unitprice
    from [order details]
    --group by orderid , productid
    order by orderid , productid
    compute sum(unitprice) by orderid , productid
    compute sum(unitprice)


  9. #9
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    Originally posted by dolfandave
    I am still gathering info on the type of reports. I am looking as some print outs from my manager and it acutally looks like they imported data into Access and used Access to format the reports.

    ddave
    Ok, before I start I'll give you that this idea is hokey almost beyond belief, but it does work. Create an MDB that contains the report that you want to run, then create an AutoExec macro to run that report then exit from Access. Schedule a job with SQL Agent to launch the MDB file at whatever interval you choose, and voilá

    -PatP

  10. #10
    Join Date
    Feb 2004
    Posts
    193
    I agree it is an arcane process but my boss and her contacts all seem technically challenged. I am sure this type of stuff happens often.

    ddave

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •