Re: Finding unused SKU's in a database
This WebDNA talk-list message is from 2002
It keeps the original formatting.
numero = 44706
interpreted = N
texte = Excellent, pretty much working as needed.Thanks!And thanks Gyuri for your suggestion as well, but I was hoping to not haveto use a [loop] for the process.GK| on 11/1/02 1:04 PM, Gary Krockover at gary@garykrockover.com so noted...|| > I think I worded this funny. Here's a dummy approach:| >| > db=catalog.txt| > SKU| > 1| > 3| > 5| >| > How would I search and display that a SKU of 2 and 4 are available inthe| > above example?|| I'd do:|| [math show=f]lastSKU=1[/math]| [search db=catalog.txt&neSKUdata=[blank]&SKUsort=1&SKUtype=num]| [founditems]| [showif [SKU]>[math]openSKU=[lastSKU]+1[/math]][openSKU] -| [math][SKU]-1[/math]
[/showif]| [math show=f]lastSKU=[SKU][/math]| [/founditems]| [/search]|| For a list like:|| 1| 3| 5| 6| 7| 8| 12| 18| 19| 26|| It returns the ranges of open SKUs as:|| 2 - 2| 4 - 4| 9 - 11| 13 - 17| 20 - 25||| Rob Marquardt| Designer/Resident Wirehead| Toast Design|| 800 Washington Avenue North| Minneapolis MN 55401| 612.330.9863 v| 612.321.9424 f| www.toastdesign.com||| -------------------------------------------------------------| 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://search.smithmicro.com/-------------------------------------------------------------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://search.smithmicro.com/
Associated Messages, from the most recent to the oldest:
Excellent, pretty much working as needed.Thanks!And thanks Gyuri for your suggestion as well, but I was hoping to not haveto use a [loop] for the process.GK| on 11/1/02 1:04 PM, Gary Krockover at gary@garykrockover.com so noted...|| > I think I worded this funny. Here's a dummy approach:| >| > db=catalog.txt| > SKU| > 1| > 3| > 5| >| > How would I search and display that a SKU of 2 and 4 are available inthe| > above example?|| I'd do:|| [math show=f]lastSKU=1[/math]| [search db=catalog.txt&neSKUdata=[blank]&SKUsort=1&SKUtype=num]| [founditems]| [showif [SKU]>[math]openSKU=[lastSKU]+1[/math]][openSKU] -| [math][SKU]-1[/math]
[/showif]| [math show=f]lastSKU=[SKU][/math]| [/founditems]| [/search]|| For a list like:|| 1| 3| 5| 6| 7| 8| 12| 18| 19| 26|| It returns the ranges of open SKUs as:|| 2 - 2| 4 - 4| 9 - 11| 13 - 17| 20 - 25||| Rob Marquardt| Designer/Resident Wirehead| Toast Design|| 800 Washington Avenue North| Minneapolis MN 55401| 612.330.9863 v| 612.321.9424 f| www.toastdesign.com||| -------------------------------------------------------------| 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://search.smithmicro.com/-------------------------------------------------------------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://search.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:
[WebDNA] ONLY the FIRST continuous run of numeric chars? (2008)
WebCat cannot handle compatible search parameters? (1997)
Purchased cart being overwritten - still !?? (1997)
PROBLEM (1997)
More on the email templates (1997)
Sendmail doesn't (was Queertrons?) (1997)
merchant accts. (1997)
Non HTML file protection - OS X (webstar or apache) (2002)
mac hack (1997)
Sorry if this is really stupid but.. (2000)
Resume Catalog ? (1997)
WebCat2 - Getting to the browser's username/password data (1997)
Fufillment e-mail? (1998)
WebCat2b13MacPlugIn - [include] (1997)
Does ".tpl" index with SE's? (2003)
SSL and Webstar 3 with Webcatalog (1998)
Change extension (2000)
How to get shownext to just shownext once (1997)
Count regular expressions in a file (2007)
Online reference (1997)