Modifying storage location in data dictionary

87 views
Skip to first unread message

Michael Reach

unread,
Mar 22, 2023, 9:18:25 AM3/22/23
to Hardhats
Because of what appears to be a bug in Cache' Fileman wizard, that doesn't convert free text fields of form (for example) 10;E1,250 to SQL properly [I'm talking to Intersystems about it now] - I'd like to modify the data dictionary of those fields to change them to 10;1 instead.
The usual Modify function doesn't give me access to the storage location; once the field has been created I can't get to it without changing the data type.
1) Is there a way to do it properly in Fileman?
2) Would simply modifying the ^DD entry ($P(^DD(file#, field#, 0), U , 3) work? I can Verify afterwards to look for problems with the results (or search for ^ in the data).
Thanks!

Sam Habiel

unread,
Mar 22, 2023, 10:22:49 AM3/22/23
to hard...@googlegroups.com
1. Don't think there's a way. You are blocked from that specifically.
2. Yes (with some provisos... the Index file, for example).

My recommendation is to work with Intersystems to fix the bug. That
feature has been in Fileman since the early 80s.

--Sam
> --
> --
> http://groups.google.com/group/Hardhats
> To unsubscribe, send email to Hardhats+u...@googlegroups.com
>
> ---
> You received this message because you are subscribed to the Google Groups "Hardhats" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to hardhats+u...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/hardhats/81ead959-5f29-4893-9400-e7e29be51b0en%40googlegroups.com.

Michael Reach

unread,
Mar 22, 2023, 11:30:21 AM3/22/23
to Hardhats
We're talking to them. It's an interesting bug: The Wizard automatically makes any E1,? field into a computed field in SQL, which of course makes it read-only. I see it in the data storage class the IS person showed me that the SQL Wizard created:

/// FileMan Field Label: 'METHOD' FileMan Field Number: '72'
Property method As %Library.String(COLLATION = "EXACT", MAXLEN = 250, MINLEN = 1, TRUNCATE = 0) [ Calculated, SqlColumnNumber = 65, SqlComputeCode = { {method}=$e({node_5},1,250)}, SqlComputed, SqlFieldName = method ];
...
/// Computed Field For Node 5
Property node5 As %Library.String(COLLATION = "EXACT", MAXLEN = 255, TRUNCATE = 0) [ Calculated, SqlColumnNumber = 64, SqlComputeCode = { {node_5}=$g(^EQADAT(1004032,{IEN},5))}, SqlComputed, SqlFieldName = node_5 ];
for
DATA          NAME                  GLOBAL        DATA
ELEMENT       TITLE                 LOCATION      TYPE
-------------------------------------------------------------------------------

1004032,72    METHOD                 5;E1,250 FREE TEXT

              INPUT TRANSFORM:  K:$L(X)>250!($L(X)<1) X
              LAST EDITED:      MAR 30,2022
              HELP-PROMPT:      Answer must be 1-250 characters in length.

David Whitten

unread,
Mar 23, 2023, 10:48:18 PM3/23/23
to hard...@googlegroups.com
Also a field defined as E1,255 can store any character including a caret (^). But a field defined as 1, will stop when you get to the first ^ in the data. 

Dave 
To unsubscribe, send email to Hardhats+unsubscribe@googlegroups.com


---
You received this message because you are subscribed to the Google Groups "Hardhats" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hardhats+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/hardhats/0c7a33dd-754a-404c-9950-843f00b43009n%40googlegroups.com.

Michael Reach

unread,
Mar 24, 2023, 10:25:09 AM3/24/23
to Hardhats
Dave, what question are you answering?

David Whitten

unread,
Mar 24, 2023, 2:20:30 PM3/24/23
to hard...@googlegroups.com
I’m answering your original original question. 

You said 

Because of what appears to be a bug in Cache' Fileman wizard, that doesn't convert free text fields of form (for example) 10;E1,250 to SQL properly [I'm talking to Intersystems about it now] - I'd like to modify the data dictionary of those fields to change them to 10;1 instead.

So if you changed it from 10;E1,250 to 10;1 you can’t store a caret (^) as a value and any value with a caret will be cut off at the first caret. 

Changing to a 10;1 will essentially break the field and not do what you want. 

Dave
To unsubscribe, send email to Hardhats+unsubscribe@googlegroups.com


---
You received this message because you are subscribed to the Google Groups "Hardhats" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hardhats+unsubscribe@googlegroups.com.


---
You received this message because you are subscribed to the Google Groups "Hardhats" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hardhats+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/hardhats/8f34440c-a626-4702-bcb3-7c28fd41f078n%40googlegroups.com.

George Timson

unread,
Mar 24, 2023, 2:35:19 PM3/24/23
to Hardhats
David of course is absolutely correct.  And, for decades, all Fileman fields of the type 'MUMPS' have automatically been created in the "E" format, because MUMPS code uses "^"s.

'Wizard'.  Hmmph.

--George Timson
Reply all
Reply to author
Forward
0 new messages