Re: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-16 Thread Chuck Miller via 4D_Tech
In principal no problem, however it is harder and harder to maintain. I would 
say fix in one full swoop. Also I would not use 4D to create and index new 
primary keys using the wizard. I would role my own code. I have posted this 
code in the past so if you look at archives you should find it.


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 Jun 14, 2019, at 11:11 AM, Narinder Chandi via 4D_Tech 
> <4d_tech@lists.4d.com> wrote:
> 
> Hi. In principle, nothing wrong with option 2 I'd say. I think the issue 
> often with fixing as you go is that we all work with code that we haven't 
> touched in months or even years so arguably these would never be fixed - 4D 
> has flagged these as obsolete since v15 and I hadn't touched any of the 
> instances so far!
> 
> In the end, after evaluating scope of usage and potential issues I went ahead 
> and converted them all. Job done!
> 
> Regards,
> 
> Narinder Chandi,
> ToolBox Systems Ltd.

**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-14 Thread Narinder Chandi via 4D_Tech
Jim,

Hi. In principle, nothing wrong with option 2 I'd say. I think the issue often 
with fixing as you go is that we all work with code that we haven't touched in 
months or even years so arguably these would never be fixed - 4D has flagged 
these as obsolete since v15 and I hadn't touched any of the instances so far!

In the end, after evaluating scope of usage and potential issues I went ahead 
and converted them all. Job done!

Regards,
 
Narinder Chandi,
ToolBox Systems Ltd.
-- 

-Original Message-
From: 4D_Tech <4d_tech-boun...@lists.4d.com> on behalf of 4D Tech Mailing List 
<4d_tech@lists.4d.com>
Reply-To: 4D Tech Mailing List <4d_tech@lists.4d.com>
Date: Friday, 14 June 2019 at 15:46
To: 4D Tech Mailing List <4d_tech@lists.4d.com>
Cc: Jim Crate 
Subject: Re: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING 
Commands

On Jun 7, 2019, at 8:48 AM, Narinder Chandi via 4D_Tech 
<4d_tech@lists.4d.com> wrote:
> 
> Hi all. I am migrating a v15 database to v17, 4D Server running on Mac. I 
need some opinions as to what to do with regards to converting commands marked 
as obsolete as per this article:
[snip]
> I have searched the archives on this topic but opinions seem to be 
divided on whether or not to do this conversion? Perhaps I am mistaken, but I 
am of the opinion that it will have to be done sooner or later as 4D reserves 
the right to remove obsoleted commands and will eventually do so?
> 
> TL;DR the options are:
> 1. Replace
> 2. Do nothing for v17

Is there anything wrong with option 2, and just fixing these as you update 
the code around them? The commands still work in v17, even subtables still seem 
to work. I may replace the subtable this time around just because it’s only 
used a couple places and it’s a convenient time to change the structure.

My personal approach with 4D is to wait until I have to touch working code, 
since perhaps by the time the commands don’t work there will be language 
enhancements that make me want to touch the code. 

Jim Crate

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


**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-14 Thread Jim Crate via 4D_Tech
On Jun 7, 2019, at 8:48 AM, Narinder Chandi via 4D_Tech <4d_tech@lists.4d.com> 
wrote:
> 
> Hi all. I am migrating a v15 database to v17, 4D Server running on Mac. I 
> need some opinions as to what to do with regards to converting commands 
> marked as obsolete as per this article:
[snip]
> I have searched the archives on this topic but opinions seem to be divided on 
> whether or not to do this conversion? Perhaps I am mistaken, but I am of the 
> opinion that it will have to be done sooner or later as 4D reserves the right 
> to remove obsoleted commands and will eventually do so?
> 
> TL;DR the options are:
> 1. Replace
> 2. Do nothing for v17

Is there anything wrong with option 2, and just fixing these as you update the 
code around them? The commands still work in v17, even subtables still seem to 
work. I may replace the subtable this time around just because it’s only used a 
couple places and it’s a convenient time to change the structure.

My personal approach with 4D is to wait until I have to touch working code, 
since perhaps by the time the commands don’t work there will be language 
enhancements that make me want to touch the code. 

Jim Crate

**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-10 Thread Narinder Chandi via 4D_Tech
Thanks Armin. I decided that I was a bit reluctant to run code across the whole 
database to replace the obsolete commands (even with structure backups in 
place!).

 

