Re: Parameterised Query vs LookUps

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



You could create a global variable in the package to store the code for your
SELECT, then use a Dynamic Properties task to assign it to the Data
Transform task. Then you can build the SQL statement with an ActiveX
script.

http://www.sqldts.com has some good examples.

"Neil" <Neil@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:1BEEE5D3-0F09-4009-99DB-1034F790D005@xxxxxxxxxxxxxxxx
> Hi,
>
> I have a Transform Data Tasks which I'm using to load data from an Oracle
> DB
> into a SQL Server DB. The data in Oracle is for all time periods but I
> want
> to filter for a specific day, this day is not known in advance but can be
> derived from a UDF in the SQL Server DB.
>
> Pseudo code
> Select * From OracleDB Where TransactionDate = Result of UDF
>
> What is the best way to achieve this?
>
> I cannot use the results of the UDF in the SQL Query because the
> connection
> being used is the Oracle one so it doesn't understand this. I have read
> that
> you can execute a look up against a diff connection and use this but i've
> been unable to get this to work.
>
> Essentially I need to execute this UDF to get my selected date and then
> use
> this in the where clause to filter.
>
> Thanks
> N


.



Relevant Pages

  • Re: DTS calling Oracle procedure
    ... Can someone let me know if there's a way of calling Oracle's procedure within a SQL Server DTS package please. ... The reason for this is that I need to execute the Oracle procedure to extract data from Oracle tables, then manipulate the data and dump the data into a temporary table which then get exported to SQL Server via DTS package. ...
    (microsoft.public.sqlserver.dts)
  • Parameterised Query vs LookUps
    ... I have a Transform Data Tasks which I'm using to load data from an Oracle DB ... derived from a UDF in the SQL Server DB. ... Select * From OracleDB Where TransactionDate = Result of UDF ... Essentially I need to execute this UDF to get my selected date and then use ...
    (microsoft.public.sqlserver.dts)
  • sql server job failing
    ... from sql server 2000 i created a link to oracle ... and created a procedure which will update sql tables ... and insert into oracle table. ... from query analyser i can execute this procedure. ...
    (microsoft.public.sqlserver.connect)
  • sql job failing
    ... from sql server 2000 i created a link to oracle ... and created a procedure which will update sql tables ... and insert into oracle table. ... from query analyser i can execute this procedure. ...
    (microsoft.public.sqlserver.programming)
  • Re: IOT, memory and transaction time
    ... easily generate it with DBMS_METADATA.GET_DDL if your verison of Oracle ... were pretty consistent no matter how big the table (this transaction ... FOREIGN KEY (versionNo) REFERENCES T_TRANSACTIONS, ... Oracle provides read consistency and SQL Server ...
    (comp.databases.oracle.misc)