>>Are you using SQL Server?
>>
>>If yes, perhaps just create a stored procedure and return the ID (you can use OUTPUT clause of the INSERT command).
>>
>
>
>I am new to WinDev, and as I said I do not know how to use OUTPUT on the its queries and did not find examples either (the examples I saw were not for queries but for direct sql statements)
Very simple example:
CREATE TABLE dbo.TestInsert (InsertedPK int identity, Name varchar(100))
GO
INSERT INTO dbo.TestInsert OUTPUT Inserted.InsertedPK VALUES ('Kevin Goff')