Fetch the data from sql server table to array

In the following script i am fetching the servers details from text file. Please anyone help me to get the same information from sql server database table. with using this query
"SELECT DISTINCT [server_name]
FROM
Servers] where
Status='1'"
$ServerName =Get-Content "c:\servers\servers.txt"
 foreach ($Server in $ServerName) {
     if (test-Connection -ComputerName $Server -Count 4 -Delay 2 -Quiet ) {
       write-output "$Server is alive and Pinging `n"
       } else {
Write-output "TXUE $Server seems dead not pinging"

i have tested it is not working..
=@"
SELECT DISTINCT [server_name] FROM Servers] where Status='1'
$connection
=new-objectsystem.data.sqlclient.sqlconnection(
"Data Source=xxx;Initial Catalog=xxx;Integrated Security=SSPI;”)
$adapter
=new-objectsystem.data.sqlclient.sqldataadapter($query,
$connection)
$table
=new-objectsystem.data.datatable
$adapter
.Fill($table)
| out-null
$compArray
=@($table)
##### Script Starts Here ######
foreach($Serverin$ServerName)
if(test-Connection-ComputerName$Server-Count4
-Delay2
-Quiet)
write-output"$Server
is alive and Pinging `n"
else{
$query

Similar Messages

  • Extract the data from SQL Server and Import into Oracle

    Hi,
    I would like to run a daily job that will export the table data from SQL server table (it will be only one or two table) and Import back into Oracle table (it might one or two table tables).
    Could you please guide me that how can i do this using either sql server or oracle?
    We have oracle 9.2 and sql server 2005.
    Normally i do from flat file which is generated by source destination nand i dump into oracle using sql*loader but this time I have to directly extract/export the data from MS Sql server and load into Oracle table, mostly it will reload so i might doing any massaging data during the load.
    If you show me the detail approach, it will be really appreciated.
    I have access to Sql server but i don't how to use sql server to do this or using oracle as a daily job even becuase have to schedule the job for this as it will be a daily job.
    Thanks,
    poratips

    Unless you can find an open source ODBC driver for SQL Server that runs on Solaris (and I wouldn't be overly hopeful there) Heterogeneous Services would require that you license something-- a third party ODBC driver, a new Oracle instance, or an Oracle Transparent Gateway.
    As I stated below, you could certainly use SQL Server's ETL tool, DTS. Oracle's ETL tools would require additional licensing since you're just on 9.2. You could also write a small application (Java or otherwise) that connected to both databases and transferred the data. If you're particularly enterprising, you could load the SQL Server Type 4 JDBC driver into Oracle's JVM and write a Java stored procedure that connected to the SQL Server database via JDBC, but that's a pretty convoluted approach.
    Justin

  • Copy the data from Sql Server to edirectory using java

    Hi ,
    I am new to e directory.I don't know how it works.Can some one assist
    me on this ,I have to extract data from SQL Server and update these
    data in edirectory.This is needs to be done using java.
    If any one can provide me the sample code or please suggest how to
    proceed .
    Thanks in advance
    dukewarm
    dukewarm's Profile: http://forums.novell.com/member.php?userid=53430
    View this thread: http://forums.novell.com/showthread.php?t=373051

    dukewarm;1792481 Wrote:
    > Hi ,
    >
    > I am new to e directory.I don't know how it works.Can some one assist
    > me on this ,I have to extract data from SQL Server and update these
    > data in edirectory.This is needs to be done using java.
    >
    > If any one can provide me the sample code or please suggest how to
    > proceed .
    >
    > Thanks in advance
    Read the values from SQL server and use LDAP to update the data in
    eDirectory.
    Thomas
    thsundel
    thsundel's Profile: http://forums.novell.com/member.php?userid=128
    View this thread: http://forums.novell.com/showthread.php?t=373051

  • Need to delete specific Months Data from SQL Server Table

    Greetings Everyone,
    So i have one table which contains 5 years old data, now business wants to keep just one year old data and data from qurter months i.e. (jan, mar, June, sep and December), i need to do this in stored procedure. how i can achive this using month lookup table.
    Thank you in advance
    R

    Hi Devin,
    In a production environment, you should be double cautious about the data. I have no idea why you’re about to remove the data just years old. In one of the applications I used to support, the data retention policy is like to keep raw data for latest month
    and the elder data would get rollup as max, min, average and so on to store in another table. That’s a good example for data retention.
    In your case I still suggest you keep the elder data in another table. If the data size is so huge that violates  your storage threshold, get the data rollup and store the aggregated would be a good option.
    Anyway if you don’t care about the elder data, you can just delete them with code like below.
    DELETE
    FROM yourTable
    WHERE YEAR(dateColumn) < YEAR(CURRENT_TIMESTAMP) OR (MONTH(dateColumn) not in (1,3,6,9,12) AND YEAR(dateColumn) = YEAR(CURRENT_TIMESTAMP))
    In some cases to remove data from very large table, DELETE performs bad. TRUNCATE would be a better option which works faster. Read more by clicking
    here. In your case, if necessary, you can reference the below draft code.
    SELECT * INTO tableTemp FROM yourTable WHERE YEAR(dateColumn) = YEAR(CURRENT_TIMESTAMP) AND MONTH(dateColumn) IN(1,3,6,9,12)
    TRUNCATE yourTable;
    INSERT INTO yourTable SELECT * FROM tableTemp
    As you mentioned, you need to do the deletion in Stored Procedure(SP). Can you post your table DDL with sample data and specify your requirement details so that I can help to compose your SP.
    If you have any question, feel free to let me know.
    Best regards,
    Eric Zhang

  • How to create a sharepoint list to add/change/delete the data in SQL server Table based on users inputs

    I have a table in sql with employee_num and I need to create a list and link that list to this table to make changes to table based on values user enter or selects.

    Hi,
    In addition, you could refer to one similar thread for related information:
    http://social.technet.microsoft.com/Forums/sharepoint/en-US/8ee8a7b2-ddfc-4654-b84e-b062aeb527ae/how-to-create-exernal-list-in-sharepoint-which-fetch-data-from-multiple-sql-table?forum=sharepointgeneral
    Regards,
    Rebecca Tu
    TechNet Community Support

  • How to select data from Sql server 2005 database tableinto oracle database table

    Hi,
    I have table text1 in sql server database and text2 in oracle database (11g). Now how to move data from SQL Server table into oracle table. So please help me how to do it.
    Thanks a lot in advance.
    rk
    OS: Windows 7 professional

    Hi,
    you can use export/import wizard and specify sql server as a source and oracle as destination.
    I hope this is helpful.
    Please Mark it as Answered if it answered your question
    OR mark it as Helpful if it help you to solve your problem
    Elmozamil Elamir Hamid
    MCSE Data Platform
    MCITP: SQL Server 2008 Administration/Development
    MCSA SQL Server 2012
    MCTS: SQL Server Administration/Development
    MyBlog

  • Error while reversing data from SQL Server to ODI

    hi,
    I was reversing data from SQL Server Java 1.6_022 in ODI Java 1.5, I was getting error Version Mismatch and I updated ODI Java version to 1.6_022.
    And now, I am getting the below error while reversing the data from SQL Server database.
    0 : 08001 : java.sql.SQLException: No suitable driver
    Looking for the assistance on the same.
    Thanks,
    Abhay

    If everything is fine the reversing should be fine. I would say check again if the Technology of the Model and the also the dataserver is created under the right Technology in topology too.
    also if this doesn't help , Please tell us the steps you have carried so far . Also can you try selective reverse is it showing the tables.

  • To fatch the data from sql to excel ??? any idea....

    dear all,
    my problem is - i want to retrive the data from sql server to excel sheet... can any one suggest the idea what to do ???
    thanks.

    You can open two connections. One to SQL Server (you can use a thin or JDBC-ODBC bridge), the other to your Excel spreadsheet using the JDBC-ODBC bridge. You could query the SQL Server database, massage and format your data, then write it to Excel. Excel works with a very limited set of SQL. Here is a program from a post by Tim Vickers that others sounded happy to have. I'm reposting here for your convenience. I have not personally run this program, so please use it at your own risk.
    import java.sql.*;
    import java.io.*;
    import java.util.*;
    import java.text.*;
    * Name: Excel.java
    * Purpose: To demonstrate how to use ODBC and Excel to create
    * a table,
    * insert data into it, and select it back out.
    * Version: Developed using JDK 1.3, but also works with JDK
    * 1.2.2
    * Instructions:
    * 1) Create a new Excel spreadsheet
    * 2) Create a new ODBC data source that points to this
    * spreadsheet
    * a) Go to Control Panel
    * b) Open "ODBC Data sources (32-bit) (wording may be
    * slightly
    * different for different platforms)
    * c) Under "User DSN" tab, press "Add" button
    * d) Select the "Microsoft Excel Driver (*.xls)" and
    * press
    * "Finish" button
    * e) Enter "Data Source Name" of "TestExcel"
    * f) Press "Select Workbook" button
    * g) Locate and select the spreadsheet you created in
    * Step 1
    * h) Unselect the "Read Only" checkbox
    * i) Press "Ok" button
    * 3) Compile and run Excel.java
    * 4) Open Excel spreadsheet and you will find a newly
    * created
    * sheet, GOOD_DAY, with three rows of data.
    * Notes:
    * If you want to select data from a spreadsheet that was
    * NOT
    * created via JDBC-ODBC (i.e. you entered data manually
    * into
    * a spreadsheet and want to select it out), you must
    * reference
    * the sheet name as "[sheetname$]".
    * When you create the table and insert the data using
    * Java, you
    * must reference the sheet name as "sheetname".
    * Also, do not have the spreadsheet open when you are
    * running
    * the program. You can get locking conflicts.
    public class Excel {
        public Excel() {
            setDefaults();
        private static void m(String pMessage) {
            System.out.println(pMessage);
        private void setDefaults() {
            setDriver("sun.jdbc.odbc.JdbcOdbcDriver");
            setUrl("jdbc:odbc");
            // ODBC data source named "TestExcel" defined from
            Control Panel
            setDataSource("TestExcel");
            setTableName("GOOD_DAY");
        public void openDatabase() {
            String lConnectStr = getUrl()+":"+getDataSource();
            try {
                Class.forName(getDriver());
                gConnection = DriverManager.getConnection(lConnectStr);
            catch (Exception e) {
                m("openDatabase(): "+e.getMessage());
        private void closeDatabase() {
            try {
                getConnection().close();
            catch (Exception e) {
                m("closeDatabase(): "+e.getMessage());
        private void createTable() {
            m("createTable() begin");
            Statement lStat = null;
            try {
                lStat = getConnection().createStatement();
                lStat.execute("CREATE TABLE "+getTableName()+" ("
                +" ID INTEGER"
                +" ,NAME VARCHAR"
                +")");
            catch (Exception e) {
                m("createTable(): "+e.getMessage());
            m("createTable() end");
        private void doInsert() {
            m("doInsert() begin");
            Statement lStat = null;
            try {
                lStat = getConnection().createStatement();
                lStat.executeUpdate("INSERT INTO "
                +getTableName()+"(ID,NAME) VALUES
                (10,'KANGAROO')");
                lStat.executeUpdate("INSERT INTO "
                +getTableName()+"(ID,NAME) VALUES (20,'KOALA')");
                lStat.executeUpdate("INSERT INTO "
                +getTableName()+"(ID,NAME) VALUES (30,'PAUL
                HOGAN')");
                lStat.close();
            catch (Exception e) {
                m("doInsert(): "+e.getMessage());
            m("doInsert() end");
        private void doQuery() {
            m("doQuery() begin");
            try {
                Statement lStat = getConnection().createStatement();
                ResultSet lRes = lStat.executeQuery(
                "SELECT * FROM "+getTableName()
                ResultSetMetaData lMeta = lRes.getMetaData();
                // print out the column headers separated by commas
                for (int i = 1; i <= lMeta.getColumnCount(); ++i) {
                    if (i > 1)
                        System.out.print(", ");
                    String lValue = lMeta.getColumnName(i);
                    System.out.print(lValue);
                System.out.println("");
                // print out the data separated by commas
                while (lRes.next()) {
                    for (int i=1; i<=lMeta.getColumnCount(); ++i) {
                        if (i > 1)
                            System.out.print(", ");
                        String lValue = lRes.getString(i);
                        System.out.print(lValue);
                    System.out.println("");
                lRes.close();
                lStat.close();
            catch (Exception e) {
                m("doQuery(): "+e.getMessage());
            m("doQuery() end");
        private void run() {
            openDatabase();
            createTable();
            doInsert();
            doQuery();
            closeDatabase();
        public static void main(String args[]) {
            m("main() begin");
            Excel lExcel = new Excel();
            lExcel.run();
            m("main() end");
            System.exit(0);
        public void setTableName(String pValue) {
            gTableName = pValue;
        public String getTableName() {
            return(gTableName);
        public void setSql(String pValue) {
            gSql = pValue;
        public String getSql() {
            return(gSql);
        public Connection getConnection() {
            return(gConnection);
        public String getDataSource() {
            return(gDataSource);
        public void setDataSource(String pValue) {
            gDataSource = pValue;
        public void setDriver(String pValue) {
            gDriver = pValue;
        public void setUrl(String pValue) {
            gUrl = pValue;
        public String getDriver() {
            return (gDriver);
        public String getUrl() {
            return (gUrl);
        private Connection
        gConnection = null
        private String
        gDataSource = null
        ,gTableName = null
        ,gSql = null
        ,gDriver = null
        ,gUrl = null
    }

  • Import data from SQL Server to Oracle

    I have created a dblink in oracle to access the SQL database. I am able to run queries through the dblink and it works fine. I have created a test table on Oracle Server to import the data. The field named "description" has CLOB data type. The corresponding datatype on SQL Server is varchar(7000).
    When I insert the data from SQL Server, it completes successfully without any error but it truncates the data on CLOB field.
    If I run the select query in SQLPlus I can see the entire description.
    Select "description" from sql_view@dblink;
    -- the above works fine.
    CREATE table test
    (description CLOB);
    INSERT INTO TEST
    Select "description" from sql_view@dblink;
    -- this works but it truncates the data after 256 characters
    My question is, how to get the data from SQL Server without truncating characters.
    Thanks in advance,
    Gopal

    I hear the same from other friend that sql server truncated the leading zeros from the id column.
    I really don't have a solution for this but you can try the work around. Export the data to flat file and upload in oracle using SQL loader, as this would be much faster and efficient.

  • Fetch the data from the tables in the SQL 2005 server to sap R/3.

    Hi Experts,
    We need to fetch the data from the tables in the SQL 2005 server to sap R/3.
    Please explain which will be the best approach to fetch the same and how to do it. Sample program can greatly help.
    << Please do not offer points >>
    Regards,
    Shobana K
    Edited by: Rob Burbank on Sep 21, 2010 2:36 PM

    Hi,
    Try NATIVE SQL statements in your abap code otherwise you can try to establish jdbc connection from ABAP program.
    search in SDN for samples!
    Suresh

  • How to fetch the data from databse table and get the required output

    Hi,
    I have made a project that connects CEP to database table but i m getting some problem in fetching the data from database.
    From the following code :
    If the where condition is removed then the application runs fine but i am still not able to fetch the data from the table because it is not showing any output.
    Can anyone please suggest me that how to write WHERE statement correctly and how i will be able to see the output.
    Following is the config.xml for processor:
    ======================================
    <?xml version="1.0" encoding="UTF-8"?>
    <wlevs:config xmlns:wlevs="http://www.bea.com/ns/wlevs/config/application"
         xmlns:jdbc="http://www.oracle.com/ns/ocep/config/jdbc">
         <processor>
              <name>JDBC_Processor</name>
              <rules>
                   <query id="q1"><![CDATA[
                             SELECT STOCK.SYMBOL as symbol, STOCK.EXCHANGE as exchange
                             FROM ExchangeStream [Now] as datastream, STOCK
                             WHERE datastream.SYMBOL = datastream.SYMBOL ]]></query>
              </rules>
         </processor>
         <jms-adapter>
              <name>JMS_IN_Adapter</name>
              <jndi-provider-url>t3://CHDSEZ135400D:7001</jndi-provider-url>
              <destination-jndi-name>jms.TestKanikaQueue</destination-jndi-name>
              <user>weblogic</user>
              <password>welcome1</password>
         </jms-adapter>
    </wlevs:config>
    Following is the assembly file:
    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns="http://www.springframework.org/schema/beans"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:osgi="http://www.springframework.org/schema/osgi"
         xmlns:wlevs="http://www.bea.com/ns/wlevs/spring" xmlns:jdbc="http://www.oracle.com/ns/ocep/jdbc"
         xmlns:spatial="http://www.oracle.com/ns/ocep/spatial"
         xsi:schemaLocation="
              http://www.springframework.org/schema/beans
              http://www.springframework.org/schema/beans/spring-beans.xsd
              http://www.springframework.org/schema/osgi
              http://www.springframework.org/schema/osgi/spring-osgi.xsd
              http://www.bea.com/ns/wlevs/spring
              http://www.bea.com/ns/wlevs/spring/spring-wlevs-v11_1_1_3.xsd
              http://www.oracle.com/ns/ocep/jdbc
              http://www.oracle.com/ns/ocep/jdbc/ocep-jdbc.xsd
              http://www.oracle.com/ns/ocep/spatial
              http://www.oracle.com/ns/ocep/spatial/ocep-spatial.xsd">
         <wlevs:event-type-repository>
              <wlevs:event-type type-name="StockEvent">
                   <wlevs:properties>
                        <wlevs:property name="SYMBOL" type="byte[]" length="16" />
                        <wlevs:property name="EXCHANGE" type="byte[]" length="16" />
                   </wlevs:properties>
              </wlevs:event-type>
              <wlevs:event-type type-name="ExchangeEvent">
                   <wlevs:class>com.bea.wlevs.event.example.JDBC_CEP.ExchangeEvent</wlevs:class>
              </wlevs:event-type>
              <wlevs:event-type type-name="StockExchangeEvent">
                   <wlevs:properties>
                        <wlevs:property name="symbol" type="byte[]" length="16" />
                        <wlevs:property name="price" type="byte[]" length="16" />
                        <wlevs:property name="exchange" type="byte[]" length="16" />
                   </wlevs:properties>
              </wlevs:event-type>
         </wlevs:event-type-repository>
         <bean id="readConverter" class="com.bea.wlevs.adapter.example.JDBC_CEP.Adapter_JDBC" />
         <bean id="outputJDBCBean" class="com.bea.wlevs.bean.example.JDBC_CEP.OutputBean_JDBC">
         </bean>
         <wlevs:adapter id="JMS_IN_Adapter" provider="jms-inbound">
              <wlevs:listener ref="ExchangeStream" />
              <wlevs:instance-property name="converterBean"
                   ref="readConverter" />
         </wlevs:adapter>
         <wlevs:processor id="JDBC_Processor" advertise="true">
              <wlevs:listener ref="OutputChannel" />
              <wlevs:table-source ref="STOCK" />
         </wlevs:processor>
         <wlevs:channel id="ExchangeStream" event-type="ExchangeEvent" advertise="true">
              <wlevs:listener ref="JDBC_Processor" />
         </wlevs:channel>
         <wlevs:channel id="OutputChannel" event-type="StockExchangeEvent"
              advertise="true">
              <wlevs:listener ref="outputJDBCBean" />
         </wlevs:channel>
         <wlevs:table id="STOCK" event-type="StockEvent"
              data-source="StockDs" table-name="STOCK" />
         <wlevs:table id="STOCK_EXCHANGE" event-type="StockExchangeEvent"
              data-source="StockDs" table-name="STOCK_EXCHANGE" />
    </beans>
    ExchangeEvent.java:
    package com.bea.wlevs.event.example.JDBC_CEP;
    public class ExchangeEvent {
         public String SYMBOL;
         public String symbol;
         public String exchange;
         public ExchangeEvent() {
         public String getSYMBOL() {
              return SYMBOL;
         public void setSYMBOL(String sYMBOL) {
              SYMBOL = sYMBOL;
         public String getSymbol() {
              return symbol;
         public void setSymbol(String symbol) {
              this.symbol = symbol;
         public String getExchange() {
              return exchange;
         public void setExchange(String price) {
              this.exchange = price;
    Adapter Class:
    package com.bea.wlevs.adapter.example.JDBC_CEP;
    import com.bea.wlevs.adapter.example.JDBC_CEP.MyLogger;
    import com.bea.wlevs.adapters.jms.api.InboundMessageConverter;
    import java.text.DateFormat;
    import java.util.Date;
    import com.bea.wlevs.adapters.jms.api.MessageConverterException;
    import com.bea.wlevs.event.example.JDBC_CEP.ExchangeEvent;
    import javax.jms.JMSException;
    import javax.jms.Message;
    import javax.jms.TextMessage;
    import java.util.ArrayList;
    import java.util.List;
    import java.util.Random;
         public class Adapter_JDBC implements InboundMessageConverter{
         @SuppressWarnings("unchecked")
         public List convert(Message message) throws MessageConverterException, JMSException {
              Random rand = new Random();
              int unique_id = rand.nextInt();
              DateFormat dateFormat;
              dateFormat = DateFormat.getTimeInstance();
              dateFormat.format(new Date());
              MyLogger.info(unique_id + " CEP Start Time is: " + dateFormat.format(new Date()));
              System.out.println("Message from the Queue is :"+ message);
              TextMessage textMessage = (TextMessage) message;
              String stringMessage = textMessage.getText().toString();
              System.out.println("Message after getting converted into String is :"+ stringMessage);
                   String[] results = stringMessage.split(",\\s*"); // split on commas
                   ExchangeEvent event1 = new ExchangeEvent();
                   event1.setSYMBOL(results[0]);
         List events = new ArrayList(2);
         events.add(event1);
         return events;
    Output Bean Class :
    package com.bea.wlevs.bean.example.JDBC_CEP;
    import com.bea.wlevs.ede.api.StreamSink;
    import com.bea.wlevs.event.example.JDBC_CEP.ExchangeEvent;
    import com.bea.core.datasource.DataSourceService;
    public class OutputBean_JDBC implements StreamSink{
         public void onInsertEvent(Object event) {
         if (event instanceof ExchangeEvent) {
              ExchangeEvent cacheEvent = (ExchangeEvent) event;
         System.out.println("Symbol is: " + cacheEvent.getSymbol());
         System.out.println("Exchange is: " + cacheEvent.getExchange());
         System.out.println(DataSourceService.class.getClass());
    Kindly let me know if you need further info.

    Do you have StockDs configured in your server config.xml?
    I think the query should look more like this:
    SELECT stocks.SYMBOL, stocks.EXCHANGE
    FROM STOCK as stocks, ExchangeStream [Now] as datastream WHERE stocks.SYMBOL = datastream.SYMBOL
    Thanks
    andy

  • Using Oracle Forms Importing Data From SQL Server into Oracle Tables.

    Dear All,
    We are using Oracle Forms 10g in windows XP and having OAS 10g and Oracle database 9i.
    How can we import data from SQL Server 2005 into Oracle tables using Oracle Forms?
    Thanks & Regards
    Eidy

    I have no idea what "Oracle Hetrogenius Services" is, so I can't help you with that, sorry.
    SQL Developer might also assist you. SQL Developer can connect to SQL Server as well as Oracle and has some tools for migration. See the documentation for details:
    http://download.oracle.com/docs/cd/E12151_01/doc.150/e12156/toc.htm
    For additional help on using SQL Developer for this task, please consult Support or the SQL Developer forum: SQL Developer
    Hope this helps,
    Jacob

  • How to extract incremental data from SQL server to oracle tables in ODI

    HI All,
    In my ODI sql server is install.My Source is in SQL server and my target is in Oracle.
    I need to create a interface mapping where i need to extract incremental data from sql server to oracle.
    There is a datetime(with Timestamp) field in sql server .I need to pull incremental data based on dateime.
    Example = tablename.DateTime > (select '1-jan-11' from dual) .....i am using this query but its not woking.the error is Invalid object name"dual".
    We are not going to use Incremental in IKM and LKM.
    Request you to please provide any suggestion ASAP.
    Thanks,
    Lony

    You can do that via Variable.
    In the interface mapping create a filter on Tablename.DateTime
    and put the condition like this
    Tablename.DateTime BETWEEN #VAR and in the variable use this query in refreshing tab with oracle schema
    SELECT max(start_time)||' AND '||max(END_TIME)+1 from audit_table where ETL_JOB_CODE = '20'In the package call the above variable in refresh mode and then interface.
    This way you will pass from the query between and condition date and pass to interface so that SQL Server fetches the data between those too range.
    Note:- You might need to tweak the date format so that SQL Server can understand.
    Hope this helps.

  • Fetch the data from two tables

    hell all
    i want to fetch the data from two tables, one is from internal table and another one is data base table. what syntax i have to use either FOR ALL ENTRIES or INNER JOIN?

    hi
    Use FOR ALL ENTRIES.
    see the sample code
      select * into table tvbrk from vbrk
                                where fkart in ('F2', 'F3', 'RE',
                                           'ZVEC' , 'ZVEM' , 'ZVED',
                                           'S1')
                                and erdat in so_erdat
                                and kunag in s_kunag. 
                                      erdat in so_erdat
                               and   fkart in ('F2', 'F3', 'RE',
                                                 'ZVEC' , 'ZVEM').
    if not tvbrk is initial.
        select * into table t_zregion from zregion
                      for all entries in tvbrk
                       where country = tvbrk-land1
                       and   region = s_regio.
      endif.
    thanks
    sitaram

  • Exporting data from SQL Server database to Oracle database

    Hello All,
    We need to replicate a table's data of SQL Server database to Oracle database.
    Can this task be accomplished using Import/Export wizard or Linked servers?
    Can help me regarding which Oracle data access components should i download to do this?
    I am using SQL Server 2012.
    And i have Oracle 11g release 2 client installed in my system.
    Thanks in Advance.
    Thanks and Regards, Readers please vote for my posts if the questions i asked are helpful.

    Yes you can definitely transfer data from SQL server to Oracle Have a look at below links
    Export SQL server data to Oracle Using SSIS
    Use OLEDB data provider to transfer data from SQL server to Oracle
    Using Import Export Wizard
    Similar thread
    Please mark this reply as answer if it solved your issue or vote as helpful if it helped so that other forum members can benefit from it.
    My TechNet Wiki Articles

Maybe you are looking for

  • E-mailing photos

    How do I e-mail an album of photos. I have AOL and Gmail, neither of which I can set as an e-mail preference (under iphoto>preferences>mail using). I know that I can e-mail an individual photo as an attachment on AOL or Gmail, but I want to send a co

  • Blu ray and surround sound

    I just purchased a Sony Bravia kdl-52v4100 and a ps3 to watch blu ray. Now I want to buy a surround sound but watch blu ray at the same time with out buying a blu ray dvd player. Is there any way I can connect my PS3 with the surround sound to play t

  • Artboards and Layers....

    Am I to understand if I have multiple artboards, they all will share the same layers? Each artboard does not have it's own separate set of layers, am I right? This is my first time using the artboard feature... CS6.

  • Problem with re install of CS5 and photoshop CC

    Hi fellow Adobe users\\i have a new pc and have tried to re install photshop CS5 - it wont install  - i have also tried to install photoshop CC trial and it also fails - cchas the code 6 andsays it did not install everything thanks for your help

  • Backoffice methodlogy and data migration tool

    Anybody know about backoffice methodology?This methodology was developed by backoffice associates.I would like to know more about it. see the link below https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/ad903bcc-0901-0010-25bd-a0e5a