<xificurC>
Regenaxer: if you remember the discussion of filling in the DB with data :) curl says curl: (52) Empty reply from server. The data gets uploaded but curl exits with 52
<beneroth>
there is a global variable holding the http status code, I believe you can set it
<Regenaxer>
yes, there is (respond)
<xificurC>
grr no doc
<Regenaxer>
:)
<Regenaxer>
(pp 'respond) ;)
<xificurC>
:)
<xificurC>
I think 204 would be most clean here
<xificurC>
but (respond "") might do the trick
<beneroth>
Regenaxer, german retailer Lidl spent 7 years and about half a billion Euros attempting to get SAP working, now the cancelled the project in favour of continuing their internally developed ERP (which SAP was supposed to replace)
<xificurC>
so a +ListTextField could be used for people to write "A B C" and search for (and A B C)
<xificurC>
sorry for jumping around, reading docs as we go :)
<Regenaxer>
yes, but the Pilog query must handle this
<Regenaxer>
For fixed number Pilog is simple
<Regenaxer>
select handles +List automatically
<Regenaxer>
So you need just eg 3 filter clauses for 3 search fields
<xificurC>
can't the input be saved in *Prjs as '("A" "B" "C") and just have (select (@@) ((prjs +Deploy *Prjs)))?
<xificurC>
I skipped the filter clauses for now
<Regenaxer>
saved in *Prjs as '("A" "B" "C") happens with +ListTextField
<Regenaxer>
but select won't work I think
<Regenaxer>
it needs atomic criteria
<xificurC>
a cons cell is an atom?
<Regenaxer>
ie 3 generators and 3 filters
<Regenaxer>
no, only number or symbol
<xificurC>
but queries often have (nr +Item (1 . 10))
<Regenaxer>
yes, a pair is a range
<Regenaxer>
that's why a list will not work as a criterium
<Regenaxer>
Pilog thinks it is a range
<xificurC>
I'm confused then, that's not an atom and is a criterium
<xificurC>
ah, ok
<Regenaxer>
yeah :)
<xificurC>
thought it might be smart with +Lists
<xificurC>
so if that was to be dynamic I would need to make the query dynamic as well
<xificurC>
build it dynamically
<Regenaxer>
yes
<xificurC>
makes sense, thanks
<Regenaxer>
So taking a fixed number is easier
<Regenaxer>
also in GUI
<Regenaxer>
Perhaps also less confusing to the user
<xificurC>
I will start with 1 and see if there is a use case for more complex queries. Just wanted to know the options :) YAGNI
<Regenaxer>
:)
<xificurC>
with +Ref I can search "foo" for "foobar" but not "bar" for "foobar". +Idx gives me this capability and +Fold folds the string and +IdxFold does an +Idx on a +Fold. Is this all correct?
<Regenaxer>
yes, though the last one first breaks down and then folds iirc
<Regenaxer>
hmm, wait. That's (+Fold +Idx), so you are right
<Regenaxer>
no
<xificurC>
so what's the difference between (+Fold +Idx), (+Idx Fold) and (+IdxFold) ?
<xificurC>
there's an entry for +IdxFold and for +Fold +Idx, none for +Idx +Fold
<Regenaxer>
It shows the use cases, and the matching select filter predicate
<Regenaxer>
ok, so the other makes not much sense for reasons I forgot ;)
<xificurC>
I'm not sure I understand how does +IdxFold match "Regen Axer" and "regenaxer" at the same time
<xificurC>
it's as if both the folded and nonfolded versions are indexed
<Regenaxer>
No, only "Regen" and "Reg" etc, or "Ax..." but also "regena..."
<Regenaxer>
The lists below show the dumps of the indexes
<xificurC>
Item Names
<xificurC>
(+IdxFold +String) part
<xificurC>
("axer" {2}) {2}
<xificurC>
("egen" {2}) {2}
<xificurC>
("Regen Axer" . {2}) {2}
<xificurC>
("regenaxer" {2}) {2}
<xificurC>
("gen" {2}) {2}
<xificurC>
("xer" {2}) {2}
<Regenaxer>
So these are what can be searched
<Regenaxer>
yes
<xificurC>
("Regen Axer" . {2}) {2}
<xificurC>
and then
<xificurC>
("regenaxer" {2}) {2}
<Regenaxer>
Yes
<Regenaxer>
the full text can be found too
<xificurC>
so the full text is an exception?
<Regenaxer>
I find +IdxFold the most intuitive for the user
<xificurC>
findable as non-folded
<Regenaxer>
yes
<Regenaxer>
It is not used in Pilog, but needed for (db ...) and (collect ...)
<Regenaxer>
ie exact accesses
<Regenaxer>
select detects that it needs to fold
<xificurC>
so
<Regenaxer>
so the index is not searched for "Reg...
<xificurC>
what is the difference between (+Fold +Idx) and (+IdxFold)? The examples only differ in the "Regen Axer" search which seems to work as an exception in +IdxFold and won't in (+Fold +Idx)
<Regenaxer>
yes, so +IdxFold is more useful
<Regenaxer>
Normally I don't use (+Fold +Idx)
<Regenaxer>
should perhaps be removed here
<Regenaxer>
But not sure. Makes sense if ("egenaxer" should be found
<Regenaxer>
despit the user entered a blank
<Regenaxer>
I should write a select query generator read macro
<Regenaxer>
They are all following the same patterns meanwhile
<beneroth>
<Regenaxer> I should write a select query generator read macro
<beneroth>
YES
<beneroth>
:D
<Regenaxer>
:)
<Regenaxer>
In the beginning it was not clear to me which combinations turn out useful
<Regenaxer>
Let's see, at the moment I'm too busy
<beneroth>
good business?
<beneroth>
or still fighting with android? :/
<Regenaxer>
Business all
<Regenaxer>
Had meeting with BTG today. Everything green :)
<xificurC>
Regenaxer: +DbHint only works *after* first search, why is that? I land on 8080 and it doesn't work, after first search URI gets rewritten to session port and it starts working
<Regenaxer>
This is not +DbHint, but a JS problem
<Regenaxer>
"Same origin"
<xificurC>
and we forgot on the search-as-you-type functionality, is there a prefix class for that too?
<Regenaxer>
If you need JS already on the first page after (app), you need to rediret
<xificurC>
ok, I can try :)
<Regenaxer>
Normally, the first page is just login
<xificurC>
this is a single page right now, not public (intranet), no need to auth
<xificurC>
and the search-as-you-type? I had a feeling I saw it on youtube when you were presenting somewhere
<Regenaxer>
so XmlHttpRequest thinks it is another server. Stupid!
<xificurC>
it is! :)
pierpal has quit [Quit: Poof]
<Regenaxer>
search-as-you-type for the pop up?
<xificurC>
I mean it is another server! :)
<Regenaxer>
Should work
pierpal has joined #picolisp
<Regenaxer>
Well, IP address is the same
<xificurC>
no, I mean each character typed in any of the search fields automatically fires the search that searchButton does
<Regenaxer>
Another port on the same server is another server? ;)
<xificurC>
so the user doesn't click on a Search button, just types and sees the results live
<xificurC>
on small db it is a nice feature :)
<Regenaxer>
Ah, no, this might be too heavy
<xificurC>
well another port can easily be another application (daemon)
<Regenaxer>
yes, application, but not server
<Regenaxer>
I think you could implement search-as-you-type
<Regenaxer>
The search button needs to be +JS then
<Regenaxer>
not sure
<Regenaxer>
You could try
<xificurC>
ok, as usual thanks for the tips and time
<Regenaxer>
np :)
<Regenaxer>
I never thought about this kind of immediate search, but what is important is that the Search button is always the first button in the dialog
<Regenaxer>
In this way Return starts the search
<Regenaxer>
I feel that better than an automatic search. Just hit Enter
pierpal has quit [Quit: Poof]
pierpal has joined #picolisp
rob_w has quit [Remote host closed the connection]
<xificurC>
interactivity is the heart of simplicity :) It's a continuation of +DbHint if you think about it from a broader perspective
* xificurC
thinks
<Regenaxer>
True, I just fear that fast typing is hindered due to permanent refreshes of the chart contents
<xificurC>
maybe. Personally, given infinite knowledge in this, I would somehow force the search to only happen after 100ms of inactivity