Contents Menu Expand Light mode Dark mode Auto light/dark, in light mode Auto light/dark, in dark mode Skip to content
MFSQL Connector 5.13.37.81 documentation
Light Logo Dark Logo
MFSQL Connector 5.13.37.81 documentation

FAQ:

  • Frequently asked questions
    • Advanced FAQ (Deep Dive Cross-Refs)

MFSQL Connector Guide:

  • Introduction to MFSQL
    • Introducing MFSQL Connector
    • System Requirements
    • MFSQL Connector modules
    • Functional Overview
      • Functional to Deep-Dive Mapping
      • Appendix A: Object-Level Mapping (Snapshot)
      • Appendix B: Remaining Unmapped / Review
    • Practical tips and Use Cases
    • Licensing
      • MFSQL Connector License Agreement
    • Installing MFSQL Connector
  • Getting Started
    • Planning and prerequisites
    • Install
      • Common installation notes
      • On‑premises: single server
      • On‑premises: split servers
      • Install the Web API
      • Cloud
        • Cloud: install connector side
        • Cloud: install Web API
        • Cloud: VAF configuration
      • High availability (SQL cluster)
      • Manual installation path
    • Post-install
      • License management (Post-Install)
      • Connection and Web API
      • Configure the context menu
      • Enable VAF logging
      • Database Mail
      • Using Agent for automated updates
        • Prevent agent job to run
        • View to check if job is running
        • View to check if job is running
        • Prevent agent job to run
      • Setup powershell utilities
        • Setup database script
        • Validate table procedure
    • Validate and smoke tests
    • Upgrades and hotfixes
      • Moving the Connector Database
      • Upgrade to version 4.10.30.74 and later
      • Update to version 4.11.33.77
    • Upgrade to Release 5
    • Next Steps after installation
    • Common installation errors and resolutions
      • Install package with logging
    • Example scripts to get started
      • Getting Started
      • Updating settings
      • Quick startup for multiple class tables
      • Initialize the application
      • Metadata Structure Changes
      • Metadata Update Development: Practical Example
      • Working with All Metadata Update Procedures
      • Aliases: Examples and Updates
      • Bulk Updating of aliases
      • Inserting New Objects Using Batch Mode
      • Creating New Objects with Auto Numbering
      • Deleting Duplicate Objects in M-Files
      • Deleting Objects in M-Files
      • Get Deleted Objects
      • Destroy Object Versions in M-Files
      • Create Lookup Views for Value Lists and Workflow States
      • Updating Value List Items
      • Working with Workflows
      • Resetting Workflow State Names on All Class Tables
      • Using update filters: ObjIDs
      • Using update filters: last modified date
      • Ad hoc columns on class tables
      • inserting new objects using transaction update
      • Inserting new objects using lookup views
      • Insert Records with single lookup columns
      • using spmfupdatetableInbatches for batch updates
      • Comparing procedures for large volume updating
      • Using multilookup upsert
      • using record by record update
      • Create public shared link
      • Get Object History records
      • Adding comments to object
      • Get Comments using Change History
      • Get Workflow state changes using Change History
      • Get all changes for object with Change History
      • Delete history logging tables
      • understanding history tables
      • Uploading Blob Files into M-Files
      • Updating the ContextMenu
      • Getting ready for reporting
      • using Search object
      • using updatetable filters - UserID
      • Using user messaging
      • sending bulk emails with attachements
      • using auto correction of synchronization errors
      • TableAudit and classtablestats
      • Example of SyncPrecedence 0 (SQL takes precedence)
      • Example of SyncPrecedence 1 (MF takes precedence)
      • Analyse Class table columns with spMFClassTableColumns
      • Explorer impact of multi lookup property changes
      • Using functions in custom procs
      • Reporting_PerformanceAnalysis
      • Example - Start Job Wait - Agent
      • agent for update context menmu queue
      • Example - Sync Procesure
      • 70 101 Example - Sync Process - Test wLogging
      • Example - Sync Process - Test
      • Example - Sync Process - Check Progress
      • Template - custom procedure
      • custom DoCMObjectAction
      • custom DoCMAction
      • custom DoCMObjectActionForWorkFlowState
      • custom DoCMAsyncAction
      • Custom CMMFiles_UpdateSQL
      • Custom DoAccountConfirmationEmail
      • Export and use M-Files event log
    • Installation Overview (legacy)
    • On Premise Installation (legacy)
    • M-Files Cloud and other hosted installations (legacy)
      • Installing the Web API
    • High Availability SQL Servers installation (legacy)
    • Configuration and setup (legacy)
      • Update settings
      • Installing the Context Menu
      • Enabling and configuring the VAF logging
      • Database Mail
      • Using Agent for automated updates
        • Prevent agent job to run
        • View to check if job is running
        • View to check if job is running
        • Prevent agent job to run
      • Setup powershell utilities
        • Setup database script
        • Validate table procedure
    • Manual installation using scripts (legacy)
      • Content Package installation (legacy)
  • MFSQL Data Exchange and Reporting Connector
    • Working with Metadata
      • Overview
      • structure-tables-and-concepts
      • core-synchronization-procedures
      • Selective and Advanced Synchronization
      • automation-and-operations
      • change-management-and-vault-moves
      • Troubleshooting and Diagnostics
      • Recipes and Examples
      • legacy-reference
    • Working with Class Tables
      • MFClass and Class Tables
      • Automated update of records from M-Files
      • Create a new class table
    • Working with Class Tables (Deep Dive)
      • Overview
      • Preparing Class Tables
      • Synchronization Strategies
      • Update Approaches
      • Performance and Scaling
      • Troubleshooting
      • Practical Examples
      • Reference Map
    • Using the Context Menu
      • overview
      • action-types-and-behavior
      • Security and Permissions
      • Creating Menu Items
      • Workflow and Event Handlers
      • queue-and-logging
      • troubleshooting-and-diagnostics
      • example-reset-and-sample-scripts
    • Reporting
      • Reporting Overview
      • Class Tables and Data Flow
      • Quick Start
      • Initial Load and Scheduling
      • Tools and Examples
      • Event Log Reporting
      • Performance and Optimization
      • Troubleshooting and Sample Queries
      • Reporting - getting started
      • Reporting : Quick start
      • Using Power BI for reporting
      • M-Files event log
  • MFSQL Integration Connector
    • Exploring metadata
    • Integration Deep Dive Topics
      • Metadata Orchestration
      • Advanced Class Table Update Strategies
      • Synchronization Conflicts and Precedence
      • File ingestion and export pipeline
      • Valuelist and Workflow Management
      • Messaging and Notifications
      • Logging and Observability
      • Search and Discovery
      • Security and User Group Insights
      • Deployment and Vault Migration
      • add-ons and automation tools
      • Application Integration Architecture
      • Automated Updates and Scheduling
    • Building custom applications and integrations
    • Property and column usage
    • Metadata Search
    • Update / Create Valuelist Items from SQL
    • User Messages
    • Lookup views
    • Send Bulk Email
    • Working with files
    • Working with aliases
    • Correcting synchronization errors
    • Change of vault
    • Daily and monthly routines for agents
    • Tips and tricks on using the connector
    • Getting deleted objects
    • Using and managing logs
      • Logging Tables
      • Enabling and configuring the VAF logging
      • Logging execution of Process and Procedure Steps
      • Setting switch to use process logging
      • MFUpdateHistory for logging of class record changes
      • Logging in custom procedures
      • Error tracing
    • Working with Object Version
    • Contextmenu queue (Removed)
    • MFSQL Connector addons and utilities
    • Users in Usergroups
  • Release 5
    • Future enhancements
  • The Connector Framework
    • Architecture
    • Connector Content
      • Assemblies
      • Metadata Structure Tables
      • Class tables
      • Utility Tables
      • Logging Tables
      • Procedures and Functions
        • spMFCreateObjectInternal
        • Parameters
        • CLR and internal procedures
      • M-Files Installation
      • Context Menu
      • Supporting Applications
        • Custom tables, views, procedures and functions
      • MFSQL Connector Operations
    • Connector Database
      • Using CLR
      • M‑Files API version and CLR assembly updates
    • Enabling the database
    • Licensing
    • Security
      • Schemas
  • Version Control
    • Version Control — Release 4
    • Version Control — Release 5

