Re: Windows Server Hardware Recommendations for 4DServer v17

2018-11-30 Thread Benedict, Tom via 4D_Tech
Hi  Neal,



>We're planning to upgrade to v17 in Q1 this coming year. We're currently 
>running our 4DServer v16 r6 application on a Windows 2008r2

>server (DELL Server PER420 with Xeon CUP E5-2407 v2 @2.40Ghz 2.40 Ghz (2 
>processors) with 32GB RAM, 64-bit). Our budget for the

>coming year includes funds for a new server machine. I'm looking for hardware 
>recommendations based on our current users and setup.

>We average about 45 concurrent users via 4D client/server and another 50 - 70 
>web connections.



You may not need any more hardware than you already have. Or you might! What 
I'm saying is that the only way to know if you are approaching (or already 
exceeding) the capability of your hardware is to measure performance. If you 
don't already have Thomas Schulmberger's Info Component installed, that would 
be a good place to start. You should be able to find it online, or contact 4D 
Tech Support. That will give you lots of key performance data which can be 
directly impacted by hardware. For example, it will tell you how often the 4D 
cache is being purged and how long it takes. Additionally, if you don't already 
have built-in application metrics, like how long it takes to do certain user 
tasks, that is something to start doing ASAP. Your users can tell you where the 
bottlenecks are, so those are things you need to collect data on. It will help 
you determine priorities. And if you can cut 10 seconds off a task done 100 
times a day by 45 users that's a massive payback.



How long does it take to run MSC on your current data file? Does it take so 
long that you have to interrupt business to do routine maintenance tasks like 
Compacting or Re-indexing? If new hardware allows you to reduce the maintenance 
burden, that alone could be a reason to upgrade. But you need to collect the 
data to know what to do.



But if you have a budget and it needs to be spent, I'd look at your disk 
subsystems. If you aren't running solid state drives that would be a great 
investment. You'll see reports run in seconds instead of minutes.



HTH,



Tom Benedict

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Audit File Updates via Triggers...

2018-11-21 Thread Benedict, Tom via 4D_Tech
Kirk Brooks writes:

>John,
>Sure you can - you make a method to extract the data
>you want. In selection based listboxes you can put the
>method in a column formula.

>On Tue, Nov 20, 2018 at 1:14 PM John DeSoi via 4D_Tech <4d_tech@lists.4d.com>
wrote:

>> Just note that you won't be able to see any of the data in an object
>> field if you are displaying records in a list box. Some possible
>> options now in version 17 if you are using collections/entity selections.

I'm with John on the suitability of object fields. If you live on an island 
where the only language is 4D, objects offer some advantages. But if there's 
ever the chance that you'd like to communicate with the outside world the 
lingua franca of rows and columns makes you friends around the globe.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v13 - Why can a record NOT be Pushed?

2018-11-06 Thread Benedict, Tom via 4D_Tech
Chip and Kirk comment:


>> forgotten the whole idea for these two commands is to allow you to

>> PUSH the record you are currently using to allow you to do queries on
>> the same table without having to save it first.

>Yes I know that about Push and Pop

>In this case I have a complicated set of inter relations (some as relational 
>lines
>and some not) and in many cases trying to get related records loses the
>current starting record, so pushing and piping insures that I end up on the
>same starting record.

