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

Question

Question

SQL Query for Laserfiche 9

asked on February 12, 2015 Show version history

Good Day.

 

I am attempting to create Dyamic Fields in LF and found this article: 

http://www.laserfiche.com/solutionexchange/article/9058

 

However if i try to execute this query, it renders a lot of errors.

 

Does anyone know of an updated SQL query for LF V9.

 

Regards

Adam

0 0

Replies

replied on February 12, 2015 Show version history

Hi Adam,

I wrote that article. There's not been any changes to the 9.2 database schema to effect the solution so it must be something else. Here's an example of a view I'm currently using:


SELECT	CONVERT(NVARCHAR(40),pv1.str_val) AS SoftwareProjectType, CONVERT(NVARCHAR(40),pv2.str_val) as DocumentType
FROM	laserficheDB.dbo.propval AS pv1
		inner join laserficheDB.dbo.propval AS pv2 ON pv1.tocid=pv2.tocid
		inner join laserficheDB.dbo.toc ON toc.tocid=pv1.tocid 
WHERE	pv1.prop_id=74
	and pv2.prop_id=73
	and toc.pset_id=6
	and (toc.toc_flags & 0x800 = 0)
	-- replace the line above with the line below in case of errors
	-- and (toc.toc_flags & convert(int,0x800) = 0)

Can you post your errors? I'll gladly help.

-Ben

1 0
replied on February 12, 2015

Adam, Can you post the specific errors you are getting?  Are the errors when you are attempting to register the external table?  Is the SQL table you are querying located on the SQL instance on your Laserfiche server? 

0 0
replied on February 12, 2015 Show version history

You can also refer to the Administration Guide Help file for information on creating an External Table in SQL. Or use Microsoft Excel to create an external table.

0 0
replied on February 12, 2015

I wrote up some detailed instructions on this including SQL statements here.

 

 

https://answers.laserfiche.com/questions/70561/Register-an-external-table-for-Dynamic-Field

 

John

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

Sign in to reply to this post.