Selecting from a SQL Server 2005 with long column names ( 30 chars)

Hi,
I was able to set up a db link from Oracle 11.2.0.1 to SQL Server 2005 using DG4ODBC.
My problem is that some column names in the Sql Server are longer than 30 chars and trying to select them gives me the ORA-00972: identifier is too long error.
If I omit these columns the select succeeds.
I know I can create a view in the sql server and query it instead of the original table, but I was wondering if there's a way to overcome it with sql.
My select looks like this:
select "good_column_name" from sometable@sqlserver_dblink -- this works
select "good_column_name","very_long_column_name>30 chars" from sometable@sqlserver_dblink -- ORA-00972Thanks

I tried creating a view with shorter column names but selecting from the view still returns an error.
create view v_Boards as (select [9650_BoardId] as BoardId, [9651_BoardType] as BoardType, [9652_HardwareVendor] as
HardwareVendor, [9653_BoardVersion] as BoardVersion, [9654_BoardName] as BoardName, [9655_BoardDescription] as BoardDescription,
[9656_SlotNumber] as SlotNumber, [9670_SegmentId] as SegmentId, [MasterID] as MasterID, [9657_BoardHostName] as BoardHostName,
[9658_BoardManagementUsername] as BoardManagementUsername, [9659_BoardManagementPassword] as BoardManagementPassword,
[9660_BoardManagementVirtualAddress] as BoardManagementVirtualAddress, [9661_BoardManagementTelnetLoginPrompt] as
MANAGEMENTTELNETLOGINPROMPT, [9662_BoardManagementTelnetPasswordPrompt] as MANAGEMENTTELNETPASSPROMPT,
[9663_BoardManagementTelnetCommandPrompt] as MANAGEMENTTELNETCOMMANDPROMPT FROM Boards)performing a select * from this view in sqlserver works and show the short column names
this is the error i'm getting for performing a select * from v_boards@sqlserver_dblink
ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
[Microsoft][SQL Native Client][SQL Server]Invalid column name 'BoardManagementTelnetLoginProm'. {42S22,NativeErr = 207}[Microsoft]
[SQL Native Client][SQL Server]Invalid column name 'BoardManagementTelnetPasswordP'. {42S22,NativeErr = 207}[Microsoft][SQL Native
Client][SQL Server]Invalid column name 'BoardManagementTelnetCommandPr'. {42S22,NativeErr = 207}[Microsoft][SQL Native Client][SQL
Server]Statement(s) could not be prepared. {42000,NativeErr = 8180}
ORA-02063: preceding 2 lines from sqlserver_dblinkI also tried replacing the * with specific column names but it fails on the columns that have a long name (it doesn't recognize the short names from the view)
what am I doing wrong?
Edited by: Pyrocks on Dec 22, 2010 3:58 PM

Similar Messages

  • Copy table from Ms SQL Server 2005 to Oracle with SSIS package

    Hi all
    I am witting an SSIS package to copy 2 tables from Ms SQL Server 2005 to an Oracle 10g database.
    Problem: I can only see the Microsoft OLDB Provider for Oracle and it is too slow. How can I use the Oracle ODBC in aMs SQL Server 2005 or building a .net SSIS package.
    thanks

    Yes I am able to see the driver on the Data Source (ODBC), I also created a connection to the Oracle database. The problem in Ms SQL Server 2005 is that the ODBC connection I created is not listed. None of the lo local connections are listed, only Microsoft OLEDB connections

  • How to enable high availability on SQL Server 2005 with Windows Server 2008 Enterprise R2

    Dear Folks,
    I would like to ask you about this thing. I'm working for IT department for bank in Myanmar. Our bank have up to 96 branches across all of Myanmar including H.O. We are using Microsoft SQL Server 2005 with Windows Server 2008 for our banking
    information system. My main problem is having to backup and restore the database backup files every time the servers in branches goes down for whatever reasons. I want to deploy this feature of high availability and failover cluster using Windows Server 2008
    and SQL Server 2005. Our branches have 2 Servers. One is for Primary and other is for Backup. What I want to do is that, I want to change Backup Server to Primary Server whenever the Primary Server goes down for whatever reasons. All the working data and databases
    from Primary will immediately replicated into Backup Server along with all the IP information of Primary Server. Please give me step by step guide for this process.

    Try below
    http://blogs.msdn.com/b/cindygross/archive/2009/10/23/checklist-for-installing-sql-server-2005-as-a-clustered-instance.aspx
    I will recommend you to upgrade SQL server to newer version for support as well as flexibility.
    Regards,
    Vishal Patel
    Blog: http://vspatel.co.uk
    Site: http://lehrity.com

  • How to integrate from MS SQL SERVER 2005 and Flatfile to Oracle 10g.

    Hi
    I am new to ODI. I am trying to load sample data from MS SQL Server 2005 and Flatfile to Oracle 10g.
    1. I have created three models.
    1-1. SQL2005 (SRC_CUSTOMER table)
    1-2. Flatfile (SRC_AGE_GROUP.txt & SRC_SALES_PERSON.txt)
    1-3. Oracle 10g (TRG_CUSTOMER table)
    You may know I got those environments from the ODI DEMO environment.
    2. I could able to reverse the tables also.
    3. I have created an interface which contains source table (from MSSQL 2005), Flatfile and target table from ORACLE model.
    4. I have imported the knowledge modules. But I am confusing in selecting the knowledge modules to source and target tables.
    I've selected LKM File to SQL for flatfile model.
    I've also selected LKM SQL to SQL for MSSQL 2005 model and IKM Oracle Incremental Update for the target table (ORACLE).
    I've also implemented the interface that I created. It worked without errors. But there is no data in target table which is TRG_CUSTOMER.
    I really would like to know what happened and what the problems are.
    You can email me [email protected]
    Thanks in advance
    Jason Lee

    what did give for SRC_AGE_GROUP SRC_CUSTOMER join condition
    if it is
    (SRC_CUSTOMER.AGE=SRC_AGE_GROUP.AGE_MIN) AND SRC_CUSTOMER.AGE=SRC_AGE_GROUP.AGE_MAX
    give it as
    (SRC_CUSTOMER.AGE>SRC_AGE_GROUP.AGE_MIN) AND SRC_CUSTOMER.AGE<SRC_AGE_GROUP.AGE_MAX

  • Errors while migrating from Microsoft SQL Server 2005 to Oracle 9i

    Hi All,
    We are trying to completely move our application from Microsoft SQL Server 2005 Database to Oracle 9i. I am doing it using the latest version of Oracle SQL Developer (1.2 build 29.98).
    When I right click my MSSQL server db and click "Capture Microsoft SQL server", it just shows a dialog with "Close" enabled.
    Kindly help.
    The migration Log has the following messages:
    oracle.dbtools.metadata.persistence.PersistenceException: Unsupported feature
    oracle.dbtools.metadata.persistence.PersistenceException: Unsupported feature
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    oracle.dbtools.metadata.persistence.PersistenceException: Protocol violation
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    oracle.dbtools.metadata.persistence.PersistenceException: Protocol violation
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    oracle.dbtools.metadata.persistence.PersistenceException: Protocol violation
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    oracle.dbtools.metadata.persistence.PersistenceException: Bigger type length than Maximum
    oracle.dbtools.metadata.persistence.PersistenceException: Bigger type length than Maximum
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    Error ocurred during capture: Protocol violation
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    oracle.dbtools.metadata.persistence.PersistenceException: Protocol violation
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    oracle.dbtools.metadata.persistence.PersistenceException: Protocol violation
    oracle.dbtools.metadata.persistence.PersistenceException: OALL8 is in an inconsistent state
    oracle.dbtools.metadata.persistence.PersistenceException: Bigger type length than Maximum
    I cant figure out what do these messages mean.
    Regards,
    Sandeep

    Pasting the errors on logging page, if this is of any help:
    SEVERE     150     0     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:OALL8 is in an inconsistent state
    SEVERE     151     1485     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:Protocol violation
    SEVERE     152     15     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:OALL8 is in an inconsistent state
    SEVERE     153     10954     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:Protocol violation
    SEVERE     154     15     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:OALL8 is in an inconsistent state
    SEVERE     155     2688     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:Protocol violation
    SEVERE     156     1140     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:OALL8 is in an inconsistent state
    SEVERE     158     62172     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:OALL8 is in an inconsistent state
    SEVERE     160     3672     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:Protocol violation
    SEVERE     161     63     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:OALL8 is in an inconsistent state
    SEVERE     162     0     oracle.dbtools.raptor.utils.NLSUtils     Error loading nls:Protocol violation

  • DB Migration from MS SQL Server 2005 to Oracle 9i

    Hi Guys
    I want to migrate the data from Microsoft SQL Server 2005 to Oracle 9i.
    Could ou please suggest me the how to proceed.
    I can simply extract the das in CSV format as their are Foreign key , Primary key concept is there. So what will be the best way to proceed ....
    regards
    Macky

    Macky,
    In the coming months we will add support for SQL Server 2005 to the Oracle Migration Workbench. See our statement of direction on OTN for more details.
    If you have extracted the data into a csv file format, you could construct a SQL Loader control file to load this data, assuming you have already created the table on the Oracle side.
    Donal

  • Creating multiple graphs dashboard in Crystal XI using a single View from MS SQL Server 2005

    How to create multiple graphs dashboard in Crystal XI using a single View from MS SQL Server 2005?
    I need to use Crystal XI and create a dashboard which shows some sales data and stuff, multiple graphs on a single screen.
    My tech team says they can display one graph per page but not 4 graphs on the same page as it uses a common view from SQL Server 2005.
    How to manage this? Can we call in multiple views / graphs in the same page? Say 4 graphs on the same page?
    We use ASP or .NET for calling crystal reports into the App.
    Regards,
    Akshay.
    INDIA

    Have you tried creating multiple sections, putting each graph in a separate section and then underlaying the sections so they appear next to each other?

  • I want to use Golden Gate to connect MS SQL Server 2005 with Oracle 10g dat

    I want to use Golden Gate to connect MS SQL Server 2005 with Oracle 10g database. So, i have installed both databases on different pc's on windows platform. MS SQL Server 2005 on windows XP and Oracle 10g on windows 2003.
    I have configure Golden Gate step by step by following oracle guideline:
    http://www.oracle.com/technetwork/articles/datawarehouse/oracle-sqlserver-goldengate-460262.html
    When i run following command on target (oracle 10g):
    replicat paramfile dirprm/inload.prm
    I encounterd following error:
    2012-05-21 20:27:06 ERROR OGG-00014 Unrecognized parameter: USERID. Paramete
    r could be misspelled or unsupported.
    2012-05-21 20:27:06 ERROR OGG-01668 PROCESS ABENDING.
    My INLOAD FILE Content are:
    SPECIALRUN
    END RUNTIME
    USERID gg_user, PASSWORD welcome1
    EXTFILE D:\oracle\gg\dirdat\ex
    SOURCEDEFS D:\oracle\gg\dirdef\emp.def
    MAP hrschema.emp, TARGET gg_user.emp;
    Can you plz suggest me that where i am wrong?
    Thanks advance to all experts.

    amardeep.sidhu wrote:
    That should work, just in case try adding DBLOGIN before USERID
    DBLOGIN USERID x..No needed in the param file i think.its not needed at all you are right, but what else could it be? Besides any special unseen character :P

  • CONNECT SQL SERVER 2005 WITH Oracle 10.2.0.3

    Hi,
    I used URL http://www.databasejournal.com/features/oracle/article.php/10893_3442661_2 but its not working.
    I was reading note# 561033.1 adn planning to try.
    If any one done ,please let me know.

    user587327 wrote:
    its not working" is pretty vague. How about if you tell us
    1) What version of Oracle rdbms you are working with (ok, I see 10.2.0.3 in subject .. good)
    2) what OS it is running on (obviously SQL Server is on Windoze, but that doesn't mean that's where Oracle is) : Linux RHEL 4.4 64 bit
    3) what you are trying to do (get an Oracle database to retrieve data from SQL Server? vice versa? something else?):
    Connect to Oracle database and retrieve data from SQL SERVER 2005.So, you want the Oracle DB to act as a client to the SQL Server db?
    >
    4) what error code (ora-nnnnn or tns-00000) you are getting
    Showing
    SQL> desc spt_values@MYSQL
    ERROR:
    ORA-28545: error diagnosed by Net8 when connecting to an agent
    Unable to retrieve text of NETWORK/NCR message 65535
    ORA-02063: preceding 2 lines from MYSQL
    ----I've never used HSO to SQL Server, so I'm getting out of my area here. However ...
    I'm puzzled by the error msg referencing "Net8". Looks like an Oracle 8i construct but you said your db is 10.2. And since the box is Linux I wouldn't expect to find an old 8i installation lurking on it.
    I searched MetaLink (should be everyone's first resource when trying to understand an error message) for "ora-28545" and got 13 hits.
    >
    5) any other diagnostic messages you might have

  • Integrating SQL Server 2005 with OBIEE 11g

    Dear Gurus,
    Is there any documentation about how to using SQL Server 2005 as datasource combined with OBIEE 11g?
    Clear steps with pictures will be very helpful.
    Thank so much
    Regards
    JOE

    Hi,
    Please refer this link.
    http://rnm1978.wordpress.com/2009/08/21/querying-sql-server-from-obiee-running-on-unix/
    Re: How to connect Linux OBIEE repository to SQL Server 2005 database
    Hope this help's
    THanks
    Satya

  • JDBC - MS SQL Server 2005 with multible instances

    I want to get data from a Microsoft SQL Server via JDBC. We have such a scenario and till now it works fine. Now we have a second instance at the sql server and we want to connect to this instance. I've found the following MSD article:
    http://msdn2.microsoft.com/en-us/library/ms378428.aspx
    <b>SQL Server 2000 and SQL Server 2005 allow for the installation of multiple database instances per server. Each instance is identified by a specific name. To connect to a named instance of SQL Server, you can either specify the port number of the named instance (preferred), or you can specify the instance name as a JDBC URL property or a datasource property. If no instance name or port number property is specified, a connection to the default instance is created. See the following examples:
    To use a port number, do the following:
    jdbc:sqlserver://localhost:1433;integratedSecurity=true;<more properties as required>;
    To use a JDBC URL property, do the following:
    jdbc:sqlserver://localhost;instanceName=instance1;integratedSecurity=true;<more properties as required>;</b>
    Because the named instance has no explicit port  I've tried to use the second one but this doesn't work. I've tried all possible combinations of these parameters but either I get an error or my adapter connects to the first instance
    Any idea how I can connect to the second named instance?

    We have also a SQL server 2000 instance at the same server. Yesterday I have spoken with the sql server admin and he told me that he has disconnect the sql server 2000 databases whatever this means. :-D
    Now all works fine. Thank you for your help
    BTW I use the following connection string:
    jdbc:sqlserver://my_db_server;instanceName=my_instance_name;DatabaseName=my_db_name

  • Migrating from MS SQL Server 2005 database to Oracle 10g

    Hello,
    I wanted the full procedure or steps to Migrate the MS SQL Server 2005 database to Oracle 10g. Is there a known procedure to do this or is there a tool which is used?
    I have not done migration of database from MS SQL Server to Oracle. Any help is appreciated. Thanks a lot for the time.
    Regards,
    RPS

    Wrong forum, go to the database forum!
    cu
    Andreas

  • Migrating CMP EJB mapped to SQL Server table with identity column from WL

    Hi,
        I want to migrate an application from Weblogic to SAP Netweaver 2004s (7.0). We had successfully migrated this application to an earlier version of Netweaver. I have a number of CMP EJBs which are mapped to SQL Server tables with the PK as identity columns(autogenerated by SQL Server). I am having difficulty mapping the same in persistant.xml. This scenario works perfectly well in Weblogic and worked by using ejb-pk in an earlier version of Netweaver.
       Please let me know how to proceed.
    -Sekhar

    I suspect it is the security as specified in the message. E.g .your DBA set the ID columns so no user can override values in it.
    And I suggest you 1st put the data into a staging table, then push it to the destination, this does not resolve the issue, but ensures better processing.
    Arthur
    MyBlog
    Twitter

  • SQL Server 2005 with an ODBC-JDBC Bridge

    Hello,
    I use an ODBC - JDBC Bridge (because when I use SQL Server 2005 Driver JDBC Version 1.1, the text connection failed). I don't know why I can't reverse my model.
    What happened?
    thanks
    Billie

    We have also a SQL server 2000 instance at the same server. Yesterday I have spoken with the sql server admin and he told me that he has disconnect the sql server 2000 databases whatever this means. :-D
    Now all works fine. Thank you for your help
    BTW I use the following connection string:
    jdbc:sqlserver://my_db_server;instanceName=my_instance_name;DatabaseName=my_db_name

  • Changing installation PATH on SQL Server 2005 with SAP DVD

    Hi experts,
    i would like to install SQL Server 2005 delivered by SAP on another disk, for example D: instead of C:\Program files\
    i read the note 363018 but there's no solution to my problem.
    Thanks in advanced for your help.
    Pascal.

    Hi Markus,
    yes, that's what i have expected but i m not good enought to find the changement to do.
    Am i allowed to post the script?
    Thanks.

Maybe you are looking for

  • Best practice for Active Directory User Templates regarding Distribution Lists

    Hello All I am looking to implement Active Directory User templates for each department in the company to make the process of creating user accounts for new employees easier. Currently when a user is created a current user's Active directory account

  • NEED ADVICES FOR RME HDSPe AIO and (other audio devices)

    Hi all! i was wondering if someone have some experience with RME HDSPe AIO card.. I'm thinking about buying one but is the latency for software monitoring (in logic pro) is good ? any issues on OS X 10.6.5? Here's my situation..at the moment i'm usin

  • Changes in events calendar

    Hello I download this event calendar. I try to change starting week from Mondays by changing this: firstDay = firstDate.getDay() + 7;and retyping days in function createCalendar() But after that is not green marked present day. It is but in 2009 year

  • Javascript, Text frame - Flip Horizontal

    I just don't understand javascript very well yet. I want to flip horizontally, a text frame, on it's center/in place. (Yes, I want the text to be wrong reading.) the name of the text frame is smallTXXX and the indesign document will be open at the ti

  • PDF File Generation in SAP-ByD

    Dear All, How to generate PDF file based  reports in SAP-ByD Best Regards, Harish.Y