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

Question

Question

sequential number not showing in forms

asked on September 13, 2021

I have seen the many posts and followed the recommendations and admin help instructions to use a sequence and stored procedure to assign sequential numbering to LF Forms. All of it works except the resulting number is not showing up in the assigned field. I have used both the number and bigint as the result set column and neither works. I do know that my stored procedure is working b/c the number is incrementing. The ticket # field itself is defined as Number. Please advise and thanks in advance.

 

The lookup rule:

The properties of the sequence:

The stored procedure was created as below:

CREATE PROCEDURE [dbo].[ITReqNumber]

AS

BEGIN

SELECT NEXT VALUE FOR [dbo].[ITReqSeqNumber]

END

GO

0 0

Answer

SELECTED ANSWER
replied on September 13, 2021

I believe that the problem is how you defined the Stored Procedure and the fact that the column/result is not named.

You need to remove the existing SP and recreate it giving the return column a name

IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'ITReqNumber')
  DROP PROCEDURE [dbo].[ITReqNumber];
GO
CREATE PROCEDURE [dbo].[ITReqNumber]
AS
BEGIN
  SELECT NEXT VALUE FOR [dbo].[ITReqSeqNumber] AS [NextNumber];
END
GO

Then in your Lookup rule, use the new column name to populate the field

1 0
replied on September 13, 2021

Thanks!! It worked. My experience with SQL is limited. Take care.

0 0

Replies

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

Sign in to reply to this post.