Another useful tool to avoid disturbing the current selection is to use SQL 
queries within Begin SQL...End SQL. I use them frequently to collect data from 
various tables into arrays (or objects if you're in the 21st Century).

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Leaving the .4DB behind??

2018-10-23 Thread Benedict, Tom via 4D_Tech
Robert says:

>But what if the structure was that collection of files and that 4D runs as
>it always does but the github version management is always in play without
>an export? What if the .4db is simply a package that didn't have to be there?
>Just a thought. I think at a minimum, we will be one mouse-click from exporting
>the code, as you can see from the new v17r3 release and I'm assuming we'll be
>able to import that same code to build a .4b from scratch. My idea saves the
>conversion steps, all other functionality would be identical.

I don't know anything about how v17r3 supports exporting code and forms to a 
source code repository. Is it triggers by 4D Macros, like MethodHistory which 
could trigger code when saving a method or is it something else? That would be 
nice, but you would still need an explicit "Commit" capability.

Ideally you could have a distributed team of developers all working on local 
copies of the 4D structure, with local test data. Once their changes are 
complete and unit tested they could be "checked in" to a github. From there an 
automated "continuous build" process would periodically grab all checked-in 
code and forms and build and deploy an updated structure to a test server where 
testers would validate the changes.

From the sound of things, we are only one step away from being able to create 
this kind of build/deploy environment in 4D. This is would really move 4D in 
the right direction, from an Enterprise acceptance point of view.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Help->v11 to v17 Upgrade or New?

2018-10-22 Thread Benedict, Tom via 4D_Tech
Dani Beaubien writes:
>
>I use the external git client for diffs against historical commits and I use 
>the
>Code Analysis component for diffs between what is in the 4D structure
>compares against the last export to the external folder.

We did a similar thing based on Thomas Maul's MethodHistory component. We added 
a UI and integrated it into our semi-automated build/version tracking process. 
Compare method versions on screen filtered by date/version.

>Works quite well. Definitely a few extra steps but benefits to be able to go 
>back
>in time and see the change history tied to code commit is amazingly useful.

We use it for pre-release code review as well as post-release troubleshooting, 
if needed. It helped improve code quality on an 8 developer team.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Defining and documenting Objects

2018-10-11 Thread Benedict, Tom via 4D_Tech
Peter Jakobsson so eloquently writes:

>The original selling point of 4D was that it was stateful and that 
>statefullness
>is what gave us massive productivity gains. Lower level languages like the
>Microsoft developer platforms, Delphi and even Javascript/Python type
>environments had the versatility but you had to pay the price in coding
>according to the classic, stateless styles. 4D is now allowing us to do stuff
>you could do in these languages but there's a great big banana skin potentially
>associated with that transition which is productivity. For example when I 
>started
>building widgets in 4D, they could be "very nice" but my productivity 
>absolutely
>plummeted since you need to spend most of the time on designing plumbing
>systems, event models and custom data structures instead of solving business
>problems which have traditionally been the 4D developer's domain.

And if you give up that advantage, why develop in 4D at all?

Can you imagine living without the Current Selection?

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Defining and documenting Objects

2018-10-11 Thread Benedict, Tom via 4D_Tech
Koen Van Hooreweghe writes:

>Objects can be 'exported' to JSON quite easily: $json_text:=JSON 
>Stringify($4Dobject) Then you can expose this text data to the external system.

>The other way around is: $4Dobject:=JSON Parse($json_text)

>I really advise the step up to v15 and further. Objects are quite fun to work 
>with...

They do look useful. Wouldn't work for ODBC access, obviously. I'll check 'em 
out.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Defining and documenting Objects

2018-10-10 Thread Benedict, Tom via 4D_Tech

> On 5 Oct 2018, at 09:15, Paul Dennis via 4D_Tech 
> <4d_tech@lists.4d.com> wrote:
>
> With tables and records and the structure it's relatively
> straightforward to track through the code and work out what's going
> on. I can see this being a real problem with objects. There just
> doesn't seem to be any visibility. The data could be buried many
> layers down in an object let alone all the quotes, dots and semi
> colons involved

I'm stuck on v13.x, so I haven't had an opportunity to learn much about 4D 
objects. One thing that I would be interested in is how easy it is to expose 
data in objects to external non-4D systems. Can I pass an object as a response 
to a web service call from a .Net app and have the JSON or whatever form the 
object takes be meaningful? Or does that even make sense?

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

[Off] RE: How to get the current time in a specified time zone

2018-10-01 Thread Benedict, Tom via 4D_Tech
Timothy Penner writes:

>There are a lot of nuances for timezone data; here are a few that I find 
>interesting -

>The following article is both interesting and funny in how it explains some of 
>these nuances:
>https://zachholman.com/talk/utc-is-enough-for-everyone-right

Indeed, the whole history of Standard Time is fascinating (at least to me). 
It's a very recent (late 19th century) concept which came about mostly due to 
advances in transportation and telecommunication. Until then, Local Time was 
all that was needed. Under Local Time, the clocks were set to whatever time the 
local people/king/government decided. It didn't matter what time it was two 
days travel from there because the links between place were asynchronous. As 
transportation speeds increased and telecommunications were established the 
world 'shrank' (became more synchronous) and it became valuable to know the 
local time everywhere. But having thousands of Local Times, sometimes varying 
by only minutes, was difficult to manage. Hence the invention of Standard Time, 
based on geography (mostly longitude).

Tom Benedict
Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: How to get the current time in a specified time zone

2018-09-26 Thread Benedict, Tom via 4D_Tech
Pat Bensky writes:

>The only thing I'm not sure about is how various time zones change in their
>relationship to GMT (eg Summer Time etc.) For example if Country A is
>normally on GMT -8 but they're currently on Summer Time so 7AM in that
>time zone is CurrentHourGMT-8+1, how do we account for that?

Ya gotta have a database and you gotta maintain it, because the rules change 
for a range of reasons. This takes me back to my programming infancy in 1988 
when I created a Hypercard stack that was filled with all the countries and 
major cities of the world. I'm a geography fan, so I thoroughly enjoyed do the 
research (pre-internet). You entered your local time and selected the 
city/country you wanted to know the time in and it would look it up and display 
it. The stack was called "What Time?" and it got an award from the Boston 
Computer Society. I distributed it as shareware (remember that concept?) and I 
sold about 10 licenses. Even got an order from Switzerland. Fulfillment was by 
mail.

Thanks for the trip down memory lane. Sorry for the diversion.

Tom Benedict
Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Volume Shadow Copy

2018-09-19 Thread Benedict, Tom via 4D_Tech
Keith writes:



>The 64bit compiled/built server application shows "Volume Shadow Copy up and 
>running" on the first page of the server admin window.

>Googling "Volume Shadow Copy" shows it to be a system that allows backups 
>while an application is running.

>I suspect this is not something we need or should have running aimed at 4D.



Prior to 4D v17, Volume Shadow Copy was something to definitely avoid on a 4D 
server. It could crash/corrupt 4D. Under v17 4D has joined the 20th Century and 
added support for it. I haven't read the details, but I think it will help 4D 
adoption in the enterprise world. And it could come in handy.



Tom Benedict

Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Team Developer - Do all developers need to be on same minor version?

2018-08-28 Thread Benedict, Tom via 4D_Tech
Jeffrey Kain jeffrey.k...@gmail.com writes:

>Nope...

>If 4D makes a major change to the protocol they'll block it.  For deployment 
>we try to have matching versions always.
>
>> On Aug 28, 2018, at 2:24 PM, Dave Nasralla via 4D_Tech 
>> <4d_tech@lists.4d.com> wrote:
>>
>> One of our systems is developed with 4D Server (Team Developer) with
>> several coders connecting to make changes. If I move the Server from,
>> say v17.0 to v17.0 HF1 or a nightly build, do all the other developers
>> need to update their versions?

Ditto here. For Deployment we always match clients to server versions, even 
down to the build number.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: New record numbering system and CALL WORKER

2018-08-28 Thread Benedict, Tom via 4D_Tech
Kirk Brooks writes:

>I am surprised this thread has drawn so much discussion. It's good
>discussion but scanning back over it a key point is that all of these
>contortions and workarounds to preserve a number sequence are based on the
>single design decision to use an invoice (in this case) number as a key
>field. I'm not criticizing of course - I used to do this as well and still
>have a few cases where that sort of design exists though nothing involving
>number series where gaps are an issue. Not to mention I've been doing 4D
>long enough to recall the first discussions about data normalization the
>community had and the, erm, hesitant embrace of it by many.

Thank you Kirk for finally mentioning this. The use of 'magic numbers' is 
tempting, but ultimately leads to lots of work to support. Keys should have no 
meaning.

That said, the need to manage sequence numbers without gaps is legitimate and 
an interesting subject (as this thread has illustrated). Just don't use them as 
relational keys, or if you do, make sure you do it with your eyes open.

Tom Benedict
Optum


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: First day experience using 4D v17.0 HF1

2018-08-15 Thread Benedict, Tom via 4D_Tech
Tim Nevels writes:



> First day 4D Server Team Developer v17 experience over a WAN was very good.



Thanks for the report Tim. I'm very impressed that anyone is doing development 
on 4D Server over the internet.



When deployed does your app use 4D Client or does it have a web front end? I 
ask because in our experience 4D performance over a WAN was intolerable. 
Minutes to open a record. But that involved long queries and loading records 
from multiple tables and executing lots of code/forms/etc. We also were dealing 
with tables with millions of records and 200 - 300 concurrent users. Our app 
may not be typical though.



V17 sounds promising for a number of reasons.



Tom Benedict

Optum



This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Export text columns containing carriage returns to Excel?

2018-08-06 Thread Benedict, Tom via 4D_Tech
I didn’t have to escape the embedded commas. I think the quotes around all the 
fields took care of them. You will likely need to experiment. I found that 
Excel is fussy about CSV. It definitely doesn’t like importing CSV via the 
import wizard unless there are no embedded delimiters.

Tom

From: Perkins, Bradley D [mailto:bperk...@lanl.gov]
Sent: Monday, August 06, 2018 12:34 PM
To: Benedict, Tom; 4d_tech@lists.4d.com
Subject: Re: Export text columns containing carriage returns to Excel?

Tom,

That sounds extremely useful. In addition to "" any "s in the text do I also 
need to \, any commas?

I doubt the data source will be too large, but if it is can break the export 
into a couple of files. We'll only need to do this once.

Thanks,

Brad Perkins

From: "Benedict, Tom" 
Date: Monday, August 6, 2018 at 1:26 PM
To: Bradley Perkins , "4d_tech@lists.4d.com" 
<4d_tech@lists.4d.com>
Subject: RE: Export text columns containing carriage returns to Excel?

Brad,

Here’s a hint that you may (or may not) find useful.

I used a single column in the QR Editor to hold the full ‘record’ I was 
exporting. I wrapped all the fields with double-quotes and used commas as field 
delimiters. I also had to escape any embedded quotes by replacing them with 
double-double quotes. The result was a CSV file which can be opened in Excel 
(double-clicked on Desktop, not via File>Open. Excel is strange). Use CSV 
avoided the didn’t need to restore any of the embedded characters.

My data source ended up being too large to use this approach, as the output 
file exceeded 4GB, so I end up writing similar code to generate the CSV. But if 
your data is modest sized the QR approach avoid the code-test-release cycle 
(unless your system is running interpreted).

Tom Benedict
Optum



From: Perkins, Bradley D [mailto:bperk...@lanl.gov]
Sent: Sunday, August 05, 2018 1:26 PM
To: Benedict, Tom; 4d_tech@lists.4d.com
Subject: Re: Export text columns containing carriage returns to Excel?


Hi Tom,

I've been working  this with the QR Editor with some success. Another challenge 
I've found is that the 4D text fields have carriage returns, carriage 
return/new line pairs, and even some tabs.  Therefore I'll need to nest the 
calls to Replace string in the proper order to place markers for all three.



Thanks for pointing out the limitations I will need to see if any of the text 
fields are larger than 32,767 characters. This is an older system that started 
life in v3. The output file size will not be an issue.

Best,

Brad


From: Benedict, Tom 
Sent: Friday, August 3, 2018 2:19:44 PM
To: Perkins, Bradley D; 4d_tech@lists.4d.com
Subject: Re: Export text columns containing carriage returns to Excel?

Brad Perkins writes:

>I've been asked to provide an export from a legacy 4D system delivered as an 
>.xlsx file.

>The challenge I'm facing is that this table contains a number of text fields 
>and
>the customer requires the imported column cells to retain the returns or line 
>feeds
>in the original text fields. If I do a straight tab-delimited export with 
>carriage returns
>as the end of line marker, the imported result does not preserve the original 
>row
>because any returns encountered in the text fields are interpreted as end of 
>row.

>My other challenge is that I need to do this with out-of-box end user 
>capabilities
>from a client (v15.4 remote) against a compiled server. I can't install 
>plugins, create new methods, etc.
>It has been many years since I've had to do this type of thing in 4D.

>Can I replace the carriage returns in the text fields with a special marker 
>during export?
>I could replace the Excel cells containing the any carriage return markers 
>with actual returns after import.

Use the Quick Report Editor. You can put formulas in the columns which include 
a call to Replace string.

There are some limitation which I’ve encountered:


-  The Quick Report Editor is 32bit (evidently) which limits the size 
of the output file to 4GB. Hopefully you don’t run in to that limit. (I did 
recently).

-  Any given cell in Excel can only hold 32,767 characters. If you have 
more than that you’ll have to do some fancy segmenting into another column in 
the output.

HTH, let me know if you have further questions. I have very recent experience 
doing just this.

Tom Benedict
Optum


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by 

RE: Export text columns containing carriage returns to Excel?

2018-08-06 Thread Benedict, Tom via 4D_Tech
Brad,

Here's a hint that you may (or may not) find useful.

I used a single column in the QR Editor to hold the full 'record' I was 
exporting. I wrapped all the fields with double-quotes and used commas as field 
delimiters. I also had to escape any embedded quotes by replacing them with 
double-double quotes. The result was a CSV file which can be opened in Excel 
(double-clicked on Desktop, not via File>Open. Excel is strange). Use CSV 
avoided the didn't need to restore any of the embedded characters.

My data source ended up being too large to use this approach, as the output 
file exceeded 4GB, so I end up writing similar code to generate the CSV. But if 
your data is modest sized the QR approach avoid the code-test-release cycle 
(unless your system is running interpreted).

Tom Benedict
Optum



From: Perkins, Bradley D [mailto:bperk...@lanl.gov]
Sent: Sunday, August 05, 2018 1:26 PM
To: Benedict, Tom; 4d_tech@lists.4d.com
Subject: Re: Export text columns containing carriage returns to Excel?


Hi Tom,

I've been working  this with the QR Editor with some success. Another challenge 
I've found is that the 4D text fields have carriage returns, carriage 
return/new line pairs, and even some tabs.  Therefore I'll need to nest the 
calls to Replace string in the proper order to place markers for all three.



Thanks for pointing out the limitations I will need to see if any of the text 
fields are larger than 32,767 characters. This is an older system that started 
life in v3. The output file size will not be an issue.

Best,

Brad


From: Benedict, Tom 
Sent: Friday, August 3, 2018 2:19:44 PM
To: Perkins, Bradley D; 4d_tech@lists.4d.com
Subject: Re: Export text columns containing carriage returns to Excel?

Brad Perkins writes:

>I've been asked to provide an export from a legacy 4D system delivered as an 
>.xlsx file.

>The challenge I'm facing is that this table contains a number of text fields 
>and
>the customer requires the imported column cells to retain the returns or line 
>feeds
>in the original text fields. If I do a straight tab-delimited export with 
>carriage returns
>as the end of line marker, the imported result does not preserve the original 
>row
>because any returns encountered in the text fields are interpreted as end of 
>row.

>My other challenge is that I need to do this with out-of-box end user 
>capabilities
>from a client (v15.4 remote) against a compiled server. I can't install 
>plugins, create new methods, etc.
>It has been many years since I've had to do this type of thing in 4D.

>Can I replace the carriage returns in the text fields with a special marker 
>during export?
>I could replace the Excel cells containing the any carriage return markers 
>with actual returns after import.

Use the Quick Report Editor. You can put formulas in the columns which include 
a call to Replace string.

There are some limitation which I've encountered:


-  The Quick Report Editor is 32bit (evidently) which limits the size 
of the output file to 4GB. Hopefully you don't run in to that limit. (I did 
recently).

