Showing posts with label property. Show all posts
Showing posts with label property. Show all posts

Thursday, March 29, 2012

Changing the text for the Document Map top level node

Can anyone tell me if it is possible to change the text on the top node of the Document Map? I was looking for a property in the Visual Studio designer or a property I could set programmatically but I couldn't find either.

The text on the top node is the file name of my Microsoft report. That is, the report file name isSalesRepOrderDetail.rdlc and the Document Map top node text isSalesRepOrderDetail. It looks pretty unpolished.

Thanks!

Black Cat Bone

I found it. In designer, expand theLocalReport property for the report viewer control and assign a string to theDisplayName property. This becomes the text on the Document Map's top node.

The code equivalent is: ReportViewer1.LocalReport.DisplayName = "Top Node Text";

|||

Thank,

How can I bring the DisplayName into the report, for example I want to show

the DisplayName in the footer of the report too.

Changing the Table Type

Is there a to change the Type property on a table? I would like to be able
to change the Type from 'User' to 'System' through code.
Adv-thanks-anceWhat do you need this for?
True system tables have object id values less than 100, and there is no way
you can create a table with such an id.
If you are only talking about what shows up in the 'type' column when you
list the objects in Enterprise Manager, you can run the procedure
exec sp_MS_marksystemobject 'mytable'
However, it would not actually be a system table, even though Enterprise
Manager lists it as such. For example, it would still show 'user table' when
using sp_help, and you would not need to set any special flags to
HTH
Kalen Delaney, SQL Server MVP
www.solidqualitylearning.com
"CSHARPITPRO" <CSHARPITPRO@.discussions.microsoft.com> wrote in message
news:A946CD68-5A88-4E55-B813-4D1ADBF49DA6@.microsoft.com...
> Is there a to change the Type property on a table? I would like to be
> able
> to change the Type from 'User' to 'System' through code.
> Adv-thanks-ance
>

Thursday, March 22, 2012

Changing the ConnectionString property for a File Connection Manager

I have a package that I plan to run against about 700 databases to look for anomalies. I have several package variables in place that are passed in at runtime. One of them will hold the path and filename of the error log for the current database in process. I want each database to generate it's own error log for documentation and research purposes. However, when I run the package, it continues to use the path and filename that I entered when I created the File Connection Manager. I am trying to update that value in a Script Task by using the ConnectionManager class and setting the value for the "ConnectionString" property. This method is working for the OLEDB Connection Manager (which tells the package which Access database to process), but not for my File Connection Manager. Please help!

DO

Don't try and use a script task to do this. Use expressions: http://blogs.conchango.com/jamiethomson/archive/2006/03/11/3063.aspx

-Jamie

|||Thanks, you've done it again.

Tuesday, March 20, 2012

Changing SSIS property defaults

To make certain SSIS features work there are many properties that need to be set over and over for most containers in the package. For example with Checkpoint\Restart, you need to set (in most cases) all of the tasks' FailPackageOnFailure to True. If you miss one, the package may not restart properly and you might never know. There are other situations where as a development team we want certain properties to be usually set the same but differently from the SSIS default.

Is there a way to control the defaults that the SSIS IDE uses?

I remember back in classic VB that if you wanted to change the defaults of a bare form you could create a template form adjusted the way you like and put it in a templates folder. Then new forms added to a project would be based on the template form.

No worries. The same thing exists for SSIS:

