Can Oracle view refer a table in Sql Server Database
Can a view created in Oracle database refer a table created in SQL Server database. If yes, how do we do it. Code will be very help full.
Again, if yes does it require any special software and what would be price of that software.
Thanks for your response in advance.
Venkat Sathiamurthy
You would need to configure Oracle Heterogeneous Connectivity to create a database link to the SQL Server system. This can either be done via the Oracle Transparent Gateway for Microsoft SQL Server, which retails for $15,000 per server at http://store.oracle.com or by configuring Oracle Generic Connectivity and using ODBC to go after the SQL Server data. Depending on the operating system you run Oracle on, there may be a free (or cheap) ODBC driver for SQL Server that could be used.
Justin
Distributed Database Consulting, Inc.
http://www.ddbcinc.com/askDDBC
Similar Messages
-
Loading data from SAS tables to SQL server database
Hi Guys
I am championing a BI Proof of Concept project to create a self-service BI platform using tabular model parallel to our traditional BI platform on SAS.
I need to load certain SAS tables to SQL server database so I can start creating reports in SSAS. Appreciate if anyone can suggest the process that I can load the files to database engine as a scheduled job.
Appreciate your feedback and if further info needed please ask.
Cheers
MarkFrom VB6 there is not much alternative than to send row by row which indeed is slow.
But you could write a C# application which uses a table-valued parameter to load the data, and this could be streamed so that the client never has the hold the entire file. I have an example of this in this article on my web site:
http://www.sommarskog.se/arrays-in-sql-2008.html
You can also use the SqlBulkCopy class, but I don't have any example of this myself.
Erland Sommarskog, SQL Server MVP, [email protected] -
How to delete/drop all the tables from SQL Server Database without using Enterprise Manager?
I tried using DROP Tables, Truncate Database, Delete and many more but it is not working. I want to delete all tables using Query Analyzer, i.e. through SQL Query.
Please help me out in this concern.
Nishith ShahInformative thread indeed. Wish I saw it early enough. Managed to come up with the code below before I saw this thread.
declare @TTName Table
(TableSchemaTableName
varchar
(500),
[status] int
default 0);
with AvailableTables
(TableSchemaTableName)
as
(select
QUOTENAME(TABLE_SCHEMA)
+
+
QUOTENAME(TABLE_NAME)
from
INFORMATION_SCHEMA.TABLES)
insert into @TTName
(TableSchemaTableName)
select *
from AvailableTables
declare @TableSchemaTableName varchar
(500)
declare @sqlstatement nvarchar
(1000)
while 1=1
begin
set @sqlstatement
=
'DROP TABLE '
+ @TableSchemaTableName
exec
sp_executeSQL
@sqlstatement
print
'Dropped Table : '
+ @TableSchemaTableName
update @TTName
set [status]
= 1
where TableSchemaTableName
= @TableSchemaTableName
if
(select
count([Status])
from @TTName
where [Status]
= 0)
= 0
break
end -
How I can install and configure dg4odbc to access SQL Server database
I need to link Oracle database (installed in Solaris) to SQL Server database. How can I install and configure dg4odbc. Is there any step by step tutorial or guide available there.Thanks in advance.
Hi,
You can download the DG4ODBC software from either MOS or eDelivery depending which versios you want to install
For 11.2.0.4 -
Patch 13390677: 11.2.0.4.0 PATCH SET FOR ORACLE DATABASE SERVER
- login to My Oracle Support
- click on 'Patches and Updates'
- search for patch number 13390677
- you may need to press the '+' button to see the platform list
- scroll down the list to and click on the 'Oracle Solaris on SPARC (64-bit)' option.
- on the next screen click on the 'Download' option
- from the list of download files choose -
p13390677_112040_platform_5of7.zip
- this is the Gateway media pack and has everything needed for a standalone gateway install.
- unzip the file and run the installer and choose the gateway you want.
For 12.1 -
https://edelivery.oracle.com
Product Pack – Oracle Database
Platform – Oracle Solaris on SPARC (64-bit)
Oracle Database 12c Release 1 (12.1.0.1.0) Media Pack for Oracle Solaris on SPARC (64-bit)
- then for the gateways download –
Oracle Database Gateways 12c Release 1 (12.1.0.1.0) for Oracle Solaris on SPARC (64-bit)
- unzip and run the installer
Whichever version you decide I recommend you install into a completely separtae ORACLE_HOME from any existing installs as this makes maintenacne easier.
For the configuration have a look at this note if you have access to My oracle Support -
How to Configure DG4ODBC on 64bit Unix OS (Linux, Solaris, AIX, HP-UX Itanium) to Connect to Non-Oracle Databases Post Install (Doc ID 561033.1)
If not, then refer to the documentation available from -
Oracle Database Help Center
- choose either 12.1 or 11.2 then the 'Information Integration' option.
You can also install the DG4ODBC on the Windows machine (or any other machine if preferred) and access it from the RDBMS on Solaris.
Regards,
Mike -
Trigger to populate table in sql server database
Maybe this isn't the right board to post this in, but here goes:
We have an Oracle 9i database, with a table that get's populated with a new record every minute or so.
We need to take some values from the newly inserted record and populate a table in a sql server database instantly. The people requesting this have not said as much, but I am thinking deletes and updates would need to be the same.
How would it be best to do this? My first thought was a trigger on the oracle table that populates the sql server table via heterogeneous db link.
Any other ideas?
thanks in advance..
update- repost in heterogeneous forum
Edited by: user571263 on Mar 15, 2011 11:25 AMMaybe this isn't the right board to post this inI think you are right:
Heterogeneous Connectivity
Werner -
How can I get the data array from SQL Server Database?
Hi,
I can write a data array(2D)into a table of my SQL Server Database. The data array was writen to a column with image type. I know a data array is transformed a binary string when writing into database, but I dont know how to get the data array when I fetch the binary string from database.
My question is:
How to transform the binary string into data array? which vi's should I use? I have tried unflatten from string but failed.
Any response is appriciated.
Redhappyxh0518 wrote:
> I can write a data array(2D)into a table of my SQL Server Database.
> The data array was writen to a column with image type. I know a data
> array is transformed a binary string when writing into database, but I
> dont know how to get the data array when I fetch the binary string
> from database.
>
> My question is:
> How to transform the binary string into data array? which vi's should
> I use? I have tried unflatten from string but failed.
In order to use Unflatten from string you first need to Flatten it
before writing it. Also depending on the database driver, the returned
data may actually not be binary but Hexadecimal encoded ASCII which you
would first have to decode to binray.
Rolf Kalbermatter
Rolf Kalbermatter
CIT Engineering Netherlands
a division of Test & Measurement Solutions -
Can Oracle 10g EM manage DB2 or SQL Server
Need to know if Oracle 10g EM do have the capability to manage DB2 and SQL Server, as ct has this requirement. If so ct will manage all DB`s using Oracle 10g EM and use it for his enterprise.
Manage, no. Monitor, yes, so long as you don't mind a bit of work.
Now, for SQL Server, I expect you'll see the capability as a result of the Peoplesoft acquisition in a future release.
DB2, well that's a bit of work if you care that much about it. Grid R2 has a lovely SDK for developing your own plugins to monitor whatever the heck you like. It's alot easier to do in R2 than R1... -
I was told that SAP on SQL Server maintains a very unique security where someone can not just directly access tables in SQL Server. I was told you need the SAP client in order to access the data stored within the DB. With other systems, normally users such as a DBA or privileged users would be able to directly log into the database and possibly alter data, whereas this is not the case for SAP on SQL. Can someone help confirm if this is true or not and explain to me how this works.
Hi Julia:
You can access data stored in SQL tables using Enterprise Manager or SQL Query Analyzer and you can do in every other database system such as DB2, Informix or Oracle; there are some well-known Cluster tables that information can only be read from inside SAP.
Regards,
Federico -
Hi,
I have to implement the following scenario in SSIS but don't know how to do since I never worked with SSIS before. Please help me.
I have 20 different text files in a single folder and 20 different tables corresponding to each text file in SQL Server 2008 R2 Database. I need to extract the data from each text file and
load the data into corresponding table in Sql Server Database. Please guide me in how many ways I can do this and which is the best way to implement this job. Actually I have to automate this job. Few files are in same format(with same column names
and datatypes) where others are not.
1. Do I need to create 20 different projects ?
or
Can I implement this in only one project by having 20 packages?
or
Can I do this in one project with only one package?
Thanks in advance.As I said I don't know how to use object data type, I just given a shot as below. I know the following code has errors can you please correct it for me.
Public
Sub Main()
' Add your code here
Dim f1
As FileStream
Dim s1
As StreamReader
Dim date1
As
Object
Dim rline
As
String
Dim Filelist(1)
As
String
Dim FileName
As
String
Dim i
As
Integer
i = 1
date1 =
Filelist(0) =
"XYZ"
Filelist(1) =
"123"
For
Each FileName
In Filelist
f1 = File.OpenRead(FileName)
s1 = File.OpenText(FileName)
rline = s1.ReadLine
While
Not rline
Is
Nothing
If Left(rline, 4) =
"DATE"
Then
date1 (i)= Mid(rline, 7, 8)
i = i + 1
Exit
While
End
If
rline = s1.ReadLine
End
While
Next
Dts.Variables(
"date").Value = date1(1)
Dts.Variables(
"date1").Value = date1(2)
Dts.TaskResult = ScriptResults.Success
End
Sub -
How to create a sql server database in SQL DEVELOPER.
I installed the SQL DEVELOPER 1.5.5, but i can't found where to create the sql server database in it. please kindly tell me if you feel free.
Thanks so much in advance.Hi,
Take a look at the main [ SQL Developer page on OTN|http://www.oracle.com/technology/products/database/sql_developer/index.html]. There is a link you should find useful, it's the Getting Started link under the Migration section. This explains how to download and setup the drivers you need to correct to non-Oracle databases. There are also links to online demonstrations on how to create connections to these databases. See how you go with that material.
It should help.
Sue -
Taking snapshot of oracle tables to sql server using transactional replication is taking a long time
Hi All,
I am trying to replicate around 200 oracle tables onto sql server using transaction replication and it taking a long time i.e the initial snapshot is taking more than 24 hrs and it still going on.
Is there any way to replicate those these tables faster?
Kindly help me out..
ThanksHi,
According to the description, I know the replication is working fine. But it is very slow.
1. Check the CPU usage on Oracle publisher and SQL Server. This issue may due to slow client processing (Oracle performance) or Network performance issues.
2. Based on SQL Server 2008 Books Online ‘Performance Tuning for Oracle Publishers’ (http://msdn.microsoft.com/en-us/library/ms151179(SQL.100).aspx). You can enable the transaction
job set and follow the instructions based on
http://msdn.microsoft.com/en-us/library/ms147884(v=sql.100).aspx.
2. You can enable replication agent logging to check the replication behavior. You may follow these steps to collect them:
To enable Distribution Agent verbose logging. Please follow these steps:
a. Open SQL Server Agent on the distribution server.
b. Under Jobs folder, find out the Distribution Agent.
c. Right click the job and choose Properties.
d. Select Steps tap, it should be like this:
e. Click Run agent and click Edit button, add following scripts by the end of scripts in the command box:
-Output C:\Temp\OUTPUTFILE.txt -Outputverboselevel 2
f. Exit the dialogs
For more information about the steps, please refer to:
http://support.microsoft.com/kb/312292
Hope the information helps.
Tracy Cai
TechNet Community Support -
How to provide joins between oracle tables and sql server tables
Hi,
I have a requirement that i need to generate a report form two different data base. i.e Oracle and Sql Server.
how to provide joins between oracle tables and sql server tables ? Any help on this
Regards,
Malliuser10675696 wrote:
I have a requirement that i need to generate a report form two different data base. i.e Oracle and Sql Server. Bad idea most times. Heterogeneous joins do not exactly scale and performance can be severely degraded by network speed and b/w availability. And there is nothing you can do in the application and database layers to address performance issue at the network level in this case - your code's performance is simply at the mercy of network performance. With a single glaring fact - network performance is continually degrading. All the time. Always. Until it is upgraded. When the performance degradation starts all over again.
If the tables are not small (few 1000 rows each) and row volumes static, I would not consider doing a heterogeneous join. Instead I would rather go for a materialised view on the Oracle side, use a proper table and index structure, and do a local database join. -
Need To Create a table in Sql Server and do some culculation into the table from Oracle and Sql
Hello All,
I'm moving a data from Oracle to Sql Server with ETL (80 tables with data) and i want to track the number of records that i moving on the daily basis , so i need to create a table in SQL Server, wilth 4 columns , Table name, OracleRowsCount, SqlRowCount,
and Diff(OracleRowsCount - SqlRowCount) that will tell me the each table how many rows i have in Oracle, how many rows i have in SQL after ETL load, and different between them, something like that:
Table Name OracleRowsCount SqlRowCount Diff
Customer 150 150
0
Sales 2000 1998
2
Devisions 5 5
0
(I can add alot of SQL Tasks and variables per each table but it not seems logicly to do that, i tryid to find a way to deal with that in vb but i didn't find)
What the simplest way to do it ?
Thank you
Best Regards
DanielHi Daniel,
According to your description, what you want is an indicator to show whether all the rows are inserted to the destination table. To achieve your goal, you can add a Row Count Transformation following the OLE DB Destination, and redirect bad rows to the Row
Count Transformation. This way, we can get the count of the bad rows without redirecting these rows. Since the row count value is stored in a variable, we can create another string type variable to retrieve the row count value from the variable used by the
Row Count Transformation, and then use a Send Mail Task to send the row count value in an email message body. You can also insert the row count value to the SQL Server table through Execute SQL Task. Then, you can check whether bad rows were generated in the
package by querying this table.
Regards,
Mike Yin
TechNet Community Support -
How can I load data into table with SQL*LOADER
how can I load data into table with SQL*LOADER
when column data length more than 255 bytes?
when column exceed 255 ,data can not be insert into table by SQL*LOADER
CREATE TABLE A (
A VARCHAR2 ( 10 ) ,
B VARCHAR2 ( 10 ) ,
C VARCHAR2 ( 10 ) ,
E VARCHAR2 ( 2000 ) );
control file:
load data
append into table A
fields terminated by X'09'
(A , B , C , E )
SQL*LOADER command:
sqlldr test/test control=A_ctl.txt data=A.xls log=b.log
datafile:
column E is more than 255bytes
1 1 1 1234567------(more than 255bytes)
1 1 1 1234567------(more than 255bytes)
1 1 1 1234567------(more than 255bytes)
1 1 1 1234567------(more than 255bytes)
1 1 1 1234567------(more than 255bytes)
1 1 1 1234567------(more than 255bytes)
1 1 1 1234567------(more than 255bytes)
1 1 1 1234567------(more than 255bytes)Check this out.
http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96652/ch06.htm#1006961 -
Migration of table from sql server to oracle
Hi,
I had to export few tables from SQL Server to Oracle. After the migration, I am checking to see all the tables in Oracle that have been migrated from Sql Server. I am executing select * from tab; and am seeing all the the tables (including those have been exported) from the output list of tables. However, when I am doing a select * from x; where x is one of the few tables that have been migrated, it says table or view does not exist. This is the problem with all other migrated tables. Any help is appreciated in advance. Thanks.
[email protected]Try select * from "x"
Maybe you are looking for
-
I can change the key of a loop while in the Loop Browser, but when I move it to the track, it devolves to its original key.
-
Can I buy out my contract to transfer phone number to company account?
Hello, Currently I have a droid phone under contract with Verizon, and I am eligible for an upgrade in June, 2015, but can buy out of the contract for $180. I also am going to get a company phone for my job, but it is required that this be the iphon
-
IPhoto library is missing, no disk to mount a new library on
I recently moved all of my iPhoto library to an external hard drive, which was then reformatted incorrectly. All of my files are now gone, and when I try to start a new library in iPhoto, I get an error saying "Please make sure the disk containing yo
-
How can I increase the number of possible answers in Captivates short answer quiz?
I am trying to offer a short answer question that has more than 8 possible answers (due to different spelling and punctuation possibilities). I can add up to 8 possible answers but don't know if it is possible to add more to the short answer quiz que
-
TS4006 I HAVE LOST MY IPOD HOW DO I TRACK but i have icloud
I HAVE LOST MY IPOD HOW DO I TRACK but i have icloud