I much prefer to inspect each change visually to asses for any potential 
implications. As there are actually not that many instances in my client’s 
system to be updated I can fortunately justify doing it this way. _o_C_STRING 
now done, just the /_o_ARRAY STRING to be replaced this afternoon.

 

Thanks to everybody who provided input on this question.

 

Regards,

 

Narinder Chandi,

ToolBox Systems Ltd.

-- 

 

From: 4D_Tech <4d_tech-boun...@lists.4d.com> on behalf of ADeeg via 4D_Tech 
<4d_tech@lists.4d.com>
Reply-To: 4D iNug Technical <4d_tech@lists.4d.com>
Date: Sunday, 9 June 2019 at 20:47
To: <4d_tech@lists.4d.com>
Cc: ADeeg 
Subject: Re: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING 
Commands

 

Narinder,

 

there is a working method from Bertrand.

http://forums.4d.com/Post/DE/17445198/1/17445199

 

Open the struct, copy the method and enjoy

 

Regards Armin

 

 

4D Tech mailing list wrote

Hi all. I am migrating a v15 database to v17, 4D Server running on Mac. I

need some opinions as to what to do with regards to converting commands

marked as obsolete as per this article:

https://doc.4d.com/4Dv15/4D/15/Deprecated-or-removed-features-in-v15-product-range.200-2063067.en.html

I have been addressing them by theme, and in some cases the conversion is

straight forward, e.g. _o_ENABLE BUTTON/_o_DISABLE BUTTON is replaced by

OBJECT SET ENABLED whilst some others can be removed completely, e.g.

_o_REDRAW LIST.

I am now looking at how to deal with the obsolete Compiler theme commands

_o_C_INTEGER, _o_C_STRING and _o_ARRAY STRING.

_o_C_INTEGER I have simply replaced with C_LONGINT as the docs state that

"...4D and the compiler retype Integers into Longints internally."

However, I am conflicted as to how best to deal with _o_C_STRING and

_o_ARRAY STRING which are replaced by C_TEXT and ARRAY TEXT respectively.

The docs state "The operation of the [_o_C_STRING/_o_ARRAY STRING] command

is strictly identical to that of the [C_TEXT/ARRAY TEXT]". Of course the

string length parameter in the obsoleted commands makes the conversion

non-trivial and code will need to reviewed for any functional regressions,

e.g. in relation to database fields of type String where the length can

still be defined (auto-truncation may not be the desired/intended

behaviour!).

I have searched the archives on this topic but opinions seem to be divided

on whether or not to do this conversion? Perhaps I am mistaken, but I am

of the opinion that it will have to be done sooner or later as 4D reserves

the right to remove obsoleted commands and will eventually do so?

TL;DR the options are:

1. Replace

2. Do nothing for v17

Thoughts?

I will deal with my questions and options regarding Subrecords in a

separate email!

Regards,

  

Narinder Chandi,

 

 

 

 

 

--

Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html

**

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

**

**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-09 Thread ADeeg via 4D_Tech
Narinder,

there is a working method from Bertrand.
http://forums.4d.com/Post/DE/17445198/1/17445199

Open the struct, copy the method and enjoy

Regards Armin


4D Tech mailing list wrote
> Hi all. I am migrating a v15 database to v17, 4D Server running on Mac. I
> need some opinions as to what to do with regards to converting commands
> marked as obsolete as per this article:
> 
> https://doc.4d.com/4Dv15/4D/15/Deprecated-or-removed-features-in-v15-product-range.200-2063067.en.html
> 
> I have been addressing them by theme, and in some cases the conversion is
> straight forward, e.g. _o_ENABLE BUTTON/_o_DISABLE BUTTON is replaced by
> OBJECT SET ENABLED whilst some others can be removed completely, e.g.
> _o_REDRAW LIST.
> 
> I am now looking at how to deal with the obsolete Compiler theme commands
> _o_C_INTEGER, _o_C_STRING and _o_ARRAY STRING.
> 
> _o_C_INTEGER I have simply replaced with C_LONGINT as the docs state that
> "...4D and the compiler retype Integers into Longints internally."
> 
> However, I am conflicted as to how best to deal with _o_C_STRING and
> _o_ARRAY STRING which are replaced by C_TEXT and ARRAY TEXT respectively.
> The docs state "The operation of the [_o_C_STRING/_o_ARRAY STRING] command
> is strictly identical to that of the [C_TEXT/ARRAY TEXT]". Of course the
> string length parameter in the obsoleted commands makes the conversion
> non-trivial and code will need to reviewed for any functional regressions,
> e.g. in relation to database fields of type String where the length can
> still be defined (auto-truncation may not be the desired/intended
> behaviour!).
> 
> I have searched the archives on this topic but opinions seem to be divided
> on whether or not to do this conversion? Perhaps I am mistaken, but I am
> of the opinion that it will have to be done sooner or later as 4D reserves
> the right to remove obsoleted commands and will eventually do so?
> 
> TL;DR the options are:
> 1. Replace
> 2. Do nothing for v17
> 
> Thoughts?
> 
> I will deal with my questions and options regarding Subrecords in a
> separate email!
> 
> Regards,
>  
> Narinder Chandi,





