You are viewing limited content. For full access, please sign in.

Question

Question

Find a Specific SQL Table

asked on July 26, 2024 Show version history

Hi, how can I find a specific SQL Table through out all my LF Forms. I'm wanting to find which LF Form is using Table_A from my SQL DB?

Thanks in Advance

0 0

Answer

SELECTED ANSWER
replied on January 3 Show version history

Hi Carlos,

Although this does not give us a list of all forms using specific tables, it does list all forms using a specific data source that we can go through individually.  This is another approach to using the the "Data Sources" within Forms.

[cf_external_dbtables]: query the datasource_id for the table name listed within the table_name column.

[cf_bp_datasource_mapping]: query to find bp_id for the datasource_id found through previous query.

[cf_business_processes]: query to find all form names that have bp_id equal to value found in previous query.

 

My example:

 

SELECT [datasource_id]
      ,[database_id]
      ,[table_name]
      ,[table_schema]
  FROM [LF_Forms].[dbo].[cf_external_dbtables]
  where table_name like '<yourtable>'

 

SELECT B.name, cast(date_created AS DATE) AS date_created, cast(B.date_updated AS DATE) AS date_updated, B.is_triggerpublic as published
  FROM [LF_Forms].[dbo].[cf_bp_datasource_mapping] A
  inner join [LF_Forms].[dbo].[cf_business_processes] B ON
  A.bp_id = B.bp_id
  where  A.datasource_id = <datasource_id found through previous query>

1 0

Replies

replied on July 26, 2024

In Forms, if you click on your username in the upper right hand corner, and then select Administration, you will see a tab for Data Sources in the left column.  Unfortunately, all we have available is the SQL database and which processes are using that.  

 

I've requested an enhancement before to this so that it would show the tables. https://answers.laserfiche.com/questions/220186/Feature-Enhancement--Forms-Data-Sources

 

3 0
replied on July 26, 2024

A systems administrator can look at the data source and get a list of all processes that have been allowed to use it.

0 0
replied on July 26, 2024

I am a systems admin. However, I don't know where and how to find it.

0 0
replied on July 26, 2024

Yeah, I already know about what you described. I was hoping I can do a SQL query at the Laserfiche DB SQL to find this information I'm looking for. Thanks

0 0
replied on July 29, 2024

Hi Carlos,

As Craig stated, there is no easy way to query out this information with current design of data sources configuration, you can give your vote to the feature request Craig shared, we will evaluate the value of the use case at proper time.

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.