20 Replies Latest reply: May 15, 2014 10:09 AM by Olly Bond RSS

    After upgrade to 12 Automation object is not working for PDF

    sparky2708 _

      We are trying to upgrade to Monarch 12 but for some reason the automation object stopped working for us when exporting PDF files to table using either .ExportTable or .JetExportTable. Any ideas how to get it to work? Here's the code we wrote quickly to test Monarch 12:

       

      Dim MonarchObj As New Datawatch.Desktop.Automation.MonarchAutomationObject

      With MonarchObj

              .SetReportFile("C:\test\Monarch_8_Programmers_Guide.pdf", True)

              .SetModelFile("C:\test\test.xmod")

              .ExportTable("c:\temp\export.txt")

      End With

       

      And we get the following in Visual Studio Output window (see below). The file "c:\temp\export.txt" contains only the header and no rows and output says that 0 rows were exported. Works fine in Monarch Desktop application (exports 1 row to the file) and in previous versions of Monarch.

       

      (1) Any ideas on what we could be doing wrong??

      (2) Any ideas why it says "partial build" (highlighted below)? When run in Monarch Desktop app it says: "Reader type: completed full build"...

       

      ===================== Datawatch.Engine 12.0.0.52 =====================

      TraceLevel: Minimum

      Codepage: 1252

      Culture: en-US

      Windows Version: 6.1.7601.65536 Service Pack 1

      ExecutionFormat: 32-bit

      PERFORMANCE: 00:00:00.0241124

      PERFORMANCE: 00:00:00.0107577

      PERFORMANCE: 00:00:00.1652207

      PERFORMANCE: 00:00:00.0128026

      Authorizer.IsFeatureEnabled Tableless_Export

      An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)

      PERFORMANCE: 00:00:00.1539475

      PERFORMANCE: 00:00:00.0044717

      PERFORMANCE: 00:00:00.0494697

      PERFORMANCE: 00:00:00.0583270

      PERFORMANCE: 00:00:00.3950729

      Generating partial build sequential table reader.

      Executing BuildTask CreateDatabase

      Executing BuildTask DownloadRemoteFile

      Executing BuildTask PrepareInputFile

      Created schema DBO_abcaae68_8fe8_407a_a0a7_9db65acf8e04 in catalog DWCH_8f1943cf_1866_4e85_9a10_a76e9f53d215

      Executing BuildTask CheckPointDatabaseReady

      Executing BuildTask LoadPerTemplateTable

      Executing BuildTask PrepareTemplateDataView

      Executing BuildTask CheckPointMainInputTableReady

      Executing BuildTask CreateReader

      Executing BuildTask PerformExport

      Export1 - Completed

      0 records written to c:\temp\export.txt

      Export time: 00:00:00.0

      Reader type: partial build[/B]

      PERFORMANCE: 00:00:00.0016664

      PERFORMANCE: 00:00:00.0018169

      PERFORMANCE: 00:00:00.0013850

      PERFORMANCE: 00:00:00.0005292

        • After upgrade to 12 Automation object is not working for PDF
          Olly Bond

          Hello Sparky, and welcome,

           

          Authorizer.IsFeatureEnabled Tableless_Export

           

          looks suspect to me - that's really only there for handling massive CSV files in Automator/DataPump.

           

          If you have a model with more than just a Detail template, then AFAIK TableLess Export doesn't make sense.

           

          Can you turn that feature off and try the process again?

           

          Does it work if you define a project file and set up a process in Automator, or are using the desktop version with the automation enabled?

           

          Best wishes,

           

          Olly

            • After upgrade to 12 Automation object is not working for PDF
              sparky2708 _

              Olly,

                 thank you for the quick reply. I am trying the Desktop version for now with the Automation enabled. How do I disable the "Authorizer.IsFeatureEnabled Tableless_Export"? I am really just running the 6 lines of code I mentioned - not really doing anything more than that. Did I enable it somehow? How do I disable it?

                • After upgrade to 12 Automation object is not working for PDF
                  sparky2708 _

                  Olly,

                      tried to run as 64bit... The problem you mentioned went away and it seems now it says: "Reader Type: full build". Still, when I do the export in Monarch I get: "Reader type:[B] completed /Bfull build". Why is mine not printing "completed" ? (eh, but it still says 0 records written):

                   

                  ===================== Datawatch.Engine 12.0.1.1 ======================

                  TraceLevel: Minimum

                  Codepage: 1252

                  Culture: en-US

                  Windows Version: 6.1.7601.65536 Service Pack 1

                  ExecutionFormat: 64-bit

                  PERFORMANCE: 00:00:00.0550624

                  PERFORMANCE: 00:00:00.0260436

                  PERFORMANCE: 00:00:00.0015112

                  Authorizer.IsFeatureEnabled Tableless_Export

                  IsFeatureEnabled Result: 0

                  Authorizer.IsFeatureEnabled PartialBuild_Export

                  IsFeatureEnabled Result: 0

                  PERFORMANCE: 00:00:00.2448134

                  PERFORMANCE: 00:00:00.0190075

                  PERFORMANCE: 00:00:00.0641859

                  PERFORMANCE: 00:00:00.0919383

                  PERFORMANCE: 00:00:00.8925256

                  Generating full build sequential table reader.

                  Executing BuildTask DownloadRemoteFile

                  Executing BuildTask PrepareInputFile

                  Executing BuildTask CreateDatabase

                  Executing BuildTask CheckPointUserEditTableReady

                  Executing BuildTask CheckPointExternalLookupTablesReady

                  Created schema DBO_66d6c340_535b_4d15_a352_00ed57a4f5db in catalog DWCH_e5f240f8_ac75_4804_9eee_0d3646e9b7cf

                  Executing BuildTask CheckPointDatabaseReady

                  Executing BuildTask LoadPerTemplateTable

                  Executing BuildTask PrepareTemplateDataView

                  Executing BuildTask CheckPointMainInputTableReady

                  Executing BuildTask CreateCalculatedFieldsTable

                  Executing BuildTask CheckPointCalculatedFieldsTableReady

                  Executing BuildTask CreateFullDataView

                  Executing BuildTask CheckPointFullDataViewReady

                  Executing BuildTask CreateReader

                  Executing BuildTask PerformExport

                  Export1 - Completed

                  0 records written to c:\temp\export.txt

                  Export time: 00:00:00.0

                  Reader type: full build[/B]

                  PERFORMANCE: 00:00:00.0015154

                  PERFORMANCE: 00:00:00.0015750

                  PERFORMANCE: 00:00:00.0012482

                  PERFORMANCE: 00:00:00.0006635

                  Dropped schema DBO_66d6c340_535b_4d15_a352_00ed57a4f5db in catalog DWCH_e5f240f8_ac75_4804_9eee_0d3646e9b7cf

                  • After upgrade to 12 Automation object is not working for PDF
                    Olly Bond

                    Hello Sparky,

                     

                    I'm afraid I do automation on DataPump, not on the desktop - because the server offers so much more (logging, distribution, monitoring etc) and because at $25,000 for the desktop product with automation enabled, the DataPump/Automator works out cheaper too. My hunch would be that the TablelessExport switch would be set in the registry somewhere, but I'm afraid that I don't currently have access to an environment where I could replicate this for you.

                     

                    Best wishes,

                     

                    Olly

                      • After upgrade to 12 Automation object is not working for PDF
                        sparky2708 _

                        Olly,

                            Thank you for your help. I guess the appropriate place to post this is in the desktop forum. I will paste it there...

                        • After upgrade to 12 Automation object is not working for PDF
                          Olly Bond

                          Hello Sparky,

                           

                          Well, it's one step forward - it seems with the right bitness it's checking whether it's in Tableless mode and finding that it isn't.

                           

                          Can you set the Trace level to Debug or maximum? Again, I think this is a registry entry.

                           

                          I'd be very curious to see the automation manual or documentation that ships with that version, as I've only got the interactive version of desktop v12 and not the automated version. If you can email it to me I'd be grateful.

                           

                          Best wishes,

                           

                          Olly

                            • After upgrade to 12 Automation object is not working for PDF
                              sparky2708 _

                              Olly,

                              I don't have an automation manual - this was done by my predecessor - not sure how he figured this all out. This automation code was in previous versions of Monarch because I only have 1 user that uses Monarch and we were thinking of upgrading him but the code we used to have (i.e. code based on the example I have above), doesn't seem to be working. So am hoping I can get the issue resolved so we can finally upgrade him.

                                • After upgrade to 12 Automation object is not working for PDF
                                  Olly Bond

                                  Hello Sparky,

                                   

                                  I was just wondering whether Datawatch provided a reference guide to automation with the automation-enabled v12 you've got? Just in case some of the commands or parameters have changed.

                                   

                                  Does the work need to be done on the desktop? If the price is the same, wouldn't it be a bit more stable / scaleable / supportable if the processes ran on a server? The desktop client can then be used just to edit or create the models as required.

                                   

                                  Best wishes,

                                   

                                  Olly

                                    • After upgrade to 12 Automation object is not working for PDF
                                      sparky2708 _

                                      Olly,

                                        work will be done on the desktop by just 1 person. He doesn't want a server - there is additional costs for that: os cost, hardware cost, it cost, etc. which is total overkill for this person's responsibilities. Just not interested in the server, need to get this working on his desktop version.

                                        • After upgrade to 12 Automation object is not working for PDF
                                          RalphB _

                                          DataWatch has not released a new Programmers Guide since version 8.  The commands for the most part are the same in 12 as in V8.  They added a few commands and deleted some others, most were retained.  I don't have the list of changes right now but from what I remember the ones deleted were rarely used like SetFieldVisible.

                                           

                                          As for bit-rate, it is best that the Modeler bit-rate matches what the bit-rate of your Office products are.

                                            • After upgrade to 12 Automation object is not working for PDF
                                              Olly Bond

                                              Hello sparky,

                                               

                                              If it has to be Desktop, then can you set the Trace level to something higher than minimum and post the verbose log here?

                                               

                                              Best wishes,

                                               

                                              Olly

                                                • After upgrade to 12 Automation object is not working for PDF
                                                  sparky2708 _

                                                  Olly,

                                                     Figured out how to change the TraceLevel to Maximum using registry. It didn't really change much in the way of output:

                                                   

                                                  ===================== Datawatch.Engine 12.0.1.1 ======================

                                                  TraceLevel: Maximum[/B]

                                                  Codepage: 1252

                                                  Culture: en-US

                                                  Windows Version: 6.1.7601.65536 Service Pack 1

                                                  ExecutionFormat: 64-bit

                                                  PERFORMANCE: 00:00:00.0543797

                                                  PERFORMANCE: 00:00:00.0250012

                                                  PERFORMANCE: 00:00:01.2179968

                                                  PERFORMANCE: 00:00:00.0535812

                                                  Authorizer.IsFeatureEnabled Tableless_Export

                                                  IsFeatureEnabled Result: 0

                                                  Authorizer.IsFeatureEnabled PartialBuild_Export

                                                  IsFeatureEnabled Result: 0

                                                  PERFORMANCE: 00:00:00.1540518

                                                  GetCatalogToUse

                                                    dataSource: (localdb)\Datawatch.Engine

                                                    catalog: Datawatch.Engine.Manager

                                                    schema: dbo

                                                  PERFORMANCE: 00:00:00.0266292

                                                  PERFORMANCE: 00:00:00.0695784

                                                  PERFORMANCE: 00:00:00.1193697

                                                  PERFORMANCE: 00:00:00.8343864

                                                  Generating full build sequential table reader.

                                                  Executing BuildTask DownloadRemoteFile

                                                  Executing BuildTask CreateDatabase

                                                  Executing BuildTask PrepareInputFile

                                                  Created schema DBO_eaab85fa_6caf_48c9_b37f_6ff18ddd1fbe in catalog DWCH_4526ddd8_ffcc_481b_9a1a_046b19ce1923

                                                  Executing BuildTask CheckPointDatabaseReady

                                                  Executing BuildTask CheckPointUserEditTableReady

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask CheckPointExternalLookupTablesReady

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask LoadPerTemplateTable

                                                  Executing BuildTask PrepareTemplateDataView

                                                  Executing BuildTask CheckPointMainInputTableReady

                                                  Executing BuildTask CreateCalculatedFieldsTable

                                                  Executing BuildTask CheckPointCalculatedFieldsTableReady

                                                  Executing BuildTask CreateFullDataView

                                                  Executing BuildTask CheckPointFullDataViewReady

                                                  Executing BuildTask CreateReader

                                                  Executing BuildTask PerformExport

                                                  Export1 - Completed

                                                  0 records written to c:\temp\export.txt

                                                  Export time: 00:00:00.0

                                                  Reader type: full build

                                                  Executing BuildTask PerformExport

                                                  PERFORMANCE: 00:00:00.0010688

                                                  PERFORMANCE: 00:00:00.0005540

                                                  PERFORMANCE: 00:00:00.0007458

                                                  PERFORMANCE: 00:00:00.0004287