Can I Dynamically Change The Width Of Objects?

Aug 25, 2005

I have a problem using the table object.  I have columns that I sometimes want to show, and I want the page to run off the edge and be two pages.  However, usually I'm hiding many of the columns and the table "shrinks" enough to fit on one page.  When this happens, the table looks right on the first page, but I get blank pages after it, because the report itself will not shrink. 

View 4 Replies


ADVERTISEMENT

How To Dynamically Change Width?

Feb 7, 2006


Folks,

We have some reports that have optional columns. We have them working very nicely, with the column showing or hiding based on values in the report -- works great.

Except -- when the columns are present, the report spans onto two pages, when exported to PDF, in width. That's understandable, as there's a lot of extra data, and exactly what we want. However, when the columns are not present, we get empty pages instead, because the report doesn't automatically contract back onto the size that fits on one page.

Changing the report to a Matrix won't work, as the hidden columns on some of these come as sets of three, where each column in the three has different formatting (different widths, format codes, etc).

Thanks!
--randy

View 14 Replies View Related

Dynamically Creating Report Width

Apr 5, 2007

Has anyone found out how to dynamically create report width.



If I have 20 columns on a report all of 2cm, then report will be 40cm width.



If I display the columns based on specific criteria using the iif function and then setting the an expression for the Visibility Hidden property, the report could potentially reduce in width.



I cannot see how to build an expression for the report width or table width, to accommodate the potential change in the width of the report when columns are not shown, thus it pages incorrectly, leaving huge white space on the right of the report when columns are hidden... has anyone come across this requirement, and hopefully a solution for it?



Many Thanks people



View 1 Replies View Related

Reporting Services :: How To Increase Width Of Textbox Dynamically Or Automatically

Aug 30, 2015

Do we have any option to increase/decrease textbox width dynamically? I know that we have option to increase or decrease height.

View 6 Replies View Related

Change Table Column Width

Mar 14, 2000

I know we could change the data type or width of a table column in SQl 7 database, but I am not certain if this column is a primary key. Can we change a primary key column width? If we can, how about this column as a foreign key in another table? Will it be automatically updated to the same width? Thanks in advance for your input.

View 1 Replies View Related

SRS2005 - How Can You Change The Field Width Of The Parameter?

Sep 8, 2007



My value is approx 50 characters wide, the parameter drop down is only displaying about 10 characters, although I have plenty of room on the screen.

Also, in a multi-parameter environment, are there any controls on where the parameters are being displayed?

thanks

View 2 Replies View Related

SQL Server 2012 :: Can Change Column Width Of Varchar In Production

Oct 17, 2014

I keep getting requests to increase the width of a varchar colum every now and then.

I want to ask if its perfectly ok when you have active users connecting to the application to do this?

View 7 Replies View Related

Dynamically Change FilterExpression

Oct 1, 2007

I am trying to filter some results using the FilterExpression Property of the SqlDataSource. I have multiple drop down lists with different filtering options. I am trying to change the filter that is applied to a gridview.
Something like this example... http://blogs.vbcity.com/mcintyre/archive/2006/08/17.aspx
 Here is some of my code..Private Sub ApplyFilter()
Dim _filterExpression As String = ""
    If (Not DropDownList1.SelectedIndex = 0) And (DropDownList2.SelectedIndex = 0) And (DropDownList3.SelectedIndex = 0) Then
        _filterExpression = "CategoryName = '{0}'"
    End If    Me.SqlDataSource1.FilterExpression = _filterExpression
End Sub
Protected Sub DropDownList1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles DropDownList1.SelectedIndexChanged
    ApplyFilter()
End Sub
But this doesn't seem to work. The FilterExpression doesn't keep the value. I am looking for a way to dynamically change the FilterExpression. Any Ideas or Suggestions?? Thanks.

View 5 Replies View Related

Dynamically Change The Servername

May 10, 2006

Hi all,

I've created 1 solution and added all my packages in different projects (like DIMENSIONS, SOURCES_SAP, ...).