-  Any given cell in Excel can only hold 32,767 characters. If you have 
more than that you'll have to do some fancy segmenting into another column in 
the output.

HTH, let me know if you have further questions. I have very recent experience 
doing just this.

Tom Benedict
Optum


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group 

Re: Export text columns containing carriage returns to Excel?

2018-08-03 Thread Benedict, Tom via 4D_Tech
Brad Perkins writes:

>I've been asked to provide an export from a legacy 4D system delivered as an 
>.xlsx file.

>The challenge I'm facing is that this table contains a number of text fields 
>and
>the customer requires the imported column cells to retain the returns or line 
>feeds
>in the original text fields. If I do a straight tab-delimited export with 
>carriage returns
>as the end of line marker, the imported result does not preserve the original 
>row
>because any returns encountered in the text fields are interpreted as end of 
>row.

>My other challenge is that I need to do this with out-of-box end user 
>capabilities
>from a client (v15.4 remote) against a compiled server. I can't install 
>plugins, create new methods, etc.
>It has been many years since I've had to do this type of thing in 4D.

>Can I replace the carriage returns in the text fields with a special marker 
>during export?
>I could replace the Excel cells containing the any carriage return markers 
>with actual returns after import.

Use the Quick Report Editor. You can put formulas in the columns which include 
a call to Replace string.

There are some limitation which I've encountered:


