

sstantoncook
Forum Replies Created
-
The q insert is highly optimised, it can handle millions of rows a second per core.
The insert must be performed in the main thread to ensure data consistency and sequencing. This is why it cannot by run with peach, even though in this example it is appending to different tables.
What use case is there to insert identical data into two tables? There may be a more appropriate process architecture to manage these tables or mechanism to achieve the same result.
-
What is the use case that you want to insert the same data into two different tables?
I can see the topic names resemble stocks but there is no filter on the data so would appear all records go into each.
The only use case I can think of having the same schema and upserting to two tables is where you maintain two versions the same schema but one with keyed columns to maintain both the full trail and current “state”.
E.g. all FX quotes in one table and the other keyed by Currency Pair and LP to display the current quoted depth.
Cheers,
Sam
-
sstantoncook
MemberSeptember 15, 2021 at 12:00 am in reply to: Lists, dictionaries, tables and lists of dictionariesHi Simon,
I agree with Rian in term of the generalisation of k data types. I.e.
- Atom is a scalar representation of a data type.
- List is a vector representation of an Atom.
- Dictionary is a keyed set of lists. The key can be a List of any type. The values can a list of any type, a list of lists and list of Dictionaries.
- Table is a List of commonly keyed Dictionaries. You can see this easily when you put two dictionaries in a list, or enlist one of them.
Your point about apply (@;.) – in both cases, dictionaries and lists, it works by indexing.
Dictionaries require the key value to index and apply the function.
Lists require the index to index to apply the function.
-
sstantoncook
MemberAugust 13, 2021 at 12:00 am in reply to: EmbedPy question, function in python that returns more than one value.Hi Kumar,
To index into a python objext you can use the syntax of a backtick character “`” to convert to q. E.g.
variable`If you have a list of variable you want to index into you could alternatively write
{x ` } each list_of_python_variables
or
list_of_python_variables@:`Depending on which syntax you prefer.
Cheers,
Sam
-
sstantoncook
MemberJuly 7, 2021 at 12:00 am in reply to: KxWarehouseData Tutorial – data not flowing from LR to IHDB and HDBHi Adriano – can you please share a screenshot of the process configuration of the TP and LR?
On a scheduled basis the LR should be checking for a new tp log file, reading the previous one and writing it to the iHDB. So I am interested to see how often the TP log rolls and how often the LR is checking for the log file.
Also the process log of the LR would help.Sam
-
sstantoncook
MemberJuly 7, 2021 at 12:00 am in reply to: KxWarehouseData Tutorial – data not flowing from LR to IHDB and HDBHi Adriano – reviewing the logs it looks like the LR process has successfully identified the intraday TP log to ingest, replayed it and written it to the iHDB location.
//File identified to replay
Found files to replay ### `s#,`kxplatform/TP/uiCore/uiCore_tp_2339_2021.07.01_H_2021.07.01.050000
//Example of an intraday partition being upserted to
<->2021.07.01D06:00:48.077 ### dev ### normal ### (252950): Upserted 1 rows for temperature to kxplatform/INTRADAY/uiCore/2021.07.01//13/uiCore_telemetry/ ###
Good spot on missing wild card required to pick up the service class. I’ll pass that back to Core.
Cheers,
Sam
-
sstantoncook
MemberJune 29, 2021 at 12:00 am in reply to: What are the permissions needed to see the Action Tracker dashboard on KX Dashboards?Hi Adriano,
Is your new user in a User Group yet and if so what AdminAPI’s have been applied to the group?
They’ll need to be apart of the ActionTrackerUsers group to have items re-assignable to them and have the ActionTrackerAPI to interact with the Action Tracker (also applied via the ActionTrackerUsers group.
Cheers,
Sam