Subject: | Re: Converter Update
| Date: | Tue, 3 Jul 2018 01:52:28 +1000
| From: | Bernie van't Hof <berniev@bje.com.au>
| Newsgroups: | pnews.paradox-dos
|
Mike,
Not a problem.
Your approach uses standard PAL MENU {Ask} ... (in your case generated by QBE_2_PAL) to create
query images and populate
them using PAL, as opposed to a QUERY/ENDQUERY text block getting parsed into a set of prefilled
query images.
Query images are based on their underlying tables and provide structural information necessary
for query construction
and validation. As an aside, this means QUERY/ENDQUERY text cannot be reliably converted directly
to SQL outside the
database environment.
QUERY/ENDQUERY is not necessarily immediately followed by Do_It! Query images can be modified
by PAL in the mean-time,
in much the same way as an editable table image.
At Do_It! the query is generated and executed.
Either method is supported by the converter. Its all just basic PAL. Most of the complxity is
not in the initial
parsing, its in the parsing of the image data and deciding what to do with it all.
- Bernie
On 2/7/18 9:00 am, Michael Kennedy wrote:
> WOW!!!!
>
> Just one point (that I touched on previously)... I never use the QUERY/ENDQUERY approach,
and I think others did
> likewise - mainly for readability of the PAL code.
>
> Instead:
> 1. I used QBE to build the on-screen query, interactively.
> 2. I then ran that QRY_2_PAL script, to convert the on-screen query to standard PAL
code (see below).
> 3. I then put that PAL code into the main app Script, followed by a DO_IT!, and some
basic checks that the query ran
> successfully.
>
> During execution, that PAL code built the query, just like the QUERY/ENDQUERY approach,
and then the DO_IT! executed it.
>
> So, this is all the converter would see (no QUERY/ENDQUERY syntax):
>
> MENU {Ask} SELECT Trans_01_Tmp
> [Account No] = "_ac1"
> [Year End Date] = "_yr1"
> [Run Batches] = "Y"
> [Business Typ] = "F or B"
> MENU {Ask} SELECT Trans_51_Tmp
> MOVETO [Account No] "_ac1" CHECKPLUS
> MOVETO [Year End Date] "_yr1" CHECKPLUS
> [Bank Code] = "Blank or 0"
> [Lodgement] = "_am1,calc 0-_am1 as Amt"
> Do_It! Qry_is_Ok("C18") Add "Answer" Temp_1 Delete "Answer" ClearAll
>
> - Mike
>
>
> On 01/07/2018 18:43, Bernie van't Hof wrote:
>> Still nibbling away ..
>> Some changes have been made after recent discussions (thank you).
>> Github updated. Most changes around:
>> pdox/converter/qbeQuery/toSql/Query.php
>> pdox/converter/qbeQuery/PalQuery.php
>> Feedback welcome!
|