Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Is there any way to get list of Tables and fields that is available in a Qlikview document through vb macro?
Thanks,
Rakul.
ActiveDocument.GetFieldDescriptions will return an IArrayOfFieldDescriptions array. Each IFieldDescription has a SrcTables property that will tell you what table(s) the Field appears in.
For an example, download Document Analyzer and look at the extractFields SUB in the module.
QV Document Analyzer http://qlikviewcookbook.com/recipes/download-info/document-analyzer/
-Rob
I'm not sure why you want to use a macro for this.
The $Table system field will give you a list of all the tables.
The $Field system field will give you a list of all the fields.
I need those information to get the list of fields used a particular table and then see if there is any new field that was added or not and if that field is not present in a straight table then add that new field to straight table.
Thanks,
Rakul.
Hi Rakul,
So when you say "... to get list of Tables and fields ..." you're not talking about tables and fields in the data model, you're meaning table objects in the interface and dimensions used in them?
cheers
Andrew
Andrew,
I meant the tables and fields in Data Model i,e created by Binary Load or script.
Thanks,
Rakul.
Hi Rakul,
m w's advice was correct.
Try a simple tablebox with fields $Table and $Field
Regards
Andrew
ActiveDocument.GetFieldDescriptions will return an IArrayOfFieldDescriptions array. Each IFieldDescription has a SrcTables property that will tell you what table(s) the Field appears in.
For an example, download Document Analyzer and look at the extractFields SUB in the module.
QV Document Analyzer http://qlikviewcookbook.com/recipes/download-info/document-analyzer/
-Rob
Thanks Rob,
Document analyzer always gives sample vb code for all scenarios.
Thanks,
Rakul.