Have an idea, suggestion, or something that doesn’t work as expected in InterSystems products or services? Share it here on the InterSystems Ideas Portal.
The Ideas Portal is where community members can propose improvements, report bugs, and help influence the product roadmap across InterSystems products and the overall developer experience. 22% of submitted ideas are implemented by InterSystems or members of the Developer Community.
💡 Ideas and bugs are both welcome, no matter how big or small. You can submit feature requests, usability improvements, workflow suggestions, and bug reports. Whether you’re an experienced expert or just getting started, your fresh perspective is valuable.
🛠️ About bugs and fixes. If you have access to InterSystems WRC, please submit bugs there for immediate action. Bug reports submitted through the Ideas Portal are reviewed and tracked, but do not guarantee immediate resolution.
Start by sharing what could be better - the community and our teams will help take it from there.
Robert, thank you for your idea.
There is a comment on your idea from InterSystems Product Manager. Please answer it to help your idea to be promoted.
Hi Robert, do you have a specific use case in mind for extending the SQL vocabulary here? We don't really see much use for the low-level vector operations in SQL outside of the similarity calculations we're using for Vector Search, other than perhaps a grad school maths homework. Unlike the $vector functions in ObjectScript, everything we'd add to SQL has the potential of colliding with user-defined functions, so we'd like to be cautious and not overload the language with functions no one really needs. And as you have found, it's not hard for those that do need them (for said homework) to implement them as UDFs themselves.
I wrote an overview of what is available actually.
Using VECTORs in ObjectScript
Almost everything is there already. It just needs to be wrapped into SQL Procedures.
Not a big deal for an experienced COS developer
As my replies and comments show it is doable but incredibly uncomfortable
Some simpler approaches as SQL Methods will be attrative
USER>zw vdiff
vdiff={"type":"integer", "count":3, "length":3, "vector":[-23,-45,0]} ; <VECTOR>
digging across documentation I detected that this is all available in COS!
and even well described in the documentation.
$vector()
$vectorop (ObjectScript)