Storage Location For A Configuration File For Global Variables In DTS

Nov 15, 2007

Hello,

We have an existing OLD System in SQL Server 2000 DTS Packages.
The Whole application runs on DTS.
There are several Packages which are called from a Master Package. Each Child packages have their own Global Variables. Most of them are the File Location variables to have the Source Location of the Input Data, mainly from the Excel Files.
Now, even if the Global Variables are there to change whenever they want to change the Locations of the Files, they have to goto each child package and change the variable themselves.
To resolve this issue, they want a configuration File (INI) / Table which would store those Variables. My thought is to read from that File/Table and Update all the packages' global variables through an ActiveX Script as the First Step of the Master package. That would eliminate the need of changing anything in the existing System.
But the Problem is the management (PM / DBAs / Team members) have different views to store the Configuration data.
1. Some wants it into a Different Database, having one table for this application so in future they can also add another table for some other application.
2. Some wants to store it in a Table in the Same Database of this Application.
3. Some wants to save it as a INI file.

As i'm the one who's going to really implement it, they have asked me to research for a best solution out there.

so I request to help me to decide which is a good solution and why.

Best Regards,
Deepak

View 4 Replies


ADVERTISEMENT

XML Configuration File Deployed Location

Dec 14, 2006

I have developed an SSIS package which uses an XML configuration file for connection information. It runs fine both from Visual Studio and from an Agent job after I specify the location of the XML configuration file in the Agent job definition.

My question is regarding the target location of the XML configuration file after deployment. I do my SSIS development on a local workstation with SQL Server 2005 DE and Visual Studio 2005 installed on it. I deploy my SSIS packages to a remote SQL Server 2005 SE server. Both machines are running SP1. I double-click the package manifest from my local workstation and specifiy the remote server in the deployment utility. The package gets deployed to the remote server just fine but the XML configuration file ends up on my local workstations C:Program FilesMicrosoft SQL Server90DTSPackages path. I would have expected that the XML configuration file would have gone to the same path on the remote server, where the package itself was deployed. Obviously, when I run the deployment utility from the remote server, it stores the XML configuration file in the same path on the remote server. But this is not a workable production solution.

View 1 Replies View Related

Configuration File Location Different In BIDS?

Jul 6, 2006

I've been working on package configurations here, mainly trying to figure out what works, and how. If I use an XML configuration, and and don't specify the path, ie just typing in test.dtsconfig, it creates the config file on my desktop. When I execute the packge in BIDS, it seems to be looking in that location. If however, I execute the package manually on the filesystem, test.dtsconfig must be in the same directory as the package (which is what I would expect). Why does this work differently in BIDS. Also, if the package is deployed to a SQL server, where would the configuration file need to be in this case? Thanks for the help.

View 1 Replies View Related

Installation Wizard && XML Configuration File Location

Jan 15, 2008

Hi,

I am using SQL Server configuration indirectly with the connection to it configured in an XML configuration file with the location of the XML file and the connections all being different between development and production. I deploy to the file system using the SSIS Deployment Manifest/Package Installation Wizard.

It seems that sometimes the path to the XML config file is updated in the deployed packages and sometimes it is not.


When the path is updated, all connection strings (as displayed in the Connection Managers section of the Execute Package Utility) are displaying the new values as well.


When it is not, it looks for the XML file in the development location and since it cannot find it all configurations still point to the development connections.


Does anyone know of any conditions when the location of the XML config does not get updated and when it doesn't?

Thanks,
Sven

View 6 Replies View Related

Changing Storage Location On SQL Cluster

Aug 14, 2006

We are running SQL Server 2000 w SP4 on a 2 node active/passive Windows 2003 w SP1 configuration. We are presented with 2 150GB LUNs and 1 600MB on particular SAN that does not belong to us. M: and N: drives are the datadrives and Q: is the quorum.

We now have our own SAN and we will be using it for the SQL cluster data storage. The SAN administrator stated that he will present me with 2 150GB LUNs and 1 600MB…pretty much the same configuration.

How will I be able to move all my data and configure the cluster to the new SAN?

Thank you for any help!

View 2 Replies View Related

SSIS Package Storage Location

Dec 5, 2007



Hi friends,

