ORACLE SELECT into prevents no results times wrong

As follows: BEGIN SELECT name into v_name from t_student WHERE id = ' 101 ' EXCEPTION when no_data_found Then v_name: = "; END;In this way, you do not have to select COUNT (1) from t_student where id = ' 101 ' in advance

Object Types for Oracle

Object Types for Oracle Object TypeIn PL/SQL, object-oriented programmers are based on object types. The object type is a user-defined composite data type that encapsulates the data structure and the procedures and functions used to manipulate those

ORACLE divides a string into three parts according to the separator

Here's an example:Select substr (' ll$ $BOAT $ $he very handsome ', 1, InStr (' ll$ $BOAT $ $he very handsome ', ' $$ ', 1, 1)-1), substr (' ll$ $BOAT $ $he very handsome ', InStr (' ll$ $BOAT $ $he very

Oracle Direction Catalog

Create directory gives us the flexibility to read and write files in an Oracle database, greatly improving the ease of use and scalability of Oracle.Its syntax is:CREATE [OR REPLACE] Directory directory as 'pathname';This case is specifically

Oracle Monitoring service startup failure case

After restoring a database on the Oracle test server, a TNS-12541, tns-12560,tns-00511 error occurred when starting the listening service, as shown in the following scenario:[Email protected] admin]$ lsnrctl statusLsnrctl for linux:version 10.2.0.4.0

Oracle Password Expiration Resolution

Oracle TIP error message ora-28001:the password has expiredLog in with Sqlplus/as SYSDBA on the Oracle server to view the account status using the following SQL statement:Select from Dba_users;Find the corresponding user name, if the status is

To view the Oracle database encoding:

1. Client-side encodingView method: Open the registry of the server where the database resides (enter regedit in the Run window) Hkey_local_machine->software->oracle->home0->nls_lang, Check out what the database client code is.2. Server-side

Oracle-Providing a dynamic result set for subqueries

Once encountered such a requirement: Request for method passed in string, content such as "user ID0, user ID1, user ID2 ...", and then according to these IDs return a result set as a data table for others to query.SELECT * FROM TBL WHERE ID IN

Oracle Learning Record a basic instruction exercise

The Oracle 11g is usedIn fact, it has been a few, but not much study, now began to re-learn, including SQL statements and so on.Start after installation,I installed the client sqldeveloper, but I need to connect after entering, I forgot how to do it,

Oracle ora-01033:oracle initialization or shutdown in progress error resolution

Oracle ora-01033:oracle initialization or shutdown in progress error resolution"ORA-01033" error when logging into databaseIn the command window, log in as sqlplus as sysdba--note that the value after the sqlnet.authentication_services parameter in

[Oracle Series] Oracle Common functions

a) Date function [focus on the first four date functions]1.add_months[return date plus (minus) The date after the specified month (before)Add_months (D1,N1)"Function": Returns the new date after the date D1, plus N1 months."Parameters": D1, Date

The principle of-spfile and pfile for the startup and shutdown principles of Oracle

Ii. Oracle's parameter file management1. Introduction of parameter FilesTwo types of parameter files:(1) spfile parameter file (binary file)(2) pfile parameter file (text file)Path to the parameter file store: $ORACLE _home/dbs[email protected] dbs]$

Oracle Startup and shutdown principle-phased start of data path

First, the principle of startup and shutdown of Oracle1. Oracle Boot Step AnalysisSql> Startup-This is the command to start the databaseORACLE instance started. --first stage, launch instance, Nomount stateTotal System Global area 608174080

Indexes in Oracle

Indexes in OracleIn a relational database, an index is a database structure that is related to a table and is another important schema object other than a table. An index is a helper object that is built on one or more columns of a table to increase

Structure of Oracle PL/SQL IF statements

The structure of the Oracle IF statement is similar to most languagesIF condition then expr; elsif condition then expr; ELSE expr; END IF;As an example:Select count (Distinct index_name)  INTO CNT FROM USER_INDEXES WHERE  Table_name=c1. table_name;  

The use of decode in Oracle

Decode function usage in OracleMeaning explanation:Decode (condition, value 1, return value 1, value 2, return value 2,... Value N, return value N, default value)The function has the following meanings:IF condition = value 1 ThenRETURN (translation

Oracle statistics collection

Oracle statistics collectionCollect statistics 1: Create an analysis table $ Cd $ ORACLE_HOME/rdbms/admin $ sqlplus/as sysdba> @ utlxplan. SQL 2: For convenience, you can create a synonymous table (by default, only sys users can use it) SQL>

Oracle inversion Function

Oracle inversion Function Oracle provides a reverse inversion function, reverse, but this function cannot be used for grouping inversion. This article provides a function that can be used for grouping inversion, as shown below: Create or replace

Some advanced management case studies of ORACLE11GDataGuard

Some advanced management case studies of ORACLE11GDataGuardAfter setting up ORACLE 11G dataguard, I also conducted a Role Switching experiment. switchover has failover, and I feel a lot of benefits. Then I continue to study some of the advanced

Auto increment of ID fields in the SQL _Oracle table

Auto increment of ID fields in the SQL _Oracle table Objective: To automatically increment the ID field when inserting data into a table. Start the experiment: (1) Create an experiment table Createtable test_ID_add ( Id number (10 ), USERNAME

Total Pages: 2147 1 .... 947 948 949 950 951 .... 2147 Go to: GO

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.