Hi everybody.
I have one dataset with parameter 'UserID' and second Dataset which fill
UserID parameter. When i run my report i can choose value from second
Dataset, but i wont that in my Parameter will be present value as 'All' which
mean all records from query. It is possible? if yes how? any sample?
P.S.
I know how add this value but i don't know how to write my query.
Thank you.Hello Dmitri,
Here is how to write the query to have 'All' included in your list of
users:
SELECT UserNo, UserName FROM Users
UNION
SELECT -1, 'All'
Take care,
Michelle|||Hi,
SELECT col1,col2,...
FROM table1
where col1 = CASE WHEN @.Param = 'All' THEN col1
ELSE @.Param
END
Eric|||oops, I forgot the second half - to check for the 'All' in your second
query:
SELECT something1, something2
FROM someTable
WHERE (User = @.User OR @.User = 'All')
or
SELECT something1, something2
FROM someTable
WHERE (UserNo = @.UserNo OR @.UserNo = -1)
Michelle|||Hi,
select col1,col2,col3
from table1
where col1 = case when @.param = 'all' then col1
else @.param
end
hth,
Eric|||Thank you all.
"Aiwa" wrote:
> Hi,
> select col1,col2,col3
> from table1
> where col1 = case when @.param = 'all' then col1
> else @.param
> end
> hth,
> Eric
>
Showing posts with label second. Show all posts
Showing posts with label second. Show all posts
Friday, March 30, 2012
Monday, March 26, 2012
Report on successful sql logins
Looking for how to create a report for sql'05 to see who's logging in succes
fully and then failed user logins as well perhaps on a second report.
Is there a way to capture logins historically with just sql server? How do
you set this up? Could someone point me in the right direction or, possibly
an example?
ThanksGo to Server Properties, Security tab, Login auditing. Login information
will be written to SQL Server Log and Windows Event Viewer.
Ben Nevarez, MCDBA, OCP
Database Administrator
"James Wuerflein" wrote:
> Looking for how to create a report for sql'05 to see who's logging in succ
esfully and then failed user logins as well perhaps on a second report.
> Is there a way to capture logins historically with just sql server? How d
o you set this up? Could someone point me in the right direction or, possib
ly an example?
> Thanks
>|||What an easy way to take that an create a report forthose logins that I coul
d give to management?
Thanks
Go to Server Properties, Security tab, Login auditing. Login information
will be written to SQL Server Log and Windows Event Viewer.
Ben Nevarez, MCDBA, OCP
Database Administrator
"James Wuerflein" wrote:
[vbcol=seagreen]
> Looking for how to create a report for sql'05 to see who's logging in succ
esfully and then failed user logins as well perhaps on a second report.
>
> Is there a way to capture logins historically with just sql server? How d
o you set this up? Could someone point me in the right direction or, possib
ly an example?
>
> Thanks
>
fully and then failed user logins as well perhaps on a second report.
Is there a way to capture logins historically with just sql server? How do
you set this up? Could someone point me in the right direction or, possibly
an example?
ThanksGo to Server Properties, Security tab, Login auditing. Login information
will be written to SQL Server Log and Windows Event Viewer.
Ben Nevarez, MCDBA, OCP
Database Administrator
"James Wuerflein" wrote:
> Looking for how to create a report for sql'05 to see who's logging in succ
esfully and then failed user logins as well perhaps on a second report.
> Is there a way to capture logins historically with just sql server? How d
o you set this up? Could someone point me in the right direction or, possib
ly an example?
> Thanks
>|||What an easy way to take that an create a report forthose logins that I coul
d give to management?
Thanks
Go to Server Properties, Security tab, Login auditing. Login information
will be written to SQL Server Log and Windows Event Viewer.
Ben Nevarez, MCDBA, OCP
Database Administrator
"James Wuerflein" wrote:
[vbcol=seagreen]
> Looking for how to create a report for sql'05 to see who's logging in succ
esfully and then failed user logins as well perhaps on a second report.
>
> Is there a way to capture logins historically with just sql server? How d
o you set this up? Could someone point me in the right direction or, possib
ly an example?
>
> Thanks
>
Wednesday, March 7, 2012
Report item not linked to a dataset
I have a need to add a text box to a report. The text box will have an
expression that I need to have that captues the value of a field from a
second data set associated with the report. I add a text box but in the edit
expresssion process I can't access any fields (from any data set) and i get
the message Report item not linked to a dataset. I'm not trying to add a new
table or anything like that. I just want to be able to grab that field value
and disply.
--
Thanks, JimOn Sep 21, 11:38 am, Jim B <J...@.lightning.com> wrote:
> I have a need to add a text box to a report. The text box will have an
> expression that I need to have that captues the value of a field from a
> second data set associated with the report. I add a text box but in the edit
> expresssion process I can't access any fields (from any data set) and i get
> the message Report item not linked to a dataset. I'm not trying to add a new
> table or anything like that. I just want to be able to grab that field value
> and disply.
> --
> Thanks, Jim
If I'm understanding you correctly, you should be able to reference a
dataset via an aggregate expression. Something like this should work.
=Max(Fields!SomeFieldName.Value, "SomeDatasetName")
Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant|||That's exactly what I needed to know. Thanks for your response to my question.
--
Thanks, Jim
"EMartinez" wrote:
> On Sep 21, 11:38 am, Jim B <J...@.lightning.com> wrote:
> > I have a need to add a text box to a report. The text box will have an
> > expression that I need to have that captues the value of a field from a
> > second data set associated with the report. I add a text box but in the edit
> > expresssion process I can't access any fields (from any data set) and i get
> > the message Report item not linked to a dataset. I'm not trying to add a new
> > table or anything like that. I just want to be able to grab that field value
> > and disply.
> > --
> > Thanks, Jim
>
> If I'm understanding you correctly, you should be able to reference a
> dataset via an aggregate expression. Something like this should work.
> =Max(Fields!SomeFieldName.Value, "SomeDatasetName")
> Hope this helps.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||On Sep 23, 9:20 am, Jim B <J...@.lightning.com> wrote:
> That's exactly what I needed to know. Thanks for your response to my question.
> --
> Thanks, Jim
> "EMartinez" wrote:
> > On Sep 21, 11:38 am, Jim B <J...@.lightning.com> wrote:
> > > I have a need to add a text box to a report. The text box will have an
> > > expression that I need to have that captues the value of a field from a
> > > second data set associated with the report. I add a text box but in the edit
> > > expresssion process I can't access any fields (from any data set) and i get
> > > the message Report item not linked to a dataset. I'm not trying to add a new
> > > table or anything like that. I just want to be able to grab that field value
> > > and disply.
> > > --
> > > Thanks, Jim
> > If I'm understanding you correctly, you should be able to reference a
> > dataset via an aggregate expression. Something like this should work.
> > =Max(Fields!SomeFieldName.Value, "SomeDatasetName")
> > Hope this helps.
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
You're welcome. Glad I could help.
Regards,
Enrique Martinez
Sr. Software Consultant
expression that I need to have that captues the value of a field from a
second data set associated with the report. I add a text box but in the edit
expresssion process I can't access any fields (from any data set) and i get
the message Report item not linked to a dataset. I'm not trying to add a new
table or anything like that. I just want to be able to grab that field value
and disply.
--
Thanks, JimOn Sep 21, 11:38 am, Jim B <J...@.lightning.com> wrote:
> I have a need to add a text box to a report. The text box will have an
> expression that I need to have that captues the value of a field from a
> second data set associated with the report. I add a text box but in the edit
> expresssion process I can't access any fields (from any data set) and i get
> the message Report item not linked to a dataset. I'm not trying to add a new
> table or anything like that. I just want to be able to grab that field value
> and disply.
> --
> Thanks, Jim
If I'm understanding you correctly, you should be able to reference a
dataset via an aggregate expression. Something like this should work.
=Max(Fields!SomeFieldName.Value, "SomeDatasetName")
Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant|||That's exactly what I needed to know. Thanks for your response to my question.
--
Thanks, Jim
"EMartinez" wrote:
> On Sep 21, 11:38 am, Jim B <J...@.lightning.com> wrote:
> > I have a need to add a text box to a report. The text box will have an
> > expression that I need to have that captues the value of a field from a
> > second data set associated with the report. I add a text box but in the edit
> > expresssion process I can't access any fields (from any data set) and i get
> > the message Report item not linked to a dataset. I'm not trying to add a new
> > table or anything like that. I just want to be able to grab that field value
> > and disply.
> > --
> > Thanks, Jim
>
> If I'm understanding you correctly, you should be able to reference a
> dataset via an aggregate expression. Something like this should work.
> =Max(Fields!SomeFieldName.Value, "SomeDatasetName")
> Hope this helps.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||On Sep 23, 9:20 am, Jim B <J...@.lightning.com> wrote:
> That's exactly what I needed to know. Thanks for your response to my question.
> --
> Thanks, Jim
> "EMartinez" wrote:
> > On Sep 21, 11:38 am, Jim B <J...@.lightning.com> wrote:
> > > I have a need to add a text box to a report. The text box will have an
> > > expression that I need to have that captues the value of a field from a
> > > second data set associated with the report. I add a text box but in the edit
> > > expresssion process I can't access any fields (from any data set) and i get
> > > the message Report item not linked to a dataset. I'm not trying to add a new
> > > table or anything like that. I just want to be able to grab that field value
> > > and disply.
> > > --
> > > Thanks, Jim
> > If I'm understanding you correctly, you should be able to reference a
> > dataset via an aggregate expression. Something like this should work.
> > =Max(Fields!SomeFieldName.Value, "SomeDatasetName")
> > Hope this helps.
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
You're welcome. Glad I could help.
Regards,
Enrique Martinez
Sr. Software Consultant
Tuesday, February 21, 2012
Report Generation Chaining
Hi
Is there an easey way to set up report generation chaining (i.e.
automatically start a second report once the first completes)?
Many thanks,
Dave HughesIn a simila vein, is there a way to ensure reports that share a schedule are
processed sequentially (in the belief that the server will be happier
processing one at at time rather than 20 at the same scheduled start time)?
Ta
Dave Hughes
"David Hughes" <spamfree@.freespam.com> wrote in message
news:uCUQ%23GbxEHA.3844@.TK2MSFTNGP12.phx.gbl...
> Hi
> Is there an easey way to set up report generation chaining (i.e.
> automatically start a second report once the first completes)?
> Many thanks,
> Dave Hughes
>
Is there an easey way to set up report generation chaining (i.e.
automatically start a second report once the first completes)?
Many thanks,
Dave HughesIn a simila vein, is there a way to ensure reports that share a schedule are
processed sequentially (in the belief that the server will be happier
processing one at at time rather than 20 at the same scheduled start time)?
Ta
Dave Hughes
"David Hughes" <spamfree@.freespam.com> wrote in message
news:uCUQ%23GbxEHA.3844@.TK2MSFTNGP12.phx.gbl...
> Hi
> Is there an easey way to set up report generation chaining (i.e.
> automatically start a second report once the first completes)?
> Many thanks,
> Dave Hughes
>
Subscribe to:
Posts (Atom)