Questions tagged [toad]

Toad is a database query tool from Quest Software. There are versions of Toad that can query Oracle, SQL Server, MySQL, PostgreSQL and more. It provides query editing & reporting, debuggers, performance analyzers and many other tools.

Toad is a database query tool from Quest Software. There are versions of Toad that can query Oracle, SQL Server, MySQL, PostgreSQL and more. It provides query editing & reporting, debuggers, performance analyzers and many other tools.

This tag should be used for questions regarding how to use Toad software.

1263 questions
-1
votes
2 answers

Execute insert script from TOAD

I used TOAD, Oracle 11g. I want to create Batch Insert script. Example INSERT INTO tbl_name (a,b,c) VALUES(1,2,3),(4,5,6),(7,8,9); But, when I use export dataset - insert statements, I get: Insert into tbl_name (1, 2, 3) Values (1, 2, 3); …
BaeDa
  • 39
  • 9
-1
votes
1 answer

Unit test the Oracle SQL stored procedure in TOAD

I have a complex stored procedure written by someone and I need to understand part of it to check what data it returns. So, started to test it by passing some data in toad. this is an Oracle stored procedure. I get error: Encountered the symbol…
user3147594
  • 61
  • 1
  • 2
  • 14
-1
votes
2 answers

Oracle plsql how to check if number has decimal points

Just started working with oracle using toad ide. trying to format the numbers from a table in specific format. the numbers come in from a variable in the table and I want to display the whole numbers as whole numbers and display floats as floats. So…
Ash
  • 1
  • 1
  • 1
  • 2
-1
votes
3 answers

Trying to add column of CLOB type to table in DB2

I need to add a column of type "CLOB" to the existing table in the database, so I am using the below query: alter table foldet add("FOLDER_FIELD_VALUE_TWO" CLOB); but I am getting the below error Error starting at line : 5 in command - alter…
vemak
  • 33
  • 8
-1
votes
1 answer

Getting the error "cannot add foreign key constraint" in my last stament in mysql

2(a) (i) Create table staffs(Staff_Id integer not null primary key, Name varchar(255), Staff_Type varchar(255), Session_Id integer not null); select * from staffs; (ii) Create table Customers(Customer_Name Varchar(255) primary key); …
Rubmay
  • 1
-1
votes
3 answers

Retrieve the maximum number for each group of records oracle DB

I failed to write SQL code to retrieve maximum number in order_number column. notice that visit_number is group contain more than one record and i want the maximum value of order_number column. visit_number , Order_number , NAME 111 , 1…
Nawaf
  • 540
  • 1
  • 5
  • 14
-1
votes
1 answer

How to autoreplace sql code

How to replace SQL code that is used very often using Toad for Oracle or Oracle SQL Developer?
Dchris
  • 2,867
  • 10
  • 42
  • 73
-1
votes
1 answer

Getting an error for sql query "(full) year must be between -4713 and +9999, and not be 0"

I am getting an error "(full) year must be between -4713 and +9999, and not be 0" unable to figure why this error is coming. SELECT B.TST_CTR_CDE, C.DESCRIPTION,TO_CHAR(TO_DATE(B.CMPLT_DTE,'yyyymmdd'), 'MONTH') Month, sum(decode(b.pass_sta,'1',1))…
tom
  • 5,114
  • 6
  • 24
  • 36
-1
votes
1 answer

why objects are being created in sys schema?

My problem is that when i create an object it is always stored in sys schema. Normally when you do not specify the schema, the object should be created in the current schema. I'm using toad 12, and the tab current schema is setted correctly. What i…
Aramillo
  • 3,176
  • 3
  • 24
  • 49
-1
votes
3 answers

Query to Find Duplicate entries

I am looking for an SQL query to give me a list of duplicate entries in a table. However, there are 3 different columns to take into account. First is an ID, Second is a Name, and third is a Date. The situation is that there are multiple Names that…
Programmer
  • 291
  • 1
  • 3
  • 14
-1
votes
3 answers

PLSQL - Add days to date in format dd/mm/yyy +1

I want to write a PLSQL query in the following way: Select ... FROM ... WHERE Date = '06/FEB/2011' + 7(days) Im new to PLSQL, I've seen solutions such as date+1, but that requires by date to be inside a variable. I tired putting into a variable…
jmich738
  • 1,565
  • 3
  • 24
  • 41
-1
votes
1 answer

CASE WHEN issue

Im trying to use a simple case when statement in my SQL query, but it doesnt seem to work. Here's my query : SELECT location_id, rtb_user_id, start_time, end_time, tt_no, assn_by, assn_time, loc_id, loc_name, parent_loc_id, hr_level,…
user3176971
  • 599
  • 2
  • 6
  • 16
-1
votes
2 answers

Why this Code is Giving ERROR

I am unable to use simple SELECT statement to initialize a variable. DECLARE A VARCHAR2(10); BEGIN A := (SELECT FIRST_NAME FROM FIMS_OWNER.EMPLOYEE_T WHERE WWID = 'NA734'); END; / ERROR: [Error] Execution (4: 11): ORA-06550: line 4, column…
Sachin
  • 963
  • 11
  • 31
-1
votes
3 answers

SELECT * FROM T_TRANS WHERE TIME_START = to_date('01-09-2014', 'DD-MM-YY');

Sory, I have Question ? Why not show up when I execute some of its field content. Please help me to fix it. Thank U SELECT * FROM T_TRANS WHERE TIME_START = to_date('01-09-2014', 'DD-MM-YY');
-1
votes
1 answer

Adding all Time values in a column

I have the following data Shift_Working_Hours -------------------- 03:45 09:00 08:45 07:50 I want to add up all the values in the Shift_Working_Hours column and I want the result as 28:40. Please guide me how can i do it…
user3152738
  • 9
  • 1
  • 1
  • 1