Thread: Need help with an UPDATE QUERY
02-21-03, 13:27 #1Registered User
- Join Date
- Feb 2003
Unanswered: Need help with an UPDATE QUERY
Version: Corel Paradox 8
Personal Background: I have a few years of experience programming on client-side applications and SQL DBs, however I am new to Corel Paradox and I need help.
I am trying to enhance a script file that is part of an existing application. I need to update one table based upon data in another table. In particular, I need to update an Alpha field in a table with the string equivalent of a date field in another table. The goal is to have the date value stored as a string in YYYYMMDD format.
Below I have provided a snippet of the code. My quess is that format() is not accessible in a query.
Thank you in advance,
qry = query
Table1.db | T1Col1 | T1Col2 |
| _join1 | _T1Col2 |
Table2.db | T2Col1 | T2Col2 |
| _join1 | .., changeto format("DY3M2D2O(%y%m%d)", _T1Col2) |
08-27-03, 18:04 #2Registered User
- Join Date
- Aug 2003
- Bologna - Italy
You can do it by two queries:
With the first one you translate the date to three alpha fields using the Year() Month() Day() functions, then use another query to bring them together in one string, or even do it in one pass...The only failure is not trying to do it.