dbTalk Databases Forums  

In Reality

comp.databases.pick comp.databases.pick


Discuss In Reality in the comp.databases.pick forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Mike Preece
 
Posts: n/a

Default In Reality - 04-05-2011 , 09:45 AM






I just noticed you can use the right square bracket as an "any number
of wildcard characters" wildcard character.... as in...

SELECT MYFILE = "]*]*]"

This will return a list of all item-ids containing two or more "*"'s
anywhere in the id.

Handy.

Do any flavours other than Reality have this capability?

Reply With Quote
  #2  
Old   
Mike Preece
 
Posts: n/a

Default Re: In Reality - 04-05-2011 , 10:20 AM






On Apr 5, 3:45*pm, Mike Preece <mich... (AT) preece (DOT) net> wrote:
Quote:
I just noticed you can use the right square bracket as an "any number
of wildcard characters" wildcard character.... as in...

SELECT MYFILE = "]*]*]"

This will return a list of all item-ids containing two or more "*"'s
anywhere in the id.

Handy.

Do any flavours other than Reality have this capability?
....or, to put it more simply, you can use a right square bracket on
its own as a wild-string...

SELECT MYFILE = "J]SON"

would return JOHNSON, JEFFERSON, JASON, etc., etc..

Reply With Quote
  #3  
Old   
Scott Ballinger
 
Posts: n/a

Default Re: In Reality - 04-05-2011 , 11:04 AM



On Apr 5, 8:20*am, Mike Preece <mich... (AT) preece (DOT) net> wrote:
Quote:
SELECT MYFILE = "J]SON"
would return JOHNSON, JEFFERSON, JASON, etc., etc..
This does not seem to work on D3:

:list only myfile eq 666]0

myfile...
6666804
6666805
6666806
6666807
6666808
6666809
6666810 <-- this is the one I wanted
6666811
6666812
6666813
6666814
6666815
6666816
6666817
6666818
6666819
6666820 <-- and this one
6666821
6666822
6666823

Guess you just have to do it the regular way:

:list only myfile eq 666] and eq [0

myfile...

6666810
6666820
6666830
6666840
6666850
6666860
6666870
6666880
6666890
6666900
6666910
6666920
6666930
6666940
6666950
6666960
6666970
6666980
6666990
6667000

Anyone care to post results from other flavors?

/Scott Ballinger
Pareto Corporation
Edmonds WA USA
206 713 6006

p.s. Note how those sequential numeric ids are hashed

Reply With Quote
  #4  
Old   
Steve Douglas
 
Posts: n/a

Default Re: In Reality - 04-05-2011 , 11:05 AM



D3 seems to ignore anything after the ]. So your example on my system returns

JULIANA
JODRIE
JIMENEZ-ALTO
JANUK
JESSUP
JULIANO
JARQUIN
etc....

Reply With Quote
  #5  
Old   
Tony Gravagno
 
Posts: n/a

Default Re: In Reality - 04-06-2011 , 01:01 AM



Steve Douglas wrote:
Quote:
D3 seems to ignore anything after the ].
Indeed, the R83 manual says "Any characters which may occur after a
']' will never be inspected." That has always been my understanding
and I would have never tried to see what happens otherwise.

That said, I've always defined the close bracket as meaning "I don't
care what comes after this". So the text "J]SON" means:
- Must start with a J.
- I don't care what comes after this
- Must end in "SON" because those are the characters I've set in the
last three positions.

The third spec could be taken to override the first, so Jepsen would
match the first two specs but not the third.

The functionality seems logical but I think we need to fall back on
defined behavior no matter how logical observed behavior seems to be.
These days, is deviation from R83 a product-differentiating feature,
or is it a bug? I think it's up to the product-specific manual. If a
DBMS manual does not explicitly define the behavior as a feature, then
it's a bug until the document includes it and functionality is
verified through proper QA testing.

With that in mind, my Reality v14.0.3 doc does not include mention of
brackets at all with regard to the English commandline. That document
refers to the Reality v7.x Beginner's Guide to ENGLISH, which seems to
agree with the R83 base.

So until we hear otherwise, I'd say Mike has found a bug which just
happens to look like it returns some useful results. Someone at
Northgate could easily claim from a Marketing perspective that this is
a feature. I'd like an evaluation to come from a Northgate Engineer
(even if posted by someone from Marketing). And then I would ask them
to file a request for a doc update.

T

Reply With Quote
  #6  
Old   
Mike Preece
 
Posts: n/a

Default Re: In Reality - 04-06-2011 , 08:00 AM



On Apr 6, 7:01*am, Tony Gravagno <tony_grava... (AT) nospam (DOT) invalid> wrote:
Quote:
Steve Douglas wrote:
D3 seems to ignore anything after the ].

Indeed, the R83 manual says "Any characters which may occur after a
']' will never be inspected." *That has always been my understanding
and I would have never tried to see what happens otherwise.

That said, I've always defined the close bracket as meaning "I don't
care what comes after this". *So the text "J]SON" means:
- Must start with a J.
- I don't care what comes after this
- Must end in "SON" because those are the characters I've set in the
last three positions.

The third spec could be taken to override the first, so Jepsen would
match the first two specs but not the third.

The functionality seems logical but I think we need to fall back on
defined behavior no matter how logical observed behavior seems to be.
These days, is deviation from R83 a product-differentiating feature,
or is it a bug? *I think it's up to the product-specific manual. *If a
DBMS manual does not explicitly define the behavior as a feature, then
it's a bug until the document includes it and functionality is
verified through proper QA testing.

With that in mind, my Reality v14.0.3 doc does not include mention of
brackets at all with regard to the English commandline. That document
refers to the Reality v7.x Beginner's Guide to ENGLISH, which seems to
agree with the R83 base.

So until we hear otherwise, I'd say Mike has found a bug which just
happens to look like it returns some useful results. *Someone at
Northgate could easily claim from a Marketing perspective that this is
a feature. *I'd like an evaluation to come from a Northgate Engineer
(even if posted by someone from Marketing). *And then I would ask them
to file a request for a doc update. *

T
Hi Tony,

Check under English Reference > The English Sentence > Item Lists >
Value Strings

Let me know if you find this:-

Right ignore/wild string (]), at the end to indicate that the item-id
may end with any characters (for example, 'Johan]'), or within the
string to indicate any number of intervening characters (for example,
'J]son').

Cheers,
Mike.

Reply With Quote
  #7  
Old   
Tony Gravagno
 
Posts: n/a

Default Re: In Reality - 04-06-2011 , 11:49 AM



Mike Preece wrote:
Quote:
Hi Tony,

Check under English Reference
The English Sentence > Item Lists
Value Strings
Yeah, found it, thanks. In my quick search yesterday I skipped the
topic Item Lists thinking that it was about save-lists. Silly me.
The index doesn't include the words 'bracket' or 'caret' for this
section.

OK, it's documented. Cool. Thanks for the tip!
T


"But Mr Dent, the plans have been available in the local planning
office for the last nine months."

"Oh yes, well as soon as I heard I went straight round to see them,
yesterday afternoon. You hadn't exactly gone out of your way to call
attention to them, had you? I mean, like actually telling anybody or
anything."

"But the plans were on display ..."

"On display? I eventually had to go down to the cellar to find them."

"That's the display department."

"With a flashlight."

"Ah, well the lights had probably gone."

"So had the stairs."

"But look, you found the notice didn't you?"

"Yes," said Arthur, "yes I did. It was on display in the bottom of a
locked filing cabinet stuck in a disused lavatory with a sign on the
door saying 'Beware of the Leopard'."

--HHGTTG

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.