-  The Quick Report Editor is 32bit (evidently) which limits the size 
of the output file to 4GB. Hopefully you don't run in to that limit. (I did 
recently).

-  Any given cell in Excel can only hold 32,767 characters. If you have 
more than that you'll have to do some fancy segmenting into another column in 
the output.

HTH, let me know if you have further questions. I have very recent experience 
doing just this.

Tom Benedict
Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v13+ Unicode characters 1-7

2018-07-31 Thread Benedict, Tom via 4D_Tech
Keisuke Miyako writes:



>.. may I suggest VT (vertical tab, Char(11)) which displays at \v in the 
>debugger.

>

>when you export the values tab-delimited,

>vertical tabs fits all values in the same cell (multi-line).

>

>not sure about Excel, but at least it should be that way with Numbers or 
>FileMaker.



Excel 2010 Windows displays the Vertical Tab character as the male symbol. 
While it does keep all the characters in the cell, they do not display in 
multi-line format.



Tom Benedict

Optum





This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: 13.x Quick Report Export Max Output File Size?

2018-07-25 Thread Benedict, Tom via 4D_Tech
Tim Penner writes:



>Is the file system Fat32?

>If so, then keep in mind that a Fat32 file system is limited to 4GB files.



It's Windows Server 2008 R2 SP1. I'm pretty sure the disk that the file is 
being written to is NTFS. And there are other files, like the .4DD, on that 
disk which are larger than 4GB.



And Mr Miyako writes:



>besides, Quick Report, as the name suggests, is for quick and simple tasks.

>to be honest, I don't think it was designed to handle files larger than 4GB.



In that case I guess I'll have to write some code.



Thanks,



Tom Benedict

Optum



This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

13.x Quick Report Export Max Output File Size?

2018-07-24 Thread Benedict, Tom via 4D_Tech
I'm exporting data from 4D to a text file using the 4D Quick Report Editor in 
v13.x. It stopped writing to disk when the file size reached 4.0GB (4,194,304 
KB). The disk it is writing to has plenty of space on it. Is there a file size 
limit to exporting data using the 4D Quick Report Editor?

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: What do you use to monitor your offsite servers?

2018-07-17 Thread Benedict, Tom via 4D_Tech
We have a number of 4D Servers which we run under a dedicated Windows Account. 
We use the same Windows Account to run all Production Servers on all machines. 
If someone needs to monitor the server they can do that via RDC using that 
Windows Account. That avoids any session confusion. However, it doesn't allow 
multiple users to monitor the same session and, since we run 4D Server from the 
desktop, rather than as a Windows Service, it also exposes the risk of the user 
accidentally 'logging off' instead of 'disconnecting' which causes 4D Server to 
quit. For these reasons we use RealVNC to monitor all servers, which is simply 
a screen sharing app.

>The issue as I understand it is this; Windows Server allows you to have 
>multiple sessions for users concurrently logged in.
>This can be confusing when multiple people connect expecting to administer the 
>same desktop, but instead of seeing a
>shared desktop they get their own desktop in their own session, even though 
>the app they are looking to administer (4D)
>is running  in another user session. To correct this they must be aware of the 
>session they are currently connected to
>and aware of the session that is running the app they want to administer.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Application Metrics

2018-07-03 Thread Benedict, Tom via 4D_Tech
Robert writes:

> in your 4D applications are you tracking usage levels of any kind? I suppose 
> it
>would be useful to know what features are heavily used and which are almost
>never used. What metrics does your system collect that you've found useful?

We don't keep track of features used, but we do keep track of performance 
metrics, mostly around system response, transaction counts and concurrent user 
counts. Feature use would be a great addition.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Server crash in MSVCR120.dll - help with debugging dump file

2018-06-25 Thread Benedict, Tom via 4D_Tech
Hi Adrian,

>Recently we've had server crashes on two customer sites with our
>application (built with 4D v15R5), and in both cases the Windows event
>log is pointing the finger at MSCVR120.dll (version 12.0.21005.1), with
>an exception code of 0xc409.

>I have a Windows minidump file from one of them which yields a bit more
>information. As far as I can tell, the actual crash is in MSCVR120.dll,
>called from the Xalan memory manager (presumably via Xalan-C_1_11.Dll in
>the 4D server folder?), but without debug symbols, there's no way of
>knowing if our code is the root cause of the crash or not (and if it is,
>where in our code?). I've discovered that MSVCR120.dll is part of the
>Visual C++ 2013 redistributable, and have (re)installed the latest
>version of that, but there's also a copy in the 4D server folder which
>I'm guessing probably overrides the system copy?

I've never had much luck trying to interpret dump files, mini or otherwise. In 
the past when we had serious server crash issues we've collected dumps and 
forwarded to 4D Tech Support for interpretation. But even then we've had very 
limited success and it's a whole lotta work on both sides. Things may have 
improved since v13.x when we were crashing, so maybe there are better, easier 
to use dump analysis tools these days.

Are you using 4D XSLT or XPath in your app? Could be a long shot, but if you 
are it could be a good place to start troubleshooting.

Sorry this isn't more helpful.

Tom Benedict
Optum


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: 2 instances of 4D connected to different 4D Servers

2018-06-20 Thread Benedict, Tom via 4D_Tech
Hi John,

>Thanks Julio.  Like you I duplicate 4D all the time to run multiple instances 
>on my Mac.
>
>On windows, however, I have been reluctant to fiddle with windows 
>installations as
>I  suspect that there are DLLs or other files installed in places that I know 
>not where.
>
>I did in fact just now try what you suggested and it works! I will do some 
>more testing, but it looks like that is the way to go.
>
>Anyone have any warnings with regard to using a duplicate of the 4D version 
>folder? For example...
>
> C:\Program Files (x86)\4D\4Dv16.0
> C:\Program Files (x86)\4D\4Dv16.0  - Copy
> put a shortcut of  C:\Program Files (x86)\4D\4D v16.0 - 
> Copy\4D\4D.exe on the desktop.

That's how I've done it for years for 4+ copies of 4D (4DDev, 4DQA, 4DUAT, 
4DTraining, 4DProduction etc). I've never had Windows complain about it. You 
can take it a step further and create .4DLink files to automate the connection 
too. Drop those in your Start Menu or Task Bar for single click access.

Tom Benedict
Optum


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: setting up mirror

2018-05-15 Thread Benedict, Tom via 4D_Tech


>Thanks for your update. I assume you have a process on mirror that runs and 
>delays

>itself for x amount of time. What happens if you try and create a second log 
>but

>first has not been integrated. What do you do? Would you mind sharing code.

>I know it should be pretty simple, but I always would prefer not to re-invent 
>the

>wheel. If so, can you email me privately.

We serialize the segmented log files. That decouples the segmentation flow from 
the integration flow. We can take the mirror offline for a period of time, then 
bring it back up and it automatically catches up. It also makes it easy to 
multiple, redundant mirrors. We have 3 in our Production system. It also allows 
us to rebuild a data file from a specific starting point from logs.

Tom Benedict
Optum Inc

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: xml to array

2018-03-28 Thread Benedict, Tom via 4D_Tech
Peter et al,