--
Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-07 Thread Narinder Chandi via 4D_Tech
Patrick,

Hi. Thanks, yes I came across a reference to QS_Toolbox this afternoon so +1 
for that and I will look into it!

Regards,
 
Narinder Chandi,
ToolBox Systems Ltd.
-- 

-Original Message-
From: 4D_Tech <4d_tech-boun...@lists.4d.com> on behalf of Patrick Emanuel via 
4D_Tech <4d_tech@lists.4d.com>
Reply-To: 4D iNug Technical <4d_tech@lists.4d.com>
Date: Friday, 7 June 2019 at 20:35
To: <4d_tech@lists.4d.com>
Cc: Patrick Emanuel 
Subject: Re: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING 
Commands

Absolutly, and there are also some tools (free) that can help you, like
QS_Toolbox ;-)




-
Patrick EMANUEL

Administrator
www.association-qualisoft.eu 
(Soft1002, Simply Asso & QS_Toolbox)
--
Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
**
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
**


**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-07 Thread Narinder Chandi via 4D_Tech
Thanks Charles, I'll PM you.

Regards,
 
Narinder Chandi,
ToolBox Systems Ltd.
-- 

-Original Message-
From: 4D_Tech <4d_tech-boun...@lists.4d.com> on behalf of Charles Miller via 
4D_Tech <4d_tech@lists.4d.com>
Reply-To: 4D iNug Technical <4d_tech@lists.4d.com>
Date: Friday, 7 June 2019 at 20:23
To: 4D iNug Technical <4d_tech@lists.4d.com>
Cc: Charles Miller 
Subject: Re: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING 
Commands

There’s code that will convert all in one fell swoop. It puts comments at
end please advise if you want it and I will forward

Regards
Chuck

On Fri, Jun 7, 2019 at 11:49 AM Narinder Chandi via 4D_Tech <
4d_tech@lists.4d.com> wrote:

> Hi all. I am migrating a v15 database to v17, 4D Server running on Mac. I
> need some opinions as to what to do with regards to converting commands
> marked as obsolete as per this article:
>
>
> 
https://doc.4d.com/4Dv15/4D/15/Deprecated-or-removed-features-in-v15-product-range.200-2063067.en.html
>
> I have been addressing them by theme, and in some cases the conversion is
> straight forward, e.g. _o_ENABLE BUTTON/_o_DISABLE BUTTON is replaced by
> OBJECT SET ENABLED whilst some others can be removed completely, e.g.
> _o_REDRAW LIST.
>
> I am now looking at how to deal with the obsolete Compiler theme commands
> _o_C_INTEGER, _o_C_STRING and _o_ARRAY STRING.
>
> _o_C_INTEGER I have simply replaced with C_LONGINT as the docs state that
> "...4D and the compiler retype Integers into Longints internally."
>
> However, I am conflicted as to how best to deal with _o_C_STRING and
> _o_ARRAY STRING which are replaced by C_TEXT and ARRAY TEXT respectively.
> The docs state "The operation of the [_o_C_STRING/_o_ARRAY STRING] command
> is strictly identical to that of the [C_TEXT/ARRAY TEXT]". Of course the
> string length parameter in the obsoleted commands makes the conversion
> non-trivial and code will need to reviewed for any functional regressions,
> e.g. in relation to database fields of type String where the length can
> still be defined (auto-truncation may not be the desired/intended
> behaviour!).
>
> I have searched the archives on this topic but opinions seem to be divided
> on whether or not to do this conversion? Perhaps I am mistaken, but I am 
of
> the opinion that it will have to be done sooner or later as 4D reserves 
the
> right to remove obsoleted commands and will eventually do so?
>
> TL;DR the options are:
> 1. Replace
> 2. Do nothing for v17
>
> Thoughts?
>
> I will deal with my questions and options regarding Subrecords in a
> separate email!
>
> Regards,
>
> Narinder Chandi,
> ToolBox Systems Ltd.
> --
>
>
> **
> 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
> **

