Skip to content

ppcs/CUST examples

Forums Forums SIMPOL Programming ppcs/CUST examples

Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • #201
    JD Kromkowski
    Participant

    Are there any ppcs examples (the CUST ones, etc) that actually work. They all seem to have a variation on f =@ ppcs.openudpfile(“ppcs.superbase.co.uk:1280”, “CUST”, error=iErrnum) but obviously ppcs.subperbase.co.uk:1280 doesn’t work. Does SIMPOL LTD have any ppcs file which we could open and explore as a means of trying to understand how it a// works?

    #1970
    Michael
    Keymaster

    On 10/07/2012 18:46, John D Kromkowski wrote:
    > Are there any ppcs examples (the CUST ones, etc) that actually work.
    >
    > They all seem to have a variation on
    >
    > f =@ ppcs.openudpfile("ppcs.superbase.co.uk:1280", "CUST", error=iErrnum)
    >
    >
    > but obviously ppcs.subperbase.co.uk:1280 doesn't work.
    >
    > Does SIMPOL LTD have any ppcs file which we could open and explore as a means of trying to understand how it a// works?

    Actually you can just change the ppcs.superbase.co.uk to http://www.simpol.com.

    Ciao, Neil

    #1972
    JD Kromkowski
    Participant

    Thanks, Neil.

    JDK

    #1973
    JD Kromkowski
    Participant

    Failed to open file 'CUST' error number: 10.

    In sbmecust project example

    If I set the ip
    sIpaddress = "www.simpol.com:1280"
    this seems to set it back
    getprivateprofilestring(sSECTION, sPPCSSERVER, "", sIpaddress,
    sINIFILE, sINIEOLCHAR)

    which I gather means there is something messed up with the conflib.sml
    and some ini file?

    Same problem in the ppctest1 project (I can't now even remember if this
    is one of your projects or mine using the ppctest code.) I'm using the
    code from the first example in Chapter 5 of the Simpol Programmer's Guide.

    That example, by the way, calls the file "CUSTS" (with S at end)?

    Also error 10 when I use the code from Chapter 13. (Note this one:
    CUST (no S).

    JDK

    On 7/15/2012 12:40 PM, Neil Robinson wrote:
    > On 10/07/2012 18:46, John D Kromkowski wrote:
    >> Are there any ppcs examples (the CUST ones, etc) that actually work.
    >>
    >> They all seem to have a variation on
    >>
    >> f =@ ppcs.openudpfile("ppcs.superbase.co.uk:1280", "CUST", error=iErrnum)
    >>
    >>
    >> but obviously ppcs.subperbase.co.uk:1280 doesn't work.
    >>
    >> Does SIMPOL LTD have any ppcs file which we could open and explore as a means of trying to understand how it a// works?
    >
    > Actually you can just change the ppcs.superbase.co.uk to http://www.simpol.com.
    >
    > Ciao, Neil

    #1974
    Michael
    Keymaster

    On 16/07/2012 15:39, John D Kromkowski wrote:
    > Failed to open file 'CUST' error number: 10.
    >
    > In sbmecust project example
    >
    > If I set the ip sIpaddress = "www.simpol.com:1280" this seems to set it back getprivateprofilestring(sSECTION, sPPCSSERVER, "",
    > sIpaddress, sINIFILE, sINIEOLCHAR)
    >
    > which I gather means there is something messed up with the conflib.sml and some ini file?
    >
    > Same problem in the ppctest1 project (I can't now even remember if this is one of your projects or mine using the ppctest
    > code.) I'm using the code from the first example in Chapter 5 of the Simpol Programmer's Guide.
    >
    > That example, by the way, calls the file "CUSTS" (with S at end)?
    >
    > Also error 10 when I use the code from Chapter 13. (Note this one: CUST (no S).

    Hi John,

    The server program wasn't running for some reason. I just started it. The table name is CUST. You can also open the location using
    SIMPOL Personal.

    Ciao, Neil

    #1975
    JD Kromkowski
    Participant

    On 7/16/2012 2:34 PM, Neil Robinson wrote:
    > On 16/07/2012 15:39, John D Kromkowski wrote:
    >> Failed to open file 'CUST' error number: 10.
    >>
    >> In sbmecust project example
    >>
    >> If I set the ip sIpaddress = "www.simpol.com:1280" this seems to set it back getprivateprofilestring(sSECTION, sPPCSSERVER, "",
    >> sIpaddress, sINIFILE, sINIEOLCHAR)
    >>
    >> which I gather means there is something messed up with the conflib.sml and some ini file?
    >>
    >> Same problem in the ppctest1 project (I can't now even remember if this is one of your projects or mine using the ppctest
    >> code.) I'm using the code from the first example in Chapter 5 of the Simpol Programmer's Guide.
    >>
    >> That example, by the way, calls the file "CUSTS" (with S at end)?
    >>
    >> Also error 10 when I use the code from Chapter 13. (Note this one: CUST (no S).
    > Hi John,
    >
    > The server program wasn't running for some reason. I just started it. The table name is CUST. You can also open the location using
    > SIMPOL Personal.
    > Ciao, Neil

    OK. I'll investigate.

    This is very intriguing that you can use Personal to open up the
    location. Although, I think I just broke it trying to run a quick report.

    #1977
    JD Kromkowski
    Participant

    Much time spent not realizing while "LastFirstName" is an index, it has
    no data in it and therefore is useless.

    Presumably it was a calculated field when it was in Superbase.

    Before I try, I gather that I am even allowed ability to create an index
    (for example on "Last Name") on this ppcstype1.

    JDK

    #1978
    Michael
    Keymaster

    On 19/07/2012 21:27, John D Kromkowski wrote:
    > Much time spent not realizing while "LastFirstName" is an index, it has no data in it and therefore is useless.
    >
    > Presumably it was a calculated field when it was in Superbase.
    >
    > Before I try, I gather that I am even allowed ability to create an index (for example on "Last Name") on this ppcstype1.
    >
    > JDK
    >

    Hi John,

    It isn't possible to create an index via PPCS. PPCS only allows for read, write, and delete (and associated locking operations).
    Any direct table maintenance must be done on the data files directly.

    I have updated the table to fill that field appropriately.

    Ciao, Neil

    #1979
    JD Kromkowski
    Participant

    > Hi John,
    >
    > It isn't possible to create an index via PPCS. PPCS only allows for read, write, and delete (and associated locking operations).
    > Any direct table maintenance must be done on the data files directly.
    >
    > I have updated the table to fill that field appropriately.
    >
    > Ciao, Neil

    OK, I understand now. I'll check it out later. But should reports take
    so long. Even with a limiting filter, I can seem to get the thing to
    resolve as if there is no optimization provide by the index and filter.
    So after 5+ minutes of "processing" I just give up. What's up with
    that? Should it really take that long?

    E.g. CUST table, Lastname < B* to get just the As.

    #1980
    Michael
    Keymaster

    On 28/07/2012 19:34, John D Kromkowski wrote:
    >> Hi John,
    >>
    >> It isn't possible to create an index via PPCS. PPCS only allows for read, write, and delete (and associated locking
    >> operations). Any direct table maintenance must be done on the data files directly.
    >>
    >> I have updated the table to fill that field appropriately.
    >>
    >> Ciao, Neil
    >
    > OK, I understand now. I'll check it out later. But should reports take so long. Even with a limiting filter, I can seem to
    > get the thing to resolve as if there is no optimization provide by the index and filter. So after 5+ minutes of "processing" I
    > just give up. What's up with that? Should it really take that long?
    >
    > E.g. CUST table, Lastname < B* to get just the As.
    >

    It shouldn't take that long, but I am currently working on the optimization issues of the underlying sql query engine. Also,
    please note that the wildcard character in SQL is the %, not the *.

    Ciao, Neil

    #1976
    Steven Kang
    Participant

    Hi John,

    The getprivateprofilestring function is retrieving the Ipaddress from the
    sbmecust.ini file located in the project bin directory. That file contains
    a single entry:

    [Config]
    ppcsserver=ppcs.superbase.co.uk:1280

    So you have to edit that to stop it being reset.

    Neil,

    Both "www.superbase.co.uk:1280" and "www.simpol.com:1280" work in Simpol
    Personal (with the very occasional error 10 on the first attempt).
    However, I *alway*s get an error 10 when using them in the openudpfile
    method in the various supplied samples mentioned above.

    Steven.

    #1981
    JD Kromkowski
    Participant

    > It shouldn't take that long, but I am currently working on the optimization issues of the underlying sql query engine. Also,
    > please note that the wildcard character in SQL is the %, not the *.

    I did know that the SQL wildcard is %, I just did not know that that was
    the convention in SIMPOL. Now noted.

    Using the Handym table, and filter Company1 like 'A%', it took 54
    seconds to get the 50 or so records out of the 505 total records. That
    seems kind of long to me

    If I set the index to Company1 and start at

    A & A Flat & Valley Roofing Services

    and "fast forward" I can get to the Bs in 5 seconds.

    So why should a report take 10 times as long. A decade ago I fooled
    around with Mysql and remote databases and huge files (millions of
    records) and it didn't seem to take that long.

    JDK

    #1984
    Michael
    Keymaster

    On 09/08/2012 00:10, John D Kromkowski wrote:
    >> It shouldn't take that long, but I am currently working on the optimization issues of the underlying sql query engine. Also,
    >> please note that the wildcard character in SQL is the %, not the *.
    >
    > I did know that the SQL wildcard is %, I just did not know that that was the convention in SIMPOL. Now noted.
    >
    > Using the Handym table, and filter Company1 like 'A%', it took 54 seconds to get the 50 or so records out of the 505 total
    > records. That seems kind of long to me
    >
    > If I set the index to Company1 and start at
    >
    > A & A Flat & Valley Roofing Services
    >
    > and "fast forward" I can get to the Bs in 5 seconds.
    >
    > So why should a report take 10 times as long. A decade ago I fooled around with Mysql and remote databases and huge files
    > (millions of records) and it didn't seem to take that long.
    >
    > JDK

    Like I said, at the moment the report engine is not optimized. I didn't write the original and am still trying to understand why
    it is so slow in certain cases. Also, don't forget that when you run a report over PPCS to that server, you probably are getting a
    ping speed of 50ms or worse. This known as the latency of the connection. Since PPCS is controlled by the client (it is not like
    an SQL system where you send the query, the server carries it out, then returns the results), the latency plays a huge issue in
    reports. It retrieves records one at a time. So, if you have 50ms ping time or latency to the server, the best you can achieve is
    to read 20 records per second. If your latency is 200ms, it becomes 5 records per second. In a modern LAN .5ms is not uncommon, so
    you can read 2000 records per second.

    Ciao, Neil

    #1540
    Michael
    Keymaster

    On 03/08/2012 06:23, Steven Kang wrote:
    > Hi John,
    >
    > The getprivateprofilestring function is retrieving the Ipaddress from the sbmecust.ini file located in the project bin
    > directory. That file contains a single entry:
    >
    >
    > [Config] ppcsserver=ppcs.superbase.co.uk:1280
    >
    > So you have to edit that to stop it being reset.
    >
    > Neil,
    >
    > Both "www.superbase.co.uk:1280" and "www.simpol.com:1280" work in Simpol Personal (with the very occasional error 10 on the
    > first attempt). However, I *alway*s get an error 10 when using them in the openudpfile method in the various supplied samples
    > mentioned above.

    Hi Steven,

    Both go to the same IP address. I tend to just use the shortest one: simpol.com:1280. As for getting a timeout in the programs,
    that is a bit surprising, but you may need to adjust the timeout and retry values when opening the connection. Check your ping
    time to the server.

    Ciao, Neil

    #1985
    JD Kromkowski
    Participant

    I understand some of the issues, but I'm not sure why a report should be
    so much slower than "fast-forwarding" through records.

    When I fast forward are the records on machine or yours.

Viewing 15 posts - 1 through 15 (of 15 total)
  • You must be logged in to reply to this topic.