Oracle - SQL Server Integration


Published on

Integration of Oracle databases with Microsoft SQL Server.

Published in: Technology
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Oracle - SQL Server Integration

  1. 1. Oracle / SQL Server IntegrationAlexandru Ticăalexandru.tica@gmail.comDBA Lounge: 2013-06-06
  2. 2. Meet the Lovers name is Julie Koesmarno. I am aMicrosoft Certified Solution Expert in DataPlatform and a Microsoft Certified SolutionExpert in Business Intelligence for SQLServer 2012. started my professional career as a part-time C developer at age 16 (was not toogood at it though because lack of softwareengineering experience back then). I gotintroduced to Unix though, which gave megood foundation for understanding Oracleand enterprise-class applications when Istarted working for a consulting company atage 19.Would youmarry me?
  3. 3. CONNECT BY PRIOR ?...What? Pervert!Lets be polite and talk in TSQL.PL what? Pervert!Send me a picture of you!select blob_imgfrom profile;BLOB type?Youre stupid man!WHAT?Do you mean PLSQL?Lets Know Each Other Better
  4. 4. What to Do?Tanel is sad!He likes Julie a lot!What can he do?He asks his collegues for help!
  5. 5. Good & Bad News● Oracle provides good integration with MSQL Server● You speak Oracle and the transformationis transparently done on the fly● The conectivity agent may reside on any host,regardless of the OS● You may take advantage of the Oracle optimizereven in connection with MSQL tables (kind of)● The integration is working in PLSQL as well● Support for resultsetsGood news!Bad news!● Separate license (just ODBC is free)Great! I will evaluate thistechnology!
  6. 6. Heterogenous Services SetupMSQLServerOracleHost1 withsuportedOSHost2 withsuportedOSHost3 withWindowsOSSetup
  7. 7.● Oracle Database● MSql Gateway● Tanel is● SQL Server 2005● A DUMMY database● Julie is hereDepartmentsTableOracle DB Link@msql
  8. 8. Describe Yourself, Babysaysgatewaywhat Tanelunderstandswhat?what?WE8MSWIN1252Single-byte toSingle-byte.Why?
  9. 9. Wanna Know Everything About You!Gatewayautomatic dictionaryconversionDont expect muchfrom the Oracleoptimizer.Dictionary transparency(not fully implemented)
  10. 10. Dialect TranslationTanel first tryWTF?Documented limitation: if the remote table has LONG RAW columns thenall tables from the query should reside on the remote site.OracleSyntaxCasesensitive!
  11. 11. Resultset SupportsaysGatewayHS_FDS_RESULTSET_SUPPORT=TRUEis readingstupid!HS_FDS_DEFAULT_SCHEMA_NAME=dborc1 := “dbo”.”GetEmployees”@msql(2)doesnt work!
  12. 12. If theres no Other Way...DONT!COMMIThere usingOracle 2PCFake package! Donttry to grant privs forit. It can be used justthrough the dblink.Alwaysthroughdb link
  13. 13. Is Oracle Optimizer Smart Enough?count: ~10000 recordsStupid query: Find all employees which have their ID matching adepartment e."first_name" from departments d, all_emp_ever@msql ewhere = e."id";
  14. 14. Other LimitationsBleah!WTF? Yes, inSQL Server ispossible!Dont mess withNULLs.Guess!What?No support forSAVEPOINTs.
  15. 15. The Geek Way: JAVAloadjava -resolve -user msint/<pwd> -v -f sqljdbc.jardbms_java.grant_permission
  16. 16. Other Forms of IntegrationsAccessing Oracle fromSQL ServerReplicating Oracle datato SQL Server
  17. 17. The Moment of TruthPROS CONSSQL / PLSQL Transparency forsimple tasksThe Oracle optimizer is not sosmart if remote SQL Servertables are involved (MVs forsmall tables?)Support for TSQL resultsetproceduresMoney, money, money....Cross platform agent Weird data type conversionsQuite many limitationsJulie is NOTdisappointed!She didnt likeTanel anyway!
  18. 18. EpilogSursa: took the rightdecision!
  19. 19. Thanks guys!