I defined the variables in Cache, as follows:

Property Content As% Stream.GlobalCharacter [Required, SqlColumnNumber = 3, SqlFieldName = B_Content];

And then use the SQL statement to add:

insert into table_name (B_Content) values ('very long string');

But the error:

0 3
0 573
Question
· Oct 26, 2017
Content-Type in REST

Greetings to all!!! How to get the value of the Content-Type field from the object of the class %Stream.Object obtained with:

stream=% request.GetMimeData (FormDataName, 1) 

I tried:

0 2
0 423

Greetings to all!!! Suppose there is a table Mother (ID, Name) and Child (ID, Name, Mother), Mother in the table Childis a relationship. Let's say the task is to deduce the names of all the children whose their moms' names start with the letter 'A', I can do this in two ways in sql, and I can not understand the difference, the pros and cons that when to use:

0 1
0 398

Hi all,

Is there a way to setup a classmethod or routine to execute immediately after cache is started?

I wrote a batch file that does execute the cache start, but I'm getting an Access Denied error on the cession command despite running as Administrator:

ccontrol start HEALTHSHARE1
csession HEALTHSHARE1 -U %SYS "##class(SomeClass).SomeMethod()"

Thanks for the help/suggestions

0 6
0 754

Hi,

I am getting the following error while logging in using LDAP authentication,

"An error occurred with the CSP application and has been logged to system error log (^ERRORS)". I've set the connection up and using Authentication Test was successful. I seem to be able to login as well but keep getting that error. If I allows unauthenticated access then the page works but changing it to LDAP is not working.

The LDAP account once created in Cache has U access to the resource related with the web application.

0 1
0 638

Sometimes you can face the situation when you did update the web app on Caché server but you cannot get the newest version of the app in a browser.

Here are couple recipes which help me to solve it. From simplest to more sophisticated and not obvious.

1. Refresh page in a browser

In Chrome it is Ctrl+R or 'Refresh' button. Obvious, but helpful.

2. Hard reset in a browser

If you are in Chrome, open Developer tools

2 1
0 1.4K

Hi,

I have a class with around 400k lines and 60 columns. Class storage is Cache SQL storage (Mapped from a global).

I want to create multiple indices on certain fields.

I am familiar with two approaches:

1. Create a new map (Index type) on a pointer global.

2. Create a bitmap index

Which approach is more recommended to be used in the case I described? If there are any other approaches, I will be happy to hear.

Thanks :)

0 11
0 703
Question
· Oct 18, 2017
Rebuild class index

I have a class. In class there is an index. This index is for quick search on name property.

Class User
{

.....

Property Name as %String;

Index NameInd On Name;

.....

}

This class is mapped to some global ^GL(userId) = "Name*other data....****"

And there is also index global ^GLNameIndex(Name, userId) = ""

When I add new User entry through class, f. i.

S user = ##class(User).%New()
S user.Name = "Some name"
​D user.%Save()

calling method %Save() adding new entry to index automatically.

0 6
0 1.4K
Question
· Oct 17, 2017
How to wrap %SQLCODE into %Status

I have a method would return %Status,

this method would run some sql queries and if the execution of these queries fail, I would like to return asap.

So how could I wrap the %SQLCODE into a %Status variable?

Thank for your help.

0 5
0 887

Hello,

I've been manipulating XML objects via Cache, but have had some difficulty understanding how to use the following method detailed within EnsLib.EDI.XML.Prop:

Method choiceGetCount(Output pCount, pDOMPath As %String, pRef As %String) As %Status

From what I've read when walking through the code for this method, it appears to count a listing of repeating XML elements. However, despite my attempts to search for examples or attempts to implement this function, I am unable to do so.

0 10
0 549

I setup an account in Cache and when I try to sort the dictionary item in the file by using the command SORT DICT filename, where filename is the name of the file i.e. SORT DICT TEST, I get the following error CMQL: The DICT entry "FIELD.ASSOC_" is not defined

The LISTDICT works correctly. Any thoughts on how to correct this error?

0 2
0 268

Hi World

I've a problem when in extract a float value from my database

the problem is that i get an interger instead of float.

my record is 2,56 but when i do a select , the request extract only 2

can you have a solution for it.

thank you

0 4
0 259
Question
· Oct 14, 2017
ZenMethod in onunloadHandler

I want to call ZenMethod when page is closing. Is it possible?

I tried

ClientMethod onunloadHandler() [ Language = javascript ]
{
zenPage.SomeZenMethod();
}


Method SomeZenMethod() [ ZenMethod ]
{
// to do some work
}

0 1
0 340
Question
· Oct 14, 2017
Multiple joins in a SQL query

HI,

I have a query like below but its syntax is not accepted by Cache.

I would like to perform a left join on two tables first and then make a inner for this result with another table.

Given the constraint that we only allow one SELECT in the query, it is possible to achieve this semantics ?

Thank for your help.

Select *
FROM ( sample . employee e
LEFT JOIN sample . company c
on c . id = e . id ) g
JOIN sample . vendor v
on v . %id = g . attr

0 3
0 978

Hello again and welcome to the next tutorial on this series: Part 4 - Sharing data across router methods. Here we are going to learn how to share a object containing data that is available for read across every router methods.

You're required to complete at least the Part 1 before entering this one. Still, this is supposed to be a really short tutorial, since there isn't much to be said about data sharing.

2 0
0 482

Hi Community,

There is any way that I can use Studio Source Control in Atelier, or adapt it to use?

We have a solution based on Studio Source Control, and I cannot make it works with Atelier, I can not even see the classes .

Thanks,

Andrei L. Nenevê

0 8
0 775

I'm trying to write an installer manifest that can create a namespace, resources (%DB_namespace) and a role (with the resource, above), based on the namespace. So you could pass in "ABC", or "XYZ", and it would create the %DB_ABC resource and the ABC role with %DB_ABC:RW permissions; or it will create the %DB_XYZ resource and the XYZ role with %DB_XYZ:RW permissions, accordingly.

0 2
0 348