I have Transfered my dts packages from sql 2000 to sql2005 by directly migrating the rows from Sysdtspackages table on sqlserver 2000 to Sysdtspackages table on Sqlserver 2005.Now im able to see all my DTS of sql2000 in sqlserver 2005 Management studio under MANAGMENT--->LEGACY--->Data transforamtion services and i have all the corresponding records in sysdtspackages table of MSDB database on SQLSERVER 2005.

Now i have to schedule a job for executing these dts packages. In the job schedule window, when i try to select my dts packages on the SSIS package store for the package source and go to SSIS --->MSDB, IM NOT ABLE TO FIND MY DTS PACKAGES? WHERE ARE MY DTS PACKAGES GONE. HOW CAN I SCHEDULE.

i can find another table by name 'sysdtspackages90' on msdb database.do i have to migrate the data from sysdtspackages to sysdtspacakges90 ?

Please help out.

Regards
Arvind



View 6 Replies View Related

Analysis :: Cube Restoration In Different Storage Location

Aug 6, 2015

I am in process of automating a cube migration from SSMS 2008 to SSMS 2012.

In this process iam deleting the existing cube databases and restoring them on a different location on the same server.
When i try to execute the restore command or restore using UI i get a wierd error message like this below:
 
"TITLE: Microsoft SQL Server Management Studio
------------------------------
 File system error: The following error occurred while opening the file 'DrivePath3F9D4D128D5E417FA6F2[CUBEDBNamepath].fact.map'.
Server: The current operation was cancelled because another operation in the transaction failed.
(Microsoft.AnalysisServices)

[Code] ....

View 5 Replies View Related

DTS Global Variables

Nov 10, 2004

Hello,

In the properties for a DTS package, I have a string variable. I need to execute an update statement based on this variable. I was going to use Execute SQL, but I didn't know now to get a value from the variables section.

I store the value there because I will be using dtsrun or the DTS library to execute the package, which I can change this value upon execution. How do I execute an update based on the value?

Brian

View 3 Replies View Related

DTS Global Variables

Aug 6, 2001

Have anyone encountered a problem with DTS Global variables. What I am trying to do is keep a counter in a global variable. It works fine when I run the job manually but if I schedule the job it doesn't increment the counter. Any ideas?

Thanks in advance!
Nancy

View 1 Replies View Related

Global Variables

May 10, 2004

cani define a global time in sql server2000, which all tables in DIFFERENT databases can use. I need this in order to INNER JOIN all tables in SAME/DIFFERENT DBs on basis of this datetime field.

View 7 Replies View Related

Global Variables

Feb 17, 2004

Hi,

Is there a way to declare a persistent global variable in SQL Server?

I'd like my stored procs to fetch data in a different source depending on a debug (or development) variable.

For example, I'd like to be able to set a variable to either 0 or 1 (true or false) and have a static SP defined as:


