Re: Updating Prices in Online Database

This WebDNA talk-list message is from

1999


It keeps the original formatting.
numero = 23466
interpreted = N
texte = OK, I tried the following and it still did not work:[showif [dbpassword]=MIKE] [search db=newcatalog.db&neskudatarq=[blank]&max=8000] [FoundItems] [Replace db=catalogtest.db&sku=[sku]]price=[Price][/Replace] [/FoundItems] [numFound] - records have been updated[/search] [/showif] [showif [dbpassword]!MIKE] Sorry, that password is not valid [/showif]Do I need to give the databases different field names for price (for example, my permanent database would have the field PRICE and the temporary database would have the field NEWPRICE). If so, would I need to do the same with the SKU field?Thanks for your help (Gil and Ken)Kenneth Grome wrote:> Yes, you are doing two thing incorrectly that I can see offhand. (1) The replace context has an extra ending brackets and an extraneous space after the word price, both of these characters should be removed. (2) The replace context fails to identify which record you want replaced, because you have not defined which record it should replace. Try writing your [replace] tag like this: > > [Replace db=catalogtest.db&sku=[sku]]price=[newPrice][/Replace] > > This assumes your catalogtest.db has a sku field as a unique record identifier. > > Sincerely, > Ken Grome Associated Messages, from the most recent to the oldest:

    
  1. Re: Updating Prices in Online Database (Kenneth Grome 1999)
  2. Re: Updating Prices in Online Database (Mike Eberly 1999)
  3. Re: Updating Prices in Online Database (Kenneth Grome 1999)
  4. Re: Updating Prices in Online Database (Gil Poulsen 1999)
  5. Re: Updating Prices in Online Database (Mike Eberly 1999)
  6. Re: Updating Prices in Online Database (Mike Eberly 1999)
  7. Re: Updating Prices in Online Database (Carlos Machado 1999)
  8. Re: Updating Prices in Online Database (PCS Technical Support 1999)
  9. Re: Updating Prices in Online Database (Carlos Machado 1999)
  10. Re: Updating Prices in Online Database (Gil Poulsen 1999)
  11. Re: Updating Prices in Online Database (The Mooseman 1999)
  12. Re: Updating Prices in Online Database (Nitai 1999)
  13. Re: Updating Prices in Online Database (Mike Eberly 1999)
  14. Re: Updating Prices in Online Database (Gil Poulsen 1999)
  15. Updating Prices in Online Database (Mike Eberly 1999)
OK, I tried the following and it still did not work:[showif [dbpassword]=MIKE] [search db=newcatalog.db&neskudatarq=[blank]&max=8000] [founditems] [Replace db=catalogtest.db&sku=[sku]]price=[Price][/Replace] [/FoundItems] [numFound] - records have been updated[/search] [/showif] [showif [dbpassword]!MIKE] Sorry, that password is not valid [/showif]Do I need to give the databases different field names for price (for example, my permanent database would have the field PRICE and the temporary database would have the field NEWPRICE). If so, would I need to do the same with the SKU field?Thanks for your help (Gil and Ken)Kenneth Grome wrote:> Yes, you are doing two thing incorrectly that I can see offhand. (1) The replace context has an extra ending brackets and an extraneous space after the word price, both of these characters should be removed. (2) The replace context fails to identify which record you want replaced, because you have not defined which record it should replace. Try writing your [replace] tag like this: > > [Replace db=catalogtest.db&sku=[sku]]price=[newPrice][/Replace] > > This assumes your catalogtest.db has a sku field as a unique record identifier. > > Sincerely, > Ken Grome Mike Eberly

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:

Moment of Thanks (1997) WebSite and *NO* Authentication Dialog Box!!? (1998) [WebDNA] A new popuated field to a DB with 700.000 records (2009) [WebDNA] [OT] hello (2012) Database Security (1998) PCS Frames (1997) AE aware WebCatalog.acgi? (1997) Possible Bug in 2.0b15.acgi (1997) writing db to disk (1997) [WebDNA] Subtotal of SKU's that begin with ... (2009) Nesting Search Within Tag? (1997) For those of you not on the WebCatalog Beta... (1997) AOL and webcat (1998) [HIDEIF] inside [FOUNDITEM] (1997) textarea to page display (1998) I've got a Bad Case of the DreadedÊÊÊÊs! Hel (2002) RE: Subtotal help (1997) [SearchString] usage (1997) Hiding HTML and breaking the page (1997) WebCat2 several catalogs? (1997)