Blog:

  • List of blogs
    • Advanced updating of Valuelists from external source
    • Align metadata from an external source with data in M-Files
    • Aligning valuelist items with different owners
    • Perform a background operation in SQL on workflow change
    • Building applications around M-Files
    • Certified Application Developer presentation
    • Changing the class of an object
    • Changing from single lookup to multi lookup
    • Considerations for deleted records
    • Considerations for large volume vault
    • Create a scheduled pull from M-Files using SQL Server Agent
    • Creating and using public shared link
    • Creating multiple related objects on file import
    • CRM and Emailer Management
    • Deleting duplicate objects
    • Exporting files from a vault
    • ExternalID versus DisplayID versus Objid
    • Explore all the objects in the vault
    • Get number of records in Class
    • Working with object change history
    • Getting started with a custom application
    • Getting to know MFSQL Connector
    • How to generate a quick follow up list
    • Illegal XML Characters
    • Importing files into M-Files
      • Example procedure for importing sales invoices on demand
        • Custom Procedure - DoUpsertVendorInvoice
    • Insert new records from SQL
    • Integration for vendor approval
      • Custom Procedure - DoVendorUpsert
      • Custom Procedure - DoNewERPVendor
      • Custom Procedure - UpdateERPVendor
    • Integration whitepaper
    • Integration with SAGE 200 - Case Management
    • Integration with SAGE 50
    • Integration with test equipment
    • Integration with Vendor Management and Purchasing with Epicor Enterprise
    • Mark for Archiving using Class Table
    • Metadata Management and data cleansing
    • Metadata Management and Realignment Case Study
    • MF-Last-Modified-User in action
    • Moving documents from one class to another
    • Moving metadata from text properties to Valuelist items
    • MultiSelectLookups
    • Near real time reporting
    • Online Ordering of special stock
    • Online Quote System
    • Practical use of logging in Procedures
    • Processing scanned documents
    • Properties with multi lookup datatypes
    • Limitations of real datatype
    • Report designers and the Connector
    • Reports from the extended Event log
    • Restore MFSQL database to a different server
    • RPC over HTTPS setup
    • Setting up a workflow state change
    • Setup Agent Proxy for MFSQLConnect
    • Status report using context menu
    • Table relations - views for reporting
    • Update large tables using batch mode
    • Upgrading to VAF 10.4
    • Updating a multi lookup property on an object
    • Updating incorrect properties across multiple related classes
    • Updating only records that changed
    • Updating millions of records
    • Using delimiter functions
    • Using event handler for SQL action
    • Using hyperlinks with MFSQL Connector
    • Using M-Files External Connector
    • Using spMFClassTableStats
    • Using the External_ID to match third party app tables
    • Using windows authentication
    • Working with Additional Properties
    • Working with checked Out objects
    • Working with date and time
    • Working with Document Collections