For each project I have a Data Source that connects to the server. The problem is that when I want to deploy a package to the server that I always need to change the Data Source before deployment.

Before SQL Server 2005 we used a connection file (which was located as well on the server as on the development pc's in the same locations) within our DTS packages. This way we didn't had to change the connections when deploying to the server.

My intention was to use the current configuration from the configuration manager(development / production) to select the servername. Unfortunately, I didn't succeed to retrieve it's value from a variable script.

I need to have a solution that dynamically changes the datasources for multiple packages depending on a specific action.

How can I achieve this the easiest way ?

Thanks in advance !

Geert

View 1 Replies View Related

Change The WHERE Conditions Dynamically

Sep 23, 2006

Is there a way I can build a case statment or similar to handle different where conditions?

I know I can do it dynamic sql but it would be nice to have a method where I can create the querries directly in a normal statement

Someting like:

Select c1, c2, c3
From Table
WHERE Case @Condition
WHEN '>' @SelColumn > @Limit
WHEN '=' @SelColumn = @Limit
WHEN '<' @SelColumn < @Limit
END

I know this doesn't work so an example that do work would be nice.

View 8 Replies View Related

Change Column Name Dynamically

Nov 30, 2007



Hi All,
I have a series of tables need to import to server. When creating the target tables, I want to change the columns name as well, for example:
Source table column Target table column


Name FN_Name
Age FN_Age

The problem is I suppose I don't know the columns name in source table, I want to the tasks scan the source table and make the change programmlly.

Which tasks or approaches can be used to implement this?

Thanks
Micror

View 6 Replies View Related

How To Dynamically Change Connection?

Oct 26, 2007

Hi. I have this kind of problem since I am not very conversant with SSIS
and stripting in VB.NET.

The set-up is the following:
Flat File Source -> Script Component -> Flat File Destination

The flat file source looks like this:

NameOfFile
Headers
Data
Data
Data and many more rows of Data
NameOfAnotherFile
Headers
Data
Data
Data and many more rows
NameOfAnotherFile
Headers
Data
Data and so on in the same manner...

My stript looks like that (not very complicated):
Public Overrides Sub Input0_ProcessInputRow(ByVal Row As Input0Buffer)
Dim strRow As String = Row.Column0.Trim()
Dim strFolder As String = "Data"
Dim strConn As String
Dim charSep() As Char = {CChar(" ")}

If Mid(strRow.ToLower(), 1, 2) = "d0" Then


' This is the file name, so start a new connection to a new file
' which definitely does not exist yet
strConn = strFolder + strRow + ".csv"

' DestinationFile is the name of the
' Flat File Connection Manager
With Me.Connections.DestinationFile
.ConnectionString = strConn
End With

Else
Row.Column0 = String.Join(",", strRow.Split(charSep, StringSplitOptions.RemoveEmptyEntries))
End If
End Sub

I have several questions regarding this one.

1. Is it ok to change the ConnectionString property of the manager
to redirect the row to a different file? If not, what more to do?

2. If the new destination file does not yet exist, will it be created for me or will
I get an error? If I do, what to do not to?

3. The most important: What steps to take so that a row is discarded
from the pipeline in the script? I want some rows not to be directed
to the file destination. These are the lines that contain the name
of the file into which the data below belongs.

If you can optimize some steps in the script, then please do so by all means.
Thank you for any comments and the knowledge you kindly agree to share with me.
Darek

View 1 Replies View Related

Select Columns With Correct Width For Fixed Width Flat File?

Dec 6, 2013

I have like 100 columns and most of them work fine, but some will not work. I need to select the columns with correct width for fixed width flat file.

Here is typical SQL statment that works for most of them.

left(RTRIM(A.City) + Replicate(' ', 25) ,25) as [City]

The above one is not working, but many other works fine like the address. Why would it work for some, but not others?

It works fine if I use any char, but not space. i.e.

left(RTRIM(A.City) + Replicate('*', 25) ,25) as [City]

View 5 Replies View Related

Change Owner Of Database Objects

Feb 23, 2001

I am in the process of cleaning up the security on one of our production databases. SA is already the owner of the database.

On this SQL server, there is a login that has access to this database that needs to be removed. When I uncheck this users access to this database I receive the following error message:
"Error 15183. The user owns objects in the database and cannot be dropped".

How can i find out what objects this logins has ownership of and how can I change the ownership of these objects to SA?

Thanks in advance,

Philip Talavera

View 1 Replies View Related

How Do I Dynamically Change The TOP X Portion Of A SELECT

Oct 26, 2006

I'm sure I'm missing something. I am returning the TOP X number of customers by revenue and I'd like to change the number of records returned by passing a parameter but I keep getting an error.    @TopX int ( or varchar)    SELECT @TopX  CompanyName, Amount FROM Sales Where..... Why will this not work?

View 4 Replies View Related

Dynamically Change The SelectCommand Property

Nov 8, 2007

Hello
I have a gridview that I use on a products page, my problems is certain products have different attributes that I would like to display.
Therefore what I would like to do is change the SelectCommand property to my SQLDatasource depending on the querystring that is passed.
For instance in my page load event I would have a CASE statement with numerous SQLString Variables.
Here is the current coding for my datasource
<asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionString %>"

SelectCommand="SELECT PS.ProductSizeMM AS [Coupling Size], PS.ProductWallThickness AS [To Suit], PS.Cost AS [Price], PS.Sold_By AS [Sold by] FROM tblProduct AS P INNER JOIN tblProductSize AS PS ON P.ProductCode = PS.ProductCode WHERE (P.ProductDescription = @ProductDescription) ORDER BY PS.Sorter">
<SelectParameters>
     <asp:QueryStringParameter Name="ProductDescription" QueryStringField="ProductDescription" />
</SelectParameters>
</asp:SqlDataSource>I have tried declaring a string variable in my page load event (SQLString) then setting the
SelectCommand="SQLString" but this causes a syntax error
Exception Details: System.Data.SqlClient.SqlException: Incorrect syntax near 'SQLString'.
Any help would be greatly appreicated!!

View 3 Replies View Related

Dynamically Change Based On Date

Feb 26, 2014

I have to change the name of the history table dynamically to what is passed in the start date.

If @start_date= '1/1/2014' then it should be history_jan14
If @start_date ='02/01/2014' then it should be history_feb14 and so on.

Is there a way you can do it ?I am using SQL Server 2008.

Code :

DECLARE @start_date datetime
DECLARE @end_date datetime
SET @start_date = '01/01/2014'
SET @end_date = '02/01/2014'

[code]...

View 2 Replies View Related

Howto Dynamically Change The BulkInsertTableName

Mar 19, 2007

Hi,

I'm novice to SSIS and looking for some help on SSIS dtexec (SQL Server 2005).

Is it possible to change the BulkInsertTableName when running a package via dtexec /SET?

My test scenario contains:

- SQLServer 2005 SP2, servername: SDPM01, instancename: GWLINST1, databasename 1: TEST, databasename 2: DEV, tablename 1: Test_Table1 (both in TEST and DEV database), tablename 2: Test_Table2 (both in TEST and DEV database)

- 1 Data Flow task in BIDS (SSIS)

- 1 Data Flow Source: Flat File Source (Flat File Connection Manager name: FTP File Output + CSV file with a few lines of data that needs to be inserted in a SQL Server table)

- 1 Data Flow Destination: SQL Server Destination (OLE DB Connection Manager name: SDPM01GWLINST1.TEST

I can dynamically change the name of the database via:

DTExec /F "Package.dtsx" /SET "Package.Connections[SDPM01GWLINST1.TEST].InitialCatalog;DEV"

How can I also dynamically change the table name where the data from the CSV file will be inserted?

DTExec /F "Package.dtsx" /SET ...

Thanks in advance,

Geert

View 8 Replies View Related

How To Change Dynamically The Connection String.

Nov 15, 2007

Hi,

I am looking to dynamically change the connection string in my SSIS package, to avoid changing the connection string each time I want to run in different environments.

Thanks in advance

View 3 Replies View Related

Change The Chart Size Dynamically

Aug 10, 2005

Hi All,

View 4 Replies View Related

Dynamically Change The DataFlow Queries

Mar 20, 2006

Hi Guys,

This is Ravi. I'm working on SSIS 2005 version. I have created the DTSX file from the SQL Server and executed it successfully from my .NET 2005 code.

Now I have a requirement that I need to dynamically change the Source database query. ie., based on the user selection I need to get the data from different tables of SQL and put it into an Excel file.

Can anyone help me in this..

Regards,
Ravi K. Kalyan
Mascon Global Limited.

View 2 Replies View Related

Dynamically Change Grouping Order

Jan 23, 2008



Hello everyone.

You may had this problem before and know how to do that or may be can suggest me with some ideas.
I am in a process of creating a report wich has 3 groups and the data at the moment grouped by Company - Product - Customer.
I want to be able to change grouping order and respectively the data in report , something like Product - Company - Customer or Customer - Product- Company. (just example)
Is that possible to do at all?
May I add some drag and drop functionality and integrate in my report ?

Any ideas will be most welcomed

Thanks in advance

View 6 Replies View Related

Subreport Width Expanding Beyond Width Of Container Report

Mar 4, 2008

I have a subreport on my main report, and the subreport contains a matrix. When I run the report, the subreport seems to expand beyond the width of the main report. The matrix itself does not expand beyond the width of the body of the main report, but for some reason it seems that the subreport does. The subreport does not contain any headers that might be messing up the width. If I cut and paste the matrix from the subreport directly onto the main report, and remove the subreport, it prints fine. But as soon as I include the subreport on the main report it prints with blank pages because the subreport expands beyond the width of the body of the main report. I have checked the width and margins on the subreport and compared to the width of the main report and all looks good. Can anyone help?

Thanks.

View 7 Replies View Related

Change Dynamically(via Code) The SqlDataSource For A GridView....

Mar 7, 2007

Hi,
say I have two Sqldatasources objects:SqlDataSource1 and SqlDataSource2....
Does anybody know how can I alter programmatically these two sqldatasources in a gridview?
Thanks!!!

View 3 Replies View Related

Change Flat File Source Dynamically

May 21, 2007

I am a relative newbie to SSIS. I have been tasked with writing packages to import data from our clients. We have about 100 clients. Each client has a few different file formats. None of the clients have the same format as each other. We load files from each client each day. Each day the file name changes. I have done all of my current development work with a constant file name in a text file connection manager.



Ultimately we will write a VB application for the computer operator to select the flat file to load and the SSIS package to load it with. I had been planning on accomplishing this thru the SSIS command line interface. Can I specify the flat file to load via a variable that is passed through the command line? Do I need to use a Script Component to take the variable and assign it to the connection manager?



Is there a better way to do this? I have seen glimpses of a VB interface to SSIS. Maybe that is a better way to kick off the packages from a VB app?



Thanks,

Chris

View 9 Replies View Related

How To Change Database Context Dynamically In SQL 2000

Oct 4, 2007

I am using Sql Server 2000.
I have about 25+ databases . I want to run a series of commands on each database... how can I change the database context - the current database - dynamically in a loop...
something like this below:



declare @SQLString Nvarchar(1000)

declare @DBName Nvarchar(100)

declare @SQL2 NVARCHAR(1000)

declare @TABLE_NAME NVarchar(100)

While @@FETCH_STATUS=0

Begin

SET @SQL2 = 'USE ' + @DB_NAME + ';GO;ALTER TABLE ' + @TABLE_NAME + ' MODIFY Name varchar(100)'

PRINT @SQL2

EXECUTE SP_EXECUTESQL @SQL2

End




I am getting an error when i run the above commands:
Msg 170, Level 15, State 1, Line 1
Line 1: Incorrect syntax near 'GO'

Can someone give me the correct solution?

View 4 Replies View Related

What Is The Best Way To Dynamically Change Server Or Database Name Inside A Sp?

Jun 8, 2006

To be clear:

You have a store procedure and inside you make Updates or Inserts against another Server. But that name can change and I dont want to change it manually in everyplace.

Per example:

SELECT *
FROM Himalaya.DBName.dbo.tblUserGroup
WHERE fldUserID = 7300

I have several Selects, Updates and Inserts pointing to that server.

What I can do if I want to change from Himalaya server to another server?

The same with the Database Name.

Thank you

View 6 Replies View Related

Dynamically Change SSIS For Each Loop Container

Jul 10, 2006

Hello,

I would like to modify "Files" attribute of the Foreach Loop of type File
Enumerator.  This attribute is used to set the mask (for example *.txt) to
specify which files to include in the selection.  I need to be able to change
this mask dynamically depending on package global variable.  Is this possible?

Thank you!

Michael

View 3 Replies View Related

How To Change Report Headers And Footers Dynamically From ASP.NET

Jan 21, 2008



Hello All,

I have designed some reports and kept these reports in the report server.

My question is: I want to change report header and footer values dynamically and save the new values in the report template, when the user enters new velues in ASP.NET GUI.

Next time if the user opens the same file the report should display the recent values.

Please help me in passing the parameters from ASP.NET app to SQL Reports and saving the parameters in the report template.

Thanks,
Rao.

View 6 Replies View Related

64 Bit TextFile ConnectionString Unable To Dynamically Change??

Feb 8, 2006

Hello,

On a 64bit Itanium cluster, I'm having a problem dynamically setting the ConnectionString of a TextFile Source using the "EvaluateAsExpression" = True and setting the ConnectionString using an expression from a variable. I get the error message:

-1073647612,0x,The result of the expression "@[User::vFullFilePath]" on property "ConnectionString" cannot be written to the property. The expression was evaluated, but cannot be set on the property.

This is not a problem at all on a 32bit machine. I can run the same package on 32bit and it runs fine.

The funny thing is, I'm able to dynamically change the ConnectionString of a Logfile that we're writing all of the errors to, which I believe is using a TextFile Destination connection under the covers somehow (I'm using the SSIS Logging, to a textfile).

Can anyone confirm if this is a problem in 64bit?

Thanks,

Andy

View 1 Replies View Related

T-SQL (SS2K8) :: Query To Show Database Objects Last Change

Mar 17, 2015

If I skip those objects that were deleted, is there a query that I can run off Master/MSDB that will show all database objects and when they were last modified, or create date if it has not been modified?

View 7 Replies View Related

Importing Text File: How To Dynamically Change The Row Delimiter

Jul 22, 2004

Hi,

I have a dts package that imports a number of text files into a SQL Server 2000 database table. The package has been set up to accept a text file with a row delimiter of carriage return and line feed ({CR}{LF}). Some of the text files I receive only have a line feed ({LF}) as the row delimiter and the dts package fails the file. Is there an activex script i can use that will scan the file and change the row delimiter as required?

i was going to use the filesystemobject which allows me to read a line at a time, however the Readline method doesn't read the new line character. The text files are too big to read into one variable and then do a replace.

Any help would be appreciated

I am using SQL Server 2000 SP3, Windows Server 2000 and Windows XP Professional. All systems are fully patched

Regards Justin

View 3 Replies View Related

How To Change Column Names Dynamically In UNPIVOT TASK

Apr 10, 2008

Dear All,

We are using UnPivot task to convert the columns into rows using the Excel File as source. But the Excel file column names are changing frequenly sometimes its having only 4 columns sometimes its 10 columns.

Everytime we are checking and unchecking the column list in Unpivot Task.

can anybody help us to solve this issue that Unpivot task should take the column name dynamically.

Thanks,
Syed

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved