Rocksolid Light

Welcome to RetroBBS

mail  files  register  newsreader  groups  login

Message-ID:  

Every little picofarad has a nanohenry all its own. -- Don Vonada


devel / comp.lang.xharbour / SKIP +1000 and SKIP -1000

SubjectAuthor
* SKIP +1000 and SKIP -1000Marco Boschi
`* Re: SKIP +1000 and SKIP -1000dlzc
 `* Re: SKIP +1000 and SKIP -1000Claudio H
  `* Re: SKIP +1000 and SKIP -1000Marco Boschi
   `* Re: SKIP +1000 and SKIP -1000dlzc
    `- Re: SKIP +1000 and SKIP -1000Marco Boschi

1
SKIP +1000 and SKIP -1000

<258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=16746&group=comp.lang.xharbour#16746

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:ad4:530b:: with SMTP id y11mr15452131qvr.36.1628066541364; Wed, 04 Aug 2021 01:42:21 -0700 (PDT)
X-Received: by 2002:a37:46cc:: with SMTP id t195mr25487318qka.57.1628066541096; Wed, 04 Aug 2021 01:42:21 -0700 (PDT)
Path: i2pn2.org!i2pn.org!aioe.org!feeder1.feed.usenet.farm!feed.usenet.farm!tr3.eu1.usenetexpress.com!feeder.usenetexpress.com!tr1.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.xharbour
Date: Wed, 4 Aug 2021 01:42:20 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=217.194.186.242; posting-account=_oyAawkAAAAkDmcMkD9UQrwxJqiaol5l
NNTP-Posting-Host: 217.194.186.242
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com>
Subject: SKIP +1000 and SKIP -1000
From: info@marcoboschi.it (Marco Boschi)
Injection-Date: Wed, 04 Aug 2021 08:42:21 +0000
Content-Type: text/plain; charset="UTF-8"
Lines: 6
 by: Marco Boschi - Wed, 4 Aug 2021 08:42 UTC

Hi,
how does the SKIP command works?
In a LAN using DBFCDX If I Open a table of 68000 records (123 mb dbf 2 mb fpt and 11 mb cdx files) if I skip +1 or -1 it's fast. If I SKIP +1000 and SKIP -1000 it takes 2 seconds. If I SKIP 9000 or SKIP -9000 it takes 20 seconds.
How does the SKIP command works?

Many thanks

Re: SKIP +1000 and SKIP -1000

<c8426cd2-83f7-44fc-90e9-793d20400eb9n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=16749&group=comp.lang.xharbour#16749

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:a37:8242:: with SMTP id e63mr26499286qkd.294.1628088735369; Wed, 04 Aug 2021 07:52:15 -0700 (PDT)
X-Received: by 2002:aed:304c:: with SMTP id 70mr38114qte.2.1628088735177; Wed, 04 Aug 2021 07:52:15 -0700 (PDT)
Path: i2pn2.org!i2pn.org!aioe.org!news.uzoreto.com!tr3.eu1.usenetexpress.com!feeder.usenetexpress.com!tr1.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.xharbour
Date: Wed, 4 Aug 2021 07:52:15 -0700 (PDT)
In-Reply-To: <258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=68.107.209.13; posting-account=7bF0GwoAAABMFHX6V4fON4-1F6LFJ834
NNTP-Posting-Host: 68.107.209.13
References: <258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <c8426cd2-83f7-44fc-90e9-793d20400eb9n@googlegroups.com>
Subject: Re: SKIP +1000 and SKIP -1000
From: dlzc1@cox.net (dlzc)
Injection-Date: Wed, 04 Aug 2021 14:52:15 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 25
 by: dlzc - Wed, 4 Aug 2021 14:52 UTC

Dear Marco Boschi:

On Wednesday, August 4, 2021 at 1:42:22 AM UTC-7, Marco Boschi wrote:
> Hi,
> In a LAN using DBFCDX If I Open a table of 68000 records
> (123 mb dbf 2 mb fpt and 11 mb cdx files) if I skip +1 or -1
> it's fast.

It is finding its position in the index, then moving up or down one record.

> If I SKIP +1000 and SKIP -1000 it takes 2 seconds. If I SKIP 9000 or
> SKIP -9000 it takes 20 seconds.
> How does the SKIP command works?

I'd think it is getting "confused" by the indexes you have open, and filters you have in effect. What happens if you "SET ORDER TO" and "SET FILTER TO" with no argument, so that it can just use the record pointer? So it is likely moving record-by-record, through the index, in current index order. Pumping the data off the server, to your computer to perform the logic, and repeating 1000 or 9000 times.

Here are some options: https://www.itlnet.net/programming/program/Reference/c53g01c/ngf31ef.html
dbgoto(recno()-1000) ... should be pretty fast.

David A. Smith

Re: SKIP +1000 and SKIP -1000

<ef3f2432-3d3b-4c96-9760-a41a42ea339dn@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=16752&group=comp.lang.xharbour#16752

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:a05:6214:5199:: with SMTP id kl25mr515476qvb.12.1628096305014;
Wed, 04 Aug 2021 09:58:25 -0700 (PDT)
X-Received: by 2002:a05:6214:19e2:: with SMTP id q2mr362919qvc.15.1628096304686;
Wed, 04 Aug 2021 09:58:24 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.xharbour
Date: Wed, 4 Aug 2021 09:58:24 -0700 (PDT)
In-Reply-To: <c8426cd2-83f7-44fc-90e9-793d20400eb9n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=181.47.6.188; posting-account=HpimJAoAAAB9g4YwFxxrm8_5y018T6ul
NNTP-Posting-Host: 181.47.6.188
References: <258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com> <c8426cd2-83f7-44fc-90e9-793d20400eb9n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <ef3f2432-3d3b-4c96-9760-a41a42ea339dn@googlegroups.com>
Subject: Re: SKIP +1000 and SKIP -1000
From: claudio@herszage.com (Claudio H)
Injection-Date: Wed, 04 Aug 2021 16:58:25 +0000
Content-Type: text/plain; charset="UTF-8"
 by: Claudio H - Wed, 4 Aug 2021 16:58 UTC

David

He wants to SKIP records folowing the order set by the active index and honoring filters, not moving the pointer in the physical order of the records.
Regards

Claudio H

Re: SKIP +1000 and SKIP -1000

<f2cffd88-3152-44df-a40c-d42cdc6bf452n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=16756&group=comp.lang.xharbour#16756

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:a0c:edb0:: with SMTP id h16mr3896506qvr.11.1628149081035;
Thu, 05 Aug 2021 00:38:01 -0700 (PDT)
X-Received: by 2002:a05:620a:24ca:: with SMTP id m10mr3472536qkn.323.1628149080840;
Thu, 05 Aug 2021 00:38:00 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.xharbour
Date: Thu, 5 Aug 2021 00:38:00 -0700 (PDT)
In-Reply-To: <ef3f2432-3d3b-4c96-9760-a41a42ea339dn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=217.194.186.242; posting-account=_oyAawkAAAAkDmcMkD9UQrwxJqiaol5l
NNTP-Posting-Host: 217.194.186.242
References: <258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com>
<c8426cd2-83f7-44fc-90e9-793d20400eb9n@googlegroups.com> <ef3f2432-3d3b-4c96-9760-a41a42ea339dn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <f2cffd88-3152-44df-a40c-d42cdc6bf452n@googlegroups.com>
Subject: Re: SKIP +1000 and SKIP -1000
From: info@marcoboschi.it (Marco Boschi)
Injection-Date: Thu, 05 Aug 2021 07:38:01 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: Marco Boschi - Thu, 5 Aug 2021 07:38 UTC

Il giorno mercoledì 4 agosto 2021 alle 18:58:25 UTC+2 Claudio H ha scritto:
> David
>
> He wants to SKIP records folowing the order set by the active index and honoring filters, not moving the pointer in the physical order of the records.
> Regards
>
> Claudio H
Many Thanks to all!
in my program I never skip +1000 I wrote some test to debug some slowness of my programs
> dbgoto(recno()-1000) ... should be pretty fast.
I have verifiedi this is very fast
it would be nice if you could do something like that
nCurKey := OrdKeyNo()
SkipKey( nCurKey + 1000)

King regards
marco

Re: SKIP +1000 and SKIP -1000

<3a3d823c-d1c5-4d2a-a57c-a20315e53e2dn@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=16758&group=comp.lang.xharbour#16758

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:a05:6214:c6f:: with SMTP id t15mr7072898qvj.52.1628192338541;
Thu, 05 Aug 2021 12:38:58 -0700 (PDT)
X-Received: by 2002:a05:620a:90c:: with SMTP id v12mr6636312qkv.190.1628192338341;
Thu, 05 Aug 2021 12:38:58 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.xharbour
Date: Thu, 5 Aug 2021 12:38:58 -0700 (PDT)
In-Reply-To: <f2cffd88-3152-44df-a40c-d42cdc6bf452n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=68.107.209.13; posting-account=7bF0GwoAAABMFHX6V4fON4-1F6LFJ834
NNTP-Posting-Host: 68.107.209.13
References: <258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com>
<c8426cd2-83f7-44fc-90e9-793d20400eb9n@googlegroups.com> <ef3f2432-3d3b-4c96-9760-a41a42ea339dn@googlegroups.com>
<f2cffd88-3152-44df-a40c-d42cdc6bf452n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <3a3d823c-d1c5-4d2a-a57c-a20315e53e2dn@googlegroups.com>
Subject: Re: SKIP +1000 and SKIP -1000
From: dlzc1@cox.net (dlzc)
Injection-Date: Thu, 05 Aug 2021 19:38:58 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
 by: dlzc - Thu, 5 Aug 2021 19:38 UTC

Dear Marco Boschi:

On Thursday, August 5, 2021 at 12:38:01 AM UTC-7, Marco Boschi wrote:
....
> it would be nice if you could do something like that
> nCurKey := OrdKeyNo()
> SkipKey( nCurKey + 1000)

https://www.itlnet.net/programming/program/Reference/c53g01c/ng2a6f6.html
.... sort of indicates that DBOI_POSITION could have been read and changed, to move to that position in the current index. But it says it was never implemented by RDDs under Clipper 5.3. I wonder if it ever was in (x)Harbour? Might trying reading it, decrementing it, and see if the record number changes. Might need to "flush the buffers" somehow, of course.

David A. Smith

Re: SKIP +1000 and SKIP -1000

<45499379-c3be-4185-88fe-6600e669da33n@googlegroups.com>

  copy mid

https://www.rocksolidbbs.com/devel/article-flat.php?id=16763&group=comp.lang.xharbour#16763

  copy link   Newsgroups: comp.lang.xharbour
X-Received: by 2002:a0c:e508:: with SMTP id l8mr9764955qvm.41.1628238800456;
Fri, 06 Aug 2021 01:33:20 -0700 (PDT)
X-Received: by 2002:a0c:b44b:: with SMTP id e11mr10030925qvf.38.1628238800205;
Fri, 06 Aug 2021 01:33:20 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!proxad.net!feeder1-2.proxad.net!209.85.160.216.MISMATCH!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.lang.xharbour
Date: Fri, 6 Aug 2021 01:33:20 -0700 (PDT)
In-Reply-To: <3a3d823c-d1c5-4d2a-a57c-a20315e53e2dn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=217.194.186.242; posting-account=_oyAawkAAAAkDmcMkD9UQrwxJqiaol5l
NNTP-Posting-Host: 217.194.186.242
References: <258bceef-a042-4ca9-a7bd-29e20408c500n@googlegroups.com>
<c8426cd2-83f7-44fc-90e9-793d20400eb9n@googlegroups.com> <ef3f2432-3d3b-4c96-9760-a41a42ea339dn@googlegroups.com>
<f2cffd88-3152-44df-a40c-d42cdc6bf452n@googlegroups.com> <3a3d823c-d1c5-4d2a-a57c-a20315e53e2dn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <45499379-c3be-4185-88fe-6600e669da33n@googlegroups.com>
Subject: Re: SKIP +1000 and SKIP -1000
From: info@marcoboschi.it (Marco Boschi)
Injection-Date: Fri, 06 Aug 2021 08:33:20 +0000
Content-Type: text/plain; charset="UTF-8"
 by: Marco Boschi - Fri, 6 Aug 2021 08:33 UTC

Many thanks David

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor