Selecting Between WinCC IndustrialDataBridge and Connectivity Pack for External SQL Export

Selecting Between WinCC IndustrialDataBridge and Connectivity Pack for External SQL Export

Exporting historical tag archives from a SIMATIC PCS 7 V8.1 SP1 single station to an external Manufacturing Execution System (MES) SQL database can be achieved via the SIMATIC WinCC/IndustrialDataBridge (IDB) or the WinCC OLE-DB Provider (Connectivity Pack). IndustrialDataBridge offers a turnkey, code-free configuration tool with built-in error handling and scheduling, requiring an IDB software license. Conversely, developing a custom VBScript or .NET application using the WinCC OLE-DB Provider executes direct SQL queries against WinCC Tag Logging archives without requiring a Connectivity Pack license when executed locally on the WinCC station. Choosing between them depends on script development resources versus software licensing budgets.

Table of Contents

Architectural Comparison: IDB vs WinCC OLE-DB Provider

Integrating DCS process history into enterprise Manufacturing Execution Systems (MES) or ERP databases requires extracting compressed time-series data from WinCC Tag Logging SQL tables. Siemens provides two distinct technical pathways to accomplish this interface:

Evaluation ParameterSIMATIC WinCC / IndustrialDataBridge (IDB)WinCC OLE-DB Provider (Script-Based)Engineering EffortCode-Free: Graphical mapping of data sources to destinations via configuration wizard.Custom Code: Requires writing and maintaining VBScript, C#, or Python routines.Software LicensingRequires IndustrialDataBridge base license + tag expansion packs.License-Free when executed locally on the WinCC single station.Buffer & Auto-ReconnectBuilt-in disk buffering and automatic reconnection during network interruptions.Must be manually coded and managed within custom application scripts.Supported TargetsMicrosoft SQL, Oracle, MySQL, MS Access, CSV, OPC DA, XML.Any destination supported by the custom script (SQL ODBC, ADO, REST API).

Licensing Rules for Local vs Remote Archive Access

Licensing for archive data extraction follows strict Siemens architectural rules:

  • Local Execution (On the WinCC Station): When a script executing locally within WinCC Runtime (e.g., Global Script VBScript) queries the local WinCC Tag Logging archive using the WinCCOLEDBProvider.1 connection string, no Connectivity Pack license is consumed or required.
  • Remote Network Access: If an external client computer connects over the plant network to query the WinCC OLE-DB Provider remotely across TCP/IP, the SIMATIC WinCC/Connectivity Pack server license is mandatory.
  • Destination Database Writes: Neither Siemens solution requires special Siemens licensing to write data into the customer's external Microsoft SQL database; standard Microsoft SQL licensing applies.

Implementation Workflows for Data Export

Option A: Turnkey Export via IndustrialDataBridge (IDB)

  1. Install SIMATIC WinCC/IndustrialDataBridge on the single station.
  2. In the IDB configuration editor, define the Source: select WinCC Historical Data and browse project archive tags.
  3. Define the Destination: select Database (MS SQL Server) and enter connection credentials.
  4. Configure trigger rules: set cyclic transfer interval (e.g., every 60 seconds) or event-based trigger on batch end.
  5. Save and launch the IDB runtime service: data transfers automatically with automatic error recovery.

Option B: Custom VBScript via WinCC OLE-DB Provider

Create a cyclic VBScript in WinCC Global Script Editor to query archive tags and insert into external SQL tables:

Sub ExportArchiveToExternalSQL()
    Dim connWinCC, connExtSQL, rs, sqlQuery
    Set connWinCC = CreateObject("ADODB.Connection")
    Set connExtSQL = CreateObject("ADODB.Connection")

    ' Open connection to local WinCC Archive (License-Free locally)
    connWinCC.Open "Provider=WinCCOLEDBProvider.1;Catalog=CC_Project_Name;Data Source=.\\WinCC"

    ' Query last 5 minutes of data
    sqlQuery = "TAG:R,'TI_101#Value','" & CStr(DateAdd("n",-5,Now)) & "','" & CStr(Now) & "'"
    Set rs = connWinCC.Execute(sqlQuery)

    ' Connect to Customer External SQL Server
    connExtSQL.Open "Provider=SQLOLEDB;Data Source=MES_SERVER;Initial Catalog=PlantData;User ID=mes;Password=secret;"

    ' Iterate and insert records
    Do While Not rs.EOF
        connExtSQL.Execute "INSERT INTO Historian (Tag, Val, Timestamp) VALUES ('" & _
            rs.Fields(0).Value & "', " & rs.Fields(1).Value & ", '" & rs.Fields(2).Value & "')"
        rs.MoveNext
    Loop

    rs.Close: connWinCC.Close: connExtSQL.Close
    Set rs = Nothing: Set connWinCC = Nothing: Set connExtSQL = Nothing
End Sub

Procurement Schedule for Connectivity and IDB

The following Equipment Schedule specifies the relevant order numbers for data integration packages:

Turnkey Data Transfer Package:
- SIMATIC WinCC / IndustrialDataBridge V7.4 Base (100 Tags): 6AV6371-1DX07-4AX0
- IndustrialDataBridge Tag Expansion (1,000 Tags):          6AV6371-1DX07-4AB0
- IndustrialDataBridge Tag Expansion (10,000 Tags):         6AV6371-1DX07-4AC0

Remote Query Software Package:
- SIMATIC WinCC / Connectivity Pack V7.4:                   6AV6371-1DR07-4AX0

[!IMPORTANT]
Commercial Accuracy Disclaimer: IndustrialDataBridge is licensed based on the active number of synchronized tags. The WinCC/Connectivity Pack is licensed per server station for remote client access. Local script-based archive extraction does not require a Connectivity Pack license. Final license quantities and MLFBs must be validated against the applicable Siemens ST PCS 7 Catalog and authorized distributor quotations.

Verification

To verify external SQL export functionality:

  1. If using IDB: open the IDB Runtime monitor -> confirm connection state displays green for both WinCC and external SQL Server.
  2. If using VBScript: trigger the script manually and review WinCC_Sys.log for SQL execution confirmations.
  3. Log into Microsoft SQL Server Management Studio (SSMS) on the external customer server.
  4. Query the destination table: SELECT TOP 10 * FROM Historian ORDER BY Timestamp DESC.
  5. Verify that new process records arrive cyclically with accurate numerical values and valid timestamps.

Limitations and Operational Precautions

Operational boundaries when querying runtime databases:

  • Avoid Saturated Cyclic Queries: Do not execute heavy SQL archive queries every second; high-frequency database extraction consumes disk I/O, impacting WinCC operator screen responsiveness.
  • Explicit Object Disposal: When utilizing custom VBScripts, always explicitly close recordsets (rs.Close) and dereference objects (Set rs = Nothing) to prevent OS handle leaks.
  • Read-Only Enforcement: The WinCC OLE-DB Provider only permits read operations (SELECT). Never attempt to write records directly to WinCC Tag Logging archive tables.

Engineer FAQ

Do I need to buy a Connectivity Pack license to read WinCC archives from local VBScript?

No. The WinCC OLE-DB Provider is installed with WinCC Runtime and can be queried by local scripts on the same PC without requiring a Connectivity Pack license.

When is the WinCC Connectivity Pack license strictly required?

It is required when an external software application located on a different computer queries the WinCC OLE-DB Provider across the network.

What is the main advantage of IndustrialDataBridge over custom VBScript?

IDB requires zero programming, handles schema mapping graphically, and includes automatic network buffering and reconnection mechanisms that would require substantial custom coding in VBScript.

Can custom VBScripts write directly into external customer SQL tables?

Yes. By creating standard ADO connection objects pointing to the customer's SQL Server, VBScript can execute standard SQL INSERT statements.

Technical References

Related Articles

Related Tags

  • IndustrialDataBridge
  • Connectivity-Pack
  • WinCC-OLE-DB
  • SQL-Export
  • Tag-Logging
  • MES-Integration
8 respuestas