-- 

-
 Chuck Miller Voice: (617) 739-0306 Fax: (617) 232-1064
 Informed Solutions, Inc.
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D, Sybase & SQL Server 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)
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-07 Thread Patrick Emanuel via 4D_Tech
Absolutly, and there are also some tools (free) that can help you, like
QS_Toolbox ;-)




-
Patrick EMANUEL

Administrator
www.association-qualisoft.eu 
(Soft1002, Simply Asso & QS_Toolbox)
--
Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html
**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-07 Thread Charles Miller via 4D_Tech
There’s code that will convert all in one fell swoop. It puts comments at
end please advise if you want it and I will forward

Regards
Chuck

On Fri, Jun 7, 2019 at 11:49 AM Narinder Chandi via 4D_Tech <
4d_tech@lists.4d.com> wrote:

> Hi all. I am migrating a v15 database to v17, 4D Server running on Mac. I
> need some opinions as to what to do with regards to converting commands
> marked as obsolete as per this article:
>
>
> https://doc.4d.com/4Dv15/4D/15/Deprecated-or-removed-features-in-v15-product-range.200-2063067.en.html
>
> I have been addressing them by theme, and in some cases the conversion is
> straight forward, e.g. _o_ENABLE BUTTON/_o_DISABLE BUTTON is replaced by
> OBJECT SET ENABLED whilst some others can be removed completely, e.g.
> _o_REDRAW LIST.
>
> I am now looking at how to deal with the obsolete Compiler theme commands
> _o_C_INTEGER, _o_C_STRING and _o_ARRAY STRING.
>
> _o_C_INTEGER I have simply replaced with C_LONGINT as the docs state that
> "...4D and the compiler retype Integers into Longints internally."
>
> However, I am conflicted as to how best to deal with _o_C_STRING and
> _o_ARRAY STRING which are replaced by C_TEXT and ARRAY TEXT respectively.
> The docs state "The operation of the [_o_C_STRING/_o_ARRAY STRING] command
> is strictly identical to that of the [C_TEXT/ARRAY TEXT]". Of course the
> string length parameter in the obsoleted commands makes the conversion
> non-trivial and code will need to reviewed for any functional regressions,
> e.g. in relation to database fields of type String where the length can
> still be defined (auto-truncation may not be the desired/intended
> behaviour!).
>
> I have searched the archives on this topic but opinions seem to be divided
> on whether or not to do this conversion? Perhaps I am mistaken, but I am of
> the opinion that it will have to be done sooner or later as 4D reserves the
> right to remove obsoleted commands and will eventually do so?
>
> TL;DR the options are:
> 1. Replace
> 2. Do nothing for v17
>
> Thoughts?
>
> I will deal with my questions and options regarding Subrecords in a
> separate email!
>
> Regards,
>
> Narinder Chandi,
> ToolBox Systems Ltd.
> --
>
>
> **
> 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
> **

-- 
-
 Chuck Miller Voice: (617) 739-0306 Fax: (617) 232-1064
 Informed Solutions, Inc.
 Brookline, MA 02446 USA Registered 4D Developer
   Providers of 4D, Sybase & SQL Server 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)
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-07 Thread JOHN BAUGHMAN via 4D_Tech

