Re: Same DB Same Time
This WebDNA talk-list message is from 2004
It keeps the original formatting.
numero = 55962
interpreted = N
texte = I'll get arguments for this, but I have a fairly busy messageboard that relies on the incremental SKU and I *was* having the problem of duplicate SKU #'s until I moved the code that generated the new number into the append itself. Previously, it would generate the new SKU higher on the page, do a few things and then append that number as a called variable.So now, I have it something like:[append db=notes.db][!][/!]sku=[math]Newsku=([Search db=notes.db&neskudatarq=[blank]&deskusort=1&skutype=num&max=1][FoundItems][sku][/FoundItems][/Search]+1)[/math][!][/!][/append]And haven't had a duplicate SKU in the past year (knocks on wood).And no, this is a 4.5 server, so the new auto-increment thingy isn't available.And, this might not even be your issue here, but thought I'd mention it.GKAt 10:57 AM 2/9/2004, you wrote:>The [replacefounditems] pulls an integer from the database, increases it >by one, and then replaces the old value. The [append] creates a new sku >by grabbing the highest integer and increasing it by one (basically an >autonumber).-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list
.To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Associated Messages, from the most recent to the oldest:
I'll get arguments for this, but I have a fairly busy messageboard that relies on the incremental SKU and I *was* having the problem of duplicate SKU #'s until I moved the code that generated the new number into the append itself. Previously, it would generate the new SKU higher on the page, do a few things and then append that number as a called variable.So now, I have it something like:[append db=notes.db][!][/!]sku=[math]Newsku=([Search db=notes.db&neskudatarq=[blank]&deskusort=1&skutype=num&max=1][founditems][sku][/FoundItems][/Search]+1)[/math][!][/!][/append]And haven't had a duplicate SKU in the past year (knocks on wood).And no, this is a 4.5 server, so the new auto-increment thingy isn't available.And, this might not even be your issue here, but thought I'd mention it.GKAt 10:57 AM 2/9/2004, you wrote:>The [replacefounditems] pulls an integer from the database, increases it >by one, and then replaces the old value. The [append] creates a new sku >by grabbing the highest integer and increasing it by one (basically an >autonumber).-------------------------------------------------------------This message is sent to you because you are subscribed to the mailing list .To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/
Gary Krockover
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
Random ads (1998)
Dreamweaver Extensions (2001)
flushdatabases (1997)
greater than or equal to (1997)
Webmerchant confirmation hooks? (1997)
Urgent Help needed (1998)
Here's how to kill a Butler Database. (1997)
Bug 4.0: Windows Virtual Directories (2000)
Trigger alternatives please ... (2004)
Re:WebCat Talk Arhives... (1998)
Proper file locations (1997)
WebCat2b15MacPlugIn - [authenticate] not [protect] (1997)
Trouble with formula.db (1997)
[defined]ish (1997)
for those in need of inspiration [OT] (2003)
WebCat2b13MacPlugin - [math][date][/math] problem (1997)
using showpage and showcart commands (1996)
test (2004)
append=T problem (1998)
[WriteFile] problems (1997)