Hi guys,
Is it possible to use SELECT FROM when using an associative array? I'm passing an array to a stored procedure through a .NET application, and I wanna be able to use that array as a condition when selecting from another table. Lets say I'm passing an array of IDs to the procedure, I wanna be able to do this:
select * from ...
Hi All:
How can I update an Apex Tabular Form with pl/sql instead of using a multi-row update(MRU), is it even possible?
Thanks in advance.
...
hi,
i really need a basic hibernate implementation calls oracle plsql function.
it must include configurations, dao and test class.
is there any example for that?
...
I have data like this in oracle database -> 20123,45 ,data type is varchar.
and I want to migrate it to column with NUMBER data type, change comma (,) to dot (.).
so expected result is 20123.45 and data type is NUMBER,
how can I do that ?
thanks before :D
...
Sorry about the rubbish question title. I have a table SET_DEFINITIONS like this:
SETKEY NOT NULL NUMBER(38)
SETENTRY NOT NULL NUMBER(38)
where the idea is that the rows define sets of numbers. For example the table could contain rows:
1 2
1 4
2 1
2 2
which would mean set 1 is {2,4} and set 2 is {1,2}. I want to wr...
Hi,
I need to have a conditional cursor, like:
If a row exists (using WHEN EXISTS or something like this), then my cursor is:
CURSOR varCursor IS SELECT 1 a FROM DUAL;
Else
CURSOR varCursor IS SELECT 2 a FROM DUAL;
But look, I don't want to change a column result, I want to change the entire cursor.
Bellow I put a bigger examp...
I'm looking for the optimal way to create a function that can accept no parameters and return all results, but also accepts parameters and return those results.
The standard I've been dealing with at my job is this:
FUNCTION get_records (
i_code IN records.code%type := NULL,
i_type ...
I have a variable defined as
define dbs '&1'
Suppose I pass database1 as an argument. Then the statement is interpreted as
define dbs database1
I want to append single quotes around the string, ie I want it to be interpreted as
define dbs 'database1'
How should I do this?
...
Ok, I have a complex recursion problem. I want to get a dependecy installation sequence of all of my objcts (all_objects table) in my Oracle 11g database.
First I have created a view holding all dependencies
create or replace
view REALLY_ALL_DEPENDENCIES as
select *
from ALL_DEPENDENCIES
union
select owner, index_name, 'INDEX', ta...
I would like to know whether anyone knows about a library or code that will accept a PL/SQL string and thow error if there is any PL/SQL injection. Most of the open source projects in the internet are created in PHP.
...
I am not new to programming, but when it comes to databases, my concepts are messed up.
I would like to know how to program in databases..
I am not sure which book to refer to ..and also I have to consolidate my concepts in databases.
Any resource with good images, on joins, normalization would be of great help
Is there any resource/ bo...
I am using dbms_metadata.get_ddl function. I extract ddl of package and package body seperate and use them separately, so i dont need PACKAGE BODY's ddl when i ask for PACKAGE ddl. However get_ddl('PACKAGE',some_package) returns PACKAGE and PACKAGE BODY's ddls together.
Is there a parameter to set, or anything else to make this possible....
Hi All,
I am trying to run this code below using Execute Immediate but its not working and values are correct.
Please suggest the correct code.
declare
v_count number:=1;
v_conc_name varchar2(400);
v_val VARCHAR2(20):='vineet';
BEGIN
v_conc_name:='INT_AP_PAY_CONV';
EXECUTE IMMEDIATE 'UPDATE xxx_cnc_prg_details
SET
...
As the title suggests, I would like to know if it is possible to join the string in a select statement within a PL/SQL procedure.
For example, I have something like this
SELECT FCS.CATEGORY,
FCS.NUMBERS,
FCS.POINTS
WHERE FCS.OBJECT = 'T'
AND FCS.THIS_DB & strSelectedDB &
So, is it possible to do something like...
How to use array( Varray) in store procedure. Actually,i have make a stored procedure from which i retrieve a list of elements.
For example:
create or replace procedure GetTargetFields ( fileformat in varchar2,
filefields out Vrray(4) )
IS
BEGIN
SELECT id
INTO filefields
FROM ...
I'm debugging a procedure which ... returns certain values. The procedure seems to use DBMS_SQL.DESCRIBE_COLUMNS2 which was, till now unknown to me.
One of the out variables of the DBMS_SQL.DESCRIBE_COLUMNS2 procedure is a collection, and I want to examine that value is being returned into that - how can I observe/watch/examine this va...
I am writing a query to find employees who earn greater than the average salary within their department. I need to display the employee ID, salary, department id, and average salary of that department.
I have a query that just almost works but it keeps giving me "ORA-00904: "AVG_SAL": invalid identifier" errors. Am I doing this correctl...
select col1 from tablename returns 2 rows, i want to concat thse two rows data into single column as comma separated.
...
I would like to write a PLSQL function that returns true if the domain name I pass is valid.
I should use regular expression, but I don't know how to do this.
declare
ignore boolean;
begin
isDomainSyntaxOk('www.laclasse.com'); --> should return true.
isDomainSyntaxOk('www.la classe.com'); --> should return false because ...
Is there a PL/SQL function or general technique to quote unqualified identifiers (e.g., mytable) for use in a dynamically constructed SQL query? How about partially or fully qualified identifiers (a.b@c)?
Consider this contrived example:
CREATE PROCEDURE by_the_numbers(COL_NAME VARCHAR, INTVAL INTEGER) IS
...
BEGIN
-- COL_NAME is ...