Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

First ever Initial load - help!

So I'm one of very few using qlikview in a "grassroots" manner at my institution. I also have posted before that I have always been a poweruser in reporting tools, but never got into programming or scripting. I've been learning SQL, to help facilitate my transition into qlikview developer.  (I feel like I'm learning Latin- so many applications to other languages!).

My question is:

I am out here, lone wolf, with a connection to table views in our Oracle data warehouse at a large university.

I've edited my script to pull the fields I need; my question is how do i limit the data on the FIRST load? I know that I can use qvd and various methods for incremental loads...but how do I limit this FIRST EVER load so that i only get the data for the 7 divisions I am responsible for?  The database is enormous, and Qlikview hangs up at about record 765,000 of the first table...and there are probably a bazillion to go.

We have numbers to represent the divisions - is there a way to stick a WHERE clause in my load statement so that it makes a first pass for me?

Let me know if this makes no sense.

1 Solution

Accepted Solutions
JonnyPoole
Employee
Employee

You can edit the SQL by hand and manually add a WHERE clause.  See below.  When you do it, reference the field name as it has been written in the script. 

ODBC CONNECT TO [Salesman;DBQ=C:\Qlik Resources\Demos\10 Minute Demo\Data\Salesman.mdb];

LOAD `Salesman ID`,

    Salesman,

    `Distributor ID`;

SQL SELECT `Salesman ID`,

    Salesman,

    `Distributor ID`

FROM SALESMAN

where `Salesman ID`=1;

View solution in original post

11 Replies
sujeetsingh
Master III
Master III

You can use a where clause in the load what is the problem then.

Anonymous
Not applicable
Author

Hi,

Upload sample data,so can help

JonnyPoole
Employee
Employee

You can edit the SQL by hand and manually add a WHERE clause.  See below.  When you do it, reference the field name as it has been written in the script. 

ODBC CONNECT TO [Salesman;DBQ=C:\Qlik Resources\Demos\10 Minute Demo\Data\Salesman.mdb];

LOAD `Salesman ID`,

    Salesman,

    `Distributor ID`;

SQL SELECT `Salesman ID`,

    Salesman,

    `Distributor ID`

FROM SALESMAN

where `Salesman ID`=1;

Not applicable
Author

Thanks so much Jonathan! This is just what I needed

JonnyPoole
Employee
Employee

I'm glad. Made my afternoon    

If you think you are good can you mark the post closed / helpful etc..

thanks again.. let us know if anything else comes up.

Not applicable
Author

So now that you've created a monster....I admit,I went nuts did a where clause in the load with TWO "ands' in it...

would that be why it's been 1 hour and 3 minutes and only 40,265 records have loaded??

JonnyPoole
Employee
Employee

ouch.  it sounds like the fields you are filtering on are not indexed in the database. is there anybody you can reach out to who knows the database ??? maybe you can find other fields that are indexed and put filters on those instead ?

Not applicable
Author

When you say indexed in the database...what exactly do you mean?

Not applicable
Author

And yes..I am that new to this that I have to ask about indexing....