How to trace from a child node to a parent node in Oracle.
For example, there is a table:
GUID Parentguid
1 0
2 1
3 1
4 2
5 2
6 5
7 5
8 7
We can detect all the child nodes under the GUID from the GUID 1 according to the parentguid
1. Sqlplus Running DB:sqlplus Sys/sys as Sysdba (Sys/sys as "username"/"password")
Or configure the client to run the client's sqlplus after listening
2. (can omit) view current service name:sql> Show parameter service_name
3. Modify Service
Scenario: There is a database encoded as UTF8 on the server, and then the local is ZHS16GBK. I directly with the EXP command to guide down, found that the database is garbled.
Resolution process: Because the code on the server is not easy to change,
First of all, my data particularity, the table has a large number of CLOB fields, between this, a lot of Niang methods are unable to handle.
My approach:
1, create a new table space, the name of course and the original table space is different.
2,
1, the concept of table spaceOracle databases are divided into logical regions called table spaces-the logical structures that form Oracle databases. An Oracle database can have one or more tablespaces, while one table space corresponds to one or
Oracle has two functions: lead and lag, which are the analytic functions used to compute offsets, and the two functions are the same in use.
The Oracle official documentation explains:
The lead is a analytic function. IT provides access to more
Today, a person in the department asked me how to trace from a child node record to a parent node in Oracle. For example, there is a table:
GUID Parentguid
1 0
2 1
3 1
4 2
5 2
6 5
7 5
8 7
We can detect all the child nodes under the GUID
Installing oracle11g on Centos6.4 does not set the character set, using the operating system default character set: we8mswin1252, which modifies the character set to: Al32utf8.
Sql> Select Userenv (' language ') from dual;
Simplified Chinese_china.
1, look at the user's proifle, which is generally default:
Sql>select username,profile from Dba_users;
2. View password expiration settings for the specified profile (such as default):
Sql>select * from Dba_profiles s WHERE s.profile= ' DEFAULT '
CMD under
Sqlplus Carriage return
Enter system user (default to create user permissions)
Create user xxx identified by xxx;(must not be lost;
Created, but at this point the linked database will error the Oracle creation user Ora-01045:user lacks
Issue background: Recently, the company database server is centralized to one machine (252) for the unified management of the databases distributed on each server. For the difference in the last section of the IP address as the name of each machine.
One, Backup script command:
@ECHO offIf not exist d:\ora_dmp MD d:\ora_dmpSET backpath=d:\ora_dmpECHO prepares to back up the databaseREM 7 days a loopIF EXIST%backpath%\one GOTO OneIF EXIST%backpath%\two GOTO TwoIF EXIST%backpath%\three GOTO
In Oracle database operations, sometimes we need to execute certain stored procedures on a regular basis. How does Oracle do that? Starting with Oracle version 10.1, Oracle has developed a new package dbms_scheduler. This package will help solve the
For some reason, Oracle on the old computer is often disconnected, and the newly bought computer is normal, and all three-party software that connects to Oracle is disconnected, like pl/sql.
So, I wonder what the cause is.
1, here to cite a
Oracle has a number of views built into the SYS user scenario that we can use to easily view system-related information. We can call these views without schema, and here are some
Summary of views about user, role, and permission information:
(1) all_
3 Default users in OracleSYS Change_on_install [as SYSDBA] System Manager Scott Tiger
Data Dictionary
View what system permissions the current user hasSELECT * from User_sys_privs;
View what object permissions the current user hasSELECT * from User_
Create a sequence first
CreateSequence testincrease_sequence
IncrementBy 1--each time you add
a few startwith 1--start counting from 1
nomaxvalue--do not set the maximum value, To set the maximum value: maxvalue9999
nocycle--has been accumulated,
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service