ComparativeAQL update

150 views
Skip to first unread message

Tony Gravagno

unread,
Jun 13, 2018, 4:02:41 PM6/13/18
to Pick and MultiValue Databases
I've updated the software and documentation for my FOSS4MV which facilitates AQL queries that compare fields.
Examples:

CLIST ORDERS WITH SHIP.STATE = CUSTOMER.STATE
CSELECT VENDORS WITH CONTACT NOT OWNER
CSORT-LABEL CUSTOMERS WITH SALES.THIS.MONTH > SALES.MONTHLY.AVERAGE

This was written for D3, mvBase, and other (?) R83-based platforms that don't natively support that syntax.
It's been tested on D3v9+ and mvBase 1.2+.
I believe some PI-based systems and flavors do support this, so don't need it. (Which ones?)


With this update, many enhancements were made as seen in the wiki, and the software can now easily be modified to support different platforms. Peer review and QA would be appreciated.

I'm hoping to see:
1) Some usage of this very useful freeware.
2) Feedback to the Issues tracker for enhancements and issues.
3) Contributions to improve upon it.
4) Enhancements or documentation to support other platforms.
5) Suggestions for improving the documentation.
6) Basic Q&A.
7) More usage of any and all of the other software in the FOSS4MV repository.
8) Rocket Software add this into D3?

If you do have any intent to contribute to the software, please follow a general guideline for all FOSS: Create a ticket first, and get confirmation that no one else is doing the same thing and that your suggestion is desirable. Such a confirmation will save you from submitting a pull request that isn't accepted for various reasons - leading to hard feelings, forks, confusion, dissent, and other unnecessary complications.

Thanks!
T

Peter McMurray

unread,
Jun 16, 2018, 8:23:25 PM6/16/18
to Pick and MultiValue Databases
Thanks TG will view with interest

Tony Gravagno

unread,
Jul 11, 2018, 9:11:37 PM7/11/18
to Pick and MultiValue Databases
I'm curious why there was no interest in ComparativeAQL, or anything else posted at FOSS4MV. Not through conceit, but knowing what we as MV developers value, I'd think ComparativeAQL would be eagerly investigated by folks here.

Does this industry (in general) shun FOSS because people only trust what they themselves write?

Is this an example of aversion to new tools in general? We see that new D3 features get relatively no mention in these MV groups (like @vars, OSFI, EVAL/FMT, MVSP, MVST, etc), can we assume that the traditional D3 developer really just wants to keep their system as R83-compatible as possible, at least until they migrate elsewhere?

To those who look at this stuff over the years and then just look away, I'm really hoping you can share some insight into why that happens. This isn't just about one utility or platform. This is a paradigm that's remained with us for decades: FOSS4MV, PickWiki, PickSource, mvDevCentral...

Should we resign ourselves to the notion that traditional MV developers are simply not interested in FOSS so that we can try to focus exclusively on a new generation?

Thanks.
T

Dick Thiot

unread,
Jul 11, 2018, 9:30:59 PM7/11/18
to mvd...@googlegroups.com
Tony,

I think that the recent interest in the Visual Studio Code extension by Grant Hart is evidence that not everyone is stuck in an R83 mode.  I know developers that only know what they learned many years ago and they use that core knowledge to maintain whatever system they work on.  However, there is another group that has adopted new technologies and integrated those into the tools that they use and also the applications that they develop.  For years, my Spectrum Conference sessions have all been on more modern technologies and tools and integration with MultiValue databases.  I think that there are a lot of sites that now use some for of integration with an API.  I encounter it at most of the sites that I deal with.  