The method was actually written by David Dancy. It was part of some XML methods 
he shared with the 4D community a number of years ago. Sure miss his presence 
in the 4D Dev world.

Hope this helps.

Tom

  // 
  // User name(OS): ddancy
  // Date and time: 30/7/10, 01:15:07
  // 
  // Method: DOM_DisplayXML
  // Description
  // Format XML element names and values for display in Hierarchical List
  //
  //
  // History
  // 
  // 30/7/10-ddancy: Created
  //
  // Parameters
  // 
C_TEXT($1;$Root_xml)
C_LONGINT($2;$Level_l)

$Root_xml:=$1
$Level_l:=$2

C_TEXT($Element_xml;$Child_xml)
$Element_xml:=$Root_xml

C_TEXT($ElementName_t)
C_TEXT($ElementValue_t)
C_TEXT($AttrList_t)

Repeat

DOM GET XML ELEMENT NAME($Element_xml;$ElementName_t)
DOM GET XML ELEMENT VALUE($Element_xml;$ElementValue_t)

$AttrList_t:=""

C_LONGINT($Attr_l;$AttrCount_l)
$AttrCount_l:=DOM Count XML attributes($Element_xml)

C_TEXT($AttrName_t;$AttrValue_t)
For ($Attr_l;1;$AttrCount_l)
DOM GET XML ATTRIBUTE BY INDEX($Element_xml;$Attr_l;$AttrName_t;$AttrValue_t)
$AttrList_t:=$AttrList_t+" "+$AttrName_t+"="+"\""+$AttrValue_t+"\""
End for

