Showing posts with label excel. Show all posts
Showing posts with label excel. Show all posts

Friday, March 23, 2012

producing a date time report in SQL/DTS

I have need to produce a report (excel sheet actually) from SQL that
would run each Tuesday and each Friday of every w.
What needs to be on the Tuesday report is everything that came in from
the Friday midnight time, until the Monday midnight time. The friday
report(sheet) would have everything that came in from Midnight Monday
evening, thru midnight Thursday. The next Tuesday report would have
everything from Midnight Thursday thru midnight Monday, and so on.
I know I can schedule the jobs to run on that interval, but how do I
selectively pick the records I want? There is a datetime field on the
table, "submit date" and what I am basically doing is a select * from
tbl_literature_orders where date > x.
Any ideas?
Thanks,
BC"Blasting Cap" schrieb:
> I have need to produce a report (excel sheet actually) from SQL that
> would run each Tuesday and each Friday of every w.
> What needs to be on the Tuesday report is everything that came in from
> the Friday midnight time, until the Monday midnight time. The friday
> report(sheet) would have everything that came in from Midnight Monday
> evening, thru midnight Thursday. The next Tuesday report would have
> everything from Midnight Thursday thru midnight Monday, and so on.
> I know I can schedule the jobs to run on that interval, but how do I
> selectively pick the records I want? There is a datetime field on the
> table, "submit date" and what I am basically doing is a select * from
> tbl_literature_orders where date > x.
> Any ideas?
> Thanks,
> BC
Try it with two jobs, one for Tuesday, one for Friday, and set the execution
time of the job appropriately. Search for your data by difference:
select * from MyTable where datefield > dateadd(d, -3, GetDate()) -- Friday
and
select * from MyTable where datefield > dateadd(d, -4, GetDate()) -- Tuesday|||Just use the DATEPART() or DATENAME() functions to determine which day it
is. Then use DATEADD() with the appropriate days to get the from and to
that you need for your WHERE clause.
Andrew J. Kelly SQL MVP
"Blasting Cap" <goober@.christian.net> wrote in message
news:eiUP1w9CGHA.4080@.TK2MSFTNGP09.phx.gbl...
>I have need to produce a report (excel sheet actually) from SQL that would
>run each Tuesday and each Friday of every w.
> What needs to be on the Tuesday report is everything that came in from the
> Friday midnight time, until the Monday midnight time. The friday
> report(sheet) would have everything that came in from Midnight Monday
> evening, thru midnight Thursday. The next Tuesday report would have
> everything from Midnight Thursday thru midnight Monday, and so on.
> I know I can schedule the jobs to run on that interval, but how do I
> selectively pick the records I want? There is a datetime field on the
> table, "submit date" and what I am basically doing is a select * from
> tbl_literature_orders where date > x.
> Any ideas?
> Thanks,
> BCsql

Friday, March 9, 2012

Processed Date for a Cube

Hi

I want to be able to display to the users the date/time a cube was last processed. We have SSAS 2005 and presenting the cube through Excel 2003 (with the SSAS 9 OLAP driver).

Thanks

LastProcessed is a property on the object avaliable only through AMO. Dont think Excel will show you this property.

You can possible wirte a AMO code yourself and use Excel programming model to show it.

Another way is to create a dimension with a single memeber based on the column in the relational database where you would keep the current date and during processing you update this dimension to pickup a new value.

Edward.
--
This posting is provided "AS IS" with no warranties, and confers no rights.

|||

Thanks for the suggestions.

I created a table with the current date and use this.

Wednesday, March 7, 2012

Process Multiple Reports at once?

I have a project that has 10 reports that I need to schedule in various
combinations with different parameters on 5 different schedules, excel output
to a file server. Possibly up to 170 different reports a day so regular
subscription set up would be a nightmare to maintain. I have looked at
Data-Driven subscriptions however what I need is different report
combinations generated not different variations of one report. Something like
this:
Schedule 1
Package 1
Reports A, B, C, D, G (All use same data parameters)
Output to Folder 1
Package 2
Reports B, C, D, E, F
Output to Folder 2
Schedule 2
Package 1...etc.
Is there a way to accomplish this with SSRS, SSIS or SOAP (which I know nada
about) - What is the best process? Subreports are not viable since the
worksheet names cannot be set. (Using 2005)
Any suggestions appreciated.
--
ABNo ideas anyone? Must be asking the impossible :)
--
Allison
"allison" wrote:
> I have a project that has 10 reports that I need to schedule in various
> combinations with different parameters on 5 different schedules, excel output
> to a file server. Possibly up to 170 different reports a day so regular
> subscription set up would be a nightmare to maintain. I have looked at
> Data-Driven subscriptions however what I need is different report
> combinations generated not different variations of one report. Something like
> this:
> Schedule 1
> Package 1
> Reports A, B, C, D, G (All use same data parameters)
> Output to Folder 1
> Package 2
> Reports B, C, D, E, F
> Output to Folder 2
> Schedule 2
> Package 1...etc.
> Is there a way to accomplish this with SSRS, SSIS or SOAP (which I know nada
> about) - What is the best process? Subreports are not viable since the
> worksheet names cannot be set. (Using 2005)
> Any suggestions appreciated.
> --
> AB|||You could do it from within a programming environment... but I don't
believe this is possible within the standard portal.|||I need to do something similar...
I know that I've done this sort of thing with Active Reports and Crystal
Reports. When you create 1 report, then a second report, and want to stitch
them together and render as 1 PDF... I haven't come across anything that
pops out in the documentation for RS 2000 that can allow me to do this so
far. Should I be looking at 2005 to accomplish this or is 2000 sufficient?
"toddnappi@.gmail.com" wrote:
> You could do it from within a programming environment... but I don't
> believe this is possible within the standard portal.
>