Data export through sql
all experts
i whant do backup through sql such as:
SQL > host exp.exe userid=system full= y file=d:\backup\sysdate||'.bk'
how i can do this
thanks in advance
Firstly, you can't run export like that. Secondly, export is a logical backup not a "real" backup.
For Windows, fill in the blanks (at least work it out instead of getting it completely handed to you) -
Problem with this method is having to store the password in the file so be careful.
>>>>>>>>>>>>>>>>>>>>>>>
Batch file -
<<<<<<<<<<<<<<<<<<<<<<<
SET ORACLE_SID=<ORA_SID>
SET ORACLE_HOME=<ORA_HOME>
REM backup controlfile to trace and generate the exp.parfile
sqlplus /NOLOG @<some_path>\backupctlfiles.sql %ORACLE_SID%
REM run an export using the generated filename in the previous step
exp parfile=<some_path>\exp.parfile
<<<<<<<<<<<<<<<<<<
backupctlfiles.sql file -
>>>>>>>>>>>>>>>>>>
define dbpassw = '<export user password>’
connect <username>/&dbpassw
alter database backup controlfile to trace;
set feedback off trimspool on trimout on pages 0 verify off
spool <some_path>\exp.parfile
select 'full=y ' || chr(10) ||
'recordlength=65535' || chr(10) ||
'direct=y '|| chr(10) ||
'file=<export_file_path>\&1\export_full.&1..'||to_char(sysdate,'YYYYMMDDHH24MMSS')||'.dmp'||chr(10) ||
'log=<export_file_path>\&1\export_full.&1..'||to_char(sysdate,'YYYYMMDDHH24MMSS')||'.log'||chr(10) ||
'consistent=y'|| chr(10)||
'userid=<username>/&dbpassw'
from dual;
spool off
exit;
Similar Messages
-
Converting 99999999 to date datatype through sql/ssis
Hi,
I am developing an ETL in which we get this column which holds the value 99999999 in one of the columnwhich is of numeric datatype. User wants that field to be date time in destination. Please help me on how to convert that value into date datatype in SSIS.
Please........Thank you Rajen,
But I have used Collasce to solve this issue.
COALESCE
(NULLIF(t1.dtetrm,
'99999999')
,'20991231') -
Dates passed through SQL to oracle backend database
Post Author: kasmith
CA Forum: WebIntelligence Reporting
Can anyone tell me how WEBI sends a date used as a parameter to an oracle database?
I am trying to increase the response time of a report, but cannot tell how web intelligence is sending the date to oracle.
Many thanks - KathyPost Author: amr_foci
CA Forum: WebIntelligence Reporting
kathy,, its all based on how you designed the universe which ur report based on, the webI is just sending the parameter as it to the universe i dont think the format will matter for this, but at the universe level this is point which u can control how u send the values to the database
good luck -
Data export(ttbulkcp) Oracle TimesTen Question
I'm trying to export an Oracle TimesTen(TimesTen Release 11.2.1.5.0) with ttbulkcp(Data export), using SQL Developer Version 2.1.1.64
All other functions are normal operation. Also ttbulkcp(Data export) in Oracle Table is normal operation. But , I get the following error in ttbulkcp(Data export) in TimesTen Table.
java.lang.NullPointerException
at oracle.dbtools.raptor.format.ResultsFormatterWrapper.getColumnCount(ResultsFormatterWrapper.java:67)
at oracle.dbtools.raptor.format.ResultsFormatter.getColumnCount(ResultsFormatter.java:130)
at oracle.dbtools.raptor.timesten.format.TimesTenLoaderFormatter.getColumns(TimesTenLoaderFormatter.java:207)
at oracle.dbtools.raptor.timesten.format.TimesTenLoaderFormatter.printColumnData(TimesTenLoaderFormatter.java:183)
at oracle.dbtools.raptor.timesten.format.TimesTenLoaderFormatter.start(TimesTenLoaderFormatter.java:73)
at oracle.dbtools.raptor.format.ResultSetFormatterWrapper.print(ResultSetFormatterWrapper.java:150)
at oracle.dbtools.raptor.format.ResultsFormatter.print(ResultsFormatter.java:200)
at oracle.dbtools.raptor.format.ResultsFormatter.doPrint(ResultsFormatter.java:416)
at oracle.dbtools.raptor.dialogs.actions.TableExportAction$5.doWork(TableExportAction.java:637)
at oracle.dbtools.raptor.dialogs.actions.TableExportAction$5.doWork(TableExportAction.java:634)
at oracle.dbtools.raptor.backgroundTask.RaptorTask.call(RaptorTask.java:193)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at oracle.dbtools.raptor.backgroundTask.RaptorTaskManager$RaptorFutureTask.run(RaptorTaskManager.java:492)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Driver not capable
Thank you.
GooGyumIf you have a DB support contract, I suggest you open a SR on Metalink/MOS, to get official response and follow-up, else you can hope someone from development picks it up here.
Regards,
K. -
Help needed in Exporting tables data through SQL query
Hi All,
I need to write a shell script(ksh) to take some of the tables data backup.
The tables list is not static, and those are selecting through dynamic sql
query.
Can any body tell help me how to write the export command to export tables
which are selected dynamically through SQL query.
I tried like this
exp ------ tables = query \" select empno from emp where ename\= \'SSS\' \"
but its throws the following error
EXP-00035: QUERY parameter valid only for table mode exports
Thanks in advance,Hi,
You can dynamically generate parameter file for export utility using shell script. This export parameter file can contain any table list you want every time. Then simply run the command
$ exp parfile=myfile.txt -
Export data from one schema to another schema through sql
Hello.
I have 2 schemes. One is called MICC_ADMIN and the other one is called MICC_PROD. What I want is to export from MICC_ADMIN to import in MICC_PROD. I tried to do it with the Data Workshop tool, but one of the table has around 19.000 records, so it gets frozen when is trying to export the data. So I'm wondering if is there any way to do it through sql command. Thanks.
Regards, Bernardo.I am going to assume that you:
1) want to export DB objects from the source schema (MICC_ADMIN) to your target schema (MICC_PROD)
2) awant to export the data held in the aforementioned tables between the two schemas
Firstly, generate the relevant DDL for your DB objects (you can do this in APEX as well - Home>Utilities>Generate DDL then complete the wizard) and run the DDL script in your target schema.
Secondly, grant access to the relevant tables in the source schema to your target schema and compose DML insert statements to transfer the data from one to another (remembering to disable the relevant constraints/triggers during the process).
Thereafter, revoke access to your source schema.
You can, of course execute this in a single script, although better to do so in a test environment first if you can! -
Getting error while trying to upload the data in excel from SSIS package through sql agent job
We are getting below errors.
Error:
The Microsoft Jet database engine cannot open the file '\\serversdev\Documents\QC Files\Prod.xls'. It is already opened exclusively by another
user, or you need permission to view its data.
Please suggest ASAP
Regards,
Ramu
Ramu GadeHi Dikshan Gade,
According to your description, you want to upload data from excel to database, when you call ssis package through SQL Server Agent job, you got the error message.
To troubleshoot the problem, please refer to the following steps:
Validate that the account has permissions on the file and the folder.
Verify that the file and the data source name (DSN) are not marked as Exclusive.
Make sure SQL Server Agent Services service account has the permission to access the database.
We can check SQL Server Agent’s activity logs, Windows Event logs and SSIS logs to get more clues. Also the tool Process Monitor is helpful to track the cause of registry or file access related issues. For more information about the issue, please refer to
the following KB article:
http://support.microsoft.com/kb/306269
If you have any more questions, please feel free to ask.
Thanks,
Wendy Fu
Wendy Fu
TechNet Community Support -
Can we use Data Pump to export data, using a SQL query, doing a join
Folks,
I have a quick question.
Using Oracle 10g R2 on Solaris 10.
Can Data Pump be used to export data, using a SQL query which is doing a join between 3 tables ?
Thanks,
AshishHello,
No , this is from expdp help=Y
QUERY Predicate clause used to export a subset of a table.
Regards -
Query data from MS SQL db through Oracle ? By using JAVA ?
Hi folks,
I would like to sync our one table in oracle db with table in different system, stored in MS SQL database.
What would be the easiest option for connection from Oracle to MS SQL db to be able to query data from MS SQL through some Oracle package?
If possible, I would like to keep all "tricky steps" within Oracle database. I heard about option with Java, but so far we have no experience with java in Oracle.
Our database: Oracle 11g Database Standard Edition One
Many thanks,
TomasC:\Users\tomeo>dg4pwd HELIOS
ORACLE Gateway Password Utility
Constructing password file for Gateway SID HELIOS
For user account SYSTEM
OPW-00001: Unable to open password-file (RC=0)
C:\Users\tomeo> -
Hi Team,
I am running a sql server job which is loading data to a sharepoint document library.File is an excel format and is getting loaded
when executed through SSDT solution .But when i am using an SQL Agent job to pick up the file it doesnt get the path and agent job fails with the error "Failed to acquire connection".I have deployed the SSIS Package through SQL Server 2012 deployment
methodologies.
I am not able to trace the error of loading data from a sharepoint library.library. Sql agent jobs works fine when i give local path.The
account which is running the sql agent job is the same who has access to document library.I also tried to run the job through proxy account. I am using a xml configuraion to store my credentials.I am able to palce the same file to a network drive in the same
server through sql server agent job. The only problem is when I am trying to load the file to a sharepoint folder.
Thanks,
Arsa..Is that the WebDAV method that you are suggesting here to map the n/w drive?
Its kind of webdav but you will be using windows nw drive to store data
yes, I am able to create the file to D: , but didn't check with the C:.
Try with c:, as c: require special permisssions
If this helped you resolve your issue, please mark it Answered -
Import/export data from ms sql 7 to xml file in a particular xpdl format
I'm trying to write java program to import/export data from ms sql 7 to xml file in a particular xpdl format. Can anyone suggest how to do it?
take a glance at what these guys do: http://www.openbusinessengine.org/docs/guide.html
-
Check data before loading through SQL *Loader
Hi all,
I have a temp table which is loaded through SQL*Loader.This table is used by a procedure for inserting data into another table.
I get error of 0RA-01722 frequently during procdures execution.
I have decided to check for the error data through the control file itself.
I have few doubts about SQL Loader.
Will a record containing character data for column declared as INTEGER EXTERNAL in ctrl file get discarded?
Does declaring column as INTERGER EXTERNAL take care of NULL values?
Does a whole record gets discarded if one of the column data is misplaced in the record in input file?
Control File is of following format:
LOAD DATA
APPEND INTO TABLE Temp
FIELDS TERMINATED BY "|" optionally enclosed by "'"
trailing nullcols
FILEDATE DATE 'DD/MM/YYYY',
ACC_NUM INTEGER EXTERNAL,
REC_TYPE ,
LOGO , (Data:Numeric Declared:VARCHAR)
CARD_NUM INTEGER EXTERNAL,
ACTION_DATE DATE 'DD/MM/YYYY',
EFFECTIVE_DATE DATE 'DD/MM/YYYY',
ACTION_AMOUNT , (Data:Numeric Declared:NUMBER)
ACTION_STORE , (Data:Numeric Declared:VARCHAR)
ACTION_AUTH_NUM ,
ACTION_SKU_NUM ,
ACTION_CASE_NUM )
What changes do I need to make in this file regarding above questions?Is there any online document for this?<br>
Here it is -
How to insert chinese data into MS SQL Server 2000 through JDBC
I am trying to insert chinese data into MS SQL server 2000 using JDBC. how to do this?
can anybody help me.
thanx.I am trying to insert chinese data into MS SQL server 2000 using JDBC. how to do this?
can anybody help me.
thanx. -
Plz its URGENT : Storing unicode data in MS SQL Server 2000 through JSPs
Hello All,
I'm trying to store unicode data, entered from JSP page into the SQL Server. For that I've tried the following :
1> I put tag -
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
2> Also set in JSP tag -
<%@page contentType="text/html;charset=UTF-8"%>
But, still data is being entered in ISO-8859-1 format, don't know why. I tried with function for convertion - private String toUniCode(String strPar)-it successfully shows me the unicode data in alret msg, but it doesn't enters unicode data in SQL Server. In SQL Server only '??????' get entered. I kept data-type in SQL Server as nvarchar to store data in unicode.
Would it be possible for me, to accept the data as UTF-8 itself & can I store it in SQL Server as it is? How can I do that? I'm accepting data in 'marathi' language.
Plz, anybody Help me, I'm trying for this from around more than 1 week.
Thanks in advance for any replies!Hello dmorris800,
Thanx for your help. In fact I've tried lot many alternatives for that. Later I realised that it was problame of Driver, not of code. I was using jdbc:odbc driver which doesn't support unicode, or I don't know what was the problame with it.
But I downloaded the driver named :'TaveConnect30C'. It is the connection optimised driver of Atinav.com This is the JDBC3 Type 4 Driver for MS SQL Server 6.5/7.0/2000 & trial version of which can be downloaded from http://www.atinav.com/download.htm
It is really very good type-4 Driver.
Cheers
-Yogesh -
Export data from MS sql server table to an oracle table
I need to move data from a sql server table to an oracle table and when ever the sql server table is updated it needs to automatically update the oracle table. Is there procedure to do this or do I migrate the data once and set up a trigger on the sql server table to update the oracle table? If the trigger is the answer how do I do that?
You might want to check out Oracle's heterogeneous services functionality if you haven't done so already. Here are a few links:
http://download.oracle.com/docs/cd/B19306_01/server.102/b14232/toc.htm
http://download.oracle.com/docs/cd/B19306_01/server.102/b14232/majfeat.htm#sthref74
Also, consulting the Oracle streams manual may be helpful -- particularly Chapter 5.
http://download.oracle.com/docs/cd/B19306_01/server.102/b14228/toc.htm
Perhaps someone who is more familiar with SQL Server could provide a more helpful answer.
Maybe you are looking for
-
LV 6.02 (or 6.1) NT 4.0 I have a vi that the front panel includes all the information I need to print except that it is on different pages of a tab control to conserve screen space. I was attempting to programatically cycle the value of the tab contr
-
MM gurus I am getting the following error while posting invoice. "No amount authorization of customers/vendors in company code?" what r the steps to resolve it. thanks raghavendra
-
Why my notes from my iPhone 5 don't synchronize w/ iCloud?
I just tried to tranfer my notes from my iphone 5 to my MacBook Pro, I did my homework by uploading and sinchronizing my phone with Itunes and then with iCloud. And the notes taken today didn't tranfer to icloud??? all my points are checked/on. any o
-
Is oracle 9.2.0.8 compatible with Sun Cluster 3.3 5/11 and 3.3 3/13? Where can I check compatibility matrix?
-
Used migration assistant but can't find my stuff
I recently purchased a new iMac 21.5 inch screen. I ran the Setup Assistant and then later ran the Migration Assistant. I migrated my files on the old computer (2006 iMac running Snow Leopard 10.6.8) first using an ethernet cable between the two co