go to post Benjamin De Boe · Oct 28, 2020 Are you asking about the web interface or the underlying API? We are currently working on a new all-SQL loader that would be easy to use from any application or prompt (or to build a GUI on :-) )
go to post Benjamin De Boe · Sep 11, 2020 Hi Mark, can you be more specific on the nature of the data and possibly application that's going to be migrated? HealthShare is more a suite of applications with standardized data models underneath, running on top of InterSystems IRIS for Health. To ingest data into HealthShare means transforming it through its APIs, whereas IRIS for Health is more comparable to a relational database like DB2. SQL Gateways allow mapping tables in remote non-InterSystems databases (such as DB2) to IRIS so they can be accessed as if they were local. That can be helpful during migrations as well as heterogeneous production environments. TSQL is a specific set of extensions of the SQL language used by Sybase and MS SQL Server that we support to ease migration scenarios for new customers with applications written in TSQL. hope this helps,benjamin
go to post Benjamin De Boe · Aug 26, 2020 Or Class Test.Person Extends (%Persistent, %XML.Adaptor) { Property Name As %String; Property Id As %Integer [ Identity ]; }
go to post Benjamin De Boe · Aug 25, 2020 This is not possible today, but happens to be something due for 2020.4 or 2021.1 in the form of expression indices. The documentation may be slightly confusing here as the BuildValueArray() mechanism applies to non-collection properties and not "array of" or "list of" properties. The section that describes it just happens to be placed right after the section describing how to use the ELEMENTS trick to index them in their entirety. Note that you can use BuildValueArray() for %ArrayOfObjects properties, but those aren't projected as a child table. A possible workaround would be through a separate property that's just there as an intermediary for your index: Property AR As array Of Sample.Address; Property AllStates As %String [ Calculated, ReadOnly, SqlComputeCode = {set {*} = {%%ID}}, SqlComputed ]; Index AllStatesIDX On AllStates(ELEMENTS); ClassMethod AllStatesBuildValueArray(value, ByRef valueArray) As %Status { kill valueArray set tObj = ..%OpenId(value), tKey = "" for { set tAddress = tObj.AR.GetNext(.tKey) quit:tKey="" set valueArray(tKey) = tAddress.State } quit $$$OK } Then you can include it in queries: select * from sample.person where FOR SOME %ELEMENT(AllStates) (%VALUE = 'KY')
go to post Benjamin De Boe · Jul 15, 2020 Hi David, maybe you can elaborate a little more on the particular latency challenge you faced? As Dmitriy mentioned, sharding will spread your data and corresponding query workload across multiple nodes in order to achieve higher efficiencies on very large datasets and is especially fit for read-mostly workloads. ECP, when used in a typical application server setup, is meant to distribute user-bound workload across multiple servers, so serving a slightly different goal. Depending on your use case, either of those (or a combination of them) can be more appropriate. See also this overview and introductory video for more info.
go to post Benjamin De Boe · Jul 9, 2020 Maybe this Getting Started guide is also a worthwhile reference
go to post Benjamin De Boe · Jul 9, 2020 if that column is currently in a string format (you can tell from the column/resultset metadata), you can use a different pattern to check if it meets the raw format: SELECT CASE WHEN '01/01/2020' %PATTERN '1.2N1"/"1.2N1"/"4N' THEN 'valid' ELSE 'invalid' END if you also want to check if that resolves to a valid date, you can use CAST or TO_DATE, but those will throw errors if they don't resolve to a valid date, so a small custom function in ObjectScript is perhaps not a bad idea
go to post Benjamin De Boe · May 11, 2020 Depends on how you're set up. There is a setting to allow specifying those values that is meant for this type of bulk load scenario. @Daniel Buxton : the multi-row insert syntax you're asking about is currently not supported by IRIS SQL (as you figured by now :-)). Robert's approach using UNION all is a creative workaround, but depending on where your big INSERT is coming from you might also just be able to generate / rewrite it into separate INSERTs? Once you have that in place, you can use the SQL Shell's RUN command or the ObjectScript $SYSTEM.SQL.DDLImport() method to execute your script file.
go to post Benjamin De Boe · Mar 13, 2020 and if you prefer something more database-independent, you can use the standard INFORMATION_SCHEMA package: SELECT TABLE_SCHEMA, TABLE_NAME, COLUMN_NAME FROM INFORMATION_SCHEMA.COLUMNS WHERE COLUMN_NAME LIKE 'PATID%'
go to post Benjamin De Boe · Mar 11, 2020 FWIW, you can just put as many conditions as you want in the same SQL query. InterSystems IRIS includes an excellent SQL optimizer that will consider all the conditions (and other clauses) in your query and decide on the most efficient path to access the data.
go to post Benjamin De Boe · Feb 20, 2020 Hi Darko, LONGVARCHAR is actually storing the text as a stream, so to make LIKE work, you'll need to convert it to a string, e.g. using SUBSTRING(), in the expression you're serving to the LIKE operator. The following works fine for me: SELECT SUBSTRING(text, 1, 999999) FROM table WHERE SUBSTRING(text, 1, 9999999) LIKE '%abc%' This looks a little clumsy, but streams are really meant for huge data that wouldn't fit in a VARCHAR. Note that you can get a massive amount of text in VARCHAR (%String) columns these days, so maybe that's worth considering. Separately, when working with iFind, that'll provide faster search results and it also transparently takes care of the stream aspect.
go to post Benjamin De Boe · Jan 9, 2020 Also, which versions are you using (on the server and client sides)?
go to post Benjamin De Boe · Jan 2, 2020 In addition to the suggestions made earlier (to provide more context such as full query & plan), you may also want to consider POSIXTIME as the data type for your date / time columns. It encodes dates as a simple 64-bit integer, which makes for efficient storage, indices and queries.
go to post Benjamin De Boe · Jan 2, 2020 Could you share the rest of the error message (hidden behind the alert) and more specifics on the ODBC connection type? And is there anything special about these tables or do you get this for each and every table?
go to post Benjamin De Boe · Nov 29, 2019 No, we indeed don't support that syntax feature. Like Evgeny said, this recursion is something we'd typically try to wrap inside ObjectScript methods, which you could then expose as a stored procedure.
go to post Benjamin De Boe · Sep 9, 2019 how about CASE :path WHEN '' THEN 1 ELSE $LENGTH(:path,'.')+1 END
go to post Benjamin De Boe · Sep 6, 2019 InterSystems IRIS (and Caché before that) will indeed make this decision for you. The SQL optimizer will analyze all the conditions in your query and select the best query plan based on the available table statistics, which includes column selectivity. See also this article on collecting those stats with the TuneTable command.As a matter of fact, our development team is making some exciting enhancements to the cost functions used to turn those table statistics into the actual cost estimates for the possible query plans. More about that at our upcoming Global Summit!
go to post Benjamin De Boe · Jun 17, 2019 Hi Guillaume,iFind indices, like bitmap indices before, require a bitmap-friendly ID key (positive integer). When you make a table the child in a parent-child relationship, the underlying storage structure will use a composite key that therefore no longer satisfies the bitmap friendliness. We do plan to lift this limitation in a future release, as it's already the case for bitmap indices, but for now you'll have to review your schema and see if a one-to-many or (preferred) foreign key would work for you.Thanks,benjamin
go to post Benjamin De Boe · May 16, 2019 Triggers expressed in SQL cannot contain a DECLARE clause, but you'd get a lot more flexibility when using ObjectScript triggers. See the reference documentation for more details.
go to post Benjamin De Boe · Apr 15, 2019 No, iKnow doesn't extract text from RTF prior to its NLP task. Besides the LibreOffice suggestion, I've also heard people who've worked with simple Java RTF extractors (part of regular JDK) and Tika in the past.