SQL Components:

  • Procedures
    • spMFAddCommentForObjects
    • Signature
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFAliasesUpsert
    • Signature
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFChangeClass
    • Signature
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFCheckAndUpdateAssemblyVersion
    • Signature
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFCheckLicenseStatus
    • spMFClassTableColumns
    • Signature
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFClassTableStats
    • Signature
    • Purpose
    • Additional Info
    • Report by Email
    • Warnings
    • Corrective Action
    • Usage
    • Additional Examples
    • Changelog
    • spMFConnectionTest
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFContextMenuActionItem
    • Signature
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFContextMenuHeadingItem
    • Signature
    • Purpose
    • Prerequisites
    • Examples
    • Changelog
    • spMFConvertTableToHtml
    • Signature
    • Parameters
    • Purpose
    • Additional info
    • Examples
    • Changelog
    • spMFCreateAllLookups
    • Signature
    • Purpose
    • Changelog
    • spMFCreateAllMFTables
    • Signature
    • Purpose
    • Examples
    • Changelog
    • spMFCreatePublicSharedLink
    • Signature
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFCreateTable
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFCreateValueListLookupView
    • Signature
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFCreateWorkflowStateLookupView
    • Signature
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFDeleteAdhocProperty
    • Signature
    • Purpose
    • Additional Info
    • Prerequisites
    • Examples
    • Changelog
    • spMFDeleteHistory
    • Signature
    • Purpose
    • Examples
    • Changelog
    • spMFDeleteObject
    • Signature
    • Parameters
    • Purpose
    • Additional Information
    • Warnings
    • Examples
    • Changelog
    • spMFDeleteObjectList
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Prerequisites
    • Additional info
    • Warning
    • Examples
    • Changelog
    • spMFDeleteObjectVersionList
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Prerequisites
    • Warning
    • Examples
    • Changelog
    • spMFDeploymentDetails
    • Signature
    • Purpose
    • Examples
    • Changelog
    • spMFDropAllClassTables
    • Signature
    • Purpose
    • Examples
    • Changelog
    • spMFDropAndUpdateMetadata
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFExportFiles
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFExportFilesMultiClasses
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Folder setting examples
    • Examples
    • Changelog
    • spMFGetDataExport
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFGetDeletedObjects
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFGetHistory
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFGetLicense
    • Purpose
    • Examples
    • Changelog
    • spMFGetMFilesAssemblyVersion
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFGetMfilesLog
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFGetObjectvers
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFGetProcedurePerformance
    • Signature
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFImportBlobFilesToMFiles
    • Signature
    • Purpose
    • Additional Info
    • Prerequisites
    • Examples
    • Changelog
    • spMFInsertClass
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFInsertClassProperty
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFInsertLoginAccount
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFInsertObjectType
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFInsertProperty
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFInsertUserAccount
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFInsertUserMessage
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Addition Info
    • Examples
    • Changelog
    • spMFInsertValueList
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFInsertValueListItems
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFInsertWorkflow
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFInsertWorkflowState
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFLogError_EMail
    • Signature
    • Purpose
    • Warnings
    • Examples
    • Changelog
    • spMFLogProcessSummaryForClassTable
    • Signature
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFObjectTypeUpdateClassIndex
    • Signature
    • Purpose
    • Prerequisites
    • Examples
    • Changelog
    • spMFProcessBatchDetail_Insert
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFProcessBatch_Upsert
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFProcessBatch_Mail
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Examples
    • Changelog
    • spMFRemoveAdditionalProperties
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFResultMessageForUI
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFSearchForObject
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFSearchForObjectbyPropertyValues
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFSendHTMLBodyEmail
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Examples
    • Changelog
    • SpmfSetAdditionalProperty
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFSetContextMenuQueue
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFSetUniqueIndexes
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFSetup_Reporting
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFSynchronizeClasses
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFSynchronizeFilesToMFiles
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFSynchronizeLoginAccount
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFSynchronizeLookupColumnChange
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFSynchronizeMetadata
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFSynchronizeObjectType
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFSynchronizeProperties
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFSynchronizeSpecificMetadata
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFSynchronizeUserAccount
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFSynchronizeValueList
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFSynchronizeValueListItems
    • Purpose
    • spMFSynchronizeValueListItemsToMfiles
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Examples
    • Changelog
    • spMFSynchronizeWorkFlowStateColumnChange
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFSynchronizeWorkflow
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFSynchronizeWorkflowsStates
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Changelog
    • spMFTableAudit
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFUnDeleteObject
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Warnings
    • Examples
    • Changelog
    • spMFUpdateAllncludedInAppTables
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Warning
    • Examples
    • Changelog
    • spMFUpdateAssemblies
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFUpdateAssemblyLog
    • Purpose
    • Additional Info
    • Changelog
    • spMFUpdateContextMenuQueue
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFUpdateExplorerFileToMFiles
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFUpdateHistoryShow
    • Purpose
    • Additional Info
    • Warning
    • Examples
    • Changelog
    • spMFUpdateItemByItem
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFUpdateMFilesToMFSQL
    • Purpose
    • Additional Info
    • Warnings
    • Examples
    • Changelog
    • spMFUpdateObjectChangeHistory
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Prerequisites
    • Examples
    • Changelog
    • spMFUpdateSynchronizeError
    • Purpose
    • Examples
    • Changelog
    • spMFUpdateTable
    • Purpose
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFUpdateTableInternal
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Additional Info
    • Changelog
    • spMFUpdateTableWithLastModifiedDate
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFUpdateTable_ObjIDs_GetGroupedList
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFUpdateTable_ObjIDs_Grouped
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • spMFUpdateTableinBatches
    • Purpose
    • Additional Info
    • Prerequisites
    • Warning
    • Examples
    • Changelog
    • spMFUsersByUserGroup
    • Purpose
    • Examples
    • Changelog
    • spMFValidateEmailProfile
    • Purpose
    • Additional info
    • Examples
    • Changelog
    • spMFVaultConnectionTest
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • spMFsettingsForDBUpdate
    • Signature
    • Purpose
    • Additional Info
    • Prerequisites
    • Warnings
    • Examples
    • Changelog
    • spMFsettingsForVaultUpdate
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
  • Tables
    • MFAuditHistory
    • Columns
    • Indexes
    • Additional Info
    • Changelog
    • MFAuthenticationType
    • Columns
    • Used By
    • Changelog
    • MFObjectChangeHistoryUpdateControl
    • Columns
    • Additional info
    • Used By
    • Changelog
    • MFClass
    • Columns
    • Additional Info
    • Indexes
    • Foreign Keys
    • Examples
    • Changelog
    • MFClassProperty
    • Columns
    • Additional Info
    • Indexes
    • Changelog
    • MFContextMenu
    • Columns
    • Used By
    • Changelog
    • MFContextMenuQueue
    • Columns
    • Additional Info
    • Indexes
    • Foreign Keys
    • Uses
    • Used By
    • Examples
    • Changelog
    • MFDataType
    • Description
    • Columns
    • Indexes
    • Used By
    • Changelog
    • MFDeploymentDetail
    • Columns
    • Additional Info
    • Used By
    • Changelog
    • MFEmailTemplate
    • Description
    • Columns
    • Additional Info
    • Placeholders
    • Example Insert statement
    • Changelog
    • MFEmailLog
    • Description
    • Columns
    • Additional Info
    • Used By
    • Changelog
    • MFEventLog_OpenXML
    • Columns
    • Additional Info
    • Used By
    • Changelog
    • MFExportFileHistory
    • Columns
    • Used By
    • Changelog
    • MFFileExportControl
    • Columns
    • Additional Info
    • Used By
    • Changelog
    • MFFileImport
    • Columns
    • Additional Info
    • Used By
    • Changelog
    • MFLog
    • Columns
    • Indexes
    • Usage
    • Changelog
    • MFLoginAccount
    • Columns
    • Additional Info
    • Relation
    • Changelog
    • MFObjectChangeHistory
    • Columns
    • Additional Info
    • Used By
    • Changelog
    • MFObjectType
    • Columns
    • Indexes
    • Changelog
    • MFProcessBatch
    • Columns
    • Additional Info
    • Used By
    • Changelog
    • MFProcessBatchDetail
    • Columns
    • Additional Info
    • Indexes
    • Used By
    • Changelog
    • MFProperty
    • Columns
    • Additional Info
    • Indexes
    • Foreign Keys
    • Changelog
    • tbMFProtocolType
    • MFPublicLink
    • Columns
    • Used By
    • Changelog
    • MFSearchLog
    • Columns
    • Used By
    • Changelog
    • MFSettings
    • Columns
    • Changelog
    • MFUpdateHistory
    • Columns
    • Additional Info
    • Indexes
    • Used By
    • Changelog
    • MFUserAccount
    • Columns
    • Indexes
    • Additional Info
    • Relation
    • Changelog
    • MFValueList
    • Columns
    • Additional Info
    • Indexes
    • USAGE
    • Changelog
    • MFValueListItems
    • Columns
    • Additional Info
    • Indexes
    • Foreign Keys
    • Examples
    • Change control
    • tbMFVaultSettings
    • MFWorkflow
    • Columns
    • Indexes
    • Changelog
    • MFWorkflowState
    • Columns
    • Additional Info
    • Indexes
    • Foreign Keys
    • Changelog
    • MFilesEvents
    • Columns
    • Indexes
    • Additional Info
    • Changelog
  • Functions
    • fnMFCapitalizeFirstLetter
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFExcelObjectHyperlink
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Notes
    • Examples
    • Related
    • Changelog
    • FnMFFloatToString
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • FnMFGetCulture
    • Signature
    • Returns
    • Purpose
    • Examples
    • Changelog
    • fnMFLastConnectorVersion
    • Signature
    • Returns
    • Purpose
    • Examples
    • Changelog
    • fnMFMultiLookupUpsert
    • Purpose
    • Examples
    • Changelog
    • fnMFObjectHyperlink
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Limitations
    • Examples
    • Related
    • Changelog
    • fnMFParseDelimitedString
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFRemoveIllegalXMLCharacters
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFReplaceSpecialCharacter
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFSplit
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFSplitPairedStrings
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFSplitString
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFTextToDate
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFVariableTableName
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
    • fnMFVaultSettings
    • Signature
    • Returns
    • Parameters
    • Purpose
    • Examples
    • Changelog
  • Views
    • MFvwAuditSummary
    • Purpose
    • Examples
    • Changelog
    • MFvwClassTableColumns
    • Purpose
    • Examples
    • Changelog
    • MFvwLogTableStats
    • Purpose
    • Examples
    • Changelog
    • MFvwMetadataStructure
    • Purpose
    • Examples
    • Changelog
    • MFvwObjectChangeHistory
    • Purpose
    • Examples
    • Changelog
    • MFvwObjectTypeSummary
    • Purpose
    • Additional Info
    • Examples
    • Changelog
    • MFvwTableID
    • Purpose
    • Examples
    • Changelog
  • Triggers
    • tMFProcessBatch_UserMessage
    • Purpose
    • Warnings
    • Examples
    • Changelog