IF @MYVARIABLE = 1
SELECT * FROM Openquery(Server1, 'SELECT * FROM Table1")
ELSE
SELECT * FROM Openquery(Server2, 'SELECT * FROM Table2')


What do you think? Since these SPs should be called a lot, I don't want to store the info in a table, I want it as a global variableso it will be as fast as possible.

Any other suggestions are also welcomed.

Thanks,

Skip.

View 3 Replies View Related

Q: DTS And Global Variables

Jul 23, 2005

Using SQL2000, I have a DTS that takes data from MySQL to sqlserver, thecatch is I want to specify a specific range of dates.How to use a global variable? At the moment I manually changes the dates andjobs run on a daily basis.sample sql statement from Mysql connection:select *from Table1where date between '1/1/2004' and '6/30/2004'CHANGE TO:select *from Table1where date between @fromdate and @todateTIABob

View 1 Replies View Related

Use Variables As A Storage [read/write] ?

Aug 2, 2007

Hello Guys,
in SSIS I want to get a set of data and do some modifications on it before I insert it into the destinatipn. So far so good. Some of the modifications will include comparisions between two columns and if certain field is NULL then I want to get the value from the other one I was comparing to. When using conditional splits, I only get the rows to be redirected so that I can do whatever next. However, I want like use the variables as a storage so that I can put the value of one of the two columns in this variable which will be actually loaded into the destination finally. Any help?
Thanks

View 1 Replies View Related

Global Server Variables

Apr 1, 2004

Is there a way in SQL Server to setup Global Server Variables or Constants

We are working with an Off the Shelf Constituent Management application based on SQL Server. We can only read from the App's DB. So we setup another DB to run SP to access the data in the main DB. One problem we have is that there codes that the app DB uses that we need to reference as criteria in our SP. Example: Code for a phone type of email is 731. So if we want to pull email addresses we need to Select where PhoneType = 731. We found out that each time the main db is rebuilt those codes change. That means finding everytime we used that code and changing it.

It would be great to be able to set a global variable and use it anytime that code is needed.

Any ideas.

View 2 Replies View Related

DTS Import With Global Variables

Dec 7, 2000

A short explanation: I have 4 locations that will import from text files.

These text files will need to be 'stamped' with a location_id. I'd like to pass the location_id to the dts package via a VB program. The reason for the VB program is I'd like to keep users from the Enterprise Manager. Is this possible to accomplish? Thanks for your help.

View 1 Replies View Related

Global Variables (passing)

Feb 23, 2001

I am executing:
--------------------------------
DECLARE @x AS int

SET @lcQuery = 'UPDATE ... WHERE .... ' + ' SET @x = @@ROWCOUNT'
EXEC (@lcQuery)

PRINT @x
--------------------------------
@x does NOT return a value, because it is "local" to the lcQuery execution. As a matter of fact, to execute it, I have to write:

SET @lcQuery = 'DECLARE @x AS int ' +
'UPDATE ... WHERE .... ' +
'SET @x = @@ROWCOUNT'
EXEC (@lcQuery)

How can I pass the variable @x to the progam from within EXEC (@lcQuery)?
How does EXEC (@lcQuery) execute? In a different space?

Thank you.

View 1 Replies View Related

DTS Global Variables DateAdd

Jan 22, 2002

As a newcomer to SQL2000, I need to create a DTS Global Variable that will import a file daily automatically. I've got the DTS working great, but I have to manually execute it every day. The log file name Accounting 02-22-2002.csv changes by the date every day. So the next record set would be Accounting 02-23-2002.csv and so on. Any ideas on how to create this? I think some VBScript is necessary from what I understand. I'm looking at the function DATEADD(d, 1, date).

View 1 Replies View Related

Using Global Variables In Triggers ?

Mar 20, 2007

We're using SQL Server 2000. I have a table with a couple fields I'd like to automatically updatre with a atrigger. One of the fields needs to log the current time the record has been modified. The other field needs to log the current user ID.Storing the current time is easy with UPDATE and GETDATE(), but obtaining the current user from my ASP.NET code isnt as pretty as I would have to pass in the user ID from my backend code into the server, perhaps as a stored procedure variable that will manually update the table with the new ID. I was hoping to perhaps set some global variable of the user ID for the current connection to the dbase so that once the trigger is made, it feeds off this connection-level global variable to plug in the needed User ID for the record.So for instance:SET @@MyCurrentUserID = 4; UPDATE MyTable SET myStuff='games';The MyTable trigger will be initiated and the LastModified field of MyTable will be auto update with the current datetime, but also the LastModifiedUser field of MyTable will be update with MyCurrentUserID.Is this possible with SQL Server 2000 for Windows 2K3?Tx

View 7 Replies View Related

Creating Global Variables

Apr 11, 2008

I have a dts package that has 4 global variables. Migrated the package to SSIS thru the wizard. But I need to fix the global variable in order to work.
This global variable is the path where the txt file is residing after you run the DTS package.
I want o know how could I create the global variable in SSIS?

View 1 Replies View Related

Transfering All Global Variables???

Jan 30, 2007

Hi

I have created two SSIS packages one is development and another is test. I used near about 15 global variables in my test SSIS package.Both development and test package working on transfering data from database and put into text files now i want to implement all these variables into development package
how i will do that wheather i have to create all these variables in development package also or there is way to transfer these variables from one package to another

Please help me out

View 9 Replies View Related

SSIS Global Variables

Jul 10, 2007

Before in DTS, I used to using ActiveX scripts to setup simple Global Variables that would later be used by the package, let's say a give state or a date.
I'm completely lost how to do the same in SSIS, can someone give me a hand?
I'm not sure what component to use and how to read this variable.

View 2 Replies View Related

Functions With Global Variables

Jul 20, 2005

Hello,I am porting a stored procedure from Oracle. It uses a variable thatremembers its previous values from each invocation. (It uses a PRAGMAREFERENCES clause for those who are familiar with Oracle.) In otherwords, the variable in a particular stored procedure acts as a globalvariable. So the each invocation of the stored procedure can see itslast value, instead of its initial default value.Is there something similar in SQLServer?

View 1 Replies View Related

DTS For Bulk Insert With Global Variables...

Feb 11, 2005

I have a flat file of records in csv format. I want ti create a dts that can be executed from asp.net using vb.net to load data from .csv file into sql server 2000 table.

Now what further i want that this DTS must have a parameter mapped to file name of .csv. so when i execute this dts from asp.net web application i will set the file path to this variable and then execute it on server.

So that meanz dts stays on server all it require before execution a new file path to load data from file that is already uploaded on server in a directory.

if any one have any idea to how to create such a dts and secondly how to execute in asp.net.



thanks in advance.

View 1 Replies View Related

Sp_msforeachtable In A DTS Package With Global Variables

Feb 27, 2001

Hi,

what I basically want to do is to delete all records from all tables where the field loadnumber equals a certain value.

To do this I've defined the global variable 'DSLoadNumber' (integer) in a DTS package, and I want to use the stored procedure sp_msforeachtable in an Execute SQL Task.

This is the code in the Execute SQL Task:

sp_msforeachtable
@replacechar = '~',
@command1 = "delete from ~ where loadnumber = ?",
@whereand = " and name not in ('dtproperties', 'dsloadlog', 'FotoMediaProduct', 'ProductFF', 'ComStat', 'ProdStat')"

This code can be parsed without any problem, but the ? is not seen as a variable.
When I get the ? out of the quotes the code cannot be parsed any longer.

Finally I've written a cursor to the job which looks like this:

DECLARE @tablename varchar(35),
@loadnumber int

SELECT @loadnumber = ?

DECLARE delete_cursor CURSOR FOR

select name
from sysobjects
where type = 'U'
and name not in ('dtproperties', 'dsloadlog', 'FotoMediaProduct', 'ProductFF', 'ComStat', 'ProdStat')

OPEN delete_cursor

FETCH delete_cursor INTO @tablename
WHILE (@@fetch_status = 0)

BEGIN

exec('delete from ' + @tablename + ' where loadnumber = ' + @loadnumber)

FETCH NEXT FROM delete_cursor INTO @tablename

END

CLOSE delete_cursor

DEALLOCATE delete_cursor

But this code doesn't compile either...

Any suggestions on how to get the code working within DTS?

Stef

View 2 Replies View Related

How To Use DTS To Export To Access Using Global Variables ...

May 6, 2002

Hi,

I am trying to export data from SQL7 to Access using a DTS package. I want to use the global variables within the package in sql statements.

How can I do that?
I have 2 global variables set: @DID & @Rowid

When tranfering data I used the sql statement to get the data from SQL7:
Select * from Tablex where ColumnX=@DID AND ColumnY > @rowid

but when I do that I get an error: You must declare the variable @DID

Why is that, if I declared it in the global variables section????

TIA.

View 4 Replies View Related

DTS Global Variables Behaviour With &> 1 User

Jun 22, 2004

Hi all

I have a DTS package that users of the database can run which basically acts like a 'live update' (as the database is based on a values produced from another system) and it takes roughly 30 or so seconds to run...

The dts package is not going to have a particularly large hit rate but i am interested in knowing what will happen if a user (user 1) attempts to run the package when it is in already in use by another user (user 2) ?

The dts package is from a sp using the dtsrun utility (passes in global variables).

I know that a second DTS will start before the first has finished but what i am not sure about is what will happen to the Global Variables when the second DTS package starts - i.e. will starting a second instance of the package with different variables have an effect on the first DTS's global variables while it is running?

I hope the answer is "No Tom, it work fine!"

View 2 Replies View Related

DTS Task Properties And Global Variables

Mar 2, 2004

Hey all,
I have a stored procedure, which need one variable as parameter. I am trying to call this stored procedure from my DTS Task and my parameter is defined as the Global Variable in DTS. here is the SP call within my DTS Task

declare @id int
select @id = DTSGlobalVariables('ClientId' ).value
exec sp_Update_DayPart @ClientId= @id


it gives me an error that DTSGlobalVariables function not defined. In this case how can i pass the value of Client Id which is my global variable to my SP.

Thanks in Advance

View 1 Replies View Related

SSIS Script Global Variables

Feb 6, 2008

How do i access global variables in SSIS scripts ?

the Dts.variables("VarName").Value

should work but doesn't ?
do i need to reference the variable another way ?

View 1 Replies View Related

Creation Of Global Variables In Runtime.

Nov 9, 2006

Is it possible to create "global" (package scope) variables in runtime in SSIS packages? If yes, please give some examples.

View 3 Replies View Related

ExecutePackage Task Global Variables

Jan 8, 2008



I'm trying to pass a global variable from a DTS package to the child packages that it calls using ExecutePackage tasks. I have selected the child's global variable on the Inner Global Variable tab and I have selected the parent's global variable on the Outer Global Variable tab. That doesn't work. Whatever I type into the Value column of the Inner Global Variable tab gets passed to the child package. How do I get the parent's global variable passed to the child package? Do I need to set the value on the Inner Global Variable tab to some special word to make it look for the parent's global variable? If I set it to nothing, nothing gets passed.

I have been able to make this work using an ActiveX Script task. I can set the Inner Global Variable value of the Task object to the parent's global variable value, but that's not the clean solution I'm looking for. There must be a simple way to do this because Microsoft's documentation brags about this feature, but they don't explain exactly how to do it.


Thanks

Steve

View 5 Replies View Related

Setting Global Variables In A Script Task, HOW?

Jan 3, 2007

I'm playing (and trying to learn)...

I have an FTP task in a for each containter and am setting the RemotePath using an expression (works great). Thought I could use this to start learning some of the scripting funtionality in SSIS (in a script task) so found some code in this forum (thanks Original Posters!) and tried my hand at some coding... Intent was to create a variable and then dynamically overwrite the Expression in the FTP Task from the script (I know I don't need to do this, I just wanted to use it for learning purposes)....

I have a variable named varFTPDestPathFileName (string) and want to set it to the value of varFTPDestPath (string) + varFTPFileName (string). Note: all variables are scoped at the package level (could this be the problem?). I did not assign any of the variables to ReadOnly or ReadWrite on the Script Task Editor page (seems to me that doing this in the code is a whole lot cleaner [and self documenting] than on the Task Editor page)...

I keep getting the following error:
"The element cannot be found in a collection. This error happens when you try to retrieve an element from a collection on a container during execution of the package and the element is not there."

Here is the script:

Public Sub Main()
Dim vars As Variables
' Lock for Read/Write the variables we are going to use
Dts.VariableDispenser.LockForRead("User::varFTPDestPath")
Dts.VariableDispenser.LockForRead("User::varFTPFileName")
Dts.VariableDispenser.LockForWrite("User::varSourcePathFileName")
Dts.VariableDispenser.GetVariables(vars)

' Set Value of varSourcePathFileName <<--- ERROR OCCURS HERE
vars("User::varSourcePathFileName").Value = _
Dts.Variables("User::varFTPDestPath").Value.ToString + _
Dts.Variables("User::varFTPFileName").Value.ToString

vars.Unlock()

Dts.TaskResult = Dts.Results.Success

End Sub

I would also like to be able to loop through the Dts.VariableDispensor to see the contents of the variables and their values.

Somthing like

For each ??? in vars
msgbox(???.Value)
Next

One other question... Do we always have to preface the variable with "User::" or "System::", if so can you explain why?

Any help would be much appreciated....

View 17 Replies View Related

Usage Of Global Variables Inside SQL Task

Mar 11, 2008

I've been looking around but haven't yet found the syntax for usage of global variables in an SQL Task.

I've set the global variable Id (see code below):

if (select field from table where id = @[User::id]) is null
select top 1 1 as response from table
else select top 1 0 as response from table

My objective with it is to set another global variable (@isNull). Supposably, when the selection returns null, I should set the variable to null, I did it by using the selections and mapping the response to that variable (is ther a better way to do so?).

When I try to execute this, it says the variable has not been defined.
Here is the error:

Error: Must declare the variable '@'.

I've also tryed it withou the brackets and the User:: thing in the beggining, (@id directly) and here is the response:

Error: Must declare the variable '@id'.

How should I access the global variables in the SQL code?
(BTW, I've checked the field in execution time and it is set to 23, the correct Id, so the block that preceedes this one is working properly)

Thanks,




View 6 Replies View Related

How To Access Static Global Variables In WPF Form

Dec 5, 2007



Hi,

can i keep my global variables in app.xaml.cs file.

if yes then how will i access those variables in MyFirstApp.xaml.cs file??

if no then what is other alternate to create global variables so that it can be access through out the project??

thanx alot
Mohan

View 4 Replies View Related







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