Forums › Forums › SIMPOL Programming › ppcs/CUST examples
- This topic has 14 replies, 3 voices, and was last updated 11 years, 8 months ago by JD Kromkowski.
- AuthorPosts
- July 10, 2012 at 5:46 pm #201JD KromkowskiParticipant
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?
July 15, 2012 at 4:40 pm #1970MichaelKeymasterOn 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
July 16, 2012 at 2:03 pm #1972JD KromkowskiParticipantThanks, Neil.
JDK
July 16, 2012 at 2:39 pm #1973JD KromkowskiParticipantFailed 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, NeilJuly 16, 2012 at 6:34 pm #1974MichaelKeymasterOn 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
July 17, 2012 at 5:26 pm #1975JD KromkowskiParticipantOn 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, NeilOK. 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.July 19, 2012 at 8:27 pm #1977JD KromkowskiParticipantMuch 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
July 25, 2012 at 6:45 pm #1978MichaelKeymasterOn 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
July 28, 2012 at 6:34 pm #1979JD KromkowskiParticipant> 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, NeilOK, 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.
August 2, 2012 at 1:26 pm #1980MichaelKeymasterOn 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
August 3, 2012 at 5:23 am #1976Steven KangParticipantHi 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:1280So 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.
August 8, 2012 at 11:10 pm #1981JD KromkowskiParticipant> 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 meIf 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
August 9, 2012 at 10:00 am #1984MichaelKeymasterOn 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.
>
> JDKLike 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
August 9, 2012 at 10:04 am #1540MichaelKeymasterOn 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
August 30, 2012 at 4:01 pm #1985JD KromkowskiParticipantI 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.
- AuthorPosts
- You must be logged in to reply to this topic.