Back to top

Creating and using public shared link¶

MFSQ: Connector allows for creating a public shared link to an object on demand.

Currently this capability is limited to single file object. Multifile objects and collections cannot be accessed. Accessing multifile objects and collections is on the roadmap and is awaiting demand for the functionality to prioritise the development.

It is simple to use: set the process_id on the class table to say 6 for all the target records; run procedure , spMFCreatePublicSharedLink; and access the link in the table MFPublicLink.

Pre-requisits¶

M-Files must be setup for Web services and have the url in the M-Files Web setting in the vault properties.

The following two settings must be exist and be correct in MFSettings table:
  • ServerURL

  • VaultGUID

Use the following script to setup or change these settings.

DECLARE @GUID NVARCHAR(100);
DECLARE @WebURL NVARCHAR(100);

SET @GUID = N'{5981E340-C62F-4DB0-8E22-684AD012E5F6}'; --replace this with the GUID, including the curley brackets
SET @WebURL = N'http://lsuk-app03.lsusa.local'; --replace with your web url

IF EXISTS (SELECT * FROM dbo.MFSettings WHERE Name = 'VaultGUID')
 BEGIN
 EXEC dbo.spMFSettingsForVaultUpdate @VaultGUID = @GUID;
 END;
 ELSE
BEGIN
INSERT dbo.MFSettings
(
    source_key,
    Name,
    Description,
    Value,
    Enabled
)
VALUES
(N'MF_Default', N'VaultGUID', N'GUID of vault', @GUID, 1);
END;

