how to generate Record using In-DB
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi All!
I have a question that I could not find an answer to.
What is the IN-DB formula used to generate a RecordID field starting at a specific number?
Thanks!
Solved! Go to Solution.
- Labels:
- In Database
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @ADocDork
All In-DB functions are related to your database functions.
So it really depends on your database. In SQL Server, I think you can use ROW NUMBER or RANK.
Cheers,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
This would be in SQL Server
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thanks! what would the actual formula be in SQL server to start at lets say 10000 and generate a recordID
Also- I need a straight RecordID not a rank
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
ROW_NUMBER() OVER(ORDER BY [Field]) + 9999
Try something like this.
[Field] being the field you have your dataset sorted by.
I can't test it here right now, but at least this is the idea.
Cheers,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You Sir,
Rock.
Thank you so much
