Importing An ORACLE Schema Into A Different Schema With A Different Tablespace
Change the new user’s default tablespace to the new tablespace:
alter user scott default tablespace newspace;
Revoke the unlimited tablespace and change the new user’s quota to have space only on the new tablespace:
revoke unlimited tablespace from scott;
alter user scott quota unlimited on newspace quota 0 on oldspace;
Do the import.
Solving System Headers Problems When Using sunfreeware.com’s GCC
When getting an error like:
In file included from /usr/include/sys/signal.h:34,
from /usr/include/signal.h:26,
from /usr/local/lib/perl5/5.8.7/sun4-solaris/CORE/unixish.h:106,
from /usr/local/lib/perl5/5.8.7/sun4-solaris/CORE/perl.h:2220,
from u32align.c:10:
/usr/include/sys/siginfo.h:259: error: parse error before “ctid_t”
/usr/include/sys/siginfo.h:292: error: parse error before ‘}’ token
/usr/include/sys/siginfo.h:294: error: parse error before ‘}’ token
/usr/include/sys/siginfo.h:390: error: parse error before “ctid_t”
/usr/include/sys/siginfo.h:392: error: conflicting types for `__proc’
/usr/include/sys/siginfo.h:261: error: previous declaration of `__proc’
/usr/include/sys/siginfo.h:398: error: conflicting types for `__fault’
/usr/include/sys/siginfo.h:267: error: previous declaration of `__fault’
/usr/include/sys/siginfo.h:404: error: conflicting types for `__file’
/usr/include/sys/siginfo.h:273: error: previous declaration of `__file’
/usr/include/sys/siginfo.h:420: error: conflicting types for `__prof’
/usr/include/sys/siginfo.h:287: error: previous declaration of `__prof’
/usr/include/sys/siginfo.h:424: error: conflicting types for `__rctl’
/usr/include/sys/siginfo.h:291: error: previous declaration of `__rctl’
/usr/include/sys/siginfo.h:426: error: parse error before ‘}’ token
/usr/include/sys/siginfo.h:428: error: parse error before ‘}’ token
/usr/include/sys/siginfo.h:432: error: parse error before “k_siginfo_t”
/usr/include/sys/siginfo.h:437: error: parse error before ‘}’ token
It’s possible to solve the problem using:
cd /usr/local/lib/gcc-lib/sparc-sun-solaris2.10/3.3.2/install-tools
./mkheaders
10 on 10
To install Oracle 10g on Solaris 10 do the following:
- Add the SUNWi15cs and the SUNWi1cs packages.
- Create the needed groups:
groupadd -g 100 oinstall
groupadd -g 101 dba
- Create the oracle user:
useradd -u 100 -g 100 -G 101 -d /data/oracle -m -s /bin/tcsh oracle
- Create the oracle project:
projadd oracle
- Edit /etc/user_attr and add the following:
oracle::::project=oracle
- Set the max.shm.memory and max.sem.ids for the project:
projmod -s -K "project.max-shm-memory=(priv,4gb,deny)" oracle
projmod -s -K "project.max-sem-ids=(priv,100,deny)" oracle
- Edit /etc/system and add the following:
set noexec_user_stack=1
- Reboot
- Install ORACLE using the installer by running the following:
./runInstaller -ignoreSysPrereqs
- Enjoy
Calling JAVA code from Oracle
To run java code from oracle do the following:
1. Create the java code on the server:
CREATE OR REPLACE AND COMPILE JAVA SOURCE NAMED "hello" AS
public class hello {
public static String world() {
return "Hello World";
}
}
/
2. Create the oracle function on the server:
CREATE OR REPLACE FUNCTION hellofunction RETURN VARCHAR2 AS
LANGUAGE JAVA NAME 'hello.world() return java.lang.String';
/
3. Call the function using a SELECT:
SELECT hellofunction() from DUAL;
Byyee SpamInferno and Hi Brightmail
I have been running on SpamInferno for the past two years for blocking the 200-300 spam messages I receive a day. I made SpamInferno when I liked the idea of not having a single spam in my mailbox. Lately though I don’t mind a couple as long as people don’t need to authenticate themselves to send me emails nor I need to accept emails manually from companies. Today I finally stopped using SpamInferno and switched to Symantec Brightmail which does exactly what I want. I only have about 5 active users on my machine so it won’t be that expensive for me to get the $28/mailbox/year license but the only bad thing is that it has a minimum of 10 licenses to get. On the other hand, a really good thing about it now is that my MX points to one of my machines at home that does the filtering and inturn saves me bandwidth on my server in the US. Once the 30 day trial is over I’m probably getting the 10 licenses to free myself from SPAM!
Searching… Made Easier!
After Fadibou told me and Mark about YaGoohoogle during lunch and after Mark wrote about it I thought of why not do the same thing but with more engines. So I did it trying to avoid doing some work. Check it out at http://search.alzaid.net
IE HTML 4.01 Specification Bug?
While developing the new WiFi system I think I found a bug. Apperntly IE is not following the HTML specifications. In the OPTION tag for a SELECT you don’t really need to specify value as it is implied and uses the content of the OPTION tag (link) but IE requires the value if you want to use the value in a JavaScript. Spent a whole hour to find that out! Lesson learned: Always use value in the OPTION tag.