IF EXISTS (SELECT * FROM dbo.MFSettings WHERE Name = 'ServerURL')
BEGIN
EXEC dbo.spMFSettingsForVaultUpdate @ServerURL = @WebURL;
END;
ELSE
BEGIN
INSERT dbo.MFSettings
(
    source_key,
    Name,
    Description,
    Value,
    Enabled
)
VALUES
(N'MF_Default', N'ServerURL', N'Web URL for M-Files', @WebURL, 1);
END;

Step by step guide¶

Links can be created in bulk and on demand and can be built into other procedures. For instance, the links can be created in the back ground and added back as a property on the object. This allows for the link to become available for use on the object itself. Another use case is to bulk create the links and to include the links in an email to a selection of customers.

Example http://ServerDNS/SharedLinks.aspx?accesskey=fd69f8b5e1a02a567ebd164dfea337b3fe2b92d3296df3d698bf6d2354cba983&VaultGUID={3E2585FF-ED4F-4EEF-888D-B7AD475195B9}


Step 1: Update the process_id of the target records

--Update a record where singlefile = 1 and set process_ID = 1

update [od]
set [od].[Process_ID] = 1
FROM   [MFOtherDocument] od where [Single_File] = 1

Step 2: Set the expiry date and run the procedure

DECLARE @Expiredate DATETIME = DATEADD(m, 1, GETDATE())
-- set expiredate to 1 month from today
EXEC [spMFCreatePublicSharedLink] @Tablename = 'MFOtherDocument'
, @Expirydate = @Expiredate
, @processID = 6

Step 3: Use the link from the public link table.

--show links for a specific Project
SELECT [mod].[Project], mod.[Name_Or_Title], mpl.link AS FileURL
FROM [dbo].[MFOtherDocument] AS [mod]
INNER JOIN [dbo].[MFPublicLink] AS [mpl]
ON [mod].objid=mpl.[ObjectID] AND mod.class_ID = mpl.[ClassID]
WHERE [mod].[Project] = 'Office Design'
Next
Creating multiple related objects on file import
Previous
Create a scheduled pull from M-Files using SQL Server Agent
Copyright © 2023, Laminin Solutions Ltd
Made with Sphinx and @pradyunsg's Furo
On this page
  • Creating and using public shared link
    • Pre-requisits
    • Step by step guide