Questions tagged [dbms-output]

145 questions
-1
votes
1 answer

Error executing DBMS_OUTPUT.PUT_LINE in Oracle

I am running DBMS_OUTPUT.PUT_LINE to send a message from a procedure and I am trying to display the debug information of what a type variable contains BFILE create or replace PROCEDURE P_FILEUPLOAD_XML IS v_dir …
John Doe
  • 1
  • 5
  • 26
-1
votes
3 answers

oracle execute immediate not executing without any error

I have a cursor to return record to be used in EXECUTE IMMEDIATE CURSOR c1 IS SELECT crs_cust.CUSTOMER_ID AS CUSTOMER_ID, subset.NEW_CUSTOMER_REFERENCE_ID AS CUSTOMER_REF_ID FROM CRS_CUSTOMERS crs_cust INNER JOIN DAY0_SUBSET subset ON …
user2102665
  • 429
  • 2
  • 11
  • 26
-1
votes
1 answer

Pl/sql dbms output

I'm very new to pl/sql and I cannot make this query run. I want it to find differences between two tables and then output ID of those transactions. Any help would be appreciated! SET SERVEROUTPUT ON DECLARE diff_id varchar2(50); diff_id2…
Lostinsql
  • 27
  • 5
-1
votes
1 answer

Executing anonymous block (pl/sql) returns numeric value

I am a beginner in oracle sql. I want to test out a simple anonymous block as following from sql plus in expecting "foo" but instead numeric value "2" is returned. I am trying to understand why. set serveroutput on size 20000; begin …
DaeYoung
  • 1,161
  • 6
  • 27
  • 59
-1
votes
1 answer

mysql query to Identify which sql table column contains given string

Given: TABLE : columns(column1(primary key),column2,column3) column1 column2 column3 1920 abc def 1930 xyz hji 1940 def abc Now, how to find column_name among column2 or…
Nikita Gupta
  • 495
  • 9
  • 24
-1
votes
2 answers

PL SQL: printing list from code block. I receive 'anonymous block completed' with heading but no results

I am not sure why my 2nd DBMS_OUTPUT.OUT_LINE doesn't print out my list? I recieve anonymous block completed and the headings (RANK: BABY NAMES: ) print out however my requested list does not. Here is my code: SET SERVEROUTPUT ON SET VERIFY…
-1
votes
2 answers

Multiple line output in pl/sql

I have a PL/SQL file that has a loop structure. The script is as follows. SET SERVEROUTPUT ON declare c_id employee.id%type; c_name employee.name%type; c_address employee.address%type; CURSOR c_employee is SELECT id, name, address…
Debdipta Halder
  • 497
  • 1
  • 5
  • 19
-1
votes
1 answer

How to get 3 out of 10 rows to get 0 value using dbms_Random.value

I am using for loop to create 10 rows. Inside a for loop, i am using dbms_random.value to generate integers between 0 to 10. I want to code dbms_random methid in such a way where each row as 30% chance to get 0.
Ish Bhatt
  • 31
  • 6
-1
votes
1 answer

dbms_output.put_line shows variable value but does not save to database

I am trying to save a value in a table after removing an & in the input variable. When I print the value of the variable in dbms_ouput.put_line I get the output. but when I save the value of the variable to database, nothing is updated. Code below…
Sarwar
  • 31
  • 1
  • 4
-2
votes
1 answer

Use variable in where clause PL/SQL

I have several queries unioned together, all of which have the same date parameter in the where clause. I'd like to make this easy to update. I've written T-SQL variables but PL SQL is a bit different. Trying to figure out how to execute something…
Katie Gray
  • 11
  • 3
1 2 3
9
10