Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Not applicable

problem using load with where clause

hi guys!!

i have two fields in table party_master namely party_type & party_name. i have to choose those party_name which have party_type=2. for this i m using where clause with load statement.

but it shows some those party names which even doesn't exists in the table. some of the names includes * sign at their begining also.

any suggestion would be appreciated..

5 Replies
agsearle
Contributor

problem using load with where clause

Can you show us the script you have so far?

Not applicable

problem using load with where clause

Do you have another field in another table that is named the same? Then it would be data from that table that you see.

Not applicable

problem using load with where clause

thanks for reply,

no, actually each fields are made unique with prefixes like party party_party_name, sales_party_name etc. in different tables.

Not applicable

problem using load with where clause

here is the script :-

ODBC CONNECT TO [odbc oracle2];

LOAD

"PARTY_LOCN_CODE",

"PARTY_PARTY_TYPE",

"PARTY_PARTY_CODE",

"PARTY_PARTY_CTGRY",

"PARTY_PARTY_CLASS",

"PARTY_PARTY_STS",

"PARTY_PARTY_NAME",

"PARTY_DIR_INDIR"

where

"PARTY_PARTY_TYPE"=02

;

SQL

SELECT

*

FROM

"NEWTON_BI1"."COR_PARTY_M";



blaise
Contributor III

problem using load with where clause

I think the problem is within the where "PARTY_PARTY_TYPE"=02 statement.

It should be "PARTY_PARTY_TYPE"=2 if the field is in number format, or "PARTY_PARTY_TYPE='02' if the field is a text (like varchar) field.

Try running the query from another query tool than Qv, just to be sure that Qv is messing something up. For a oracle db i would recommend SQL Developer (can be downloaded for free from oracles homepage). It's a wonderfull tool when working against an Oracle db.

Finally, i would but the where clause inside the select statement instead, but thats just me.