Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Good morning -
I am extremely new to QV and have what is probably a basic question.
My company's BI group creates a refreshed .qvw file everynight and posts it to a shared location.
I then open QV on my local machine and run a binary script to load that .qvw file Binary [\\path\filename.qvw];
Is there a way to modify the binary script so i can limit the fields that are loaded? I really only need to use about half of the available records. Because i am using my local machine the reduced size would be beneficial.
Thank you.
try put write
where condition under binary statment like
where sales>=10000;
Hi.
I believe that it isn't possible to do a "partial" binary load.
One thing that you can do is after the binary load, use "Drop Table" or "Drop Field" to eliminate the data that you don't need.
Hope it helps.
Regards,
Gabriel
Hi,
after the binary load you can manipulate all the present tables in your load script so indeed drop fields, tables etc..
hth
F.
Thank you for the prompt response. In this case, i need to keep the tables and fields intact; however, i need to remove about 65% of the records. Is there an equivalent "DROP WHERE" clause? I'm hoping the solution can be part of the script i run each morning.
Binary load is an "all or nothing" feature. All your data will be loaded.
You can do an aditional scripting to get rid of data you don´t want
Binary [\\path\filename.qvw];
noconcatenate load * resident T1 where Month='Jan' // just an example
drop table T1
You can not only drop tables and fields, but reduce data as well after the binary load. For example:
tmp:
INNER KEEP (TableName) LOAD * // or just one key field instead of *
RESIDENT TableName
WHERE <any conditions you want>;
DROP TABLE tmp;
Subscribing to what Clever Anjos says, you could also use the FIRST prefix when doing further scripting.
Like this:
FIRST 10000 LOAD * RESIDENT MyTable;
Wonderful. I was unaware of the Resident option. So if the .qvw loaded is called "MAIN" and i only want the january records it would look like:
tmp:
INNER KEEP (MAIN) LOAD *
RESIDENT MAIN
WHERE date="Jan"
DROP TABLE tmp
And from there i would continue to work within the "MAIN" table, correct?
Yes, it´s correct