Dragging Table Columns to SQL Worksheet
When Dragging table columns to the sql worksheet it puts the column name at the end of the page instead of where you place your mouse cursor.
Version
Release 4 Build 1184
That is how it is implemented so not a bug. We do the same when you drag over a table, append with 2 lines of padding. Obviously not how you want it. I have logged an enhancement to be reviewed for a future release.
-- Sharon
Similar Messages
-
Can't drag a table into the SQL worksheet anymore under 1.5.5
IIRC, in 1.5.4 I could expand my list of tables and then drag it into the SQL worksheet page at which point a SELECT statement for the table with all of the columns would be generated.
This does not appear to be happening for me in 1.5.5Had the same thing happening over the last versions. It never worked in a session, unless deleting the setting dir. But upon restart it would be messed up again.
After upgrading to 1.5.5, it started working again and had no problems since.
The team pretty much waived the problem away because it's apparently something with our setups and exceptions aren't worth the effort. The only way to get this looked at is opening a SR on Metalink.
Regards,
K. -
SQL-Developer 1.5.4 - SQL-Worksheet does not use Table-Owner
In old versions of the sql-Developer you can drop a Table in the Worksheet and a select Query was built. With the new version 1.5.4 the table-owner is missng and you must fill in the table-owner or the query does not work with tables of other users.
Is that a bug or are there the posibility of change settings to drop tables in the SQL-worksheet with table-owners.The drag and drop functionality was updated so that when you use drag and drop the schema is not prefixed for the current user you are connected to. However it is appended if you drag a table form another connection. It appears to have been overlooked for Other Users. We will address this in a future release. In the meantime,a workaround is to create a connection to the other users and then the drag and drop will append the connection name.
Sue -
The ability to drag a table from the object browser into a worksheet to create a select statement seems to have stopped working. When I try to drag a table accross, nothing happens - no mouse cursor changes-nothing. There is nothing in the java console when I try to drag altough I get the exception below on startup..
SQL Dev 1.1.3, upgraded from 1275
Java 1.5_05
WIndows XP Pro SP2
4th Elephant Errors Lookup 0.4
4th Elephant Insider 2.0.1
Update:
I've just upgraded another installation (without extensions) and the same problem occurs.
Exception in thread "AWT-EventQueue-0" oracle.classloader.util.AnnotatedNoClassD
efFoundError:
Missing class: oracle.dbtools.logging.ILoggingPage
Dependent class: oracle.dbtools.logging.ui.LoggingPage
Loader: main:11.0
Code-Source: /C:/progs/sqldeveloper-2514/sqldeveloper/extensions/ora
cle.sqldeveloper.jar
Configuration: system property C:\progs\sqldeveloper-2514\sqldeveloper
\extensions\oracle.sqldeveloper.jar
The missing class is not available from any code-source or loader in the system.
at oracle.classloader.PolicyClassLoader.defineClass(PolicyClassLoader.ja
va:2307)
at oracle.classloader.PolicyClassLoader.findLocalClass(PolicyClassLoader
.java:1481)
at oracle.classloader.SearchPolicy$FindLocal.getClass(SearchPolicy.java:
167)
at oracle.classloader.SearchSequence.getClass(SearchSequence.java:119)
at oracle.classloader.PolicyClassLoader.internalLoadClass(PolicyClassLoa
der.java:1693)
at oracle.classloader.PolicyClassLoader.access$000(PolicyClassLoader.jav
a:141)
at oracle.classloader.PolicyClassLoader$LoadClassAction.run(PolicyClassL
oader.java:297)
at java.security.AccessController.doPrivileged(Native Method)
at oracle.classloader.PolicyClassLoader.loadClass(PolicyClassLoader.java
:1657)
at oracle.classloader.PolicyClassLoader.loadClass(PolicyClassLoader.java
:1639)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at oracle.dbtools.raptor.RaptorDBAddin$3.mainWindowOpened(RaptorDBAddin.
java:331)
at oracle.ide.IdeCore.fireIdeEvent(IdeCore.java:754)
at oracle.ide.IdeCore.mav$fireIdeEvent(IdeCore.java:113)
at oracle.ide.IdeCore$3.run(IdeCore.java:718)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchTh
read.java:242)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre
ad.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)Message was edited by:
smitjb (new)I've just tried deleting the jar files for the 3 third party database browsers. Dragging still doesn't work
Here is my extensions window...
Check For Updates oracle.ide.webupdate 11.1.1.0.11.42.52 Loaded
Code Editor oracle.ide.ceditor 11.1.1.0.11.42.52 Loaded
Database Connections (IDE) oracle.jdeveloper.db.connection 11.1.1.0.11.42.52 Loaded
Database Developer oracle.onlinedb 11.1.1.0.11.42.61 Loaded
Database Object Explorers oracle.ide.db.explorer 11.1.1.0.11.42.52 Loaded
Database UI oracle.ide.db 11.1.1.0.11.42.52 Loaded
External Tools oracle.ide.externaltools 11.1.1.0.11.42.52 Loaded
Feedback oracle.ide.feedback 11.1.1.0.11.42.52 Loaded
File Support oracle.ide.files 11.1.1.0.11.42.52 Loaded
Help System oracle.ide.help 11.1.1.0.11.42.52 Loaded
Import/Export Support oracle.ide.importexport 11.1.1.0.11.42.52 Loaded
Log Window oracle.ide.log 11.1.1.0.11.42.52 Loaded
Mac OS X Adapter oracle.ideimpl.apple 11.1.1.0.11.42.52 Loaded
Navigator oracle.ide.navigator 11.1.1.0.11.42.52 Loaded
Object Gallery oracle.ide.gallery 11.1.1.0.11.42.52 Loaded
Object Viewer oracle.dbdev.oviewer 10.1.3.27.66 Loaded
Oracle IDE oracle.ide 11.1.1.0.11.42.52 Loaded
Oracle JDeveloper Fusion oracle.javacore 11.1.1.0.11.42.52 Loaded
Oracle SQL Developer oracle.sqldeveloper 1.1.3.27.66 Loaded
Oracle SQL Developer Extras oracle.sqldeveloper.extras 1.1.3.27.66 Loaded
Oracle SQL Developer Reports oracle.sqldeveloper.report 10.1.3.27.66 Loaded
Oracle SQL Developer SearchBar oracle.sqldeveloper.searchbar 10.1.3.27.66 Loaded
Replace With oracle.ide.replace 11.1.1.0.11.42.52 Loaded
Runner oracle.ide.runner 11.1.1.0.11.42.52 Loaded
SQL Formatter oracle.dbtools.sqlformatter 10.1.3.25.79 Loaded
SQL Worksheet Window oracle.dbtools.sqlworksheet 10.1.3.27.66 Loaded
SQL*Plus Integration oracle.jdeveloper.db.sqlplus 11.1.1.0.11.42.52 Loaded
Snippet Window oracle.dbdev.snippet 10.1.3.27.66 Loaded
Web Browser and Proxy oracle.ide.webbrowser 11.1.1.0.11.42.52 Loaded
XML Editing Framework IDE Extension oracle.ide.xmlef 11.1.1.0.11.41.91 Missing dependencies: oracle.ide.daf, oracle.ide.palette2
audit oracle.ide.audit 11.1.1.0.11.42.52 Loaded
oracle.ide.indexing oracle.ide.indexing 11.1.1.0.11.42.52 Loaded -
I need the "Real" Table / Table Column names from a sql view
Firstly, we have a system with ~1000 tables and ~250 views. We have field level security on the table columns (in our code)
Now we have a lot of views which select data from the tables, but I need to get the "Table Column Name" that is linked in the view.
I know there are view columns that is not linked to a specific table column, (or concatenation of columns) so those columns can just return NULL.
From the sample you will see there is a view selecting data from another view. I know it is not the best sql performance (execution path) but that is another topic on its own.
I went through a lot of the sys.* stored procs or sys.* views to try and figure out if there is a view that we can use to get the expected results.
here is the sql code:
if
Exists (select
* from
sys.all_objects
where name =
'AliasView2')
drop view dbo.AliasView2
if
Exists (select
* from
sys.all_objects
where name =
'AliasView1')
drop view dbo.AliasView1
if
Exists (select
* from
sys.all_objects
where name =
'Table4')
BEGIN
alter table dbo.Table4
DROP CONSTRAINT [FK_T4_T3]
alter table dbo.Table4
DROP CONSTRAINT [PK_T4_Constraint]
drop table dbo.Table4
END
if
Exists (select
* from
sys.all_objects
where name =
'Table3')
BEGIN
alter table dbo.Table3
DROP CONSTRAINT [FK_T3_T2]
alter table dbo.Table3
DROP CONSTRAINT [PK_T3_Constraint]
drop table dbo.Table3
END
if
Exists (select
* from
sys.all_objects
where name =
'Table2')
BEGIN
alter table dbo.Table2
DROP CONSTRAINT [FK_T2_T1]
alter table dbo.Table2
DROP CONSTRAINT [PK_T2_Constraint]
drop table dbo.Table2
END
if
Exists (select
* from
sys.all_objects
where name =
'Table1')
BEGIN
alter table dbo.Table1
DROP CONSTRAINT [PK_T1_Constraint]
drop table dbo.Table1
END
create
Table dbo.Table1
T1_PK int
NOT NULL
Identity(1, 1)
CONSTRAINT [PK_T1_Constraint]
PRIMARY KEY (T1_PK),
T1_Field1 varchar
NULL,
T1_Field2 varchar
NULL,
create
Table dbo.Table2
T2_PK int
NOT NULL
Identity(1, 1)
CONSTRAINT [PK_T2_Constraint]
PRIMARY KEY (T2_PK),
T2_Field1 varchar
NULL,
T2_Field2 varchar
NULL,
T2_FK int
NOT NULL
CONSTRAINT [FK_T2_T1]
FOREIGN KEY (T2_FK)
REFERENCES dbo.Table1
(T1_PK)
create
Table dbo.Table3
T3_PK int
NOT NULL
Identity(1, 1)
CONSTRAINT [PK_T3_Constraint]
PRIMARY KEY (T3_PK),
T3_Field1 varchar
NULL,
T3_Field2 varchar
NULL,
T3_FK int
NOT NULL
CONSTRAINT [FK_T3_T2]
FOREIGN KEY (T3_FK)
REFERENCES dbo.Table2
(T2_PK)
create
Table dbo.Table4
T4_PK int
NOT NULL
Identity(1, 1)
CONSTRAINT [PK_T4_Constraint]
PRIMARY KEY (T4_PK),
T4_Field1 varchar
NULL,
T4_Field2 varchar
NULL,
T4_FK int
NOT NULL
CONSTRAINT [FK_T4_T3]
FOREIGN KEY (T4_FK)
REFERENCES dbo.Table3
(T3_PK)
GO
--Create a basic view to select some data
CREATE
VIEW dbo.AliasView1
AS
select
t2.T2_FK as Table2_ForeignKey,
t1.T1_Field1 as Table1_FieldOne,
t2.T2_Field1 as Table2_FieldOne
FROM Table1 t1
Left outer
join Table2 t2 on t2.T2_FK
= t1.T1_PK;
GO
--Create another view that select basic data, and also selecting data from view 1
CREATE
VIEW dbo.AliasView2
AS
select
v1.Table1_FieldOne
as Table1_FieldOne,
v1.Table2_FieldOne
as Table2_FieldOne,
t3.T3_Field1 as Table3_FieldOne,
t3.T3_Field2
FROM Table3 t3
Left outer
join AliasView1 v1 on v1.Table2_ForeignKey
= t3.T3_PK;
GO
--My attempt to get the desired output, but no luck
SELECT
col.COLUMN_NAME as AliasColumnName, col.DATA_TYPE, col.CHARACTER_MAXIMUM_LENGTH
as max_length, colu.*
FROM
information_schema.COLUMNS col
left
outer join
(SELECT
VIEW_SCHEMA, VIEW_NAME, COLUMN_NAME,
min(TABLE_NAME)
as TABLE_NAME
FROM information_schema.VIEW_COLUMN_USAGE colu
WHERE VIEW_NAME =
'AliasView2'
Group by VIEW_SCHEMA, VIEW_NAME, COLUMN_NAME
) COLU ON colU.VIEW_NAME
= col.TABLE_NAME
and colu.COLUMN_NAME
= col.COLUMN_NAME
left
outer join
(select a.name
as TableName, c.name
as FieldName
from sys.foreign_key_columns fk
join sys.all_objects a
on a.object_id
= fk.parent_object_id
join sys.all_columns c
on c.object_id
= a.object_id
and c.column_id
= fk.parent_column_id
join sys.all_objects ar
on ar.object_id
= fk.referenced_object_id
join sys.all_columns cr
on cr.object_id
= ar.object_id
and cr.column_id
= fk.referenced_column_id
join sys.schemas scr
on scr.schema_id
= ar.schema_id
) fks on fks.TableName
= colu.TABLE_NAME
and fks.FieldName
= colu.COLUMN_NAME
WHERE COL.TABLE_NAME
= 'AliasView2'
order
by col.ORDINAL_POSITION
This is the results being returned: (That is not 100% what I am looking for)
AliasColumnName
DATA_TYPE
max_length
VIEW_SCHEMA
VIEW_NAME
COLUMN_NAME
TABLE_NAME
Table1_FieldOne
varchar
1
dbo
AliasView2
Table1_FieldOne
AliasView1
Table2_FieldOne
varchar
1
dbo
AliasView2
Table2_FieldOne
AliasView1
Table3_FieldOne
varchar
1
NULL
NULL
NULL
NULL
T3_Field2
varchar
1
dbo
AliasView2
T3_Field2
Table3
The desired results must be like the following:
AliasColumnName
DATA_TYPE
max_length
VIEW_SCHEMA
VIEW_NAME
COLUMN_NAME
TABLE_NAME
Table1_FieldOne
varchar
1
dbo
AliasView2
T1_Field1
Table1
Table2_FieldOne
varchar
1
dbo
AliasView2
T2_Field1
Table2
Table3_FieldOne
varchar
1
dbo
AliasView2
T3_Field1
Table3
T3_Field2
varchar
1
dbo
AliasView2
T3_Field2
Table3
NOTE: the COLUMN_NAME and TABLE_NAME must the REAL field of the TABLE it belongs to and not only ONE LEVEL Higher’s ALIAS View NameNow we have a lot of views which select data from the tables, but I need to get the "Table Column Name" that is linked in the view.
If you are using SQL Server 2012/2014, then you can use
sys.dm_exec_describe_first_result_set (Transact-SQL) to gte the informations.
Olaf Helper
[ Blog] [ Xing] [ MVP] -
SQL Loader: handling difference datatypes in data file and table column
Hi,
I am not sure if my question is valid but I am having this doubt.
I am trying to load data from my data file into a table with just a single column of FLOAT datatype using SQL Loader. But very few insertions take place, leaving a large number of record rejected for the same reason-
Record 7: Rejected - Error on table T1, column MSISDN.
ORA-01722: invalid number
The data in my datafile goes like this: (with a single space before every field)
233207332711<EOFD><EORD> 233208660745<EOFD><EORD> 233200767380<EOFD><EORD>
Here I want to know if there is any way to type cast the data read from the data file to suit my table column's datatype.
How do I handle this? I want to load all the data from my datafile into my table.Pl continue the discussion in your original post - Pls help: SQL Loader loads only one record
-
Invalid Column error in Access SPT & SQL Worksheet!
SQLWKS> select x.rr,
2> x.name,
3> x......,
4> x.mail_addr1,
5> x.mail_addr2,
6> x.mail_addr3,
7> x.mail_addr4,
8> x.mail_postcode,
9> x....,
10> x........,
11> x........,
12> x........,
13> x........,
14> a_b_c(x.mail_postcode) z 'this is the line that calls
function 'a_b_c' (using x.mail_postcode as the variable) which
throws the error below in access and sql worksheet.
15> from x
16> where (.........
17> or ..... is null)
18> and not exists
19> (select 'x' from .......where .......=
20> x.rr)
21>
a_b_c(x.mail_postcode) z
ORA-00904: invalid column name
If anybody has any idea how to get around this please email me
or post you comments.
Thanks
Leslie
nullSQLWKS> select x.rr,
2> x.name,
3> x......,
4> x.mail_addr1,
5> x.mail_addr2,
6> x.mail_addr3,
7> x.mail_addr4,
8> x.mail_postcode,
9> x....,
10> x........,
11> x........,
12> x........,
13> x........,
14> a_b_c(x.mail_postcode) z 'this is the line that calls
function 'a_b_c' (using x.mail_postcode as the variable) which
throws the error below in access and sql worksheet.
15> from x
16> where (.........
17> or ..... is null)
18> and not exists
19> (select 'x' from .......where .......=
20> x.rr)
21>
a_b_c(x.mail_postcode) z
ORA-00904: invalid column name
If anybody has any idea how to get around this please email me
or post you comments.
Thanks
Leslie
null -
Drag and drop a table column?
Hi All gurus.
Is it possible to drag a standard table as well as an ALV table column?
To re-phrase my question, I want to swap the positions of 2 columns in a table. Possible?
Thanks in adv!>
Aishi Sharma wrote:
> Great. But we are already on EHP3. But I can't see the functionality. Do we need to code in a particular fashion for the tables? or do we need to switch "on" the EHP or something like that?
You must be confusing ERP Enhancement Packages with NetWeaver Enhancement Packages. They are two completely different things. NetWeaver Enhancement Package 1 is just now in Ramp-Up. NetWeaver EnhP2 is in development and EnhP3 doesn't exist at all yet. Therefore I must assume when you say you on EHP3 you mean ERP Enhancement Package 3. -
SQL from Table Column with Dynamic URL Problem
This is the SQL I'm attempting to save to a table column via the Object Browser;
select
"a"."PBR_BRIEF_ID" "Brief ID",
"a"."PROJECT_NUMBER" "Project",
"b"."DESCRIPTION" "Description",
"b"."ACTUAL_END_DATE" "Actual End",
"b"."RFS_DATE" "RFS",
"b"."LOCATION_CODE" "Location",
''||"b"."ESA_CODE"||'' "ESA",
"b"."PROJECT_USER_STATUS" "Status",
"b"."PROJECT_TRIGGER" "Trigger"
from
UPT1TRIAL.FUND_PLAN_BRIEF_LINK_CCR@NDSD "a",
UPT1INTEGRAL.INT_PROJECT_DATA@NDSD "b"
where
"a"."PBR_BRIEF_ID" = :P3_BRIEF_ID and
"a"."PROJECT_NUMBER" = "b"."PROJECT_DEFINITION_NUMBER"
The intesting bit is the following, where a URL is return behind a particular column;
''||"b"."ESA_CODE"||'' "ESA",
It's interesting because when I click on "Apply Changes" in the Object Browser, the text that appears in the column is as follows, i.e. with APP_ID and SESSION populated;
''||"b"."ESA_CODE"||'' "ESA",
Why would that happen??
The full SQL above is used in an application page with a SQL Query (PL/SQL function body returning SQL query). The basic SQL works OK but because of what the Object Browser is doing, the link does not.
Message was edited by:
Damian - apologies for lack of formatting!!
Message was edited by:
DamianDamian,
Use
& lt;
for your < tags and then the message will appear in the proper format.
If you are using dynamic sql to generate an url with APP_ID and SESSSION you could:
a) create page items (P1_APP_ID and P1_SESSION)
b) compute those page items to the actual APP_ID and SESSION_ID
c) use the value of those items while generating your dynamic sql (instead of APP_ID and SESSION)
Then, your links will show the right APP_ID and the right SESSION.
Denes Kubicek -
Sql Loader INFILE name value in table column Value
Hi,
Here is my Sql Loader Script
LOAD DATA
infile '%1'
APPEND INTO TABLE XX_SUPPLIER_UPD
FIELDS TERMINATED BY ";" OPTIONALLY ENCLOSED BY '"' TRAILING NULLCOLS
ACTION Char
,ADDRESS_TYPE Char
,REGION Char "LTRIM(RTRIM(:REGION))"
,PO_BOX Char
,,WWW_ADDRESS Char
,status Char "NVL(:status,'X')"
,filename Char "replace(:infile,'\"','')"
I am getting the infile name as the parameter and i want to insert that parameter value in the column name fillename. Can any one guide me to how to do.
Cheers!
Jayaraj.SIf you were to use external tables instead of SQL*Loader, you can dynamically change the location of the external table (i.e. the filename) using a simple ALTER TABLE statement.
External tables also mean that all the control is inside the database rather than relying on external utilities and external scripts.
;) -
SQL Worksheet doesn't work after reordering a column
SQL Developer 1.1 (1.1.0.23.64)
Sun Java jdk1.6.0
RHEL-4.4
Once a column is reordered in SQL Worksheet Data Grid, it is not possible to receive an output in Results tab (Grid Data) from any consequent query issued after that. The Grid Results panel remains blank (frozen) !!!
AlbertDoesn't happen for me... did you follow the getting started and installation docs?
K -
Dragging the columns to existing logical table source.....
Hi,
I am just learning OBIEE 11g and I am using a turorial from oracle it is
"Creating a Repository Using the Oracle BI 11g Administration Tool" for practice purpose.
In this tutorial it is saying that drag that columns from phscial layer to Logica Table Source
in BMM Layer to avoid creating a second logical table source.. But when I am trying to drag the columns to
existing logical source it is disabling I mean which it is not allowing .. is there any other technique to
do it... or Am i wrongly approaching.. .The below is brief description in the
tutorial.
"Drag all six columns from D50 Sales Rep in the Physical layer to D5 Sales Rep in the BMM layer. This action
creates logical columns and adds a D50 Sales Rep logical table source to D5 Sales Rep.
Rename the D50 Sales Rep logical table source to LTS1 Sales Rep.
In the Physical layer, expand D52 Sales Rep Position.
Drag POSTN_DESC and POSTN_LEVEL from D52 Sales Rep Position to LTS1 Sales Rep. Note that you are
dragging the columns to the logical table source, not the logical table. Dragging to the logical table would create a
second logical table source.
Drag DISTANCE from D51 Sales Rep Parent Child to LTS1 Sales Rep. Again, you drag the column to the logical
table source, not the logical table."
help would be appreciated.
Thanks and Regards,
Sri_Oracle.Hi Sri,
When you are dragging a physical column onto an existing Logical table source and if it does not let you do so, then it means that there is no physical join between the existing physical table(which the logical source is pointing to already) and new physical table (from which you are dragging the column now). So, please make sure, you have the join in place.
Hope this helps.
Thank you,
Dhar -
Copy/Past from SQL Worksheet with Column Headers
Is there a way to copy & paste results out of a SQL Worksheet and have the column headers included?
Message was edited by:
user640368Hi,
I've never known that this feature has been implemented.
The feature exchange said that it is Accepted without giving the detail of when would it be implemented.
http://apex.oracle.com/pls/otn/f?p=42626:39:1324151408296493::NO::P39_ID:5021
The current release notes don't say anything about this as well.
My mistake than if it was noted on previous version.
However, glad to hear if this has been possibly to be done.
I'll have it a try once I've access to my SQL Dev.
Regards,
Buntoro -
Drag a column from one position to another within the table.
Hello All,
In Web Dynpro Java, Is it possible to provide user a functionality with which he/she can move the columns of a table from one position to another ?
Scenario : Users want flexibility to decide the location the columns as per their convinience while they are working with the application.
So can we develop some code or can we use some UI element so that user is able to drag a column from one position to another within the table.
Regards
Mrinalini.Hi Mrinalini,
Yes this is possible you can try to move the table columns (Change the order). for this you don't need to do additional coding or property change its a default property for web Dynpro java tables.
Regards
Jeetendra -
How to specify a table column that is a PL/SQL reserved word
I am writing the following trigger
CREATE OR REPLACE TRIGGER SMS_MSG_TR_B_U
BEFORE UPDATE ON sms_msg
FOR EACH ROW
BEGIN
IF :OLD.BODY != :NEW.BODY THEN
RAISE_APPLICATION_ERROR(-20001,'Invalid update');
END IF;
END SMS_MSG_TR_B_U;
and I get the following error: PLS-00306: wrong number or types of arguments in call to '!='
This is because BODY is a reserved word in PL/SQL but it is not in SQL.
I tried to quote it with " but this does not work.
Does anybody knows the syntax to be able to test a column that has the name of PL/SQL reserved word?You are exactly right, BODY is of type CLOB. So the problem does not lie with the name of the column but the type.
Thanks!
<BLOCKQUOTE><font size="1" face="Verdana, Arial, Helvetica">quote:</font><HR>Originally posted by Gints Plivna ([email protected]):
Hmm, quite interesting
I tried:::::
SQL> create table sms_msg (body VARCHAr2(100));
Table created.
SQL> CREATE OR REPLACE TRIGGER SMS_MSG_TR_B_U
2 BEFORE UPDATE ON sms_msg
3 FOR EACH ROW
4 BEGIN
5 IF :OLD.BODY != :NEW.BODY THEN
6 RAISE_APPLICATION_ERROR(-20001,'Invalid update');
7 END IF;
8 END SMS_MSG_TR_B_U;
9 /
Trigger created.
SQL> show err
No errors.
SQL> insert into sms_msg values ('qaqa');
1 row created.
SQL> update sms_msg set BODY=body;
1 row updated.
SQL> update sms_msg set BODY='qaqa1';
update sms_msg set BODY='qaqa1'
ERROR at line 1:
ORA-20001: Invalid update
ORA-06512: at "GINTS2.SMS_MSG_TR_B_U", line 3
ORA-04088: error during execution of trigger 'GINTS2.SMS_MSG_TR_B_U'
So You can see no problem!
Maybe body is of some exotic data type like long or clob, blob?
Is valid to use "!=" for these data types?
P.S. I tried this example on 8.0.3 and 8.1.6<HR></BLOCKQUOTE>
null
Maybe you are looking for
-
Mailbox Export from Windows 7 Machine Not Working
Good Morning All We are running Exchange 2007 SP3 on a Windows 2003 R2 server. From my Windows XP machine I am able to use the export-mailbox command without issue. From my Windows 7 machine I am unable to run this command at all and receive this err
-
Hi everyone, I'm totally new here and I've been trying to teach myself Premiere for a while, but have come across a snag that I can't seem to find the answer to. I'm creating a tutorial for work and I have video screen captures that are 1440X868 AVI
-
I know how to customize it, but it's just that when i open the window to drag the items to my toolbar nothing happens. it wont let me drag anything i can delete things just by clicking on it. so is it locker or something? do i have to reset safari?
-
Premiere crashes when trying to export with Media Encoder via Dynamic-Link
I work with clips from a networkdrive and I think the problems relates to this fact. My User-Account is an Admin-Account. I don't have any other Accounts. I also set Premiere, Adobe Media Encoder and every dynaimclinkmanager and -mediasever I could f
-
Hello, I recently changed to cable internet through a Linksys router (802.11a/b/g/n, I think. Was using DSL before). Initially my internet speed got noticeably faster, but now it seems to have slowed down dramatically. For reference, I have gone to w