BookmarkSubscribeRSS Feed
u63052832
Calcite | Level 5

I'm studying SAS but I can't find the package com.sas.services.connection.omr, error in source:

 

import com.sas.services.connection.omr.OMRConnectionFactoryConfiguration;

ConnectionFactoryConfiguration cxfConfig
= new OMRConnectionFactoryConfiguration(iOMI, reposID, name);

 

Where do I find it?

Thanks.

5 REPLIES 5
ChrisHemedinger
Community Manager

Are you researching how to build a Java client that connects to SAS? That's what this Java snippet is part of. More Javadoc here:

https://support.sas.com/rnd/javadoc/94/Foundation/index.html?com/sas/services/connection/omr/OMRConn...

 

If you're goal is to just learn SAS, then I would start with one of the basic SAS programming courses or tutorials. If you are looking to build another application that connects to SAS, consider looking at SASPy (for Python) or using the many APIs available in SAS Viya.

SAS For Dummies 3rd Edition! Check out the new edition, covering SAS 9.4, SAS Viya, and all of the modern ways to use SAS!
u63052832
Calcite | Level 5

Hello, I'm studying how to access SAS through Java. Through saspy I connect through port 8591 (workspace server), but through port 8561 (metadata server) and later the workspace I'm not able to. So I found an example that uses this package, but I can't find the jar.

 

 

ChrisHemedinger
Community Manager

Do you need to go through the Metadata server? The Metadata server acts like a directory -- you connect to it to query what Workspace servers you have, then you use that to connect to the Workspace. But if you already know the Workspace (like with SASPy config), you can skip Metadata and go direct to the Workspace. This is not permitted in every setup, but if SASPy is working for you (no Metadata), then this should.

 

See the developer guide:

SAS Help Center: Developing Java Clients

 

The sas.*.jar files are usually installed with SAS Foundation Services in a /SASVersionedJarRepository folder. Check your SAS install for these.

SAS For Dummies 3rd Edition! Check out the new edition, covering SAS 9.4, SAS Viya, and all of the modern ways to use SAS!
u63052832
Calcite | Level 5

The SAS installation don´t have this jar.
On the workspace server with port 8591, it connects normally via saspy:
sas = saspy.SASsession(omruser='xxxx', cfgname='winiomwin')
Please enter the password for OMR user xxxx: ········
SAS Connection established. Subprocess id is 1234

Workspace with port 8599 returns error.

ChrisHemedinger
Community Manager

These jar files are also installed with any Java-based SAS client, including SAS Management Console. If you don't have this on your current machine, perhaps install it from your SAS software depot. Also they *should* be part of the SAS Integration Technologies client (which is also installable from your depot).

 

They do not require an additional license to use, but note that SAS Integration Technologies is required for a client application (even a custom client you build in Java) to connect to a remote (non-localhost) SAS Workspace.

SAS For Dummies 3rd Edition! Check out the new edition, covering SAS 9.4, SAS Viya, and all of the modern ways to use SAS!

hackathon24-white-horiz.png

The 2025 SAS Hackathon Kicks Off on June 11!

Watch the live Hackathon Kickoff to get all the essential information about the SAS Hackathon—including how to join, how to participate, and expert tips for success.

YouTube LinkedIn

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 5 replies
  • 1127 views
  • 0 likes
  • 2 in conversation