Re: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread David Adams via 4D_Tech
Thanks to TIm and Brian for responding here, always appreciated.

There is no lack of clarity from 4D that the official channel is to post on
the forums. Before that, it was bugs.4d.fr. That's always been clear. Heck,
I can't even count the number of times I said that on this list over the
years. Of course when I said it, I didn't really think much good would come
from it. I can open up 4D today and point out tons of bugs (cosmetic,
usability, functional, and crashing) that have been known about for years
and versions. So, yeah, reporting bugs doesn't have a lot to do with bugs
getting fixed.

Pardon me for being so simple minded, but what remains completely unclear
is why customer information is ignored. See, that's the issue: You've got
customers sending you information, you know what they say, and you say
"nope, doesn't count." That's about 4D's relationship with your customers,
it's not about your customers doing things wrong. "Posting on the NUG
doesn't count" just feels like a weak cop-out. That 4D doesn't see this, I
just don't understand.

If you guys used any sort of normal, commercial bug-tracking or forum
platform, I think the position "do everything there" would be a lot more
tenable.  But a hidden bug system (which I still have no access to because
of my hemisphere) and a home-made forum system in 2017? You just have to
accept that that's not going to work for some people. For good reason.

I've tried the Forums. While 4D Engineers participate there a little, I
heard nothing form the Product Team. Ever. And from Engineering, I mostly
heard or observed that posts were being put in the "wrong" forum, and that
any sort of design critique wasn't welcome. You can say that a feature is
not working correctly, but that a feature or feature set has a design flaw?
Not a good reception. At all.

The question is, do you want to make 4D better? Do you want to make 4D more
reliable? Yes or no. Blowing off customer input = "no". Making it harder
for customers to provide input = "no". Not providing feedback on bug status
= "no." Not documenting the tools properly = "no". Calling bad design
"standard behavior" = "no." Telling people that its' down to us to track
down a bug that freezes the server and that 4D isn't actively investigating
it on their own? Yeah, that's most definitely "no." Giving people a hard
time for pointing out flaws in the *design* of features, also "no".

Your business, your choice.
**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread John Baughman via 4D_Tech
Ok, OK. Feature request sent…

——
Currently an object field's dirty flag only gets set if the object field itself 
is referenced...

OB SET([MyTable]MyObjectField;"property";"newValue")
SAVE RECORD[MyTable] //The field's dirty flag is set and the new value is saved.

MyTable]MyObjectField.property:="newValue"
SAVE RECORD[MyTable] //The field's dirty flag is NOT set becaaue a propery has 
been modified, not the field itself, and so the new value is NOT saved.

This has been designated as standard behaviour. 4D Tech Support has been 
telling developers to add a line of code that sets the dirty flag...

MyTable]MyObjectField.property:="newValue"
MyTable]MyObjectField:=MyTable]MyObjectField //the field is referenced
SAVE RECORD[MyTable] //The field's dirty flag is set and the new value is saved.

Based on an extensive thread ( [Warning] Settings properties values on object 
field by object notation) on the NUG, many developers including myself believe 
this should not be considered as standard behviour. 

Request that the dirty flag of an object field be set whenever it is modified 
using dot notation.

It is also requested that until this behaviour is changed, a warning be added 
to the LRM that clearly explains the current behaviour of an object field.

Developers expect that modifying a field using :=, regardless of the type, will 
result in the updated data being saved to the datafile. Any other field typds 
that have "properties" that contain data should provide the same expectation. 
If not this "non-standard" behaviour must be clearly documented.
__

John

> On Nov 1, 2017, at 3:32 PM, Brian Young via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> I think I understand the logic and emotion from all sides of this thread.  I 
> want to try and clarify (repeat?) a couple discussion points so this can end 
> up being a constructive thread, and not just a user group chat that doesn’t 
> get the attention it deserves.
> 
> 
> There are a lot of strong reactions to this being marked as "standard 
> behavior”.  My understanding is simply:  standard behavior means the issue 
> has been reviewed and the engineers find the behavior matches the 
> specification.
> 
> So, it is the specification that you would like to see changed.
> 
> I understand why.  Several strong arguments have been made on this thread.
> 
> These arguments should be posted on the feature request forum which is the 
> official place to request this kind of change.  This is especially important 
> because in this case we are talking about a feature that is currently in 
> preview.  The feature is not yet recommended for production use and "final 
> implementation could be slightly different”.  It is the ideal time to request 
> changes in behavior and I do not see a request for this posted yet. Please 
> post it so that engineering has a clear understanding of your concerns.
> 
> Feature Request Forum (login required first):
> http://forums.4d.com/Forum/EN/1075213/0/
> 
> (let me know if you need help with logging in to the forum due to the recent 
> SSO login changes.)
> 
> 
> my very best
> 
> -Brian
> 
> 
> 
> 
> **
> 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
> **

John Baughman
Kailua, Hawaii
(808) 262-0328
john...@hawaii.rr.com





**
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 - LEP and MS-DOS command line

2017-11-01 Thread Chip Scheide via 4D_Tech
Thanks again.

Why?
I do not need the directory listing itself. I need the size of the directory 
for copying.
I need to check the size of directory being copied to insure that there is free 
space before starting the copy.

files are easy :)


> Dir
> https://technet.microsoft.com/en-us/library/cc755121(v=ws.11).aspx
> 
> LEP
> http://doc.4d.com/4Dv16R5/4D/16-R5/LAUNCH-EXTERNAL-PROCESS.301-3481371.en.html
> 
> stdOut can be text or BLOB,
> the encoding is UTF-16LE on Windows if you pass BLOB (and if the 
> command line program is Unicode).
> I guess on an English system it doesn't really matter.
> 
> of course, since v13, 4D can recursive parse all items in a folder.
> http://doc.4d.com/4Dv16/4D/16.2/DOCUMENT-LIST.301-3433852.en.html
> 
> but iterating every items sounds like a stressful task
> https://stackoverflow.com/questions/10015341/size-of-a-directory
> 
> why would you need that piece of information?
> 
>> 2017/11/02 9:27、Chip Scheide <4d_o...@pghrepository.org> のメール:
>> So... I Should expect LEP to return a directory listing (given the 
>> command is written correctly) in $LEP_Output?
> 
> 
> 
> 
> **
> 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
> **

Hell is other people 
 Jean-Paul Sartre
**
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: FTP_Progress

2017-11-01 Thread Sujit Shah via 4D_Tech
Looks like we need to roll our own progress bar by

a) Getting the file size on host/client
b) monitoring the file size of download or upload on host/client

for receive and send..



On Thu, Nov 2, 2017 at 2:21 PM, Sujit Shah  wrote:

> Thanks but how do we monitor the download? How will I know that the
> download is complete?
>
> On Thu, Nov 2, 2017 at 2:16 PM, Keisuke Miyako via 4D_Tech <
> 4d_tech@lists.4d.com> wrote:
>
>> the built-in progress bar was retied in Internet Command 64-bits, no
>> progress bar is shown.
>>
>> http://doc.4d.com/4Dv15/4D/15/4D-Internet-Commands-64-bit-ve
>> rsion-for-OS-X.300-2048298.en.html
>>
>> quote:
>>
>> Progress bar
>>
>> The 4D IC 64-bit version for OS X does not display a progress bar when
>> executing time-consuming operations. The FTP_ProgressFTP_Progress command
>> is deprecated in the 64-bit version of OS X.
>> When called in this environment, the command returns error -2201
>> (unimplemented feature).
>>
>> > 2017/11/02 11:57、Sujit Shah via 4D_Tech <4d_tech@lists.4d.com> のメール:
>> > Is the progress still shown? What if there is a need to hide the
>> progress bar.
>>
>>
>>
>>
>> **
>> 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
>> **
>
>
>
>
> --
>
> xxx
> "There must be ingenuity as well as intention, strategy as well as
> strength. "
>
>



-- 

xxx
"There must be ingenuity as well as intention, strategy as well as
strength. "
**
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: FTP_Progress

2017-11-01 Thread Sujit Shah via 4D_Tech
Thanks but how do we monitor the download? How will I know that the
download is complete?

On Thu, Nov 2, 2017 at 2:16 PM, Keisuke Miyako via 4D_Tech <
4d_tech@lists.4d.com> wrote:

> the built-in progress bar was retied in Internet Command 64-bits, no
> progress bar is shown.
>
> http://doc.4d.com/4Dv15/4D/15/4D-Internet-Commands-64-bit-
> version-for-OS-X.300-2048298.en.html
>
> quote:
>
> Progress bar
>
> The 4D IC 64-bit version for OS X does not display a progress bar when
> executing time-consuming operations. The FTP_ProgressFTP_Progress command
> is deprecated in the 64-bit version of OS X.
> When called in this environment, the command returns error -2201
> (unimplemented feature).
>
> > 2017/11/02 11:57、Sujit Shah via 4D_Tech <4d_tech@lists.4d.com> のメール:
> > Is the progress still shown? What if there is a need to hide the
> progress bar.
>
>
>
>
> **
> 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
> **




-- 

xxx
"There must be ingenuity as well as intention, strategy as well as
strength. "
**
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: FTP_Progress

2017-11-01 Thread Keisuke Miyako via 4D_Tech
the built-in progress bar was retied in Internet Command 64-bits, no progress 
bar is shown.

http://doc.4d.com/4Dv15/4D/15/4D-Internet-Commands-64-bit-version-for-OS-X.300-2048298.en.html

quote:

Progress bar

The 4D IC 64-bit version for OS X does not display a progress bar when 
executing time-consuming operations. The FTP_ProgressFTP_Progress command is 
deprecated in the 64-bit version of OS X.
When called in this environment, the command returns error -2201 (unimplemented 
feature).

> 2017/11/02 11:57、Sujit Shah via 4D_Tech <4d_tech@lists.4d.com> のメール:
> Is the progress still shown? What if there is a need to hide the progress bar.




**
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: Web Preferences Change on 15.5

2017-11-01 Thread Doug Hall via 4D_Tech
I forgot to mention that it appears the settings are unchanged from the
original default settings (like from a new database), on my web server.

On Wed, Nov 1, 2017 at 9:17 PM, Doug Hall  wrote:

> I didn't notice this happening on 4D 15.4, but it seems that now, when I
> replace my structure on my 4D Server machine, the web preferences (in the
> Database Settings menu option) change on my 4D Remote (web server) machine.
> I used to only have to change the default web user, since my development
> structure doesn't have any user logins besides the Designer and
> Administrator. Now, I have to change a LOT of the settings under the web
> tab. :-(
>
> Any ideas what may be going on? Where are these preferences stored, when
> transferred to a client machine? Also, in which manual are these settings
> discussed?
>
> Thanks,
> Doug
>
**
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
**

Web Preferences Change on 15.5

2017-11-01 Thread Doug Hall via 4D_Tech
I didn't notice this happening on 4D 15.4, but it seems that now, when I
replace my structure on my 4D Server machine, the web preferences (in the
Database Settings menu option) change on my 4D Remote (web server) machine.
I used to only have to change the default web user, since my development
structure doesn't have any user logins besides the Designer and
Administrator. Now, I have to change a LOT of the settings under the web
tab. :-(

Any ideas what may be going on? Where are these preferences stored, when
transferred to a client machine? Also, in which manual are these settings
discussed?

Thanks,
Doug
**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Brian Young via 4D_Tech
I think I understand the logic and emotion from all sides of this thread.  I 
want to try and clarify (repeat?) a couple discussion points so this can end up 
being a constructive thread, and not just a user group chat that doesn’t get 
the attention it deserves.


There are a lot of strong reactions to this being marked as "standard 
behavior”.  My understanding is simply:  standard behavior means the issue has 
been reviewed and the engineers find the behavior matches the specification.

So, it is the specification that you would like to see changed.

I understand why.  Several strong arguments have been made on this thread.

These arguments should be posted on the feature request forum which is the 
official place to request this kind of change.  This is especially important 
because in this case we are talking about a feature that is currently in 
preview.  The feature is not yet recommended for production use and "final 
implementation could be slightly different”.  It is the ideal time to request 
changes in behavior and I do not see a request for this posted yet. Please post 
it so that engineering has a clear understanding of your concerns.

Feature Request Forum (login required first):
http://forums.4d.com/Forum/EN/1075213/0/

(let me know if you need help with logging in to the forum due to the recent 
SSO login changes.)


my very best

-Brian




**
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 - LEP and MS-DOS command line

2017-11-01 Thread Keisuke Miyako via 4D_Tech
Dir
https://technet.microsoft.com/en-us/library/cc755121(v=ws.11).aspx

LEP
http://doc.4d.com/4Dv16R5/4D/16-R5/LAUNCH-EXTERNAL-PROCESS.301-3481371.en.html

stdOut can be text or BLOB,
the encoding is UTF-16LE on Windows if you pass BLOB (and if the command line 
program is Unicode).
I guess on an English system it doesn't really matter.

of course, since v13, 4D can recursive parse all items in a folder.
http://doc.4d.com/4Dv16/4D/16.2/DOCUMENT-LIST.301-3433852.en.html

but iterating every items sounds like a stressful task
https://stackoverflow.com/questions/10015341/size-of-a-directory

why would you need that piece of information?

> 2017/11/02 9:27、Chip Scheide <4d_o...@pghrepository.org> のメール:
> So... I Should expect LEP to return a directory listing (given the command is 
> written correctly) in $LEP_Output?




**
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 - LEP and MS-DOS command line

2017-11-01 Thread Chip Scheide via 4D_Tech
Thanks! I look at that tomorrow

So... I Should expect LEP to return a directory listing (given the command is 
written correctly) in $LEP_Output?

> Hello,
> 
> if <>x_Quote+$Path ends with a directory symbol,
> double-quoting the string isn't enough,
> the directory symbol is also an escape prefix,
> so you have an open-ended escaped-double quote if that makes any sense.
> 
> for a more robust (that is, than just surrounding the string with 
> double quotes)
> way to escape parameters, this might be of help:
> 
> https://github.com/miyako/4d-component-sublaunch
> 
> ---
> 
> C_TEXT($1;$0;$param)
> 
> If (Count parameters#0)
> 
> $param:=$1
> 
> C_LONGINT($platform;$i;$len)
> PLATFORM PROPERTIES($platform)
> 
> If ($platform=Windows)
> 
>   //argument escape for cmd.exe; other commands (curl, ruby, etc.) 
> may be incompatible
> 
> $shoudQuote:=False
> 
> $metacharacters:="&|<>()%^\" "
> 
> $len:=Length($metacharacters)
> 
> For ($i;1;$len)
> $metacharacter:=Substring($metacharacters;$i;1)
> $shoudQuote:=$shoudQuote | (Position($metacharacter;$param;*)#0)
> If ($shoudQuote)
> $i:=$len
> End if
> End for
> 
> If ($shoudQuote)
> If (Substring($param;Length($param))="\\")
> $param:="\""+$param+"\\\""
> Else
> $param:="\""+$param+"\""
> End if
> End if
> 
> Else
> 
> $metacharacters:="\\!\"#$%&'()=~|<>?;*`[] "
> 
> For ($i;1;Length($metacharacters))
> $metacharacter:=Substring($metacharacters;$i;1)
> $param:=Replace string($param;$metacharacter;"\\"+$metacharacter;*)
> End for
> 
> End if
> 
> End if
> 
> $0:=$param
> 
> 
> 
> **
> 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
> **

Hell is other people 
 Jean-Paul Sartre
**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Keith Goebel via 4D_Tech
I think the “standard behaviour” answer is a mistake on the part of 4D, and I 
hope they will reconsider their stand on this.
As others have said, “Target:=value“ should always mean the target gets changed 
to the value. 
Anything else is “non-standard behaviour”.
It may be tricky to make it happen in this instance, but it needs to be done. 
Just my $0.02…
KG

> If it is true that this wasn’t implemented as we naturally think it should 
> have been for performance reasons, I’d like to express that I would prefer it 
> to be slower and know that it is saved than faster and find out later it 
> wasn’t saved.
**
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: Working with a 64 bit Integer in an object

2017-11-01 Thread Arnaud de Montard via 4D_Tech

> Le 1 nov. 2017 à 21:16, David Adams via 4D_Tech <4d_tech@lists.4d.com> a 
> écrit :
> 
> I know it's a field type, but can you touch it with anything other than SQL?

I'm wondering since a while about this: 64 bit is 128/2, 128 is a uuid, a uuid 
can be managed in langage as hexadecimal string and there is a uuid type field. 
Unfortunately I don't know how to convert a 64 bit number to hexadecimal. 

-- 
Arnaud de Montard 





**
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: open gmail in browser from 4D

2017-11-01 Thread Keisuke Miyako via 4D_Tech
how about

OPEN URL("https://mail.google.com/;)

you could analyse the absolute path to reach a particular folder,
but they could change at any time.

and if the user is not already logged in to Google on their browser,
they'd be redirected anyway.



**
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 - LEP and MS-DOS command line

2017-11-01 Thread Keisuke Miyako via 4D_Tech
Hello,

if <>x_Quote+$Path ends with a directory symbol,
double-quoting the string isn't enough,
the directory symbol is also an escape prefix,
so you have an open-ended escaped-double quote if that makes any sense.

for a more robust (that is, than just surrounding the string with double quotes)
way to escape parameters, this might be of help:

https://github.com/miyako/4d-component-sublaunch

---

C_TEXT($1;$0;$param)

If (Count parameters#0)

$param:=$1

C_LONGINT($platform;$i;$len)
PLATFORM PROPERTIES($platform)

If ($platform=Windows)

  //argument escape for cmd.exe; other commands (curl, ruby, etc.) may be 
incompatible

$shoudQuote:=False

$metacharacters:="&|<>()%^\" "

$len:=Length($metacharacters)

For ($i;1;$len)
$metacharacter:=Substring($metacharacters;$i;1)
$shoudQuote:=$shoudQuote | (Position($metacharacter;$param;*)#0)
If ($shoudQuote)
$i:=$len
End if
End for

If ($shoudQuote)
If (Substring($param;Length($param))="\\")
$param:="\""+$param+"\\\""
Else
$param:="\""+$param+"\""
End if
End if

Else

$metacharacters:="\\!\"#$%&'()=~|<>?;*`[] "

For ($i;1;Length($metacharacters))
$metacharacter:=Substring($metacharacters;$i;1)
$param:=Replace string($param;$metacharacter;"\\"+$metacharacter;*)
End for

End if

End if

$0:=$param



**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Tim Nevels via 4D_Tech
On Nov 1, 2017, at 4:01 PM, Timothy Penner wrote:

> I am sorry if you do not see the information I am providing as helpful. I 
> sincerely feel bad for the people who have been bitten by this bug and I am 
> trying to help the situation by asking the doc team to update the docs, and 
> also at the same time, I am explaining to you and the community the correct 
> process if you (or anyone) would like to see this behavior changed.

That’s what is needed. Document this behavior so that it known and can be dealt 
with. Then it is up to every developer to read the documentation and not forget 
this special situation. I know that I’ll never forget this situation after this 
long email thread. So there’s really no need for me to submit a feature 
request. I have no need for it now. I just have to be careful when dealing with 
object fields. 

As for new 4D developers, they need to RTFM. If they don’t and they get bit by 
this, that their problem. It’s documented feature of 4D. 

> This whole thing reminds me of an old saying: you can lead a horse to water 
> but you cannot force them to drink.

You know that’s right. I just hate the taste of the 4D Forums' water so I 
seldom go there to drink it. The water tastes good here. :)

Tim


Tim Nevels
Innovative Solutions
785-749-3444
timnev...@mac.com


**
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: SQL error

2017-11-01 Thread Chip Scheide via 4D_Tech
that explains the fact that a restart of 4D fixed the issue!

On Wed, 1 Nov 2017 16:10:46 -0500, Richard Wright via 4D_Tech wrote:
> I’ve seen Nested Begin/End SQL errors when a previous statement did 
> not complete. If you get an error and then abort the code it’s left 
> open and the next time you try to run you get this kind of error.
> 
> 
> Richard Wright
> DataDomain
> rwri...@datadomainsoftware.com
> 
> 
>> Date: Wed, 1 Nov 2017 10:48:29 -0600
>> From: David Witton 
>> 
>> Milan
>> 
>> Thanks - after I posted, I caught that and corrected, but still get the
>> same error.
>> 
>> On Wed, Nov 1, 2017 at 10:06 AM, Milan Adamov via 4D_Tech <
>> 4d_tech@lists.4d.com> wrote:
>> 
>>> No “:” in front of $arrCount?
>>> 
>>> Milan
>>> 
>>> Sent from my iPad
>>> 
 On Nov 1, 2017, at 17:04, David Witton via 4D_Tech <4d_tech@lists.4d.com>
>>> wrote:
 
 Here's a SQL block that throws Error code: 1427, Nested Begin/End SQL not
 allowed.
 
 Begin SQL
 SELECT Athena.First_Name, Athena.Last_Name, Athena.DOB, Count(*) as
>>> recCount
 from Athena
 Group by Athena.First_Name,Athena.Last_Name,Athena.DOB
 HAVING Count (*)>1
 into :$arrFld1,:$arrFld2,:$arrFld3, $arrCount;
 End SQL
> 
> 
> 
> 
> **
> 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
> **
---
Gas is for washing parts
Alcohol is for drinkin'
Nitromethane is for racing 
**
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: SQL error

2017-11-01 Thread Richard Wright via 4D_Tech
May I kindly suggest reading a basic primer on SQL. 

> Date: Wed, 1 Nov 2017 17:15:01 +
> From: Timothy Penner 
> 
> I think you have multiple issues with this SQL Statement.
> 
> I don’t think you can select a COUNT(*) along with other fields in the same 
> SQL Statement;
> Count returns a number, not an array.
> While the fields return an array.
> 
> In addition to that, what is 'HAVING Count(*) > 1' supposed to do?
> 
> And then as already mentioned you were missing the : before the variable.
> 
> See also: http://livedoc.4d.com/4Dv15/help/Command/en/page18316.html
> 
> -Tim

**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Timothy Penner via 4D_Tech
> Does 4D realize that *officially* ignoring their customers isn't exactly an 
> example of great customer service.

I am not ignoring customers; I am responding. I am directing people in the 
right direction, the direction of the official channels... My intent is to help 
the customers get better results by explaining what the official channels for 
reporting things are.

Official requests for help/answers should be filed through taow.4d.com
Official feature requests should be filed through forums.4d.com
Official bug reports go on the forums.4d.com but partners can get additional 
help via taow.4d.com

I will say it again, the iNUG is not an official channel for reporting issue, 
bugs, or feature requests. This has been said over and over for years, nothing 
has changed.

> This whole business that somehow it's our fault that we're not "doing it 
> right" just doesn't sell. I mean, 4D can say that - but how many people does 
> it convince? I doubt it's more than a handful, if even that.

I am sorry if me redirecting people to the forums is interpreted as saying 
"your doing it wrong" - I am trying to help the community get better results by 
telling them the appropriate place to make such a request (in case you missed 
it, the forums is the appropriate place).

> The only obvious interpretation is that 4D doesn't want to be bothered with 
> feature requests and bug reports (even on the Forums, frankly).

The feature request forums is visible to the public, you do not even need to 
login to view it. Having the feature request forums visible to the public adds 
a layer of transparency to the process because now everyone can see the 
discussion regarding the requests. Logged in users can reply and help refine 
the request by adding their viewpoint or interpretation of how it could be made 
better. In addition to this, everything is logged to a database (not in a 
mailbox).

I don’t see how this leads someone to think 4D doesn’t want to be bothered with 
the requests. In fact, we do want to see the requests - we want to see them so 
badly that we have a dedicated place for them to be posted. Please us it.

-Tim



**
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: identify duplicates

2017-11-01 Thread Reiner Kief via 4D_Tech
What about comparing hashes?

> Am 31.10.2017 um 21:40 schrieb David Witton via 4D_Tech 
> <4d_tech@lists.4d.com>:
> Does anyone have a suggestion on how to proceed?


Reiner Kief
Software & IT-Consulting
Weinbergstrasse 45
63853 Moemlingen
Germany

www.kief-online.de
Member of the german developer network die4DWerkstatt









**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread David Adams via 4D_Tech
> So, if you want to officially request such a change, it needs to go on
the forums.

Does 4D realize that *officially* ignoring their customers isn't exactly an
example of great customer service.

I tried the forums for about six months, I don't think I got _any_
information from 4D Engineering, but I sure did get told I was wrong a lot.
About matters of fact and opinion.

And, to date, I have seen zero evidence that participating on the Forums
does anything at all to forward the cause of bugs or features getting fixed.

This whole business that somehow it's our fault that we're not "doing it
right" just doesn't sell. I mean, 4D can say that - but how many people
does it convince? I doubt it's more than a handful, if even that.The only
obvious interpretation is that 4D doesn't want to be bothered with feature
requests and bug reports (even on the Forums, frankly). Hey, your company,
your rules...but it doesn't make 4D come across as customer-focused.

But, again, it's entirely up to 4D how to deal with their business. But,
please, quit saying that the problems with customer service are the
customers.
**
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: Working with a 64 bit Integer in an object

2017-11-01 Thread David Adams via 4D_Tech
Yeah, if 4D isn't working, try NTK. In either case, if you can get at the
value as raw text then you'll be able to find text --> 64-bit conversion
code. The question in 4D at that point is how to store it. I know it's a
field type, but can you touch it with anything other than SQL?
**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Timothy Penner via 4D_Tech
Hi Tim,

We have official channels for reporting issues, feature requests, and bugs.
- Requests for help/answers are handled through taow.4d.com
- Feature requests are handled through forums.4d.com
- Bugs are also handled through the forums but partners can get help filing the 
bug via taow.4d.com

The iNUG is a discussion list - it is not an *official* channel for any of the 
above listed items.

It's really confusing to me to see so much discussion about changing a 
particular feature; however no official request has been filed on the feature 
requests forums to see this behavior changed. It sounds like you (and maybe 
others also) have no desire to post an official request to the forums.

I am sorry if you do not see the information I am providing as helpful. I 
sincerely feel bad for the people who have been bitten by this bug and I am 
trying to help the situation by asking the doc team to update the docs, and 
also at the same time, I am explaining to you and the community the correct 
process if you (or anyone) would like to see this behavior changed.

This whole thing reminds me of an old saying: you can lead a horse to water but 
you cannot force them to drink.

-Tim PENNER




**
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
**

Working with a 64 bit Integer in an object

2017-11-01 Thread Justin Leavens via 4D_Tech
Is it possible to work with a 64 bit integer that's being returned to me in
an object from an HTTP call? I can't seem to avoid it being turned into
"-1.502644539978e+18". I also have a POST that requires me to pass back the
64-bit int value. I would use 4D or NTK for the object handling if it made a
difference. 

The only way I can see it's possible would be to just manually parse the
text response instead of treating the response as an object. But that's a
drag since it's coming back in an array. 

thanks for any ideas.



--
Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Tim Nevels via 4D_Tech
On Nov 1, 2017, at 2:00 PM, Timothy Penner wrote:

>> It is good we are having this discussion because this will lead to a 
>> change/solution to this issue.
> 
> This discussion would more constructive if it took place on the Feature 
> Request forum.
> 
> As described in tech tip 76725;
> {
> Feature requests are handled on the 4D Forums: 
> http://forums.4d.fr/Forum/FR/1075213/0/0
> 
> Having the feature requests handled through the forums is quite valuable to 
> the community because of the following:
> 
> 1. 4D Engineering participates on the 4D Forums, so you have the opportunity 
> to discuss the feature request in a more immediate fashion.
> 
> 2. Other users can participate in the feature request discussion and help 
> refine the feature request so that it is appealing to more users. Also, the 
> more users who participate in the discussion, the more visibility that 
> particular feature request will have.
> }
> 
> So, if you want to officially request such a change, it needs to go on the 
> forums.

Thanks for reminding me that everything talked about on this mailing list never 
reaches 4D Engineering. I keep forgetting that this is just a place for people 
to help each other. It’s not the place to offer improvements to the 4D product 
that have any chance of actually producing a change. 

And of course it is not your job to take information you read hear and pass it 
on to 4D Engineering because you think it is a good idea and would improve the 
4D product. That’s the job of us 4D developers to do that. And the only chance 
of that happening is to create a feature request on 4D Forms. 

I keep forgetting that you are participating on this mailing list to help the 
members with their problems. You are not a conduit to pass on information and 
topics discussed here to 4D Engineering. 

Makes me think of that saying “what happens in Las Vegas stays in Las Vegas”. 
What is said on the iNUG stays on the iNUG and goes no further. 

I won’t be making a feature request asking for a change regarding this issue. I 
really don’t know what to do to fix/resolve this problem. I was just offering 
ideas. 

Tim


Tim Nevels
Innovative Solutions
785-749-3444
timnev...@mac.com


**
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: SQL error

2017-11-01 Thread Chuck Miller via 4D_Tech
Hi all
I have noted in the past that fn calls fail when you have an existing method 
turn it into fn call and r5un unless you restart. If you create a new method 
and mark as fn no restart is needed.

Regards

Chuck

 Chuck Miller Voice: (617) 739-0306
 Informed Solutions, Inc. Fax: (617) 232-1064   
 mailto:cjmillerinformed-solutions.com 
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D and Sybase connectivity
  http://www.informed-solutions.com  

This message and any attached documents contain information which may be 
confidential, subject to privilege or exempt from disclosure under applicable 
law.  These materials are intended only for the use of the intended recipient. 
If you are not the intended recipient of this transmission, you are hereby 
notified that any distribution, disclosure, printing, copying, storage, 
modification or the taking of any action in reliance upon this transmission is 
strictly prohibited.  Delivery of this message to any person other than the 
intended recipient shall not compromise or waive such confidentiality, 
privilege or exemption from disclosure as to this communication. 

> On Nov 1, 2017, at 1:15 PM, Timothy Penner via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> I think you have multiple issues with this SQL Statement.
> 
> I don’t think you can select a COUNT(*) along with other fields in the same 
> SQL Statement;
> Count returns a number, not an array.
> While the fields return an array.
> 
> In addition to that, what is 'HAVING Count(*) > 1' supposed to do?
> 
> And then as already mentioned you were missing the : before the variable.
> 
> See also: http://livedoc.4d.com/4Dv15/help/Command/en/page18316.html
> 
> -Tim
> 
> 
> 
> **
> 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
> **

**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Kirk Brooks via 4D_Tech
Tim,

On Wed, Nov 1, 2017 at 10:13 AM, Tim Nevels via 4D_Tech <
4d_tech@lists.4d.com> wrote:

> On Nov 1, 2017, at 11:04 AM, Keisuke Miyako wrote:
>
> > like a global preference, to the effect of
> >
> > "Call OB Copy implicitly when performing object assignments"
> >
> > it is an interesting point of view,
> > to frame it as an issue of the assignment operator being different,
> > as opposed to how objects and their properties are different "because
> they are references".
>

I agree with you it would be great to have a specific operator. To me that
would be :==  to mean OB COPY instead of OB ASSIGN REF (or whatever what
happens now should be called). That way there would be no ambiguity about
you want which is important for shared code or components.
No idea how practical that is since it would only be valid with a
particular data type. I would love to see  == added as a type specific
comparator too but that's another thread.


>
> I like that idea. If you are an “expert” or an optimization fanatic
> working to reduce every millisecond and every byte of memory used, you turn
> the preference OFF. Everything works like it currently does. You know what
> your are doing and if you make a mistake, it’s on you.
>

​Thinking about this - let's say I have a situation where I regularly need
to use APPLY TO SELECTION to all or a large number of records​ (large =
100ks or a million) and these might be records in a 'mature' structure so
they may have lots and lots of fields including some object fields and
maybe even some blobs and big text fields (all stored in the record for
sake of argument). The time to run this command will depend on how many
records actually have to be written to disk. If the ATS is something like a
method that marks records as "done" if some criteria is met most, maybe
all, records might not be changed. This wouldn't be an optimization of
milliseconds if each record was re-written even if it didn't change. Just
speculating but this is could explain why 4D does what it does. Of course
if a method is applied that updates the 'done' key in an object field...
it's good we know to also make some field level mod to trigger the save
action.

OTOH - if I have a database where such situations would never occur (though
I hate to assume 'never') and I use object fields a lot (and I do) having
the option to tell 4D to always rewrite a record on save would be useful.

This doesn't bother me really. Sometimes I use 4D to build a race car and
sometimes I use it to build a tractor. The cool thing is I can use it to
build both. The complication is I can use it to build both. It's up to me
not to put 4' tall tires on the race car and not to put the high speed
transmission in the tractor even though I can.

My perspective - this is a quirk of 4D resulting from mashing up JSON,
about as loosey goosey a data transfer protocol as you can get (well,
there's REN), with a strictly typed language. It works but there are
issues. This is an issue. Which means it needs to be known and documented.
I don't want to beat up on the folks maintaining the docs so I agree with
the earlier comment about the value of user (developer) comments on the
docs for calling out such things.

-- 
Kirk Brooks
San Francisco, CA
===

*The only thing necessary for the triumph of evil is for good men to do
nothing.*

*- Edmund Burke*
**
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
**

open gmail in browser from 4D

2017-11-01 Thread Chuck Miller via 4D_Tech
Hi All

4d Version 15.x. I want to be able to open a new mail message when company uses 
google mail in a browser window. Google hosts their domain. Has anyone done 
this. I need a solution for macs and windows. Has anyone done this. I have 
tried open URL and it only opens Mail on my mac. Not sure what happens on 
windows
Command used open url (Ihave tried “mailto:email”;”mail for gmail”) top no avail

Thanks and regards

Chuck

 Chuck Miller Voice: (617) 739-0306
 Informed Solutions, Inc. Fax: (617) 232-1064   
 mailto:cjmillerinformed-solutions.com 
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D and Sybase connectivity
  http://www.informed-solutions.com  

This message and any attached documents contain information which may be 
confidential, subject to privilege or exempt from disclosure under applicable 
law.  These materials are intended only for the use of the intended recipient. 
If you are not the intended recipient of this transmission, you are hereby 
notified that any distribution, disclosure, printing, copying, storage, 
modification or the taking of any action in reliance upon this transmission is 
strictly prohibited.  Delivery of this message to any person other than the 
intended recipient shall not compromise or waive such confidentiality, 
privilege or exemption from disclosure as to this communication. 

**
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: SQL error

2017-11-01 Thread David Witton via 4D_Tech
Tim

Aside from the missing colon - which had been corrected - I also believe
the statement is valid, since it's working in another method in the DB. To
eliminate copy and past errors, I retyped the SQL block, but still got the
error.

What I didn't do is quit and restart 4D - after that the code ran as
expected.

Go figure.

On Wed, Nov 1, 2017 at 12:02 PM, Timothy Penner via 4D_Tech <
4d_tech@lists.4d.com> wrote:

> > I think you have multiple issues with this SQL Statement.
>
> I was wrong. I didn’t fully understand the SQL statement at the time of my
> last reply, upon further inspection it seems the SQL is valid (apart from
> the missing : in the variable reference).
>
> There must be something else wrong, like using this statement inside of a
> SQL function {fn} call for example. I think we are missing some context
> about how you are using this method, because executing this code in a
> method by itself is working in a sample database here.
>
> -Tim
>
>
>
> **
> 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
> **
>



-- 
David Witton
**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Tom Swenson via 4D_Tech


On 11/1/17, 2:08 PM, "4D_Tech on behalf of Tom Swenson via 4D_Tech" 
<4d_tech-boun...@lists.4d.com on behalf of 4d_tech@lists.4d.com> wrote:

➢ And, yes, I too was told that the engineers were leaning to declaring 
this as standard behavior. Why? I have not a clue.

Ooops, I was just going to chime that it was probably easier to declare it 
as default behavior rather than “fix” it.

**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Tom Swenson via 4D_Tech
➢ And, yes, I too was told that the engineers were leaning to declaring this as 
standard behavior. Why? I have not a clue.


**
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: SQL error

2017-11-01 Thread Timothy Penner via 4D_Tech
> I think you have multiple issues with this SQL Statement.

I was wrong. I didn’t fully understand the SQL statement at the time of my last 
reply, upon further inspection it seems the SQL is valid (apart from the 
missing : in the variable reference).

There must be something else wrong, like using this statement inside of a SQL 
function {fn} call for example. I think we are missing some context about how 
you are using this method, because executing this code in a method by itself is 
working in a sample database here.

-Tim



**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Timothy Penner via 4D_Tech
> It is good we are having this discussion because this will lead to a 
> change/solution to this issue.

This discussion would more constructive if it took place on the Feature Request 
forum.

As described in tech tip 76725;
{
Feature requests are handled on the 4D Forums: 
http://forums.4d.fr/Forum/FR/1075213/0/0

Having the feature requests handled through the forums is quite valuable to the 
community because of the following:

1. 4D Engineering participates on the 4D Forums, so you have the opportunity to 
discuss the feature request in a more immediate fashion.

2. Other users can participate in the feature request discussion and help 
refine the feature request so that it is appealing to more users. Also, the 
more users who participate in the discussion, the more visibility that 
particular feature request will have.
}

So, if you want to officially request such a change, it needs to go on the 
forums.

Kind Regards,

Tim PENNER





**
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: SQL error

2017-11-01 Thread Timothy Penner via 4D_Tech
I think you have multiple issues with this SQL Statement.

I don’t think you can select a COUNT(*) along with other fields in the same SQL 
Statement;
Count returns a number, not an array.
While the fields return an array.

In addition to that, what is 'HAVING Count(*) > 1' supposed to do?

And then as already mentioned you were missing the : before the variable.

See also: http://livedoc.4d.com/4Dv15/help/Command/en/page18316.html

-Tim



**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Tim Nevels via 4D_Tech
On Nov 1, 2017, at 11:04 AM, Keisuke Miyako wrote:

> like a global preference, to the effect of
> 
> "Call OB Copy implicitly when performing object assignments"
> 
> it is an interesting point of view,
> to frame it as an issue of the assignment operator being different,
> as opposed to how objects and their properties are different "because they 
> are references".

I like that idea. If you are an “expert” or an optimization fanatic working to 
reduce every millisecond and every byte of memory used, you turn the preference 
OFF. Everything works like it currently does. You know what your are doing and 
if you make a mistake, it’s on you. 

Existing databases upgraded to the new version have this preference turned OFF. 
So it functions the same as it does now. But for newly created databases this 
preference is turned ON. So a new 4D developer does not have to deal with this 
issue/problem. But the “expert” developer can go turn this preference OFF.

Or maybe you could add a new assignment operator like “==“. You modify how “:=“ 
works with object fields so it does the “implicit copy assignment” you talk 
about. But if you are an “expert” and know what you are doing, then you use the 
new “==“ assignment operator. This does this reference assignment thing that 
the current “:=“ operator does for objects. 

Then you have the best of both worlds. Experts can get the optimizations or 
whatever with “==“. The rest of us won’t care and just use good old “:=“ and 
know it works as expected in all situations. No need to think about all this 
reference stuff.

The big problem is there is a lot of code out there dealing with objects. So 
changing how object assignments and references could break existing code that 
relies on these features and probably don’t even know it. 

Just throwing out ideas. I don’t know what would be the correct solution. 

It is good we are having this discussion because this will lead to a 
change/solution to this issue.

Tim


Tim Nevels
Innovative Solutions
785-749-3444
timnev...@mac.com


**
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: identify duplicates

2017-11-01 Thread Janet Jonas via 4D_Tech
Here is a strategy I have used since V6 to enforce a semi-informal primary key 
for records in an important file. Another parameter was added when our business 
changed a few years ago. I think you could make it work for your task:

C_BOOLEAN($0;$DupExists)
C_TEXT($2;$3;$Value1;$Value2)
C_LONGINT($1;$CurrentKey;$4;$Value3)

$CurrentKey:=$1
$Value1:=$2
$Value2:=$3
If (Count parameters>3)
$Value3:=$4
Else
Value3:=0
End if 

$DupExists:=False

CREATE SET([Contracts];"Duplicates")
SET QUERY DESTINATION(Into set;"Duplicates")

QUERY([Table];[Table]Value1=$Value1;*)
QUERY([Table]; & ;[Table]Value2=$Value2;*)
if($Value3#0)
QUERY([Table]; & ;[Table]CAID=$Value3;*)
End if
QUERY([Table]; & ;[Table]Key#$CurrentKey)  //In case record we are checking has 
already been saved

If (Records in set("Duplicates")>0)
$DupExists:=True
End if 
SET QUERY DESTINATION(Into current selection)
CLEAR SET("Duplicates")

$0:=$DupExists

JJ


> On Oct 31, 2017, at 3:12 PM, 4d_tech-requ...@lists.4d.com wrote:
> 
> Message: 4
> Date: Tue, 31 Oct 2017 14:40:50 -0600
> From: David Witton >
> To: 4D iNug Technical <4d_tech@lists.4d.com >
> Subject: identify duplicates
> Message-ID:
>    >
> Content-Type: text/plain; charset="UTF-8"
> 
> I'm looking for a strategy to identify duplicate records in a table - that
> is, records for which 3 fields are identical across two or more records -
> or in another case, where a single field is not unique.
> 
> Does anyone have a suggestion on how to proceed?
> 
> -- 
> David Witton
> 
> 

**
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: SQL error

2017-11-01 Thread David Witton via 4D_Tech
Milan

Thanks - after I posted, I caught that and corrected, but still get the
same error.

On Wed, Nov 1, 2017 at 10:06 AM, Milan Adamov via 4D_Tech <
4d_tech@lists.4d.com> wrote:

> No “:” in front of $arrCount?
>
> Milan
>
> Sent from my iPad
>
> > On Nov 1, 2017, at 17:04, David Witton via 4D_Tech <4d_tech@lists.4d.com>
> wrote:
> >
> > Here's a SQL block that throws Error code: 1427, Nested Begin/End SQL not
> > allowed.
> >
> > Begin SQL
> > SELECT Athena.First_Name, Athena.Last_Name, Athena.DOB, Count(*) as
> recCount
> > from Athena
> > Group by Athena.First_Name,Athena.Last_Name,Athena.DOB
> > HAVING Count (*)>1
> > into :$arrFld1,:$arrFld2,:$arrFld3, $arrCount;
> > End SQL
> >
> >
> **
> 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
> **




-- 
David Witton
**
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: SQL error

2017-11-01 Thread Milan Adamov via 4D_Tech
No “:” in front of $arrCount?

Milan

Sent from my iPad

> On Nov 1, 2017, at 17:04, David Witton via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> Here's a SQL block that throws Error code: 1427, Nested Begin/End SQL not
> allowed.
> 
> Begin SQL
> SELECT Athena.First_Name, Athena.Last_Name, Athena.DOB, Count(*) as recCount
> from Athena
> Group by Athena.First_Name,Athena.Last_Name,Athena.DOB
> HAVING Count (*)>1
> into :$arrFld1,:$arrFld2,:$arrFld3, $arrCount;
> End SQL
> 
> 
**
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
**

SQL error

2017-11-01 Thread David Witton via 4D_Tech
Here's a SQL block that throws Error code: 1427, Nested Begin/End SQL not
allowed.

Begin SQL
SELECT Athena.First_Name, Athena.Last_Name, Athena.DOB, Count(*) as recCount
from Athena
Group by Athena.First_Name,Athena.Last_Name,Athena.DOB
HAVING Count (*)>1
into :$arrFld1,:$arrFld2,:$arrFld3, $arrCount;
End SQL

First, I copied it directly from another method in the same DB that
references another table. I just changed the table and field names- that
method works correctly.

Next, I retyped the block from scratch - still the same result.

Any ideas on what to try next are welcome.
-- 
David Witton
**
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: identify duplicates

2017-11-01 Thread Chip Scheide via 4D_Tech
One of the things others have mentioned, but have not really expounded 
upon...
What constitutes a duplicate?
For an individual field this can be complex, for multiple fields...

For some data types (numerics) a duplicate is easy to define
2 = 2 = 2 = 2 (integer/long integer)

For others (text) it is not simple.
A = A
But does 
A = a ?
or
A = ? (such as A[or a] + umlaut) 

Does
Mike MacKenzie = MacKenzie, Mike ?

If you have 3 fields which you are looking to locate duplication it 
becomes more of an issue (assuming each field is text).
It also could be an issue depending on how the 3 fields are 
concatenated.
ex.  Name + longint ID + street address

How is the name constructed? is it consistent across all data (Mike 
MacKenzie vs MacKenzie Mike vs Michael MacKenzie)
How is the longint ID converted to text?  String(ID), or 
String(ID;), is the padding long enough?
How is the street Name constructed? Number Street Name Designation (123 
East West Ave)
Is the street name construct consistent across all data? (123 East West 
Ave vs 123 East West vs 123 East West Avenue)

Assuming (a BIG assumption), that the data is 'clean', i.e. all the 
data is formatted similarly) a couple of approaches:
- might be to use the function DISTINCT VALUES (with counting option On 
- if available in your version of 4D) on all 3 fields independently 
then use one of the arrays to loop over the data looking for duplicate 
values in the other fields.

- if you can modify the data (add a field to the table), and the amount 
of data is not too large, or you have very little execution time 
constraint, you could add a field which would hold the concatenated 3 
field values, then use DISTINCT VALUES.

- I have not really worked with this aspect of 4D, so I am not sure, 
but I know that it is possible to build a composite index (2 [or more?] 
fields to make a single index. Whether you can use the composite index 
with DISTINCT VALUES I am not sure.

I'm sure there are ways in which the approach can be made efficient, 
but it will definitely depend on the data, and what constitutes a 
duplicate.

On Tue, 31 Oct 2017 14:40:50 -0600, David Witton via 4D_Tech wrote:
> I'm looking for a strategy to identify duplicate records in a table - that
> is, records for which 3 fields are identical across two or more records -
> or in another case, where a single field is not unique.
> 
> Does anyone have a suggestion on how to proceed?
> 
> -- 
> David Witton
> **
> 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
> **
---
Gas is for washing parts
Alcohol is for drinkin'
Nitromethane is for racing 
**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Arnaud de Montard via 4D_Tech

> Le 1 nov. 2017 à 02:46, Tim Nevels via 4D_Tech <4d_tech@lists.4d.com> a écrit 
> :
> 
> The real “sloppy” part is that this was not documented with a big red flag 
> saying something like “object fields don’t work like other fields so if you 
> do this … it does not work the same as if you do that to any other field 
> types. The workaround is to do...” 

User comments are made for that, IMHO. 
 
(one has to be connected to add comment)
Despite poor editor and interest of 4D for this feature:
- obvious place for a remark, an example, etc. 
- good reminder in case I don't remember later 
- other users can see it 
- doc team will integrate it if they think it's relevant

-- 
Arnaud de Montard 





**
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: identify duplicates

2017-11-01 Thread Arnaud de Montard via 4D_Tech

> Le 31 oct. 2017 à 21:40, David Witton via 4D_Tech <4d_tech@lists.4d.com> a 
> écrit :
> 
> I'm looking for a strategy to identify duplicate records in a table - that
> is, records for which 3 fields are identical across two or more records -
> or in another case, where a single field is not unique.
> 
> Does anyone have a suggestion on how to proceed?

I have some code to find duplicates of a combination of N fields in a given 
selection. The result is a sub selection of found duplicates. Is that the need? 
Surely not the fastest solution, BTW… 

-- 
Arnaud de Montard 




**
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: pointers to arrays

2017-11-01 Thread Arnaud de Montard via 4D_Tech

> Le 31 oct. 2017 à 21:47, Kirk Brooks via 4D_Tech <4d_tech@lists.4d.com> a 
> écrit :
> 
> Peter,
> This is easy to do with local arrays and dynamic variables. It looks like
> you only need to build text arrays. You can declare a local array, ARRAY
> TEXT($aText2d;0;0). Then you can resize this to add more 'columns' as
> needed and populate them.

I'd choose that too: 2D arrays to grab imported data, listbox if display is 
needed. 
Creating records after will be easy and fast with array to selection. 
To convert an array text in array else, here's some code that I use: 


-- 
Arnaud de Montard 




**
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: [Warning] Settings properties values on object field by object notation

2017-11-01 Thread Peter Bozek via 4D_Tech
On Wed, Nov 1, 2017 at 2:17 AM, Keisuke Miyako via 4D_Tech <
4d_tech@lists.4d.com> wrote:

>
> to explicitly indicate that the object has been modified, just use the line
>
> [myTable]myObjectField:=[myTable]myObjectField
>

YEs, I use wrapper around SAVE RECORD, so can put there

Field($passedTable;1)->:= Field($passedTable;1)-->

Clumsy, but will work.


> and you have total control of when to save the field,
> which results in better performance, immediately as well as in the long
> term.
>
> to me this sounds like a better deal than a blanket "save always" system
> (the real sloppy design choice, in my opinion)
>
>
I undertand this dilemma, it is well understood from other email in this
thread:

a direct assignment
via dot notation
via set object
via set (sub)object
via martians landing in Washington D.C

it should NOT matter how the modification occurred - a modification
occurred - save the change(s) if requested .



"Set via subobject" means something like
$subObject:=OB GET([Table]ObjectField;"subobject";is object)
subObject.property:="value"

or, in one line
OB SET(OB GET([Table]ObjectField;"subobject";is object);"property";"value")

Now, it is quite difficult to argue that this should set modifier flag to
true, even if it modifies object field (lazy to test, but I gather it would
not, so the point is moot.)

Problem is different: if developer modifies record and calls SAVE RECORD,
he awaits that the record is saved. If it means that records is saved when
it does not need to be, so be it. If the records is not saved when it needs
to be, it is a bug, not sloppy design choice (although understandable
sloppy design choice.)

--

Peter Bozek
**
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
**