I have data consisting of various numeric fields (dec 8.2).
I want to load them into an Oracle table dropping the decimal and making them char(8).
My sql loader cntrl file defines them as ;
Field1 char "to_char(:field1,'99999999')"
But this does not work.
I get error ;
ORA-01401: inserted value...
This is my controlfile to recreate the database ;
STARTUP NOMOUNT
CREATE CONTROLFILE set DATABASE "PROD" RESETLOGS NOARCHIVELOG
MAXLOGFILES 16
MAXLOGMEMBERS 2
MAXDATAFILES 500
MAXINSTANCES 1
MAXLOGHISTORY 453
LOGFILE
GROUP 1 '/usr/local/erp/oracle/proddata/logPROD1.dbf'...
I clone a db from one server to another as folows ;
1. shutdown immediate on server A (Solaris 8, Ora 9i)
2. copy all datafiles to server B (Solaris 8, Ora 9i)
3. startup creating new cntrl file
Usually all is ok but sometimes it says that one of the datafiles needs recovery.
Someone said that...
Thanks for the reply. Great script and if you don't mind I will make use of it
BUT it does not solve my problem.
I am setting up a batch job that must tell me if any tablespaces are heading for problem.
It is an automated script so I must get either a boolean reply or a count of objects.
I am trying to write a database check that will send me an email message if there is any tablespace > 90% used.
The email is not the problem. The problem is that I am trying to return either a TRUE flag or a count of tablespaces where % used > 90.
Anyone got such a thing ?
I have a table of over 1 million records and the update_statistics command runs for many hours on it - even seems to hang at times.
How can I improve this ?
Are there any parameter settings that will help ?
I have a large table as follows
Rec_Type Rec_Month Rec_Year Stuff
A Oct 2004 sdsddsxfdfsdf
A Nov 2004 tyytrtrt
B Oct 2004 rgdrghgdfdf
C Oct 2004 jtyjtjtrjtyjtyjty
C Nov 2004 ererggdfg
I want to select where...
I have a file with rec length of 2096.
I can "more" the file but would like to "grep" it.
How can I split a file vertically ie selecting each record bytes 1-1000 only
(Note ; not lines 1-1000 but bytes or columns)
If I login as root - my environment is fine.
If I login as another user and su without the - option, my environment is not set.
What I want to do is set "alias rm -i" and "set -o vi" when I su (without using the - option).
I have a job scheduled via cron.
It runs fine but sends me a blank email every day.
There are no echo or print statements in the job.
Why am I getting this email and how do I stop it ?
When I run optdiag, I get this message and optdiag aborts ;
Cant get localized message
Optdiag failed
What is it looking for ?
----------------------------
This is my command and the resultant output file;
>optdiag statistics recon -o recon.opt -Uid -Ppass
>cat recon.opt
OptDiag/12.5.0.3/EBF...
Why does this write each record on a separate line ?
(note; only a small sample of actual script)
sqlplus -S id/pass@sid << EOT >>/dev/null
set heading off
set pagesize 0
set linesize 132
set serveroutput off
set verify off
set feedback off
spool fileout
select vendor_name , vendor_alt
from...
I want to validate this input (year comma month) ;
2004,06
and the validation must check for valid year 1999 - 2010
must check for a comma
must check for valid month 01-12
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.