Quantcast
Channel: Questions in topic: "variables"
Browsing all 49 articles
Browse latest View live
↧

Declare Variable

I am trying to declare the following variable. calmonth comes from table so I get an error that it is invalid column name. I want to use something like the %type attribute but is that available in...

View Article


Dynamic varchar variable

I want to create a dynamic varchar variable like 'B0001'. if the last charcater of the variable exceeds 9 then the variable should look like 'B0010' and if the last character exceeds 99 the variable...

View Article


Is it possible to roll back a date when a field ID changes?

![alt text][1] Greetings all, I am needing to know is it possible in SQL Server 2008 R2 to make a date change as a particular row id changes? I have to recreate a sales import process. I always grab...

View Article

SSIS Variables in For Loop

I am trying to run a discrete extract for six consecutive months. I have set a Global variable @[User::startDate] at the package level. I have Configured the for loop as follows: InitExpression =...

View Article

SSIS - PASSING VARIABLES IN AS ORACLE DATE

I am trying to use a date populated in an ssis package inside of a query to pull from an oracle table. My script will be a variable called in the ole db source so in this variable - called MyOraclePull...

View Article


Why can't I select from a table name defined as a variable

Depending on the season, I have to select from the appropriate table (stored in a configuration table). A simplified version of it is below (does not work) DECLARE @TableNameTY varchar(15) set...

View Article

Need to use the contents of a field in a table select

Need to use the contents of a field as a table select. For example, my table (ATest) contains a field name (selection_id). The contents of the field contains a table name (selection_12345) that I need...

View Article

how to declare range of variables (Ex: declare @rno1 numeric, @rno2 numeric,...

how to declare range of variables (Ex: declare @rno1 numeric, @rno2 numeric, @rno3 numeric, @rno4 numeric, .....@rno100 numeric)

View Article


Table Variables with Linked Server

I am trying to match a small record set (500 records) with a huge dataset on a linked server...the linked server tables have about 2 million records so i want all the processing to occur remotely and...

View Article


Error when EXEC is used with a temp table variable

This is a simplified version of what I am doing. I am building a sql statement using a loop, which creates code for a pivot table. When I run this with the select statement it runs fine, but when I use...

View Article

SSIS - Variable driven connection string

I wonder if anyone can help. I need to create a connection string that will get it's database and server details from a table. I have created variables, populated them, returned the details to check...

View Article

Deleting Specific Number of Records Per id

We have 67 id's each of which contain x number of emails. So id 1 may have 10000, id 2 may have 12,350... The client wants 12,500 per id final. Before we send to the program to remove the bad emails,...

View Article

Using variables in Select,From,where clauses

I have captured table and column names from INFORMATION_SCHEMA.COLUMNS and .TABLES in a temporary table. I want to search these select columns in their respective tables for a specific int value. I...

View Article


DB2 UDB to SQL Server 2012 using SSIS

Hello: I am new to SSIS and I desperately need your help! I need to move 10,000 tables from a DB2 database (9.7.4) to SQL Server 2012 along with their indexes (if possible) as well as data. I have...

View Article

Using variables in a SQL Query (ALM) ?

I am trying to run a SQL Query in ALM12 like the following select count(*) from sample where name = 'sam' and date = '01/01/15' Is there any way i can assign the values (sam, 01/01/15) to variables and...

View Article


Copying a file to a new location adding the datetimestamp

I have created the variable. I keep getting an error with the below code trying to add the datetimestamp. @[Dest_Dir]+"\\snap3\share1\uploads\[SAP Report...

View Article

SSIS Package

I need a step by step walk through on how i can create a stored procedure, add it to my package to fire off and create the table i want. I have the syntax for all the tables i need to create. My end...

View Article


Please help me its very urgent

I am extracting data from multiple servers but I am getting this error please help me for this [Source [269]] Error: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code:...

View Article

DTS_E_OLEDBERROR in SSIS please help me on this

I am extracting data from multiple servers by using SSIS package but I am getting this error please help me for this [Source [269]] Error: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has...

View Article

For loop container loop error please help me on this

The package is for getting data from sql server and loading into ms acces database which is already available in one folder and this package will run every day and it will create a file with present...

View Article
Browsing all 49 articles
Browse latest View live