SSIS: Location for your package templates
(http://blogs.conchango.com/jamiethomson/archive/2005/11/12/2380.aspx)

It won't allow you to set default properties of tasks though - which I think is what you are after.

-Jamie

|||

Yes, I was hoping to set defaults for packages and tasks. Any recommendations? Our DTS developers are balking at the multitude of properties needed to be set to implement certain features.

What do you name the templates that you put in the templates folder so that they are used in the IDE? Package1.dtsx?

Thanks.

|||

Chopaka wrote:

Yes, I was hoping to set defaults for packages and tasks. Any recommendations? Our DTS developers are balking at the multitude of properties needed to be set to implement certain features.

Sorry, that's not possible. It would be nice if it were though - perhaps you could suggest it at Microsoft Connect.

Whenever they build the ability to reuse pre-configured tasks then you will be able to do it. I wouldn't expect that until v3 at the earliest though.

Chopaka wrote:

What do you name the templates that you put in the templates folder so that they are used in the IDE? Package1.dtsx?

Whatever you like!

-Jamie

Wednesday, March 7, 2012

Changing PageHeight dynamically

My requirement is to have my report display on one 11 by 8.5 page. Is there a way to programmatically change the PageHeight report property based on the number of rows returned in a table? i.e., if the rowcount for table x >= 10, change PageHeight to 9.5.

Any ideas?

Thanks.

Brad

Is there anyway to achieve this?|||

Not really but you can use the next size or change the orientation of your report but before you do that run test copies through either preview or Reportveiwer depending of your choice for display and printing. Here is what I know there is an interactive height setting which you can use to reduce the size so maybe you can use it to increase it. Try the link below for details.

http://blogs.msdn.com/bwelcker/archive/2005/08/19/Alien-Lanes-_2800_Logical-and-Physical-Pagination-Rules_2900_.aspx

Thursday, February 16, 2012

Changing flat file connection file name property

Hi,

I have a task to traverse a folder of CSV files of same format and then populate into one sql server table.

Is there a way where I can change the source CSV file name runtime using FOR EACH loop container for flat file connection manager ?

any help would be much appriciated.

Thanks,

Furrukh Baig

Yes. By using package expressions. There is an example in the SSIS tutorials that I think does exactly what you want to do assuming all files are in the same directory.|||Thanks mate... you are star ...|||

I'm also trying to do the same thing, except that each folder has a number of different csv files. Would appreciate if someone could give me a link of the sample (as mentioned in the previous post) and whether it's better to have different flat file source for each type of csv file format or should I just use 1 flat file source.

I've tried using 1 flat file source but the number of columns are different for each files and the number of columns in the flat file source isn't dynamic (I've to prespecify it first).

|||I'm assuming you're talking about the foreach loop container in the tutorial (ms-help://MS.VSCC.v80/MS.VSIPCC.v80/MS.SQLSVR.v9.en/sqltut9/html/88a973cc-0f23-4ecf-adb6-5b06279c2df6.htm) Can you use a similar concept to loop thru xml files? I have an xml source, 2 sorts and a merge-join. Whenever I change the input file, I need to open my sorts and click ok. How will that work if I need to iterate thru a directory of files?

Changing flat file connection file name property

Hi,

I have a task to traverse a folder of CSV files of same format and then populate into one sql server table.

Is there a way where I can change the source CSV file name runtime using FOR EACH loop container for flat file connection manager ?

any help would be much appriciated.

Thanks,

Furrukh Baig

Yes. By using package expressions. There is an example in the SSIS tutorials that I think does exactly what you want to do assuming all files are in the same directory.|||Thanks mate... you are star ...|||

I'm also trying to do the same thing, except that each folder has a number of different csv files. Would appreciate if someone could give me a link of the sample (as mentioned in the previous post) and whether it's better to have different flat file source for each type of csv file format or should I just use 1 flat file source.

I've tried using 1 flat file source but the number of columns are different for each files and the number of columns in the flat file source isn't dynamic (I've to prespecify it first).

|||I'm assuming you're talking about the foreach loop container in the tutorial (ms-help://MS.VSCC.v80/MS.VSIPCC.v80/MS.SQLSVR.v9.en/sqltut9/html/88a973cc-0f23-4ecf-adb6-5b06279c2df6.htm) Can you use a similar concept to loop thru xml files? I have an xml source, 2 sorts and a merge-join. Whenever I change the input file, I need to open my sorts and click ok. How will that work if I need to iterate thru a directory of files?

Changing field props in SQL Management Studio

Hi,
I have average database with something like 15M records. I have to change
some fields property of tables with average 4M records. On smaller tables I
can change one field at time and save design would be successful but on
larger tables I got timeout something like 25 seconds after pressing OK.
Where I can change timeout period or disable it?
Tried to put 0 on Connection window, changed to 0 remote query timeout, but
it does not change anything.
Thanks
RobertI strongly encourage you to do these changes using ALTER TABLE instead of the GUI since the GUI can
be quite clumsy regarding the SQL it generates.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Piasecznik" <WYpiasecznikWAL@.op.pl> wrote in message news:frdfec$1gmi$1@.news2.ipartners.pl...
> Hi,
> I have average database with something like 15M records. I have to change some fields property of
> tables with average 4M records. On smaller tables I can change one field at time and save design
> would be successful but on larger tables I got timeout something like 25 seconds after pressing
> OK.
> Where I can change timeout period or disable it?
> Tried to put 0 on Connection window, changed to 0 remote query timeout, but it does not change
> anything.
> Thanks
> Robert
>

Friday, February 10, 2012

Changing control/Property box values

Help!
I'm trying to figure out how to change the values on the properties control
box dynamically. Things such as Hidden, size, font. With the RS format of
<name>!<fieldname>.Value, how are such things called?
Example code (which doesn't work because of compile problems:
=iif(Fields!TableName.Value = Parameters!tblName.Value,
ReportItems!Hidden.Value = "False", ReportItems!Hidden.Value = "True")
The goal is to hide a list box/field. What do I use in place of
ReportItems!Hidden.Value to make this work?
Thanks,
CatadminHi,
I have the same problem as you. I'm trying with custom code, you can see a
description:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/RShowto/htm/hrs_designer_v1_1nfp.asp
But only can access the "value", somethig like this:
Function NullData (txt As textbox) As Boolean
If (txt.value = "") Or _
(txt.value) Is Nothing Then
Return False
End If
Return True
End Function
I'm working to change the width property value. If I'm sucess I will post
here.
Maybe you can do something more with this. I hope it can be helpfull.
"Catadmin" wrote:
> Help!
> I'm trying to figure out how to change the values on the properties control
> box dynamically. Things such as Hidden, size, font. With the RS format of
> <name>!<fieldname>.Value, how are such things called?
> Example code (which doesn't work because of compile problems:
> =iif(Fields!TableName.Value = Parameters!tblName.Value,
> ReportItems!Hidden.Value = "False", ReportItems!Hidden.Value = "True")
> The goal is to hide a list box/field. What do I use in place of
> ReportItems!Hidden.Value to make this work?
> Thanks,
> Catadmin