I have a few Radio buttons, some of which have to have the same value. I need to know which one the user have selected, so I am using text, however it does not work well so far.

Example:
I have 4 Radio buttons: Apple, Pear, Lemon and Orange, with values: Apple, Pear have Value 1, and Lemon and Orange have Value of 2
(this unfortunatelly cannot be changed for this particular application)

I need to figure out that the user picked specifically Apple, so I am using text as follows:

0 5
0 157

Hello,

I have a quick question regarding TSTART, however not certain if there is an answer.

If I am inside the transaction and I loose connection - I always assumed that transaction would TROLLBACK, however it does not.

Is there anything special I need to set up with my TSTART, in order for this transaction to safely rollback?

*********

As example: Let's say I am inside the TSTART and setting up / altering some data and my VPN connection got disconnected. I kind of expect all the data to be rolled back.

Thank you,

Alex

0 6
0 207

I have a quick question regarding swizzled objects.

I have an original object, say Object a, I am working with.

I set a property a.something.somethingother.somethingelse.myNewProperty to some value x.

Then at some point I am saving a and continuing to work with it. I assume here by saving a, I saved myNewProperty as well. (as it should work)

2 5
0 274

This is a lesson learned, which I would like to share with community.


Recently I ran into an issue, where I was using %ConstructClone and it kept cloning extra records, which were not needed. The record for which I was trying to run a clone had many-to-one relationships.

The solution to this issue was using param -1. If you run %ConstructClone(-1) it will not clone relationships, but rather just clone single oref as desired in this case.


I hope this information helps someone who is working with similar records.

4 0
0 386

I have a custom written date, setup as myDate in my application, which always behaved fine for years, and now it's acting a little weird.

When I run SQL in Display mode the date shows as 1/10/1841 for some but not ALL rows.

When I run the same exact query in logical Mode the date shows normal format, in my case, for example 10/1/2019. When the application is running is shows the incorrect date. When I run the terminal session and open a ref point and ask to write a date is shows 10/1/2019, but I am expecting internal format here - 65287.

0 4
0 279
Question
· Sep 5, 2019
Ambiguous sort column error

Hello,

I have a small SQL question.

Running an example queries in our Samples Namespace:

1. select top 5 Description,Category from Cinema.Film order by Category - runs fine no issues and returns 2 columns as expected

2. select top 5 * from Cinema.Film order by Category - runs fine no issues and returns 8 columns as expected

3. select top 5 Description,Category,* from Cinema.Film order by ID - runs fine no issues, and returns 10 columns, with my first 2 repeated

4. When I try to combine the first 2 queries:

0 4
0 147

Hello,

I assume there is a simple explanation for this, but I do get <OBJECT DISPATCH> error, when I am trying to set a global to a value.

My example is huge, but I reproduced it using Samples namespace:

First I delete the Title from ##class(Cinema.Film) - 3

Secondly:

SAMPLES>s ref=##class(Cinema.Film).%OpenId(3)
SAMPLES>w ref.Title

SAMPLES>set ^AK(1)=$G(ref.Title)

SET ^AK(1)=$G(ref.Title)
^
<OBJECT DISPATCH> *Property 'Title' in class 'Cinema.Film' must be MultiDimensional

0 4
0 723

Hello all,

I have an XSL question and I wanted to see if someone within a community can help me out.

To Summarize: I am working with XSL documents, single and multi-pages.
Inside my style sheet XML document, which is supporting my pages, everything on the page, including a headers, footers and the items are calculated
based on the portrait measurements.
Pages come up on the screen as portrait, but sometimes, depending on dynamic data are wide, they do not print properly in portrait.

0 1
0 390
Question
· Nov 15, 2018
SQL calculated property rollback

Greetings all,

I have a quick SQL question. I am working with a class, which has a calculated property, which in turned indexed.
The calculation for this property is created based on another property value via:
SqlComputeOnChange = attributes - so basically every time I add a property attribute to my class, my new property
is calculated based on some SqlComputeCode which calls some class method.

That initial setup works as designed.

0 1
0 259

Hello All,

I hope it's not a silly question.

Here is my issue:
I have 3 simple classes:

Parent class, let's say:

Class ParentClass Extends %RegisteredObject
{
Property a As %String;
}

and two children classes
Class A.Child Extends ParentClass
{
Property b As %String;
}

Class B.Child Extends ParentClass
{
Property c As %String;
}

So no issues - all compiles and seem to work.

But, when I add %XML.Adaptor to my parent class, so:

0 3
0 987

My questions are regarding ClassMethods with a private keyword tags.

When we use a wizard to add a new method, we are given a options to
select private checkbox to make it a private method as well as
Class Method checkbox in the same time.

1. What would be the reason and the case to select and use them both?
2. Secondly, if there is such a case in already developed application is it
safe to remove the private tag from ClassMethod? Obviously if it's not a
ClassMethod private tag cannot be removed as easily.

Thank you,

0 11
0 474

Hello,

I was wondering if there is a way to maybe temporarily alter the [Private] tag dynamically or any other way to run a Unit test against class method, which has been labeled as [Private]?

I mean, I understand there is a workaround to create a non private class method inside this class, which will in turn call this private method and run a Unit test on the non private method, but I am looking for a way to do this without altering the original class.

Thank you,

Alex

0 2
0 335

Hello All,

I have a question / issue regarding the calling list.FindOref(<object from indexOpen call>)
Here is a simple way to reproduce the issue:
2 classes: Utility.contacttypes and Utility.person
*************************

Class Utility.contacttypes Extends %Persistent
{
Property description As %Library.String(TRUNCATE = 1);
/// Index for property description
Index descriptionIndex On description [ Unique ];
}

*************************

3 5
0 343

I am using a method: %OverrideGuidAssignment("NEW GUID HERE") to override my GUID, and would like to know if there are any parameters, which allow this method to return a status & or error msg?
If you currently set it to a variable it returns the new GUID you originally passed in, regardless of if it failed to override or not.

Thank you in advance

0 5
0 374