> On Jun 7, 2019, at 6:02 AM, Chip Scheide via 4D_Tech <4d_tech@lists.4d.com> 
> wrote:
> 
> - Run compiler, fix individual errors, or notice sizes you missed above 
> and do global replaces using C_Text(;  -> C_Text(


 Rather than rerunning the compiler…

1. Find In Design for _o_C_String( Leave this window open
2. Find id Design for _o_C_String(x;  If any found, do the 
first one found
3. Replace in content _o_C_String(x;   ->  C_Text(   When done, 
close the window
4. Refresh the first Find In Design window
5. Repeat 2 - 4 until none found
6. Close first FID window and do FID for starts with _o_handle what 
is left.

I think this might be a bit quicker than dealing with the compiler each time.

John

**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-07 Thread Kirk Brooks via 4D_Tech
Hi Narender,
Welcome back.

Changing the variable declarations is a simple regex exercise. In fact I
think 4DPOP may have a command in it already for doing so. If not it's not
too difficult to write a method to loop through all the code, find the old
strings and replace them.

I don't have any code on hand at the moment but a REGEX pattern like:

"_o_.+STRING \(\d+;"

will find either declaration. The "\d+;" bit deals with whatever number is
present as well as the extra ; you won't need.

Then you can pull that substring and see if it contains "ARRAY" and know
what to replace it with:

"ARRAY TEXT ("
"C_TEXT ("


Hope that helps.

On Fri, Jun 7, 2019 at 8:49 AM Narinder Chandi via 4D_Tech <
4d_tech@lists.4d.com> wrote:

> Hi all. I am migrating a v15 database to v17, 4D Server running on Mac. I
> need some opinions as to what to do with regards to converting commands
> marked as obsolete as per this article:
>
>
> https://doc.4d.com/4Dv15/4D/15/Deprecated-or-removed-features-in-v15-product-range.200-2063067.en.html
>
> I have been addressing them by theme, and in some cases the conversion is
> straight forward, e.g. _o_ENABLE BUTTON/_o_DISABLE BUTTON is replaced by
> OBJECT SET ENABLED whilst some others can be removed completely, e.g.
> _o_REDRAW LIST.
>
> I am now looking at how to deal with the obsolete Compiler theme commands
> _o_C_INTEGER, _o_C_STRING and _o_ARRAY STRING.
>
> _o_C_INTEGER I have simply replaced with C_LONGINT as the docs state that
> "...4D and the compiler retype Integers into Longints internally."
>
> However, I am conflicted as to how best to deal with _o_C_STRING and
> _o_ARRAY STRING which are replaced by C_TEXT and ARRAY TEXT respectively.
> The docs state "The operation of the [_o_C_STRING/_o_ARRAY STRING] command
> is strictly identical to that of the [C_TEXT/ARRAY TEXT]". Of course the
> string length parameter in the obsoleted commands makes the conversion
> non-trivial and code will need to reviewed for any functional regressions,
> e.g. in relation to database fields of type String where the length can
> still be defined (auto-truncation may not be the desired/intended
> behaviour!).
>
> I have searched the archives on this topic but opinions seem to be divided
> on whether or not to do this conversion? Perhaps I am mistaken, but I am of
> the opinion that it will have to be done sooner or later as 4D reserves the
> right to remove obsoleted commands and will eventually do so?
>
> TL;DR the options are:
> 1. Replace
> 2. Do nothing for v17
>
> Thoughts?
>
> I will deal with my questions and options regarding Subrecords in a
> separate email!
>
> Regards,
>
> Narinder Chandi,
> ToolBox Systems Ltd.
> --
>
>
> **
> 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
> **



-- 
Kirk Brooks
San Francisco, CA
===

What can be said, can be said clearly,
and what you can’t say, you should shut up about

*Wittgenstein and the Computer *
**
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: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING Commands

2019-06-07 Thread Narinder Chandi via 4D_Tech
Thanks Chip. I am less concerned about the how as I am happy to manually brute 
force replace the 200 instances of usage. It's more about whether or not to...

Regards,
 
Narinder Chandi,
ToolBox Systems Ltd.
-- 

-Original Message-
From: Chip Scheide <4d_o...@pghrepository.org>
Date: Friday, 7 June 2019 at 17:02
To: 4D iNug Technical <4d_tech@lists.4d.com>
Cc: Narinder Chandi <4dtechmailingl...@toolbox.uk.com>
Subject: Re: v15 to v17 Conversion of Obsolete _o_C_STRING/_o_ARRAY STRING 
Commands

not the easiest thing to do.

what I did:
 - globally replace:
C_String(;  -> C_Text(

Where  is a string size that is used a lot in your system(s).
repeat until most of the more often used string sizes are done.

- globally replace:
C_String(   -> C_Text(
- Run compiler, fix individual errors, or notice sizes you missed above 
and do global replaces using C_Text(;  -> C_Text(

repeat the above for arrays

Not fast, but that should resolve the issue - eventually

Chip
On Fri, 07 Jun 2019 16:48:59 +0100, Narinder Chandi via 4D_Tech wrote:
> _o_C_INTEGER I have simply replaced with C_LONGINT as the docs state 
> that "...4D and the compiler retype Integers into Longints 
> internally."
---
Gas is for washing parts
Alcohol is for drinkin'
Nitromethane is for racing 



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