APPEND TO ARRAY(DOM_Reference_at;$Element_xml)
APPEND TO ARRAY(DOM_ElementName_at;($Level_l*"
")+"<"+$ElementName_t+$AttrList_t+">")
APPEND TO ARRAY(DOM_ElementValue_at;$ElementValue_t)

$Child_xml:=DOM Get first child XML element($Element_xml)

If ((OK=1))
DOM_DisplayXML ($Child_xml;$Level_l+1)
End if

$Element_xml:=DOM Get next sibling XML element($Element_xml)

Until ((OK=0))

OK:=1

Tom

From: Peter Mew [mailto:peterm3...@gmail.com]
Sent: Tuesday, March 27, 2018 2:09 PM
To: Benedict, Tom
Cc: 4d_tech@lists.4d.com
Subject: Re: xml to array

Hi Tom
I would very much like to see your method
thanks
-pm

On Tue, Mar 27, 2018 at 10:04 PM, Benedict, Tom 
> wrote:

Hi Peter,



>

>Is there a 4D command that will take a block of xml, and turn it into a number 
>of arrays (or pairs of arrays (attribute and value) Or is this a stupid 
>question Thanks –pm



I have a method to do this. Let me know if you need it.



Tom  Benedict

Optum Inc


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v13 -Automatically repaired method

2018-03-27 Thread Benedict, Tom via 4D_Tech
Chip Scheide writes:



>Any way to recover the code?

>

>There is no backup, as the code was written today.

>



We use the old but solid MethodHistory component from Thomas Maul. It writes 
all methods to a 4D table, so all edits are preserved. It comes in very handy. 
We use it for a primitive form of version control. It has served us well. 
Something like this is easy to implement in any system.



Tom Benedict

Optum Inc

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: xml to array

2018-03-27 Thread Benedict, Tom via 4D_Tech
Hi Peter,



>

>Is there a 4D command that will take a block of xml, and turn it into a number 
>of arrays (or pairs of arrays (attribute and value) Or is this a stupid 
>question Thanks -pm



I have a method to do this. Let me know if you need it.



Tom  Benedict

Optum Inc

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Using the new 4D SSO feature on Windows

2018-03-02 Thread Benedict, Tom via 4D_Tech
Timothy Penner > responded to Bob Miller 
>



>The whole idea with Single Sign On is that the user logs in to the machine, 
>and then subsequent system

>they use while logged in to the machine will use the same login credentials 
>automatically.



That's what I thought, but here (a Fortune 6 company) they are ultra-secure and 
SSO means that while you may have one user name and one password, but in 
addition to logging into your workstation or the network (Windows Login) you 
are also required to use it to log in to every application separately. So SSO 
means different things to different people.



Tom

Optum, Inc

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: [SAD NEWS] legendary developer and 4D base-rock Ortwin Zillgen

2018-02-27 Thread Benedict, Tom via 4D_Tech
>

>it is with great sadness, that I have to inform you, that Ortwin Zillgen has 
>passed away end of last week.

>Suddenly, unexpectedly and far too early at the young age of 64.

>



Sad indeed. I had not met the man, but admired his intellect and developer 
skills as expressed on the iNUG. There is a small handful of posters which I 
_always_ read. His name was among that number.



Condolences to his family and friends.



Tom Benedict

Optum Inc

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: 4D Parameter

2018-02-07 Thread Benedict, Tom via 4D_Tech
Tim Nevels responded



>On Feb 6, 2018, at 2:00 PM, Miguel Gonzalez wrote:



>> Is there a way to make the processes running in 4D Server not taking

>> too much resources?

>> I know that this is for the processes to finish quickly when send to the 
>> server.

>>

>> My problem is that this behaviour reduce notably the performance on

>> the 4D clients.

>> Is there some 4D parameter that it gives more priority to the clients

>> than the server.

>



>

>Usually Stored Procedures that hog the CPU are looping through records

>or doing some repetitive task. So put DELAY PROCESS in the loop so that

>it does one iteration of the loop, pause for a short time and then resume.



Tim's comments will help improve performance if the stored procedure is 
iterating over records. However, it the 'slow' process is a long sequential 
query, it will not improve client response. If that is the case you will need 
to look at query optimization or data model revisions or both.



There is no 'priority' flag for processes, at least not in v12 or v13. V16 
Workers may help you out, but I have no experience with them yet.



Tom Benedict

Optum Inc

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Re: "Goodbye 4D Write" email

2018-02-02 Thread Benedict, Tom via 4D_Tech
Whoops. Sent too soon..

I meant to add that if you are going to go to the trouble of writing a bunch of 
code to make 4D Write Pro work as you need, it might be a smaller effort to 
write the code needed to integrate one of the Javascript word processor 
libraries to your app.

Tom

From: Benedict, Tom
Sent: Friday, February 02, 2018 7:57 AM
To: 4D_Tech@lists.4D.com
Subject: Re: "Goodbye 4D Write" email


There are plenty of Javascript text editor libraries available.

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: "Goodbye 4D Write" email

2018-02-02 Thread Benedict, Tom via 4D_Tech
There are plenty of Javascript text editor libraries available.

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Anyone using 4D Write Pro with a semblance of success?

2017-10-16 Thread Benedict, Tom via 4D_Tech
There are lots of Javascript word processing libraries available. 
Database/application integration and programmability is key to 4DWrite's value. 
Has anyone tried using callbacks in a web area hosting a Javascript word 
processor to do mail merge? I haven't tried, so I don't know how feasible it is.

Tom Benedict
Optum. Inc

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: read from a MS SQL server with 4D

2017-09-13 Thread Benedict, Tom via 4D_Tech
Fernando writes:



>I need to read from a MS SQL server with 4D.

>Someone can give a link with examples.



SQL LOGIN is a good command to start with.

Tom Benedict
Optum Inc
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: [Off] Remote backup

2017-09-12 Thread Benedict, Tom via 4D_Tech
Bob Miller writes:

>[Server#1] Runs 4D Server that users are actively using.  Code in a loop on 
>the 4D Server calls
>"New Log File" every 10 minutes.  Code in the loop then calls LEP to a script 
>to transfer the last journal file to [Server#2].
>
>[Server#2] Runs 4D Server that users aren't aware of.  Code in a loop on the 
>4D Server detects
>that a complete journal file has arrived (as it will every ten minutes, my 
>uncertainty is how it knows the file transfer is
>complete) and integrates it using INTEGRATE MIRROR LOG FILE.  Code in the loop 
>then calls LEP
>to a script to transfer this journal file to [Server#3].  4D Backup runs on 
>this machine and sends its backup file to [Server#3]

>[Server#3] This is a repository, nothing is actively running on it, it could 
>be iCloud, Amazon S3, etc.

>Do I have this basically correct?

Yes.

>Then some technical questions:

>It would seem that Server#1 never runs 4D Backup, because any restoration
>would be done using Server#2.  Nevertheless, if Server#1 started up and
>somehow choked, a "normal" behavior would be to restore from backup and
>integrate the log file.  Since this behavior would be turned off, what is
>the procedure you use if Server #1 won't start?  Do you copy the mirror on
>Server #2 to Server#1?

Yes.

>How do you handle the timing, so that [Server#2] knows that the file
>transfer is complete and it is OK to integrate the log file?  Does
>[Server#1] somehow send a 'I'm Done' message to [Server#2] in your
>implementation?

I think that 4D will complain that the log file is 'busy'. I must confess I've 
never encountered this case in 10+ years of running multiple mirrors. If I 
recall correctly, our system copies the file with a 'temp' name, then when the 
copy is 'done' it changes the name. That limits the exposure considerably. It's 
pretty much an 'instant' name change, so the mirror never tries to integrate a 
'busy' file.

>What do you do if [Server#1] dies to now point users to [Server#2],
>assuming the Server application is a built application so that the server
>address and port number are built into the (built) 4D Client?

There are a number of ways to deal with this on the hostname/DNS level. We've 
never done this. Surprisingly, we never had any hardware failures when we used 
dedicated hardware and since moving to SAN/VM there have been a few drive 
failures, but they never affected operations due to the redundancy and 
'auto-move' features of VM.

BTW, there is a 4D Tech Note which includes all the code that you can need to 
set this up. But it only supports file share or web service as the file 
transport mechanism. Easy enough to do the LEP RoboCopy or whatever instead 
though.

Enterprise systems can't afford to not be mirrored. There are lots of white 
papers available which outline DR scenarios and potentials solutions for 
enterprise. Less than enterprise systems should seriously look at the very 
modest cost of deploying a 4D mirror. A few thousand dollar investment will 
provide a viable DR solution. Business interruptions due to natural disasters 
are very expensive to recover from. Being able to assure your business managers 
that the data that they depends on is safe, secure and available to deploy 
anywhere they need it is extremely compelling. Setting up a 4D Mirror is a 
simple, low cost way to satisfy that requirement.

I've advocated that 4D should build the mirroring capability into 4D Server, 
rather than providing a component. That would raise it to higher level of 
support and more systems would use mirroring. (Maybe they have? I haven't been 
following the v16 feature set closely, as I'm stuck on v13.x)

HTH,

Tom Benedict
Optum, Inc


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

JSON Tools Was: Re: C-objects and memory use

2017-07-26 Thread Benedict, Tom via 4D_Tech
David Adams dpad...@gmail.com writes:

>Well, 4D's tools for manipulating JSON are sub-standard, if your goal is to 
>parse/produce JSON freely. In this respect, the XML tools (external libraries 
>built into 4D) are far more standard and comprehensive.

Along these lines, is there a stable and maintained library for querying JSON 
similar to XPath? I looked for one a few years ago when I was developing my 
Simple Rules Engine but found that there wasn't anything mature yet, so I stuck 
with XML/XPath.

This page 
http://orangevolt.blogspot.com/2012/12/8-ways-to-query-json-structures.html#!/2012/12/8-ways-to-query-json-structures.html
 mentions a number of tools. Anyone have any experience integrating them with 
4D?

Tom Benedict
Optum Inc
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: 4D Write Pro interface plug in or component?

2017-07-11 Thread Benedict, Tom via 4D_Tech
John DeSoi writes:

>> On Jul 10, 2017, at 5:55 PM, John Baughman via 4D_Tech 
>> <4d_tech@lists.4d.com> wrote:
>>
>> Pro looks to be a good upgrade, but I hate the fact that it comes without a 
>> typical word processor user interface built in. I just don't have time to 
>> create the interface.

>Agree. The application I am working on only used it for online help and one 
>template based table. It was much easier (and less expensive) to convert 
>everything to use markdown instead.

We used 4D Write for years as a styled text editor with rulers. It didn't need 
any DB integration. Finally moved that functionality to a Javascript Text 
Editor. Works great.


Tom Benedict
Optum Inc
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Optimizing and improving 4D queries.

2017-06-29 Thread Benedict, Tom via 4D_Tech
Hi Eric,



> I was hoping there way a way like in mysql to explain slow queries to tell my 
> how or what why the query was being slow.



Have you tried the DESCRIBE QUERY EXECUTION command? It will tell you the query 
path and plan including execution time.



HTH,



Tom Benedict

Optum





This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Data mining from Oracle Application using 4D

2017-06-02 Thread Benedict, Tom via 4D_Tech
Rooftop99 says:



>I have a large Oracle database from which I need to regularly extract specific 
>data using a 4D

>application.  Is there a preferred way to connect the two for data mining?  
>ODBC, or ???

>Anyone doing this with success and willing to share the connection 
>architecture?

I only have experience connecting 4D with SQL Server, not Oracle, so there may 
be some platform specific considerations, but I'm thinking you could simply use 
4D native SQL commands to connect and call a stored procedure in Oracle. You 
would need to set up DSN on the client side for the Oracle connection.. The 
extracted data would populate arrays in 4D.

If the queries are ad hoc and need to change, you might better off with a 
Oracle or SQL specific plugin, but if you aren't doing Inserts or Updates in 
Oracle I think native 4D SQL should meet your needs.

HTH,

Tom Benedict
Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Get table fragmentation

2017-05-29 Thread Benedict, Tom via 4D_Tech
Cannon writes and David responds:

>I'm working on some server health reporting. I can get the percentage of table 
>fragmentation using "Get table fragmentation" for each table.
>I'm not quite sure what to do with it, though. I'd like to get a report when 
>the overall fragmentation reaches some threshold where it might
>be worth compacting the datafile. 20% is suggested by on tech note.

>But I suspect the number of records matters. For example, if a table only has 
>100 records, I probably don't care if it is even 80% fragmented.
>But if a table has 10 million records and is used a lot, I may not even want 
>20% fragmentation. And, if only one table is fragmented and the
>rest are fine, maybe it is worth compacting? But probably not in all cases?

>Has anyone worked out some logic that can be automated and which takes these 
>kinds of things into account to let you know when it
makes sense to compact the whole datafile?


>> If anyone knows the answer to Cannon's question, I'd really like to know 
>> too! I went down this road a few years ago in V13 and

>>couldn't figure out any way to get worthwhile information out of the 
>>fragmentation percentage.

>>Apart from getting the numbers for snapshots and automated health checks, I 
>>also had a little dialog you could look at in real-time.

>>My observation was that tiny tables with deletes appeared to be massively 
>>fragmented. But there were only a few records in

>>play, so it didn't really mean anything. I couldn't find a way to get 
>>anything like the results MSC seems to generate.

I am way out of date with 4D, as we are stuck on v13.x until the end of time, 
but many years ago I had the same question about Get table fragmentation. I 
found that it returned a range of values before and after 
compacting/rebuilding/recovering the data file. Usually the numbers were 
smaller after MSC processing, but not always.

I asked Josh Fletcher about it back in 2011 and he said:


Hi Tom,



So I have one possible explanation for this behavior.



First it's important to understand how 4D allocates space in the data file.  
When needs to locate free space in the data file, for example, it doesn't 
"scan" the whole data file.  Instead, for every 2 MB of data file content 4D 
creates a 2KB "bit table".  Each bit in the bit table corresponds to a 128 KB 
block of the data file.  If a bit in the bit table is 1, it means that block of 
the data file is occupied.  If the bit is 0, that block is free.



These bit tables are created "as needed", i.e. they are not located in one 
particular place.  So, for example, say a table contains only 1 Mb records. 
When you compact it you'll get something like this:



[bittable1][record1][record2][bittable2][record3][record4][bittable3][record5][record6]...



Note: In fact, it's not exactly this simple because each bittable also needs to 
be allocated like any other data file object so its space must be tracked in 
another bittable.  But because it is quite small (2 KB), we can ignore that for 
this example.



Get table fragmentation returns the percentage of records that are not stored 
contiguously.  If there are bit tables between the records, the level of 
fragmentation reported will increase.  So in the example above Get table 
fragmentation will return near 50%.



This is not a problem per se, it just reflects the reality of objects allocated 
in the data file.  The fact is, because those objects are so large, they'll be 
inefficient to access no matter what (multiple blocks of data file will need to 
be loaded) so the fact that they table is considered fragmented is a non-issue 
in this case.



I hope that makes sense.  Let me know.



-Josh

I don't know what, if anything, has changed in 4D since v13.x. Maybe nothing. 
In any event, we just compact once a month, and have no idea whether it makes a 
difference. We're pretty certain it is better than compacting once a year, but 
one a month makes us feel good for some reason.

Hope this helps.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Restart Client Under Program Control

2017-05-26 Thread Benedict, Tom via 4D_Tech
In v 13.x, when a client 'loses a connection' to 4D Server due to a network 
interruption of some sort, 4D.exe will display and dialog which includes a 
"Restart" button. When "Restart" is clicked 4D.exe relaunches and auto-logs in 
using the same credentials (or maybe it is just using the 4DLink file which I 
created?). Anyhow, what I'd like to do is call this 'feature' from 4D code to 
re-launch 4D.exe on demand.  Is this possible?

Thanks,

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Access Groups and Objects

2017-05-17 Thread Benedict, Tom via 4D_Tech
I think this question comes up from time to time, but I couldn't find it in the 
archives.

We use 4D Users & Groups for menu, form and method access control. Is there a 
way to get a listing of menus, forms and methods by access group?

Thanks,

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: dog's breakfast

2017-05-08 Thread Benedict, Tom via 4D_Tech
David Adams included this gem in a recent post:

"It was enough of a dog's breakfast..."

That's a phrase we don't hear enough of on this side of the pond.

Thank you, David, for your enthusiastic use of language, programming or 
otherwise. It's always a pleasure to read your posts, whether or not I have a 
technical interest in them.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Tom Benedict's rule engine - something that you need to know

2017-04-23 Thread Benedict, Tom via 4D_Tech
David,

>Tom Benedict mentioned in passing that a "rule engine" he presented at the 
>Summit in 2014 might be
>the right tool to help John Foster solve a problem.
>My ears perked up because I've long wanted to have a rule engine in 4D but 
>haven't taken the time to
>write one. Tom hooked me up with the notes (I also have direct access @ 4D, as 
>it turns out), and I
>wanted to make this resource visible to a wider range of people.

Thanks for the kind words. And double thanks for articulating the value of a 
rule engine to developers. It takes some time to get one's head around these 
concepts and you have a marvelous ability to write about complex issues in a 
way that is accessible and engaging.

>So, assuming that you are or have access to an expert, the coding parts you 
>need are the encoded rules
>and the rule processor. Normally, that means a database + a language that 
>excels at processing list
>structures. 4D isn't a great list processor language, but it can do it. Tom 
>very cleverly leverages some
>XML+XSLT code that David Dancy (I miss him!) shared. XML is all about trees 
>and XSLT is a tree-processing
>language. Nice!

What I implemented works on a flat XML tree, basically just a list of key-value 
pairs, so the XPath just uses the root. That makes it extremely 'simple', which 
was my goal. But there's no reason it couldn't have additional dimensions 
leveraging the power of XPath. I think your 'dichotomous key' example would 
benefit from that kind of approach.

>It's the sort of powerful, core technique that it would be very easy to spend 
>a career never hearing about. There
>are TONS of database in the 4D world that can make use of this technique. If 
>you have anything to do with
>medicine, check this idea out - it was largely made for you. (Seriously.)
>
>Hopefully Tom or someone else using this sort of tool can offer some 
>real-world, 4D-based examples of
>how it's made their life better.

Our business delivers Tobacco Cessation Services on behalf of state governments 
for their citizens. Criteria for these service offerings varies over time 
depending on funding and the specific service offerings vary by demographics. 
One would think that these criteria would be known and fixed across all states, 
which would allow the use of a normalized data model. But the reality is that 
exceptions arise frequently. So even though every state may identify pregnant 
women on Medicaid the same way, one state may want to target a sub population 
who only uses smokeless tobacco, or is Native American or live in a certain 
county (since many public health services are county based). The possibilities 
are endless and the changes need to be made on relatively short notice. They 
also need to support activation/deactivation on a schedule. A Rule Engine is 
perfect for these scenarios. We use a similar solution for applying eligibility 
criteria inclusion in Randomized Controlled Studies. The other realm we have 
used this in is Survey Questionnaires where skip pattern rules are evaluated 
after every question to determine what the next question should be.

One of the biggest benefits of moving the rules out of code and into data is 
the way it shortens the test cycle. Rule edits don't need to wait for a daily 
'push to QA' for testers to verify changes.

In short, adding a Rule Engine to our application has delivered efficiency and 
made the it much more responsive to business changes, giving the organization 
an additional competitive edge.

I'd be happy to send the session notes to anyone who is interested. (Er, unless 
4D objects, since I think they 'own' the session notes). Or you can probably 
find them somewhere on partnercentral.4d.com, although I wasn't able to in a 
quick glance just now.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Dynamic Method Creation & Content Changing

2017-04-20 Thread Benedict, Tom via 4D_Tech
Hi John,


> I am wondering if anyone is modifying methods on the fly by inserting 
> selective lines of code. What

>I have in mind is selectively inserting into case statements.



>Why do I need it? Because I have have a client who needs to setup various 
>medical trials and

routines that get generate or updated based upon these 4D list. Currently 
>there are a whole slew

>of manual steep that are required and it's quite days to mess things up.



Sounds like you need a Rule Engine. I presented a session on implementing a 
Simple Rule Engine in 4D at the 2014 Summit. If you attended the Summit that 
year, you can find the Session Notes on the thumb drive. If not, let me know 
and I'll send you details.



Tom Benedict

Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Methods, Components, Comments, and Tooltips

2017-04-20 Thread Benedict, Tom via 4D_Tech
Lutz writes:

>we use a modified version of the mentioned vc-framework component. It saves 
>all changes in the code to text files
>immediately and keeps track of the timestamps of the changes in an external 
>database. The text files can be
>committed to a source code versioning tool like svn, mercurial, git ...

>We extended it a bit to allow reimporting of the exported code. So we are able 
>to switch between branches and
>we can do team development without a development server and dev clients. All 
>members of our team use single user >instances of 4D. The result of the 
>development will be compiled into a built/merged server application.
>A very old version (V13 yet) with import code can be found on Github: 
>https://github.com/elutz/vc-framework-v13

Do your apps use 4D forms? If so, how do you deal with them with respect to 
version control?

Thanks,

Tom Benedict
Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Clean Slate - Modern User Experience.

2017-04-17 Thread Benedict, Tom via 4D_Tech
Peter Jakobsson responds:



>> Where could I go to see samples of what folks are doing with 4D which brings 
>> the UI into the modern era? Any thoughts?



>Doesn't the O/S define 'modern era' ?



I couldn't agree more. If you are using 4D "client" for your app, create style 
sheets and leverage the platform wherever you can. That automatically keep your 
app 'modern', plus it makes it very easy to support multiple platforms and OSs.



A few random thoughts:



-  I've seen some nice 'hybrid' UIs, which include Web Areas for 
navigation and 4D objects for data.



-  Like Mitchell points out, don't get too carried away with color. 
Limit your palette and make sure the different colors are used consistently.



-  Decide whether you want to use application menus. Make it extremely 
obvious to the user when to use menu items and when to use form controls. You 
may even decide to not use menus at all.



-  Consider hiring a UX designer for a few months to analyze your app 
and set up a style guide and screen templates.



Tom Benedict

Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re:Server Mirroring

2017-03-20 Thread Benedict, Tom via 4D_Tech
Cannon Smith writes:

>I'm looking into the idea of setting up a mirrored server. One one hand I want 
>to be
>pretty aggressive about sending log files to the mirror-probably every couple 
>of minutes.
>On the other hand, I don't want to use "New log file" and then send the log 
>file if nothing has changed.

>Has anyone done something similar? Can I safely check the size of the log 
>file, or maybe the
>modification date? Just wondering if anyone has any tricks for this.

What is your concern about frequent log shipping? Is it the overhead? In our 
experience New log file is pretty darn quick, although we haven't actually 
timed it. It might take some work to figure out exactly what the size of 
'nothing' is too.

I haven't tried checking the size or mod date of the .journal, but I would 
guess it should work.

But I do recommend mirroring. It's the only way you can provide 24x7 uptime. 
And it makes offline maintenance (MSC Compact, Verify, etc) possible. Not to 
mention redundancy for DR.

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: v13 MSC Maintenance Mode Activation—Mac.

2017-03-16 Thread Benedict, Tom via 4D_Tech
Hi Robert ListMail < >

>I’ve got a v13-based single-user web-serving 4D database running on a headless 
>Mac server (in a land far,
>far away) that I maintain via Mac Screen Sharing. Recently I’ve been unable to 
>launch MSC in
>Maintenance Mode (via option key depressed at startup) . Any ideas?

This is a bit of a long shot…

Any chance you can put a copy of 4D Server on that machine? I think it will run 
even if you don’t have a license. You can launch MSC from the menu.

HTH,

Tom Benedict
Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: 4D 15.4 HF1 (windows) - crashes when run as service

2017-03-09 Thread Benedict, Tom via 4D_Tech
Keith White writes:

>Retaining access to 4D Server's user interface is currently essential for 
>system admins to be able to drop users or to see 4D error message dialogs that 
>may have appeared on the 4D Server UI.

>Now I know you're going to tell me that you can use the 4D Remote 
>Administration Window to do the drop-users thing.  Great, but how do you get 
>to _that_ if all your 4D connection licenses are currently used up?  Catch-22

When 4D Server starts up, have it launch a 4D Client logged into 4D Server. 
That way it will always get the first license and you'll have access to the 
Administration Window.

HTH,

Tom Benedict
Optum

This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Virtualization - Yea or Nay

2017-02-27 Thread Benedict, Tom via 4D_Tech
Hi Doug,

>My reason for posting this message is to solicit feedback on the pros and cons 
>of moving
>an existing system to a virtual environment. The IT department at a client 
>site is pushing
>a client to virtualize their 4D system and I've been asked to provide input.

>In a short, my understanding is that 4D can work well in a virtual environment 
>providing
>that the VM is configured for OLTP. The hallmarks of that configuration 
>appears to be
>use of SSD's as the primary drives, apparently acting in a caching function, 
>and as well
>as optimization to support small block transfers (2k? 8k?).

It's works great, especially if, as you've stated, sufficient resources are 
allocated to 4D. That really is the key. Also, make sure that the primary 
resources are dedicated to 4D. VM is extremely smart and, unless specifically 
told not to, will divert resources away from 'idle' applications. So if 4D 
Server is 'quiet' for a period of time, it may 'lose' it's priority with 
respect to resources (CPUs, caches, SSDs etc) and performance will go down the 
tube. And it may take 10-15 minutes for those resources to be 'moved' back to 
4D Server, once 4D activity resumes. This can be avoided by dedicating 
resources.

The other key is to have lots of experience with VM management and 
configuration in the IT team. Hopefully, your app is not going to be their 
first VM. Also, if they say they are doing it to save money on hardware, be 
very suspicious. Enterprize grade VM hardware is extremely expensive. The 
savings is in the flexibility, fault tolerance and redundancy it provides. 
Adding a server is a task measured in minutes rather than days. Moving a server 
is a completely transparent operation done while the wheels are spinning. It's 
really quite remarkable.

We have a 250 user 150 GB 4D Server fully virtualized. Along with a number of 
Test and Dev servers. It pretty much just works. One thing we still use 
hardware for is monthly data file compacts (via MSC). The VM system isn't 
optimized for that kind of activity evidently. Other than that, it works great.

HTH,

Tom Benedict
Optum
This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
**
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**