Query transform with where condition not equal to
All,
I have a two tables in a Data services job where I am using a Query transform to load the data from these two tables into another table. In the where tab in query transform i had a conditon saying table1.column1 <> table2.column1 and table1.column2 <> table2.column2.
I need to see the record count of table1-table2 in my final thrid table, but I see more record count and also the not equal condition is failing. Its working for an equal condition but the not equal condition is failing.
The equivalent SQL query for the above transform has to be:
select * from table1 inner join table2 on table1.column1 = table2.column1 where table1.column1 <> table2.column1 and
table1.column2 <> table2.column2.
Any thoughs on how to fix my query transform.
Thanks
Hi
As per your below statement
"I need to see the record count of table1-table2 in my final thrid table, but I see more record count and also the not equal condition is failing. Its working for an equal condition but the not equal condition is failing."
If you trying to get the records from table-1 which are not in table-2 (as you trying table1-table2)
you can try logic in query transformation where clause
not table1.field1 in (table2.field1)
and
not table1.field2 in (table2.field2)
it gives you count from table1 only
Regards
Ahalya Gopinath
Similar Messages
-
Export/Import with where condition
DearAll,
I am facing a problem in the delete of a huge table that take 3 hours
DELETE FROM HST HST
WHERE JV_TYPE <> 999
and ( HST.VALUE_DATE <= TO_DATE ('31/12/2010','DD/MM/YYYY')
AND HST.TRANS_DATE <= TO_DATE ('31/12/2010','DD/MM/YYYY'))
what i am trying to do is to export the HST table and import it into another table
but what i need to do is to have a dump with where condition including only the needed records in the table not deleted in the DML above as well as the indexes, triggers.
ThanksIf I try the following:
CONN / AS SYSDBA
CREATE OR REPLACE DIRECTORY dpump_dir1 AS '/folder/';
GRANT READ, WRITE ON DIRECTORY dpump_dir1 TO bokprod;
expdp bokprod/bokprod@uat TABLES=HST PARFILE=hst_query.par
In the parfile:
QUERY=hst:"WHERE JV_TYPE <>999 and ( HST.VALUE_DATE > TO_DATE ('31/12/2010','DD/MM/YYYY') AND HST.TRANS_DATE > TO_DATE ('31/12/2010','DD/MM/YYYY'))"
DUMPFILE=exp.dmp
DIRECTORY=dpump_dir1
LOGFILE=exp.log
impdp bokprod/bokprod@uat DIRECTORY=dpump_dir1 DUMPFILE=exp.dmp
TABLES=bokprod.hst REMAP_TABLE=bokprod.hst:hst_imported
My question is:
1- the parameter file, if i put it in the dpump_dir1 directory, is it read by the expdp command?
2- the hst_imported table created by the remap_table command , is it created with the indexes and triggers already existant on hst table?
Appreciate yoyr help Dears -
Hi Everyone,
I am getting rows into internal table lt_mseg even if this where condition like this werks NE gs_t001w-werks in below code
is true. It looks like it's not excluding if not equal to gs_t001w-werks. Is anything wrong in below code? please help me...
SELECT * INTO TABLE gt_t005 FROM t005 WHERE xegld = 'X'.
SELECT * FROM t001w INTO TABLE gt_t001w FOR ALL ENTRIES IN gt_t005
WHERE ( land1 = gt_t005-land1 OR land1 = 'NO' ) AND vkorg NE 'LDE'.
SELECT * FROM mkpf INTO TABLE gt_mkpf
WHERE budat IN p_oextdt AND vgart = 'WL'.
LOOP AT gt_mkpf INTO gs_mkpf.
CHECK gt_t001w[] IS NOT INITIAL.
SELECT * FROM mseg APPENDING TABLE lt_mseg
FOR ALL ENTRIES IN gt_t001w
WHERE mblnr = gs_mkpf-mblnr
AND mjahr = gs_mkpf-mjahr
AND bwart NE '641'
AND xauto = ' '
AND werks NE gs_t001w-werks
AND kunnr = gt_t001w-kunnr.
ENDLOOP.Hi Sany,
Thanks for your reply. I f I remove this LOOP AT gt_mkpf INTO gs_mkpf and use for all entries how can I exlude plants that I got from t001w?
I used range here in below code now I am getting run time error in this loop, it says value table for IN itab operator has unexpected format....
DATA:
gt_t005 TYPE TABLE OF t005,
gs_t005 LIKE LINE OF gt_t005,
gt_t001w TYPE TABLE OF t001w,
gt_rng_plant type range of t001w,
gs_rng like line of gt_rng_plant,
gs_t001w LIKE LINE OF gt_t001w,
gt_mkpf TYPE TABLE OF mkpf,
gs_mkpf LIKE LINE OF gt_mkpf .
SELECT * INTO TABLE gt_t005 FROM t005 WHERE xegld = 'X'.
SELECT * FROM t001w INTO TABLE gt_t001w FOR ALL ENTRIES IN gt_t005
WHERE ( land1 = gt_t005-land1 OR land1 = 'NO' ) AND vkorg NE 'LDE'.
SELECT * FROM mkpf INTO TABLE gt_mkpf
WHERE budat IN p_oextdt AND vgart = 'WL'.
gs_rng-sign = 'I'.
gs_rng-option = 'EQ'.
LOOP AT gt_t001w INTO gs_t001w.
gs_rng-low = gs_t001w-werks.
gs_rng-high = gs_t001w-werks.
APPEND gs_rng TO gt_rng_plant.
ENDLOOP.
LOOP AT gt_mkpf INTO gs_mkpf.
SELECT * FROM mseg APPENDING TABLE lt_mseg
FOR ALL ENTRIES IN gt_t001w
WHERE mblnr = gt_mkpf-mblnr
AND mjahr = gt_mkpf-mjahr
AND bwart NE '641'
AND xauto = ' '
AND werks not in gt_rng_plant
AND kunnr = gt_t001w-kunnr.
ENDLOOP. -
Outbound merge not working with where conditions in 10g
Hi,
These are my database details both remote and local database
SQL> select * from v$version;
BANNER
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bi
PL/SQL Release 10.2.0.4.0 - Production
CORE 10.2.0.4.0 Production
TNS for HPUX: Version 10.2.0.4.0 - Production
NLSRTL Version 10.2.0.4.0 - ProductionI am doing a merge into a remote database from a local table using below query...
MERGE into sap_mmd_po_all@cosmic_dev.somedomainname trg using (select * from sap_mmd_cmas_po where upload_flag in ('I','U')) src
on (trg.PO_NO=src.PO_NO and trg.LINE_DISTRIB_SEQ=src.LINE_DISTRIB_SEQ)
WHEN MATCHED THEN
update set
trg.PO_STATUS_FLG=src.PO_STATUS_FLG,
trg.SHIP_TO_FACILITY_CD=src.SHIP_TO_FACILITY_CD,
trg.DELV_TO_PHONE_NO=src.DELV_TO_PHONE_NO,
trg.DELV_TO_NM=src.DELV_TO_NM,
trg.DELV_TO_ADDRESS_1=src.DELV_TO_ADDRESS_1,
trg.PO_ITEM_NO=src.PO_ITEM_NO,
trg.ITEM_DESCRP=src.ITEM_DESCRP,
trg.PARTY_NM=src.PARTY_NM,
trg.VENDOR_ITEM_ID=src.VENDOR_ITEM_ID,
trg.PO_LN_CRTE_DT=src.PO_LN_CRTE_DT,
trg.BILL_UOM_CD=src.BILL_UOM_CD,
trg.COMMODITY_CD=src.COMMODITY_CD,
trg.COMMODITY_NM=src.COMMODITY_NM,
trg.BSNSS_UNIT_NO=src.BSNSS_UNIT_NO,
trg.PO_LN_ORD_QTY=src.PO_LN_ORD_QTY,
trg.DISTRIB_AMT=src.DISTRIB_AMT,
trg.PO_LN_DEL_IND=src.PO_LN_DEL_IND,
trg.PO_DEL_IND=src.PO_DEL_IND,
trg.PO_TYPE=src.PO_TYPE,
trg.DOC_DATE=src.DOC_DATE,
trg.CRTE_DT_TM=src.CRTE_DT_TM,
trg.UPD_DT_TM=systimestamp,
trg.SOURCE_SYSTEM=src.SOURCE_SYSTEM,
trg.PO_LN_LST_CHNGE_DT=src.PO_LN_LST_CHNGE_DT,
trg.TXJCD=src.TXJCD,
trg.PLANT=src.PLANT
where (src.upload_flag='U')--if i remove this then it is working
WHEN NOT MATCHED THEN
insert( trg.PO_NO,
trg.LINE_DISTRIB_SEQ,
trg.PO_STATUS_FLG,
trg.SHIP_TO_FACILITY_CD,
trg.DELV_TO_PHONE_NO,
trg.DELV_TO_NM,
trg.DELV_TO_ADDRESS_1,
trg.PO_ITEM_NO,
trg.ITEM_DESCRP,
trg.PARTY_NM,
trg.VENDOR_ITEM_ID,
trg.PO_LN_CRTE_DT,
trg.BILL_UOM_CD,
trg.COMMODITY_CD,
trg.COMMODITY_NM,
trg.BSNSS_UNIT_NO,
trg.PO_LN_ORD_QTY,
trg.DISTRIB_AMT,
trg.PO_LN_DEL_IND,
trg.PO_DEL_IND,
trg.PO_TYPE,
trg.DOC_DATE,
trg.CRTE_DT_TM,
trg.UPD_DT_TM,
trg.SOURCE_SYSTEM,
trg.PO_LN_LST_CHNGE_DT,
trg.TXJCD,
trg.PLANT)
values( src.PO_NO,
src.LINE_DISTRIB_SEQ,
src.PO_STATUS_FLG,
src.SHIP_TO_FACILITY_CD,
src.DELV_TO_PHONE_NO,
src.DELV_TO_NM,
src.DELV_TO_ADDRESS_1,
src.PO_ITEM_NO,
src.ITEM_DESCRP,
src.PARTY_NM,
src.VENDOR_ITEM_ID,
src.PO_LN_CRTE_DT,
src.BILL_UOM_CD,
src.COMMODITY_CD,
src.COMMODITY_NM,
src.BSNSS_UNIT_NO,
src.PO_LN_ORD_QTY,
src.DISTRIB_AMT,
src.PO_LN_DEL_IND,
src.PO_DEL_IND,
src.PO_TYPE,
src.DOC_DATE,
systimestamp,
src.UPD_DT_TM,
src.SOURCE_SYSTEM,
src.PO_LN_LST_CHNGE_DT,
src.TXJCD,
src.PLANT)
where src.upload_flag='I'--if i remove this then it is working
;And it is throwing an error like...
SQL Error: ORA-00904: "A3"."UPLOAD_FLAG": invalid identifierBut when I replace the remote table name with local table name then query is functioning fine...
table structure in local database..
CREATE TABLE SAP_MMD_CMAS_PO
( "PO_NO" VARCHAR2(10 BYTE) NOT NULL ENABLE,
"LINE_DISTRIB_SEQ" NUMBER NOT NULL ENABLE,
"PO_STATUS_FLG" VARCHAR2(40 BYTE),
"SHIP_TO_FACILITY_CD" VARCHAR2(100 BYTE),
"DELV_TO_PHONE_NO" VARCHAR2(50 BYTE),
"DELV_TO_NM" VARCHAR2(100 BYTE),
"DELV_TO_ADDRESS_1" VARCHAR2(1000 BYTE),
"PO_ITEM_NO" VARCHAR2(100 BYTE),
"ITEM_DESCRP" VARCHAR2(200 BYTE),
"PARTY_NM" VARCHAR2(1000 BYTE),
"VENDOR_ITEM_ID" VARCHAR2(100 BYTE),
"PO_LN_CRTE_DT" TIMESTAMP (6),
"BILL_UOM_CD" VARCHAR2(50 BYTE),
"COMMODITY_CD" VARCHAR2(50 BYTE),
"COMMODITY_NM" VARCHAR2(50 BYTE),
"BSNSS_UNIT_NO" VARCHAR2(50 BYTE),
"PO_LN_ORD_QTY" NUMBER,
"DISTRIB_AMT" NUMBER,
"PO_LN_DEL_IND" VARCHAR2(10 BYTE),
"PO_DEL_IND" VARCHAR2(10 BYTE),
"PO_TYPE" VARCHAR2(10 BYTE),
"DOC_DATE" TIMESTAMP (6),
"CRTE_DT_TM" TIMESTAMP (6),
"UPD_DT_TM" TIMESTAMP (6),
"SOURCE_SYSTEM" VARCHAR2(100 BYTE),
"PO_LN_LST_CHNGE_DT" TIMESTAMP (6),
"TXJCD" VARCHAR2(50 BYTE),
"PLANT" VARCHAR2(10 BYTE),
"UPLOAD_FLAG" VARCHAR2(1 BYTE),
PRIMARY KEY ("PO_NO", "LINE_DISTRIB_SEQ")
--table structure in remote database table
CREATE TABLE SAP_MMD_PO_ALL
( "PO_NO" VARCHAR2(10 BYTE) NOT NULL ENABLE,
"LINE_DISTRIB_SEQ" NUMBER NOT NULL ENABLE,
"PO_STATUS_FLG" VARCHAR2(40 BYTE),
"SHIP_TO_FACILITY_CD" VARCHAR2(100 BYTE),
"DELV_TO_PHONE_NO" VARCHAR2(50 BYTE),
"DELV_TO_NM" VARCHAR2(100 BYTE),
"DELV_TO_ADDRESS_1" VARCHAR2(1000 BYTE),
"PO_ITEM_NO" VARCHAR2(100 BYTE),
"ITEM_DESCRP" VARCHAR2(200 BYTE),
"PARTY_NM" VARCHAR2(1000 BYTE),
"VENDOR_ITEM_ID" VARCHAR2(100 BYTE),
"PO_LN_CRTE_DT" TIMESTAMP (6),
"BILL_UOM_CD" VARCHAR2(50 BYTE),
"COMMODITY_CD" VARCHAR2(50 BYTE),
"COMMODITY_NM" VARCHAR2(50 BYTE),
"BSNSS_UNIT_NO" VARCHAR2(50 BYTE),
"PO_LN_ORD_QTY" NUMBER,
"DISTRIB_AMT" NUMBER,
"PO_LN_DEL_IND" VARCHAR2(10 BYTE),
"PO_DEL_IND" VARCHAR2(10 BYTE),
"PO_TYPE" VARCHAR2(10 BYTE),
"DOC_DATE" TIMESTAMP (6),
"CRTE_DT_TM" TIMESTAMP (6),
"UPD_DT_TM" TIMESTAMP (6),
"SOURCE_SYSTEM" VARCHAR2(100 BYTE),
"PO_LN_LST_CHNGE_DT" TIMESTAMP (6),
"TXJCD" VARCHAR2(50 BYTE),
"PLANT" VARCHAR2(10 BYTE),
"DELETE_FLAG" VARCHAR2(1 BYTE) DEFAULT 'N',
PRIMARY KEY ("PO_NO", "LINE_DISTRIB_SEQ")
)It seems to me like a bug, but not quite sure...
your suggestions are appreciated.
Thanks,
Ravi Kumar
Edited by: ravikumar.sv on Dec 14, 2009 1:31 PM
Commented the where conditions in merge queryHi,
Yes, i hit the same error....
SQL> ed
Wrote file afiedt.buf
1 merge into hr.test1@test_dblink using test2 on (test1.id = test2.id)
2 when matched then update set test1.col1=test2.col2 where test2.id=2
3* when not matched then insert (id, col1) values(test2.id,test2.col2)
SQL> /
merge into hr.test1@test_dblink using test2 on (test1.id = test2.id)
ERROR at line 1:
ORA-00904: "A3"."ID": invalid identifier
ORA-02063: preceding line from TEST_DBLINKBUT here is a work around...to add the where condition while joining(ON) itself.
SQL> ed
Wrote file afiedt.buf
1 merge into hr.test1@test_dblink using test2 on (test1.id = test2.id and tes
t2.id=2)
2 when matched then update set test1.col1=test2.col2
3* when not matched then insert (id, col1) values(test2.id,test2.col2)
SQL> /
2 rows merged.
SQL>For you the condition would be...
on (trg.PO_NO=src.PO_NO and trg.LINE_DISTRIB_SEQ=src.LINE_DISTRIB_SEQ AND src.upload_flag='U')cheers,
Edited by: Avinash Tripathi on Dec 14, 2009 2:53 PM -
Export data with where condition
Hello,
I am doing an export using exp utility in oracle.
exp fas/fas@fdbl file=aud log=aud.log parfile=exp
Contents of parfile - exp
compress=n
indexes=n
constraints=n
grants=n
triggers=n
statistics=none
consistent=y
query=\"where org_grp_i=33 \"
I am getting error when i include query = \"where org_grp_i=33 \". Without giving this condition the export is doing fine, its successful. how do i give this where condition in the parfile since i want to export lots of tables with this same condition. org_grp_i is common in all the tables.
Thanks1. create directory ----
sql> conn / as sysdba
sql>create directory "data" as 'c:\';
2. grant read, write privs. to exp or imp users.
sql>grant read , write on directory data to scott;
sql>grant read , write on directory data to tester;
3.conn imp or exp user
sql>conn scott/tiger
SQL> host expdp scott/tiger directory=data dumpfile=eg.dmp tables=avgsal
Export: Release 10.1.0.2.0 - Production on Wednesday, 25 October, 2006 19:14
Copyright (c) 2003, Oracle. All rights reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Produc
tion
With the Partitioning, OLAP and Data Mining options
Starting "SCOTT"."SYS_EXPORT_TABLE_01": scott/******** directory=data dumpfile=
eg.dmp tables=avgsal
Estimate in progress using BLOCKS method...
Processing object type TABLE_EXPORT/TABLE/TBL_TABLE_DATA/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 64 KB
Processing object type TABLE_EXPORT/TABLE/TABLE
Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
. . exported "SCOTT"."AVGSAL" 5.312 KB 5 rows
Master table "SCOTT"."SYS_EXPORT_TABLE_01" successfully loaded/unloaded
Dump file set for SCOTT.SYS_EXPORT_TABLE_01 is:
C:\EG.DMP
Job "SCOTT"."SYS_EXPORT_TABLE_01" successfully completed at 19:15
SQL> drop table avgsal purge;
Table dropped.
SQL> host impdp tester/tester directory=data dumpfile=eg.dmp
Import: Release 10.1.0.2.0 - Production on Wednesday, 25 October, 2006 19:16
Copyright (c) 2003, Oracle. All rights reserved.
Connected to: Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Produc
tion
With the Partitioning, OLAP and Data Mining options
Master table "TESTER"."SYS_IMPORT_FULL_01" successfully loaded/unloaded
Starting "TESTER"."SYS_IMPORT_FULL_01": tester/******** directory=data dumpfile
=eg.dmp
Processing object type TABLE_EXPORT/TABLE/TABLE
Processing object type TABLE_EXPORT/TABLE/TBL_TABLE_DATA/TABLE/TABLE_DATA
. . imported "SCOTT"."AVGSAL" 5.312 KB 5 rows
Processing object type TABLE_EXPORT/TABLE/STATISTICS/TABLE_STATISTICS
Job "TESTER"."SYS_IMPORT_FULL_01" successfully completed at 19:16
SQL>
note : cmd>impdp help=y
cmd> expdp help=y
see doc. for more info
http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14215/toc.htm
Message was edited by:
user52 -
Multiple selection in Query Panel. Operator Does not equal generates error.
Hi,
I'm using Jdeveloper 11.1.1.4 and creating Oracle Fusion Web Application with ADF Business Components.
I want to use multiple selection on LOV in ADF Query Panel with Table, but I get the following error
when I use operator "Does not equal":
Error: Unsupported model type.
SelectMany does not support a model of type class java.lang.Integer.
A simple example:
Schema: HR
Generate default Business Components for tables Departments and Employees.
Model:
Create List of Values for EmployeesView(DepartmentId)
List Data Source: DepartmentsView1
List Attribute: DepartmentId
Display Attributes: DepartmentName (UI Hints)
Create View Criteria EmployeesByDepartmentVC for EmployeesView
Criteria Item:
Attribute: DepartmentId
Operator: Equals
Operand: Literal
Select "Support Multiple Value Selection" (UI Hints)
ViewController:
Create blank JSF Page: showEmployees.jspx
Drag EmployeesByDepartmentVC from Data Controls to showEmployees.jspx
Create Query=>ADF Query Panel with Table
Run application.
Press Advanced button.
Select operator "Does not equal" and department names "Administration;Marketing"
Press Search
Error: Unsupported model type.
SelectMany does not support a model of type class java.lang.Integer.
Note: it works fine with operator "Equals"
Best,
Kees.Hi,
I was reading:
http://www.oracle.com/technetwork/developer-tools/jdev/jdev-11gr2-nf-404365.html#bugs_fixed_in_11.1.2.2.0
Bugs Fixed in 11.1.2.2.0
Bug.No. 13508184
unsupported model type error thrown for multi select view criteria
I have tested the use case described in this thread with JDeveloper 11.1.2.2.0 but I still get the same error.
when I use operator "Does not equal":
Error: Unsupported model type.
SelectMany does not support a model of type class java.lang.Integer.
Is there anybody who can tell me more about this bug fix?
Thanks,
Kees. -
Dynamic LOV with where conditions
Hi all! I have a question regarding Dynamic LOVs. I have a List of values that can be used from three pages, the query is something like this:
SELECT a.CODE CODE_DISPLAY,
a.CODE CODE_RETURN
FROM OREF_COUNTRIES a,
OREF_REGIONS b
WHERE a.REG_ID = b.ID AND
b.CODE = :P336_LOV_REGION;
The thing is I don't want to hardcode the name of the item ":P336_LOV_REGION" because this is the name of 1 item of one page, and I'd like to use this LOV from another two pages, so the name of the item won't be ":P336_LOV_REGION". How can I create a reusable dynamic LOV with a where condition depending on one item of the page?
Thanks!!hi! anyone has any information about this?
Daniela. -
How to create list partition Where value not equal
Hi ,
How to crate partition where i want to store all data what is not equal to ,priview values,(A,B,C,D,E) ?
PARTITION PN001 VALUES (*is all values !=A,B,C,D,E*) TABLESPACE test_1Thanks !
ID>
In partition
<partition_name> values (default) ? will be stored data where value is null too ?
>
See the VLDB partitioning guide
http://docs.oracle.com/cd/E18283_01/server.112/e16541/part_admin001.htm#sthref247
>
Creating List-Partitioned Tables
The semantics for creating list partitions are very similar to those for creating range partitions. However, to create list partitions, you specify a PARTITION BY LIST clause in the CREATE TABLE statement, and the PARTITION clauses specify lists of literal values, which are the discrete values of the partitioning columns that qualify rows to be included in the partition. For list partitioning, the partitioning key can only be a single column name from the table.
Available only with list partitioning, you can use the keyword DEFAULT to describe the value list for a partition. This identifies a partition that accommodates rows that do not map into any of the other partitions.
>
Note the last two sentences above. The DEFAULT partition will contain data for values (including NULL) that do not map to other partitions. -
Table Rows with Multiple Conditions Not Showing Up in RH
Hi everyone,
I'm currently evaluating TCS2 (Framemaker 9 and RoboHelp 8 on Windows XP) and have come across the following issue:
One of our FrameMaker source files contains a table in which one of the rows has multiple conditions applied. When one of the conditions is shown in Framemaker, and the others are hidden, the row is displayed in Framemaker as expected. However, when the file is then imported or linked into Robohelp, the same table row vanishes, even though the Apply FrameMaker Conditional Text Build Expression check box is selected in the Framemaker Conversion Settings > Other Settings screen. This only appears to affect table rows - when paragraph text is tagged with the same conditions, it is imported correctly into RoboHelp.
For example, when Condition B is shown and Condition A is hidden in the Framemaker file, the content appears like this in Frame:
Unconditional
Unconditional
Condition A and Condition B applied
Condition A and Condition B applied
Condition B applied
Condition B applied
Paragraph text with Condition A and Condition B applied.
Paragraph text with Condition B applied.
When the same file is imported into RoboHelp, the row with both conditions applied is absent from the table:
Unconditional
Unconditional
Condition B applied
Condition B applied
Paragraph text with Condition A and Condition B applied.
Paragraph text with Condition B applied.
Installing patches 8.0.1 and 8.0.2 did not resolve the issue (and actually caused other, unrelated issues) and I see the same behavior regardless of whether I import or link the FrameMaker document.
Has anyone else seen this issue? Any help would be much appreciated.
Thanks
DaveBIt just seems that the items I select as align to top in the
property inspector should force the items to the top of their
cells, unless I'm missing something. -
Select-options with where condition
Hello ABAPers,
I want to create a select-options like s_operid for vbpa-kunnr but with a condition specified is VBPA-KUNNR where VBPA-PARVW = 'WE'.
Thanks in advance. Pls reply asap. Points will definitely be rewarded.
Rituhi,
use this
PARAMETERS : TAB_ID TYPE ZALOAD_PROD_COMB-TAB_ID OBLIGATORY.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR TAB_ID.
DATA : BEGIN OF INT_TAB_ID OCCURS 0,
TAB_ID TYPE ZALOAD_PROD_COMB-TAB_ID,
END OF INT_TAB_ID.
DATA : LOC_MAX TYPE ZALOAD_PROD_COMB-TAB_ID.
CLEAR INT_TAB_ID.
REFRESH INT_TAB_ID.
SELECT MAX( TAB_ID) INTO (LOC_MAX) FROM ZALOAD_PROD_COMB.
COUNT = LOC_MAX + 1.
DO 10 TIMES.
MOVE COUNT TO INT_TAB_ID-TAB_ID.
APPEND INT_TAB_ID.
COUNT = COUNT + 1.
ENDDO.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
RETFIELD = 'TAB_ID' u201C Internal table field name
DYNPPROG = 'PROG_NAME u201C Program name
DYNPNR = SY-DYNNR
DYNPROFIELD = 'TAB_ID' u201C Field where u need F4 help
VALUE_ORG = 'S'
WINDOW_TITLE = u2018Any descriptionu2019
TABLES
VALUE_TAB = INT_TAB_ID. u201C Internal table name
Mark the post answered once ur problem is solved .... -
Where data not equal to something
Guys how to retrieve record where emp_name is not equal to 'GEORGE_BUSH';
I mean
select emp_name from emp where emp_name != 'george';
ignores emp_name = null too.
what is the correct syntax.
thanks
msWhen you compare anything to NULL, the result is false. You need to explicitly account for NULL values, i.e.
SELECT emp_name
FROM emp
WHERE emp_name != 'george'
OR emp_name IS NULLJustin -
Query help for where condition
Hi ,
I have String value in table now I require to check that value is valid or not .
I have below Query .
SELECT *
FROM Table TCI
WHERE (ISDATE(SUBSTRING(SUBSTRING(Data,82,6),1,4)+'-'+SUBSTRING(SUBSTRING(Data,82,6),5,2)+'-'+'01')<>1 OR LEN(LTRIM(RTRIM(SUBSTRING(Data,82,6)))) < 0 OR SUBSTRING(Data,82,6)='000000')
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,88,6)))) < 0 OR SUBSTRING(Data,88,6)= '000000' OR ISDATE(SUBSTRING(SUBSTRING(Data,88,6),1,4)+'-'+SUBSTRING(SUBSTRING(Data,88,6),5,2)+'-'+'01')<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,173,6)))) < 0 OR ISDATE(SUBSTRING(SUBSTRING(Data,173,6),1,4)+'-'+SUBSTRING(SUBSTRING(Data,173,6),5,2)+'-'+'01')<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,195,6)))) < 0 OR ISDATE(SUBSTRING(SUBSTRING(Data,195,6),1,4)+'-'+SUBSTRING(SUBSTRING(Data,195,6),5,2)+'-'+'01') <>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,217,7))))<0 OR ISNUMERIC(LTRIM(RTRIM(SUBSTRING(Data,217,7)))) <> 1)
AND ISNUMERIC(REPLACE(SUBSTRING(Data,334,10),'-','0'))<>1
AND ISNUMERIC(SUBSTRING(Data,345,10))<>1
AND ISNUMERIC( SUBSTRING(Data,355,10))<>1
AND ISNUMERIC(SUBSTRING(Data,416,8))<>1
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,104,6))))<0 OR ISNUMERIC(SUBSTRING(Data,104,6))<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,145,7))))<0 OR ISNUMERIC(SUBSTRING(Data,145,7))<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,152,7))))<0 OR ISNUMERIC(SUBSTRING(Data,152,7))<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,159,7))))<0 OR ISNUMERIC(SUBSTRING(Data,159,7))<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,166,7))))<0 OR ISNUMERIC(SUBSTRING(Data,166,7))<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,179,3))))<0 OR ISNUMERIC(SUBSTRING(Data,179,3))<>1)
AND (LEN(LTRIM(RTRIM(SUBSTRING(Data,201,3))))<0 OR ISNUMERIC(SUBSTRING(Data,201,3))<>1)
AND (ISNUMERIC(REPLACE(SUBSTRING(Data,365,10),'-','0'))<>1 OR ISNUMERIC( REPLACE(SUBSTRING(Data,365,10),'-','0'))<>1)
AND (ISNUMERIC(REPLACE(SUBSTRING(Data,375,10),'-','0'))<>1 OR ISNUMERIC( REPLACE(SUBSTRING(Data,375,10),'-','0'))<>1)
AND (ISNUMERIC(REPLACE(SUBSTRING(Data,385,10),'-','0'))<>1 OR ISNUMERIC(REPLACE(SUBSTRING(Data,385,10),'-','0'))<>1)
AND (ISNUMERIC(REPLACE(SUBSTRING(Data,395,10),'-','0'))<>1 OR ISNUMERIC(REPLACE(SUBSTRING(Data,395,10),'-','0'))<>1)
AND (ISNUMERIC(REPLACE(SUBSTRING(Data,405,10),'-','0'))<>1 OR ISNUMERIC(REPLACE(SUBSTRING(Data,405,10),'-','0'))<>1)
I need only invalid record set from below Query ;
like; If it is not isdate and is_numeric type for particular row then it return only that row.
currently i'm facing issue like whole string is invalid in that case it gives row .
should I use case statement in where clause ?
Thanks
Please Mark This As Answer or vote for Helpful Post if this helps you to solve your question/problem. http://techequation.comI need only invalid record set from below Query ;
like; If it is not isdate and is_numeric type for particular row then it return only that row.
currently i'm facing issue like whole string is invalid in that case it gives row .
should I use case statement in where clause ?
Hi PrajapatiNeha,
Your requirement is confusing. Judging from the query, the column data
seems to be a string which consists of fixed length date or numberic format substrings, so you are verifying each substring is valid and need to select the invalid substrings?
If that is your requirement, why not just extract the substrings into a derived table and filter based on the derived table? The substrings in the derived table will give a more directly overview of your long data string.
If you have any question, feel free to let me know.
Eric Zhang
TechNet Community Support -
Filter Criteria with where condition in graph api query
Hi
Filter criteria in graph api is working fine through this api
https://graph.windows.net/adummydirectory.onmicrosoft.com/users?$filter=displayName eq 'Ashok'&api-version=1.5
Select criteria is also working fine through this api
https://graph.windows.net/ adummydirectory.onmicrosoft.com/users?api-version=1.5&deltaLink=&$select=displayName,accountEnabled
But when I am combining both query that means, I want that select criteria should also apply with filter clause like
https://graph.windows.net/adummydirectory.onmicrosoft.com/users?$filter=displayName
eq 'Ashok'&api-version=1.5&deltaLink=&$select=displayName,accountEnabled
But its generating error
"odata.error": {
"code": "Request_UnsupportedQuery",
"message": {
"lang": "en",
"value": "Unsupported expression node type 'Equal' for Where expression."
So please suggest how we can use select clause with filter criteria. our requirement is that we don’t need all attributes .we want selected attributes for filtered users.Greetings!
The differential query syntax does not allow for a filter other than $filter=isof(<directory entry type>). You are not able to use any other query string for this type of query. Please see the following MSDN link for details:
http://msdn.microsoft.com/en-us/library/azure/jj836245.aspx
I will need to do a bit more research to see if it is possible to request specific attributes for an object query and post back to this thread when I have a response.
Regards,
MaxV ( MSFT ) -
Loop at table with unspecified type but with where-condition
Hi,
Doing a loop over an internal table with unspecified type and in addition using a condtion may be done as follows: Thereby the
condition would be "... WHERE parentid EQ i_nodeid" if the type of <it_htab> would be static. However dynamic specification of a component through bracketed character-type data objects is not possible.
FIELD-SYMBOLS: <it_htab> TYPE STANDARD TABLE,
<wa_htab> TYPE ANY,
<parentid> TYPE rsparent.
ASSIGN me->ref_htab->* TO <it_htab>.
LOOP AT <it_htab> ASSIGNING <wa_htab>.
ASSIGN COMPONENT 'PARENTID' OF STRUCTURE <wa_htab> TO <parentid>.
CHECK <parentid> EQ i_nodeid.
ENDLOOP.
Since you have to loop over the whole table and to check within the loop whether the condition is fullfilled, this is rather bad for performance.
Questions: Are there any tricks to do this better?
Best Regards and Thank you,
Ingo>
Lalit Mohan Gupta wrote:
> you can put the condition in the where clause....
only if you have the upcoming 7.0 EhP2 (Kernel 7.02 or 7.20) the following dynamic where works:
DATA cond_syntax TYPE string.
cond_syntax = `parentid = i_nodeid`.
LOOP AT <it_htab> ASSIGNING <wa_htab>
WHERE (cond_syntax).
in older releases you would have to use program generation to achieve a dynamic where... .
Kind regards,
Hermann -
XPath query works with CLOB but not with object relational
hi all
i have the following queries,the XQuery work with all, but XPath queries work with XMLType CLOB and Binary XML, but they do not work with XMLType as Object relational,
select extract (object_value,'movies/directorfilms/films/film [studios/studio = "Gaumont"]')
from xorm;
select extract (object_value,'movies/directorfilms[director/dirname = "L.Cohen"]/films/film[position()=2]/t')
from xorm;
they shows this message
ORA-00932: inconsistent datatypes: expectd SYSTEM.name683_COLL got CHAR
thanksHi Marco
fisrt here is my RO
BEGIN
DBMS_XMLSCHEMA.registerSchema(
SCHEMAURL=>'http://......../ORMovies.xsd',
SCHEMADOC=>bfilename('DB','Movies.xsd'),
LOCAL =>false,
GENTYPES=>true,
GENTABLES=>FALSE,
CSID=>nls_charset_id('AL32UTF8'));
END;
create table XORM of xmltype
xmltype store as object relational
XMLSCHEMA "http://......../ORMovies.xsd"
ELEMENT "movies";
INSERT INTO XORM
VALUES(XMLType(BFILENAME('DB','ORMovies.xml'),nls_charset_id('AL32UTF8')));
here the XQuery format that work fine with the OR
A/D
select XMLQuery ('for $a in movies/directorfilms/films/film
where $a/studios/studio = "Gaumont"
return $a'
passing object_value
returning CONTENT)"TitleX"
from xorm;
child element query
select XMLQuery ('for $a in movies/directorfilms/director[dirname = "Feyder"]
let $b:=$a/../films/film[position()=2]
return $b/t'
passing object_value
returning CONTENT)"TitleX"
from xorm;
here is the XPath format which doesn't work
select extract (object_value,'movies/directorfilms/films/film [studios/studio = "Gaumont"]')
from xorm;
select extract (object_value,'movies/directorfilms[director/dirname = "Feyder"]/films/film[position()=2]/t')
from xorm;
by the way all queries work fine with the CLOB or Binary XML
many thanx Marco
Maybe you are looking for
-
Challenge passing parameters to discoverer report
Hello everyone, I am following the instructions on this website - http://learndiscoverer.blogspot.com/2008/11/metalink-note-304192.html Basically, we want to use parameters for discoverer reports, especially date parameters because of some performanc
-
Hi I would like to get help with my iTunes account
Im having problems with my iTunes account and also. With my payment info
-
Method called three times on page loading
I have a page with panelTabbed and several showDetailItems. On the first showDetailItem I have ADF Query component with the results table. I want the second showDetailItem to be enabled or disabled depending on whether there is a selected row in the
-
Hello Guru: how to set up f.27 to send mail to customer according to e-mail in customer master please. thx in advance.
-
Suddenly can't click and drag within my playlists
I can drag songs or podcasts to my playlist, but cannot organize them once they are in there. Also, previously I could drag them in a particular order, and achieve the desired result but that is no longer the case. Thanks for your consideration.