You are not logged in.
Pages: 1
I would like to know why this simple join fails
SELECT a.PRODUCTTYPE, b.PRODUCTTYPE, a.REFERENCE, a.INVDATE, a.SECTOR,
FROM TABLEREF a JOIN TABLEREF b ON b.REFERENCE = a.REFERENCE
WHERE a.INVDATE = '27.06.2022' AND a.SECTOR = '7'
ORDER BY a.REFERENCE
Thanks in advance
ab, Could you give me an idea of how to deal with what you say about interface-based services over Websockets?
Thanks in advance.
ab, is there someone who can help me?
Hello, I have inherited an app that uses "TWebSocketServer", it receives and sends data to all connected clients but now I need to be able to identify each client and, depending on the case, send data only to one of them and not to all of them. Is there an example to do this?
Thanks in advance.
Hi,
the same service can return the error message in 2 different ways, one of them is an array. How can you distinguish and display the "errorText" message of each one.
a) '{"errorCode": 400, "errorText": "There are ongoing communications}}'
b) '{"errorCode": 400, "errorText": "[{\" ACTIVITY_GROUP \ ": \" A \ ", \" MODEL \ ": \" HELLO \ ", \" STATUS \ ": 0}, \ r \ n {\ "ACTIVITY_GROUP \": \ "B \", \ "MODEL \": \ "SALE \", \ "STATUS \": 0}] \ n "} '
Thanks in advance.
I can't keep it without compression because the json size is about 150k.
Is there another way to send this binary data?
I only need to send this data from server to clients.
Why do you want to reinvent the wheel?
Because I don't know which programming language will use on client-side
Hi ab,
Then, how can I send this?
Hi,
Modifying the Project31ChatServer example, I compress some json records with Zlib for compatibility and then call "NotifyBlaBla(pseudo,msg)" where msg is the compressed json.
Once compressed I take volume size to compare with the size received.
What happens is that the client receive fewer bytes than the server sends.
I have no idea how to solve it or because it happens.
Thanks in advance for any help.
Hi Turrican,
How can I save some data from each client session?
Thanks Turrican.
What I need is to identify each client to send several packets to one and others times send the some packets to all clients.
Hi guys.
Using the websocket example (Project31ChatServer and Project31ChatClient) I wish I could send asynchronous messages from the server side to each cliente subscripted to the server.
Is there some example to do that?
Thanks in advance.
Thanks Ab but can't understand. Have you an example?
I need to convert to JSON this static arrays and don't known how.
type
TCCConfig = packed record
Version: string[10];
DNDReasons: array[1..15] of string[15];
end;
const
__TCCConfig = 'Version string[10] DNDReason array[1..15] of string[15]';
....
// then use move to fill this record with lData stream.
var
CCConfig: TCCConfig;
CurOff: Integer;
begin
TTextWriter.RegisterCustomJSONSerializerFromText(TypeInfo(TCCConfig), <------------- ERROR
__TMCCConfig).Options := [soReadIgnoreUnknownFields,soWriteHumanReadable];
CurOff := 1;
system.move(lData[CurOff], CCConfig, sizeof(CCConfig));
Hi, I need dim this strings with this values because I receive an stream from an app server and I use Move to populate this record.
TCCConfig = packed record
Version : string[10];
DNDReasons : array[1..15] of string[15];
end;
....
system.move(lData[CurOff], CCConfig, sizeof(CCConfig));
But I must declare so:
type
TCCConfig = packed record
Version : string;
DNDReasons : array of string;
end;
const
__TCCConfig = 'Version string DNDReasons array of string';
How can I deal with this?
Thanks in advance.
Many thanks AB, this work fine.
Thanks Ab.
With this code fire the error: TJSONCustomParsers.Search(kind=6) not DynArray or Record.
type
TPosFlags = set of TPosFlag;
const
__TPosFlags = '(pfInService, pfSupervisorHelp, pfReadyForCalls, pfMakingCall, '+
'pfMakingCall2, pfReadyForChats, pfACDCall, pfACDChat, pfEnteringDigits)';
type
TPosData = packed record
PosNumber: Word;
UserId: Word;
PosFlags: TPosFlags;
end;
TACDPositions = array of TPosData;
const
__TPosData = 'PosNumber Word UserId Word PosFlags TPosFlag'
TTextWriter.RegisterCustomJSONSerializerFromText(TypeInfo(TPosFlags),
__TPosFlags).Options := [soReadIgnoreUnknownFields,soWriteHumanReadable];
Hi Turrican.
I want pass to JSon.
TTextWriter.RegisterCustomJSONSerializerFromText(TypeInfo(TPosData),
__TPosData).Options := [soReadIgnoreUnknownFields,soWriteHumanReadable];
Hi,
I'm developing with Delphi 7 and I don't known how define the constant for this record. Can you help me?
type
TPosFlag = (pfInService, pfSupervisorHelp, pfReadyForCalls, pfMakingCall,
pfMakingCall2, pfReadyForChats, pfACDCall, pfACDChat, pfEnteringDigits);
TPosData = packed record
PosNumber: Word;
UserId: Word;
PosFlags: set of TPosFlag;
end;
const
__TPosData = 'PosNumber Word UserId Word PosFlags set of TPosFlag';
Thanks in advance.
Hi AB.
I need any encryption that is standard.
I'm using ZCompressStream (s, s1, zcMax) from ZLib;
On the client side have´t Mormot, so I need something as standard as possible.
I try to use Mormot because I have recommended it.
I just need some example of use.
Thank you.
Hi guys,
I'm new in mormot and need to compress a TMemoryStream with ZLib and then encrypt with AES before send thru TCP.
An external application then must decrypt and decompress this Stream.
Can anybody help me.
Thanks in advance.
Hi guys.
I need to show data from a received json with nested arrays and I have no idea how to do that, this is an json example:
Thanks in advance for any help.
[
{
"AgentInfo": {
"ID": 5,
"Type": 2,
"UserName": "agente2",
"FirstName": "Ariel",
"LastName": "Ortego",
"Email": "",
"Settings": {
"TecnoVozID": "5"
}
},
"CurrentWork": {
"MessageStats": {
"AssignedMessages": 0,
"RepliedMessages": 0,
"DiscardedMessages": 0,
"ReturnedToQueueMessages": 0,
"UnassignedMessages": 0
},
"TimeStats": {
"TotalAuxTime": 0,
"AuxTime": [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
],
"AvailTime": 0,
"WorkingTime": 0,
"UnreadTime": 0
}
},
"DayWork": {
"MessageStats": {
"AssignedMessages": 0,
"RepliedMessages": 0,
"DiscardedMessages": 0,
"ReturnedToQueueMessages": 0,
"UnassignedMessages": 0
},
"TimeStats": {
"TotalAuxTime": 0,
"AuxTime": [
0,
0,
0,
0,
0,
0,
0,
0,
0,
0
],
"AvailTime": 0,
"WorkingTime": 0,
"UnreadTime": 0
}
}
}
]
Many thanks for your kuicly response, it´s all i need for now.
Thanks for the example, this is what I need.
This post has a response with a json object, how can I get this response?
Sorry I'd never worked with web services.
Hi, guys.
I´m developing with Delphi 7 and need to connect to a web services and make an http post with some parameters.
Can showme some example of use?
Thanks in advance
Thanks its run ok
Still no made this but i want to known how populate a grid via ClientDataset or DataSet from json
Hi, I´m new with Mormot.
I whish get a Json via WebService and show a grid that must refresh each 5 seconds.
How can do that?
Thanks in advance.
Pages: 1