oracle11g

multiple row insert in Oracle SQL

元气小坏坏 提交于 2020-01-24 05:49:13
问题 I use multiple row insert syntax in oracle SQL like this: INSERT ALL INTO student(ID, FIRST_NAME, LAST_NAME, AGE) VALUES(4,'test_name','test_lname',17) INTO student(ID, FIRST_NAME, LAST_NAME, AGE) VALUES(5,'test_name2','test_lname2',20) INTO student(ID, FIRST_NAME, LAST_NAME, AGE) VALUES(6,'test_name3','test_lname3',21) select * from dual; can anyone explain me what is the meaning of using select * from dual at the and of statement? 回答1: it the syntax for INSERT ALL INSERT ALL INTO <table

Insufficient Privileges Error while creating a Instead of Trigger

こ雲淡風輕ζ 提交于 2020-01-23 19:23:13
问题 I have a view on which i need to create a Trigger whenever there is an insert action on the view. When i try to create a Instead of Trigger, i get an error saying that i have insufficient Privileges. Isn't it that when i create a trigger, select privileges are enough? If not, what are the privileges required to create this Trigger. Thanks 回答1: To create a trigger in your own schema on a table in your own schema or on your own schema (SCHEMA), you must have the CREATE TRIGGER system privilege.

Insufficient Privileges Error while creating a Instead of Trigger

二次信任 提交于 2020-01-23 19:22:38
问题 I have a view on which i need to create a Trigger whenever there is an insert action on the view. When i try to create a Instead of Trigger, i get an error saying that i have insufficient Privileges. Isn't it that when i create a trigger, select privileges are enough? If not, what are the privileges required to create this Trigger. Thanks 回答1: To create a trigger in your own schema on a table in your own schema or on your own schema (SCHEMA), you must have the CREATE TRIGGER system privilege.

How to parse data using REGEXP_SUBSTR?

自作多情 提交于 2020-01-22 02:16:46
问题 I have a data set like this (see below) and I try to extract digits which are in form {variable_number_of_digits}{hyphen}{only_one_digit}: with mcte as ( select 'ILLD/ELKJS/00000000/ELKJS/FHSH' as addr from dual union all select 'ILLD/EFECTE/0116988-7-002/ADFA/ADFG' as addr from dual union all select 'IIODK/1573230-0/2216755-7/' as addr from dual union all select 'IIODK/1573230-0/2216755-700/WRITE' as addr from dual ) select addr, REGEXP_SUBSTR(addr,'(\/)([0-9-]+)',1,1,NULL,2) AS num1, REGEXP

Replacing Email Domains

▼魔方 西西 提交于 2020-01-22 02:07:27
问题 I'm trying to change the inputted domain name to a new domain name, for example, "hotmail.com" becomes "outlook.com". I believe I'm on the right track, just my substring is off. CREATE OR REPLACE PROCEDURE PR_ChangeDomain (P_Email_Address varchar2) IS Cursor C_Email IS Select Email_Address, Broker_Number From Customer Where Email_Address = P_Email_Address; V_Email varchar2(50); BEGIN Open C_Email; Fetch C_Email into V_Email; While C_Email%FOUND LOOP Update Customer Set Email_Address = SUBSTR(

How to hide Oracle Apex Database Application Code After Publish

空扰寡人 提交于 2020-01-21 10:00:41
问题 With Oracle APEX, after I finished developing application I want to publish it to customer on its LAN network, when I export file I choose Build Status Override: Read Application Only But when I want to import it, it can be changed to Read and Build Application and -in other hand- its Build status can be changed to Read and Build Application from instance administration even if I imported it as Read Application Only . I want to import Application in a way that no one can modify it or see its

How to hide Oracle Apex Database Application Code After Publish

两盒软妹~` 提交于 2020-01-21 09:59:25
问题 With Oracle APEX, after I finished developing application I want to publish it to customer on its LAN network, when I export file I choose Build Status Override: Read Application Only But when I want to import it, it can be changed to Read and Build Application and -in other hand- its Build status can be changed to Read and Build Application from instance administration even if I imported it as Read Application Only . I want to import Application in a way that no one can modify it or see its

How to hide Oracle Apex Database Application Code After Publish

a 夏天 提交于 2020-01-21 09:59:07
问题 With Oracle APEX, after I finished developing application I want to publish it to customer on its LAN network, when I export file I choose Build Status Override: Read Application Only But when I want to import it, it can be changed to Read and Build Application and -in other hand- its Build status can be changed to Read and Build Application from instance administration even if I imported it as Read Application Only . I want to import Application in a way that no one can modify it or see its

Is there any way to determine if a package has state in Oracle?

空扰寡人 提交于 2020-01-21 03:01:04
问题 Is there any way in Oracle to determine whether a package has state or is stateless? I'm not aware of any view in the data dictionary that contains that information. The "ORA-04068: existing state of packages string has been discarded" error is rather annoying. It can be eliminated by removing package variables from the package. 11g introduced the feature that a package with variables that are all compile-time constants will be treated as stateless. I could have two sessions and compile the

ORA-12505, TNS:listener does not currently know of SID given in connect des

◇◆丶佛笑我妖孽 提交于 2020-01-20 04:23:26
问题 Please kindly help me as I just installed Oracle 11g but cannot connnect using SQL Devloper using the settings below: Username: system Password: mypassword Hostname: localhost Port: 1521 SID: XE Error message: Status : Failure -Test failed: Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor I checked on Windows Services: OracleServiceXE: Started OracleXETNSListener: Started I also unable to connect to