Is there a possiblity to add the “auto_increment” attribute to QueryNew() in Coldfusion?
I want to simulate a database, so I need a primary key, which I refer to.
My goal is an easy navigation with nav_id and nav_pid (parent id).
If there is no easy solution I’ll do it with a loop or just add it as follow:
<cfset querySetCell(nav, "nav_id", 1) />
thx for your help!
I’m sorry, there is no auto-increment attribute that could be set for a querycolumn in a newly created queryobject: https://helpx.adobe.com/de/coldfusion/cfml-reference/coldfusion-functions/functions-m-r/querynew.html
So you must go with a loop and create your query: