How to link oracle table with ax 2009 table? - ssis

I have to pull data from Oracle's "A-Table" on daily basis and insert the same to Ax "A-Table".
Can anyone please tell me how can I achieve the same.
Thanks

You need to download the Oracle drivers for Windows ( http://www.oracle.com/technetwork/developer-tools/visual-studio/downloads/index.html ).
Then take a look at this http://floditt.blogspot.mx/2011/08/using-adonet-with-x.html. Instead of using System.Data.SqlClient data types you have to use the oracle classes (System.Data.OracleClient.OracleConnection, OracleCommand, OracleReader, etc...) which you have installed previously.
If you want it to be run everyday just set a new batch job (in Base -> Inquiries -> Batch job).

Related

How to import Oracle sql file into MySQL

I have a .sql file from Oracle which contains create table/index statements and a lot of insert statements(around 1M insert).
I can manually modify the create table/index part(not too much), but for the insert part there are some Oracle functions like to_date.
I know MySql has a similar function STR_TO_DATE but the usage of the parameter is different.
I can connect to MySQL, but the .sql file is the only thing I got from Oracle.
Is there any way I can import this Oracle .sql file into MySQL?
Thanks.
Although the above job can be done by manually editing the script appropriately however there are products available which can be of use. Refer to the link for more information on one such product.
P.S. I am not affiliated in any way to the product
Since you mention about insert script basically i think you will be inserting data for this you can use any ETL tool, like open source tool like Pentaho data integrator, pretty simple to do, just search table to table transformation from different database connection on youtube to learn you should be able to connect to both mysql and oracle database else this wont help, but all the table structures you should create manually in the source database for data - you can just load it using ETL, no need to edit for every single line of insert if its more than 100 may be its very painful thing to do.

Best way to synchronise data: MySQL -> SQL Server

I have a fairly straight way to copy selective data using SQL like so:
# Courses
DROP TABLE db_node.courses;
CREATE TABLE db_node.courses LIKE db_prod.course_sis;
INSERT INTO db_node.courses SELECT
*
FROM
db_prod.course_sis
WHERE
db_prod.course_sis.enabled = 1
AND db_prod.course_sis.hidden <> 1;
This is easy when I am on the same server with the same db, however I want to run this SQL to get put the final data on the SQL Server.
This isn't just a once off thing, it would need to be handled every hour or so. I am unable to change db's, one will always be MySQL and SQL Server because the data is used in a sharepoint app.
Thanks
There are several third-party tools to make this transition easier.
Check out SSMA here and here.
I'd also look at SQL Studio scheduled tasks to automate the process.

Exporting a large data from oracle

I want to export a large amount of data from oracle something like 7 million records and then import it in mysql. but during the exporting a data from oracle(using oracle sql developer), the sql developer freezed. Any ideas how to export a large amount of data from oracle and then import it in the mysql.
To do that you need an ETL tool (http://en.wikipedia.org/wiki/Extract,_transform,_load)
There is one open source good product called Pentaho Data Integration.
Website: http://community.pentaho.com/
Download: http://forums.pentaho.com/showthread.php?133266-Kettle-4-4-0-stable-has-been-posted-to-SourceForge-net
How to use it: http://pldwh.blogspot.co.uk/2013/01/pentaho-data-integration-how-to-use.html
NOTE: You do not have to create any repository (file/db) you can just create:
a new transformation -> add table input and table output -> define connections
and you are done.
SQL Developer doesn't handle large data sets very well, but SQL*Plus is very capable in that respect and has been used for this for decades. Spooling out a file of that size is no problem, and it's a free tool of course.
You have to pay attention to various settings to override the default headings, linesize, pagesize, feedback etc..
Run tests on a select of about 1,000 records to establish that you have the correct settings. Off the top of my head ...
set heading off
set feedback off
set echo off
set termout off
set linesize 2000
set define off
set trimspool on
There may be a few I've forgotten -- if you see undesirable formatting issues in the output post a followup if you can't resolve them yourself.

Enter data in geography column in SQL Server management studio

I've created a new table in SQL Server Management Studio, which includes a Geography column.
Now, I'm trying to enter data in this column using the SSMS UI, but I just can't find the right way of doing it.
So, how can that be done?
I wouldn't think SSMS natively supports doing this with a nice interface (e.g. a map). Maybe there's some add-on to allow this, or likely some 3rd party app.
If you're happy with doing it in SQL, try this:
UPDATE tableName SET geographyColumn = geography::Point(47.65100, -122.34900, 4326)
Derived from here.
Here are 4 more ways to do the same.
If editing a table cell a la mano just type in
POINT (2.434548 48.858319 4326)

How to tell if someone is looking at one of the records on your database?

I want to add some fake records/rows for in the table for MS SQL 2008 Standard Edition database and use these records to monitor my database.
The purpose for this is to monitor hackers. It is possible to create a trigger to do this. It seemed like the DDL Triggers can not do this tasks.
If you can't control access to your database via stored procedures (where you could add your own logging), you will need to use auditing or server-side trace for this. There is no such thing as a select trigger and there are no DMVs that will tell you which rows were looked at via any select action.