oracle11g

SSRS 2016 Data source won't display Oracle connection type

梦想与她 提交于 2019-12-25 08:09:46
问题 I have a couple of new SSRS 2016 installations. Both of them fail to show the Oracle connection type. They will show Oracle Essbase, but that isn't what I'm looking for. The full Oracle client is installed in both cases and I can successfully make a connection using the OLEDB connection type and invoking the Oracle OLEDB driver. Unfortunately, I have hundreds of reports that I'm moving to these new instances and the OLEDB client behaves slightly differently than the .Net client and causes

Oracle auto increment trigger issue

ⅰ亾dé卋堺 提交于 2019-12-25 07:59:27
问题 I am having an issue when creating the auto increment trigger in Oracle 11g. If someone can point out what I am doing wrong, I would really appreciate it. My script for the sequence is this : CREATE SEQUENCE SPSS_QUOTE_LINE_ITEMS_SEQ start with 1 increment by 1 minvalue 1; The script for trigger: CREATE OR REPLACE TRIGGER SPSSQUOTELINEITEMS_ON_INSERT BEFORE INSERT ON SPSS_QUOTE_LINE_ITEMS FOR EACH ROW BEGIN SELECT SPSS_QUOTE_LINE_ITEMS_SEQ.NEXTVAL INTO :new.line_num FROM dual; END; The error

PLS-00201: identifier 'R_CUR' must be declared in dynamic sql

泄露秘密 提交于 2019-12-25 07:59:05
问题 Requirement: what I want from this code is to execute the cursor dynamically and set variable var true or false based on column values. Problem: But while I am running the below code its showing me error: Error at line 4 ORA-06550: line 1, column 10: PLS-00201: identifier 'R_CUR' must be declared ORA-06550: line 1, column 7: PL/SQL: Statement ignored ORA-06512: at line 61` set serveroutput on; DECLARE CURSOR cur IS SELECT EMPNO, ENAME, JOB, MGR FROM emp WHERE EMPNO = 7839; TYPE t_cur IS TABLE

Check string for numbers and characters in Oracle 11G

不羁岁月 提交于 2019-12-25 07:48:43
问题 I am working on something. I got to check a string for validation. This string has a country code and a university code (from their own tables in the database) and a bunch of numbers. Now I need to validate this string. I need to check this string on the country code and university code and if it has numbers yes or no. I have tried alot of things at the moment. I tried to use alot of if statements, regexp_like, instr, substr, select statements and others. But I am not capable of checking the

Yii2 oracle 11g gii relations timeout

烂漫一生 提交于 2019-12-25 07:47:24
问题 I have: Windows Server 2012 R2 wampserver 3.0.6 64bit yii2 php_oci8_12c enabled, php_pdo_oci enabled, oracle instantclient-basiclite-windows.x64-12.1.0.2.0 System Path defined according added mod_fcgid 2.3.9 to Apache added oci8 2.0.12 Thread Safe x64 for PHP 5.6 (replaced old php_oci8_12c.dll) I see PDO for Oracle in phpinfo. I have a db_o.php config file: return [ 'class' => 'yii\db\Connection', 'dsn' => 'oci:dbname=//SOME_IP_ADDRESS:PORT/YOUR_SID;charset=UTF8', 'username' => '', 'password'

Want a SQL to get days between 2 date and exclude Saturday and Sunday in Oracle [duplicate]

佐手、 提交于 2019-12-25 07:47:10
问题 This question already has answers here : Oracle: Days between two date and Exclude weekdays how to handle negative numbers (2 answers) Closed 7 months ago . As the title said, I want to calculate days between 2 dates and exclude weekend(Saturday and Sunday) in Oracle, I have no idea about this at all, can anyone help give an example SQL? 回答1: Try this. Change start_date and end_date as per your requirement. If you want number of weekdays, use WITH test_data AS ( SELECT TO_DATE('01-JAN-2014',

Using between operator for string which stores numbers

↘锁芯ラ 提交于 2019-12-25 06:59:25
问题 I have a column in which numbers are stored as string because of the nature of the column where any kind of data type is expected like date, numbers, alpha numeric, etc. Now i need to check if the values in that column is in defined range or not here is sample data for testing create table test (val varchar2(10)); insert into test values ('0'); insert into test values ('67'); insert into test values ('129'); insert into test values ('200'); insert into test values ('1'); Here expected range

oracle express 11g exception weird

走远了吗. 提交于 2019-12-25 06:46:20
问题 CREATE TABLE "EMPLOYEE" ("SSN" NUMBER(*,0) NOT NULL ENABLE, "MANAGER_SSN" NUMBER(*,0) NOT NULL ENABLE, "STREET" CHAR(40) NOT NULL ENABLE, "CITY" CHAR(25) NOT NULL ENABLE, "DEP_NO" NUMBER(*,0) NOT NULL ENABLE, "NAME" CHAR(15) NOT NULL ENABLE, "SALARY" NUMBER(8,2) NOT NULL ENABLE, "HIRE_DATE" DATE, CONSTRAINT "PK_EMPLOYEE" PRIMARY KEY ("SSN") ENABLE ) and when i try to insert into that table : insert into employee values (1,1,"cola","beirut",1,"mohamad",1500,"7-feb-1999") it says : ORA-00984:

Calling Oracle procedure that returns rows using SimpleJdbcCall in Spring

谁说我不能喝 提交于 2019-12-25 05:13:26
问题 I have written the following code MapSqlParameterSource in = new MapSqlParameterSource(); in.addValue("V_OPP_ID", bean.getOpportunityId()); in.addValue("V_NAME",bean.getName()); in.addValue("V_FROM_DATE", bean.getStdate()); in.addValue("V_TO_DATE", bean.getEddate()); in.addValue("V_USERTYPE", bean.getUserType()); jdbcCall.execute(in); Here the jdbcCall.execute(in) returns me resultset/table corresponding to Arraylist. How do i extract this ArrayList Is using jdbcCall a correct Approach ? If

Query to return unique values when one of column value is repeating

最后都变了- 提交于 2019-12-25 04:53:33
问题 I have a sql query like the following SELECT Name.Nameguid,Name.Name,relation.ancestorguid,relation.productguid,relation.pathLength FROM Name Name JOIN ProductRelationship relation ON Name.productGuid = relation.ancestorGuid AND relation.productGuid = '6075D04A-E74A-464B-94E7-25374F0B9833' ORDER BY relation.pathLength DESC Which returns the following NameGuid Name AncestorGuid ProductGuid PathLength 6D39CB04-88D9-4125-A052-8DF608AAD29C NameParentOnly 8E07F824-763C-434F-926C-80FCC8690243