However, I have recently been speaking on the topic of developers and whether they are expanding their skill set or at stagnant in the past.  At Spectrum, I called this session "Are You A Dinosaur".  it was a fun and lively discussion.  The bottom line is that for some, being a dinosaur is OK and they are able to do their job.  However, there are others that are "Senior MultiValue Developers" (I don't like using the word old) that work at learning new technologies.  For many this is a significant task.

My bottom line is that not everyone fits into a single stereotype.  I am not sure why your ComparativeAQL submission has not had interest shown in it.  It sounds like a tool that would be helpful.  I for one have not needed it yet but have will likely in the future if it is still available get more into it at the point and time that I need to use it.

I hope that helps.

Dick 

--
You received this message because you are subscribed to
the "Pick and MultiValue Databases" group.
To post, email to: mvd...@googlegroups.com
To unsubscribe, email to: mvdbms+un...@googlegroups.com
For more options, visit http://groups.google.com/group/mvdbms

Ian Harper

unread,
Jul 12, 2018, 11:23:30 AM7/12/18
to Pick and MultiValue Databases
For the record, I'm interested and I know I there was a time when I wish I had this tool. I'm keeping it in mind if I ever need to do some comparative AQL in the future. I didn't immediately install it because I wasn't sure if it would clash with anything already in the MD (example: CONV is a program on our machine that will do iconv/oconv. I copied DM,MD, CONV to CONV1 in the accounts that I use to get the AQL functionality).

Martin Phillips

unread,
Jul 12, 2018, 11:40:35 AM7/12/18
to mvd...@googlegroups.com

Just to set the record straight, QM has always supported comparative field references in queries. I was very surprised when this thread started because I had always though that it was in all mv products.

 

 

Martin Phillips
Ladybridge Systems Ltd
17b Coldstream Lane, Hardingstone, Northampton NN4 6DB, England
+44 (0)1604-709200

--

geneb

unread,
Jul 12, 2018, 11:58:30 AM7/12/18
to Pick and MultiValue Databases
On Wed, 11 Jul 2018, Tony Gravagno wrote:

> Does this industry (in general) shun FOSS because people only trust what
> they themselves write?
>
I suspect the root cause is "Pay Me or GTFO" engrained by decades of
painfully expensive per-seat licensing for basically every MV host
platform ever produced. OpenQM is the outlier with reasonable per-seat
costs.

IMHO, the whole per-seat licensing thing needs to die and die quick. Jump
to /reasonable/ per cpu or per server licensing. The only place for
per-seat restrictions should be in (free or token charge and doesn't
expire) developer configurations.

> Should we resign ourselves to the notion that traditional MV developers are
> simply not interested in FOSS so that we can try to focus exclusively on a
> new generation?
>
Focusing on a new generation is good, but there needs to be a way to get
past the Dijkstra BASIC stigma so new devs will quit sneering at the core
language that all MV systems use.

g.


--
Proud owner of F-15C 80-0007
http://www.f15sim.com - The only one of its kind.
http://www.diy-cockpits.org/coll - Go Collimated or Go Home.
Some people collect things for a hobby. Geeks collect hobbies.

ScarletDME - The red hot Data Management Environment
A Multi-Value database for the masses, not the classes.
http://scarlet.deltasoft.com - Get it _today_!

Martyn

unread,
Jul 12, 2018, 12:14:36 PM7/12/18
to Pick and MultiValue Databases
> Jump to /reasonable/ per cpu or per server licensing.

I would be very grateful if you could expand on your thoughts.    What do you mean by per CPU or per server licensing, where you might have 5, 10 or 250 or more users working on a single server.  Are you looking for a single license cover any number of users.  With regards to the CPU license option, I assume you are talking about CPU licensing to limit the license to one license per machine where the machine is used by multiple people??

Bearing in mind that everyone needs to pay the bills. I'm sure you guys don't work for nothing and if you do, you won't be in business for long, likewise the Vendors if they give everything away for free.

How do you license your software?

Revelation have always been fare with their licensing.  The licenses are based on concurrent users, so it is cost effective where people share machines or where someone wants to have multiple licenses for their own use/reasons.  The web licensing uses dynamic licenses, so that one license serves countless people, it's only restricted by how the developer creates the system, process times, etc.  Revelation even provide 3 licenses in their development environment to support development, testing, reporting, etc. etc.

I think that it would be useful to know what you all think is fair to Vendors, VARs and End Users.  Most people just keep asking for free licenses but that will only result in the MV community dying faster.  If the vendors cannot pay the bills, then they will pack up and then where will anyone be.   

Andrew Cole

unread,
Jul 12, 2018, 12:35:22 PM7/12/18
to Pick and MultiValue Databases
This post was before I arrived here but upon seeing it I think I'll be taking a hard look at this. I've been wanting something like this for awhile. On a related note, today I was looking for how to: "SELECT DICT FILE WITH 0 being numeric". I see that OpenQM actually does this with LIKE if I remember correctly. I'd love to see more enhancements to the query system in MV.

Ryengoth

unread,
Jul 12, 2018, 12:40:23 PM7/12/18
to mvd...@googlegroups.com
Your best bet for those kinds of modifications is to use QM and work with Martin to determine the best approach to resolve the immediate issue you have.

Glen

On Thu, Jul 12, 2018 at 12:35 PM Andrew Cole <andrew...@gmail.com> wrote:
This post was before I arrived here but upon seeing it I think I'll be taking a hard look at this. I've been wanting something like this for awhile. On a related note, today I was looking for how to: "SELECT DICT FILE WITH 0 being numeric". I see that OpenQM actually does this with LIKE if I remember correctly. I'd love to see more enhancements to the query system in MV.

--

Andrew Cole

unread,
Jul 12, 2018, 12:52:35 PM7/12/18
to Pick and MultiValue Databases
No, I was lamenting the fact that QM has the feature I want while mvBase (the platform I'm stuck with atm) does not.

Wols Lists

unread,
Jul 12, 2018, 1:27:05 PM7/12/18
to mvd...@googlegroups.com
Does your system have the EVAL keyword? Iirc this goes back to Pr1me
days, so it's very much a Prime-style thing.

Basically, you put an i-descriptor on the command line so you can do
something like

WITH EVAL "ISNUM(@ID)" EQ TRUE

That's why I was slightly surprised to see the comment about comparing
two fields in a query - I would have just used EVAL as a matter of course.

Cheers,
Wol

Tony Gravagno

unread,
Jul 12, 2018, 1:39:52 PM7/12/18
to Pick and MultiValue Databases
On Thursday, July 12, 2018 at 9:35:22 AM UTC-7, Andrew Cole wrote:
On a related note, today I was looking for how to: "SELECT DICT FILE WITH 0 being numeric".



01 S
02 0
08 A;IF 0(MCN) = 0 THEN "1" ELSE ""
09 R
10 1

SELECT DICT FILE WITH NUMERIC.ID

Explanation:
The Master Dictionary defines the Dictionaries above it.
This looks at the ID of a dict item and strips anything that's not numeric.
What's left is only numeric.
If non-numerics have been stripped and the ID hasn't changed, the ID is numeric.

Equivalent F-correlative if the A doesn't work on your system:
08 F;CYES;C1;0(MCN);0;=;[]

Explanation:
Push YES onto the top of the stack. Any random text is ok.
Push the number one above that. This is for a text extraction of 1,x.
Push the ID with numeric-only characters.
Push the full ID.
The = sign compares the next two values, pops them off, returns a 1 or 0.
With other values popped we're back the the result from above and "1" after that.
The [] substring operation is the equivalent to v3[v2,v1], which in this case is "YES"[1,x], where x is either 0 or 1.
If 0 then the substring returns "". If 1, the substring returns the non-null value of "Y".

So:
LIST DICT FOO WITH NUMERIC.ID
or
LIST.DICT FOO WITHOUT NUMERIC.ID

This works on data files too, as the MD also defines data files unless a dict item overrides the definition:
LIST CUSTOMERS WITH NUMERIC.ID

HTH
T

Tony Gravagno

unread,
Jul 12, 2018, 1:45:02 PM7/12/18
to Pick and MultiValue Databases
For Wol, Martin, and others, R83>AP>D3 has never had the feature, and to my knowledge none of the other R8x-derivatives have either (ADDS>mvBase, Reality) which is why I wrote that utility.
mvBase does not support I-TYPES or Eval.
D3 now supports Eval but only for processing codes (conv/corr) in the command line, not BASIC syntax.
mvBase is reportedly inheriting D3 features but not yet.

geneb

unread,
Jul 12, 2018, 2:01:09 PM7/12/18
to Pick and MultiValue Databases
On Thu, 12 Jul 2018, Martyn wrote:

>> Jump to /reasonable/ per cpu or per server licensing.
>
> I would be very grateful if you could expand on your thoughts. What do
> you mean by per CPU or per server licensing, where you might have 5, 10 or
> 250 or more users working on a single server. Are you looking for a single
> license cover any number of users. With regards to the CPU license option,
> I assume you are talking about CPU licensing to limit the license to one
> license per machine where the machine is used by multiple people??
>
I don't know that it would make sense for OI to use a per service license
as it's a desktop application, isn't it? (Note that the last time I
saw OI was pre-1.0 and I recall little about it. I was a huge fan of
Advanced Revelation though - I even wrote some C code that would allow
you to access EMS from within R/BASIC, but there didn't seem to be much
interest in it so I dropped it.)

Does OI have a dedicated server component to it?

> Bearing in mind that everyone needs to pay the bills. I'm sure you guys
> don't work for nothing and if you do, you won't be in business for long,
> likewise the Vendors if they give everything away for free.
>
I view products like OpenQM, jBASE, D3, etc. as server-bound developer
platforms. If Jonny Dev writes an accounting package that runs atop an MV
system, then a per-user license fee would make sense.

> How do you license your software?
>
I don't - I do D3 & Windows development for a manufacturing company. It's
all internal consumption. I don't write anything for resale.

> I think that it would be useful to know what you all think is fair to
> Vendors, VARs and End Users. Most people just keep asking for free
> licenses but that will only result in the MV community dying faster. If
> the vendors cannot pay the bills, then they will pack up and then where
> will anyone be.
>

It pains me to say this, but for server-centric products it might make
sense to look at how SQL server is licensed. You have the option of per
server+CAL licensing, or per core. Server+CAL makes sense only up to a
small # of users, after that it's more cost effective for the
customer to purchase per-core licenses. I found this that illustrates
their cost structure a bit (very simplistic example)
http://www.mirazon.com/how-is-sql-server-2016-licensed-part-1-the-basics/

Compare that to what D3 currently costs per seat, which is around $600.
My largest plant has 130 seats, which works out to $78k. If they had a
per-core fee structure available (and for this example, priced the same as
SQL Server 2016 Std), I could license 8 cores for around $30k and not have
to worry about how many people I have connected to the system and not have
to play any "pooling" games.

Now the pricing structure probably doesn't matter to big companies with
deep pockets, but in order for MV to accumulate a bigger user base, it
needs to be attractive to the small & medium sized companies that don't
have those deep pockets. The assumption here is that the little companies
will eventually become big companies. Those larger companies can
influence what other companies use for their infrastructure needs, and
that's how the MV market can be grown.

Now per-seat licensing doesn't have to be as painful as the D3 example -
OpenQM charges something around $120 (I _think_) per seat, which means you
can have around 63 seats before you hit the SQL server example cost. That
kind of fee structure is perfectly fine for small companies that
realistically may not have a need for 63 seats (or even half that).

I think one of the issues is that MV can be targeted at two vastly
different customer types. Customers like myself that are doing
internal-only systems to support the business and customers that are
building a product for resale around MV. The retail customer is going to
be vastly more cost concious on a per-seat basis because that cost has the
potential to carve out from what they can charge for software that THEY
created. I don't see marketing efforts that specifically target either
one of those categories. (Realistically, I don't think I've ever seen any
MV marketing in the ouside world. Advertising cars to the people that
already have that car isn't going to help you much. :) )

Holy crap, that got long winded. I'm going to put on my asbestos
underwear on and go back to my cave. ;)

Steve Trimble

unread,
Jul 13, 2018, 8:04:27 AM7/13/18
to mvd...@googlegroups.com
Tony - couldn't you write a program called by the DICT record in D3/mvBASE ? I use this option quite a bit since I'm more experienced in BASIC than I am with DICT oriented solutions.
I think Andrew can do this in mvBASE as well. Not sure though. It's been a while since I've been on mvBASE. I really love QM.

just thinking out loud.
Computerized Data Mgmt Inc
Steve Trimble
(501) 615-8674 office
(501) 772-3450 cell / text


Tony Gravagno

unread,
Jul 13, 2018, 2:00:23 PM7/13/18
to Pick and MultiValue Databases
Steve, I'm not understanding which part of this has your attention.
If I understand your suggestion, do you mean doing something like this: (not syntactically valid)

08 A;IF 0(CALL COMPARE("F1","F2) THEN 1 ELSE 0

That relies on new dict items for users to reference, whereas ComparativeAQL uses existing dict items.
It also precludes native syntax like "WITH PRICE < COST".

Actually, within the program there IS a dict item being created.

So the only unusual aspect of this utility is that it creates a bunch of new verbs, for anyone who wants to use the functionality.
To get the functionality with existing verbs, (needs to be tested!) one could replace the native verbs with a catalog pointer to the C-equivalent. So LIST becomes a catalog pointer to CLIST.

Any help?

Still not understanding your drift, I'm wondering ... this is already a solution for D3 and mvBase, why is there a need to create another approach?

Thanks.
T
Reply all
Reply to author
Forward
0 new messages