Re: Feature Request: DB Field manipulation
This WebDNA talk-list message is from 1998
It keeps the original formatting.
numero = 17609
interpreted = N
texte = >I've seen enough people ask how to add a field to a database that I thought>I'd propose this:>>[ADDFIELD db=SOME.DB&field=FIELDNAME]>This would add a new field (FIELDNAME) to a databse (SOME.DB).>...[COPYFIELD]Added to the list...thanks!In the meantime, I think a WebDNA template could be made that doessomething similar. Something like the following (untested)[include file=FieldAdder.inc&db=SOME.DB&fld=SKU&field=ZipPlusFour]-- FieldAdder.inc --[WriteFile file=newdatabase.db][ListFields db=[db]][fieldname] [/listfields][field][search db=[db]&ne[fld]data=[blank]][FoundItems][ListFieldsdb=[db]][interpret][[fieldname]][/interpret] [/listfields][/FoundItems][/Search][/WriteFile]Grant Hulbert, V.P. Engineering | ==== eCommerce for the Rest of Us ====Pacific Coast Software | WebCatalog, WebMerchant,11770 Bernardo Plaza Court | SiteEdit Pro, PhotoMaster,San Diego, CA 92128 | Typhoon619/675-1106 Fax: 619/675-0372 | http://www.smithmicro.com/
Associated Messages, from the most recent to the oldest:
>I've seen enough people ask how to add a field to a database that I thought>I'd propose this:>>[ADDFIELD db=SOME.DB&field=FIELDNAME]>This would add a new field (FIELDNAME) to a databse (SOME.DB).>...[COPYFIELD]Added to the list...thanks!In the meantime, I think a WebDNA template could be made that doessomething similar. Something like the following (untested)[include file=FieldAdder.inc&db=SOME.DB&fld=SKU&field=ZipPlusFour]-- FieldAdder.inc --[WriteFile file=newdatabase.db][ListFields db=[db]][fieldname] [/listfields][field][search db=[db]&ne[fld]data=[blank]]
[founditems][ListFieldsdb=[db]]
[interpret][[fieldname]][/interpret] [/listfields][/FoundItems][/Search][/WriteFile]Grant Hulbert, V.P. Engineering | ==== eCommerce for the Rest of Us ====Pacific Coast Software | WebCatalog, WebMerchant,11770 Bernardo Plaza Court | SiteEdit Pro, PhotoMaster,San Diego, CA 92128 | Typhoon619/675-1106 Fax: 619/675-0372 | http://www.smithmicro.com/
Grant Hulbert
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:
Need relative path explanation (1997)
webcat2b12 CGI -- Date comparisons (1997)
.htaccess to make WebDNA serve HTML (2007)
Stats (2004)
OFF-TOPIC: Lending investors ... (2002)
Keep away (1997)
Correct Linux Version for WC 6 (2006)
Semi OT: IE losing info from forms when back button is used (2005)
RE: incrementing a counter remotely? (1999)
WC2f3 (1997)
Version Question (2000)
'does not contain' operator needed ... (1997)
[group] ? (1997)
Out of the woodwork (2007)
How to redirect based on price subtotal? (1998)
AOL (1999)
minimalist shopping cart. (1997)
# fields limited? (1997)
a new bug? (1999)
For you expert WebDNA coders (was Interesting speed (2003)