Re: Moving records

This WebDNA talk-list message is from

2000


It keeps the original formatting.
numero = 28601
interpreted = N
texte = > >Is there any easier way to move a record in databaseA.db to > >databaseB.db without, > >1) Doing a search > >2) Doing an append > >3) Doing a delete > >No, that's how you have to do it. > > > >This is painful as I have to specify the fieldnames, as there is no > >way to link [ListFields DatabaseName] to a founditems context. > >Yes there is! Assuming the field names in both db's are the same, >and if you are moving only one record, you can do the following: > >[search db=thisDB&...&max=1] >[founditems] >[append db=otherDB] >[listfields thisDB(or otherDB)] >[fieldname]=[interpret][[fieldname]][/interpret]& >[/listfields] >[/append] >[delete db=thisDB&eqskudata=[sku]] >[/founditems] >[/search] > >Just remember, if you need to retrieve more than one record, you >must move the delete tag outside the founditems context and use a >different technique for the deleting records from thisDB ... :) Thanks for that Ken. I never thought of the [Interpert] tag.Micheal O Shea Email:micheal@com4u.ch com4u.ch http://www.com4u.ch Breitistrasse 7B PGP key available upon request. CH-5506 Maegenwil Tel: +41 62 896 46 26 Switzerland------------------------------------------------------------- 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 Associated Messages, from the most recent to the oldest:

    
  1. Re: Moving records (Michael O Shea 2000)
  2. Re: Moving records (Kenneth Grome 2000)
  3. Moving records (Michael O Shea 2000)
> >Is there any easier way to move a record in databaseA.db to > >databaseB.db without, > >1) Doing a search > >2) Doing an append > >3) Doing a delete > >No, that's how you have to do it. > > > >This is painful as I have to specify the fieldnames, as there is no > >way to link [ListFields DatabaseName] to a founditems context. > >Yes there is! Assuming the field names in both db's are the same, >and if you are moving only one record, you can do the following: > >[search db=thisDB&...&max=1] >[founditems] >[append db=otherDB] >[listfields thisDB(or otherDB)] >[fieldname]=[interpret][[fieldname]][/interpret]& >[/listfields] >[/append] >[delete db=thisDB&eqskudata=[sku]] >[/founditems] >[/search] > >Just remember, if you need to retrieve more than one record, you >must move the delete tag outside the founditems context and use a >different technique for the deleting records from thisDB ... :) Thanks for that Ken. I never thought of the [Interpert] tag.Micheal O Shea Email:micheal@com4u.ch com4u.ch http://www.com4u.ch Breitistrasse 7B PGP key available upon request. CH-5506 Maegenwil Tel: +41 62 896 46 26 Switzerland------------------------------------------------------------- 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 Michael O Shea

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:

Three new problems, maybe a fourth (1997) New commands in Final candidate (1997) Need relative path explanation (1997) Digest Version (2000) Emailer 1.0.2 Conflicts? (1998) Not seeing cart info on Invoice.tmpl (was PROBLEM) (1997) Setting up shop (1997) _ in front of field name (1998) [WebDNA] Calculate Cube root (2012) username/password dialogue (2001) Dedicated hosting recommendations (2000) webcat2b12 CGI -- Date comparisons (1997) Protect tag for large groups? (1999) Looking for a host (1997) WebCat2b13MacPlugIn - [shownext method=post] ??? (1997) MacWEEK article help needed (1996) OT: Hello to the list (2004) Extended [ConvertChars] (1997) Webcat 3 Bug?!?! Netscape + Protect + Posted Form (1998) [Announce]: Web server security and password protection (1997)