Showing posts with label named. Show all posts
Showing posts with label named. Show all posts

Friday, March 30, 2012

How to diplay a dataset in a table

Hi all..
I have a dataset named "Primas" that returns 3 records with 3 fields each.
I want to display a list of those records with a header and a summarize row.
To do that, I placed a Table control into the layout. Assigned "Primas" as
the dataset and I placed a textbox control into it with the value of
=Fields!CODIGOPRIMA.value (CODIGOPRIMA belongs to Primas dataset)
When I build the report, I get the error:
"Expression value of object CODIGOPRIMA reference field CODIGOPRIMA. Report
element expressions can only reference a field in actual dataset scope or, if
they are inside an aggregate, the specified dataset scope"
(I translated the messaege from Spanish, so I'm not sure if it is accurate,
but that's the idea).
The question.. why I get that message although I have the dataset specified
for that table? When I go to a field property inside the table, under
expressions, system shows me only the fields from a dataset that is the
parent of the table (a List)
Any help will be greately appreciated,
Thanks
JaimeYou might check that the Dataset is aware of the field you are trying to
use. You can do this by clicking on the Refresh button on the Data tab with
that dataset selected. I get that same message if I've added or changed a
field in the underlying database and forget to refresh the dataset.
Jared
"Jaime Stuardo" <JaimeStuardo@.discussions.microsoft.com> wrote in message
news:8C285D68-701D-451F-A2A8-363B80874025@.microsoft.com...
> Hi all..
> I have a dataset named "Primas" that returns 3 records with 3 fields each.
> I want to display a list of those records with a header and a summarize
> row.
> To do that, I placed a Table control into the layout. Assigned "Primas" as
> the dataset and I placed a textbox control into it with the value of
> =Fields!CODIGOPRIMA.value (CODIGOPRIMA belongs to Primas dataset)
> When I build the report, I get the error:
> "Expression value of object CODIGOPRIMA reference field CODIGOPRIMA.
> Report
> element expressions can only reference a field in actual dataset scope or,
> if
> they are inside an aggregate, the specified dataset scope"
> (I translated the messaege from Spanish, so I'm not sure if it is
> accurate,
> but that's the idea).
> The question.. why I get that message although I have the dataset
> specified
> for that table? When I go to a field property inside the table, under
> expressions, system shows me only the fields from a dataset that is the
> parent of the table (a List)
> Any help will be greately appreciated,
> Thanks
> Jaime|||Hi Tom...
I have done so but the same problem happens. And when I go to the field
value combobox, only dataset fields associated with the List are shown, not
table daaset fields.
Jaime
"Tom Rocco" wrote:
> You might check that the Dataset is aware of the field you are trying to
> use. You can do this by clicking on the Refresh button on the Data tab with
> that dataset selected. I get that same message if I've added or changed a
> field in the underlying database and forget to refresh the dataset.
> Jared
> "Jaime Stuardo" <JaimeStuardo@.discussions.microsoft.com> wrote in message
> news:8C285D68-701D-451F-A2A8-363B80874025@.microsoft.com...
> > Hi all..
> >
> > I have a dataset named "Primas" that returns 3 records with 3 fields each.
> >
> > I want to display a list of those records with a header and a summarize
> > row.
> > To do that, I placed a Table control into the layout. Assigned "Primas" as
> > the dataset and I placed a textbox control into it with the value of
> > =Fields!CODIGOPRIMA.value (CODIGOPRIMA belongs to Primas dataset)
> >
> > When I build the report, I get the error:
> > "Expression value of object CODIGOPRIMA reference field CODIGOPRIMA.
> > Report
> > element expressions can only reference a field in actual dataset scope or,
> > if
> > they are inside an aggregate, the specified dataset scope"
> > (I translated the messaege from Spanish, so I'm not sure if it is
> > accurate,
> > but that's the idea).
> >
> > The question.. why I get that message although I have the dataset
> > specified
> > for that table? When I go to a field property inside the table, under
> > expressions, system shows me only the fields from a dataset that is the
> > parent of the table (a List)
> >
> > Any help will be greately appreciated,
> > Thanks
> > Jaime
>
>

How to differentiate process instances in perfmon

In a multi-instance cluster, how can you match a named sql server instance
with an instance of sqlservr.exe? When setting up counter collection in
perfmon, I choose the "process" performance object, then the "% processor
time" counter". In list of instances, I can see sqlservr#1, sqlservr#2, etc.
How do I know which named instance each of those represents?
TIA.
Hello
One way (I dont know if is the best way) is to match the ProcessID on
Process Counter from Performance Monitor to the ProcessID that is on the
ErrorLog from the Instance.
Something like:
PerfMon -> Process -> ProcessID -> Select SQLServer# on the instances.
Now go to SQL Server Enterprise Manager for each instance and look on the
ErrorLog for the line:
Server Process ID is 3636.
That should be easy if you need to do just on time.
Carlos Eduardo Selonke de Souza
http://carlos.geekbunker.org
"Denise" wrote:

> In a multi-instance cluster, how can you match a named sql server instance
> with an instance of sqlservr.exe? When setting up counter collection in
> perfmon, I choose the "process" performance object, then the "% processor
> time" counter". In list of instances, I can see sqlservr#1, sqlservr#2, etc.
> How do I know which named instance each of those represents?
> TIA.
|||That's a good idea, thanks for the suggestion.
I don't have access to the error log on all the servers, but I can use
SELECT SERVERPROPERTY ('processid')
"Carlos Eduardo Selonke de Souza" wrote:
[vbcol=seagreen]
> Hello
> One way (I dont know if is the best way) is to match the ProcessID on
> Process Counter from Performance Monitor to the ProcessID that is on the
> ErrorLog from the Instance.
> Something like:
> PerfMon -> Process -> ProcessID -> Select SQLServer# on the instances.
> Now go to SQL Server Enterprise Manager for each instance and look on the
> ErrorLog for the line:
> Server Process ID is 3636.
> That should be easy if you need to do just on time.
> --
> Carlos Eduardo Selonke de Souza
> http://carlos.geekbunker.org
>
> "Denise" wrote:

Monday, March 19, 2012

How to detect active connection of a SQL Server?

Hi There,
Who know how to detect active connection to a particular SQL Server?
Eg: I have a SQL Server named MyServer and there are 3 computers link to
MyServer when my application start, but how do I know which of the 3
computers is linked to MyServer when application is running?
Thanks!
Wallace Wong
A2000 Solutions Pte Ltd
Blk 5 Ang Mo Kio Industrial Park 2A #07-17 TECH II Singapore 567760
Tel: (65) 6720 2000 Fax: (65) 6720 2987
Hi,
you can query the following objects:
SQL SERVER 2000:
SELECT * FROM sysprocesses
SQL SERVER 2005:
SELECT * FROM sys.dm_exec_sessions
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
|||"wallace" <wallace@.a2000.net> wrote in message
news:O7X575BUHHA.496@.TK2MSFTNGP06.phx.gbl...
> Hi There,
> Who know how to detect active connection to a particular SQL Server?
> Eg: I have a SQL Server named MyServer and there are 3 computers link to
> MyServer when my application start, but how do I know which of the 3
> computers is linked to MyServer when application is running?
>
> Thanks!
> --
> Wallace Wong
> A2000 Solutions Pte Ltd
> Blk 5 Ang Mo Kio Industrial Park 2A #07-17 TECH II Singapore 567760
> Tel: (65) 6720 2000 Fax: (65) 6720 2987
>
|||select count(*) from dbo.sysprocesses where status<>'Background'
EggHeadCafe.com - .NET Developer Portal of Choice
http://www.eggheadcafe.com

How to detect active connection of a SQL Server?

Hi There,
Who know how to detect active connection to a particular SQL Server?
Eg: I have a SQL Server named MyServer and there are 3 computers link to
MyServer when my application start, but how do I know which of the 3
computers is linked to MyServer when application is running?
Thanks!
Wallace Wong
A2000 Solutions Pte Ltd
Blk 5 Ang Mo Kio Industrial Park 2A #07-17 TECH II Singapore 567760
Tel: (65) 6720 2000 Fax: (65) 6720 2987Hi,
you can query the following objects:
SQL SERVER 2000:
SELECT * FROM sysprocesses
SQL SERVER 2005:
SELECT * FROM sys.dm_exec_sessions
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
--|||"wallace" <wallace@.a2000.net> wrote in message
news:O7X575BUHHA.496@.TK2MSFTNGP06.phx.gbl...
> Hi There,
> Who know how to detect active connection to a particular SQL Server?
> Eg: I have a SQL Server named MyServer and there are 3 computers link to
> MyServer when my application start, but how do I know which of the 3
> computers is linked to MyServer when application is running?
>
> Thanks!
> --
> Wallace Wong
> A2000 Solutions Pte Ltd
> Blk 5 Ang Mo Kio Industrial Park 2A #07-17 TECH II Singapore 567760
> Tel: (65) 6720 2000 Fax: (65) 6720 2987
>|||Hello,
Execute SP_WHO system stored procedure from SQL Server Management studio --
Query window (SQL 2005) or Query Analyzer in SQL 2000 to get
all the connections in SQL Server. This gives you the Hostname of the each
connection
Thanks
Hari
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message news:...
> "wallace" <wallace@.a2000.net> wrote in message
> news:O7X575BUHHA.496@.TK2MSFTNGP06.phx.gbl...
>

Friday, February 24, 2012

how to delete a column using script code

hi all

iam having a query , c guys iam having a table in sql with some coulmns in it , i have a column named as country in the table , now wat i want to be done is , i want to delete the column country based on some conditions , i ve to write a script code as : i ve to check if the column is there already or not if its there it shld delete the column or if its not there it shld not show any error and just return empty handed thats all , i dont know wat to be done , so if anyone knows abt it pls do send as soon as possible guys , hopefully waiting for a reply

Note : any dbts pls do mail me again

Venkatesan

I understand this is your first post. Welcome to the forums.

Some info that might help you:

If you want a proper response to your question, you need to explain the facts, provide the table structure(s), some sample data. You dont need to provide your entire HTML code from visual studio. Only relevant code. Any amount of ambiguity or missing information can lead people trying to answer your question away from your post, to a more informative post. Otherwise your post will go down the pages unanswered.

Now, coming back to your question, do you want to delete the column or the values in the column? Posting some sample condition would also help!!

|||

hi dinakar

thanks for ur reply , first let me apologise , c yar i dont have any code to post it here , actually i dont know how to write one , i will explain my req again , 1st i have a table named as tbl_employees which has some columns and in that there is a column named as country , intially for live database that country column will not be there and if clients( i mean in live ) wants to have it , then they can add it , the scenario is like this , so as a developer we used to do it and ensure it that its working in local , after it works we have to put it in live , so that time we cannot delete it manually , for that we have to send a script file to check whether the column is there or not , if its there i have to delete the country column through a query thats wat i dont know how to do , so wat i need is to code to delete the country column itself not the values in it , i think i have explained to u well , waiting for a reply asap, thanks in advance

Venkatesan

|||

ALTER TABLE yourTableDROP COLUMNCountry

|||thanks man