BookmarkSubscribeRSS Feed
SebStu
Calcite | Level 5

Hi!

We try to use the JDBC Driver to view tables in a database viewer from Jetbrains (Data Grip, Pycharm, Intellij). 

Driver: SAS Drivers for JDBC | SAS Support

 

Situation

  1. We connected a SAS Dataservice with PyCharm (and other IDEs Intellij, DataGrip from Jetbrains) succesfully.
  2. All tables and column information in the database tool tab looks fine….
  3. But, if we open a table, the column name on all culomns is "<anonymous>"
  4. Only Columns with a given comment/label will show the comment text.
  5. Checking the DDL we found out, that each column without a comment has a plenty of blanks as a comment 😥

Anyone have seen this behaviour? Ideas to fix it?

We realy not want to copy the column name in all columns mandatory.😂

 

2021-09-16 14_40_20-test__st_05 – CARS.png

Column defintions of sashelp.cars 

2021-09-16 14_40_03-test__st_05 – CARS.png

Table View with column names shows as "anonymous" 

 

2021-09-17 09_08_28-Modify Table.png

Responding Metadata vom SAS JDBC, see the many blanks as comment (sas called 'label')

 

2021-09-16 14_41_42-test__st_05 – CARS.png

DDL Created based on responding Metadata 

 

Parallel Jetbains Issue

Database Table Colum Name "<anonymous>" instead Colum Name : DBE-14103 (jetbrains.com)

 

5 REPLIES 5
ballardw
Super User

It would likely be helpful to include the LOG from running the code reading the data source. Copy the text of the code and all messages from the code generating the data set from the LOG and paste the text into a text box opened on the forum with the </> icon appearing above the message window on the forum.

The text box is important as it will preserve the formatting of the text which often includes diagnostic information that gets reformatted when pasting into a code box.

 

If you are going to post pictures you need to explain why each image is posted and what we should be looking for and likely what program you are using to examine this. How are you "opening the table"? Also which SAS environment are you working in? On Demand, Enterprise Guide, or something else.

SebStu
Calcite | Level 5

Hi! I am using the linked SAS JDBC driver in PyCharm, so there is no SAS Log.

Tom
Super User Tom
Super User

No idea what a "comment" is. 

 

But it is perfectly normal to not attach a LABEL to a variable.  For example that last photographs looks like it might be the SASHELP.CARS sample dataset that ships with SAS.  Only some the variables have labels or formats attached to them.

image.png

What most SAS procedures that use the LABEL in the output instead of the NAME will do is use the NAME when the LABEL is empty.

 

As to the blanks remember that SAS has only two types of variables. Fixed length character strings and floating point numbers.  It appears that whatever is populating the "comment" is taking the value of the LABEL field and including the trailing blanks that are included to pad it out to its full storage length.

SebStu
Calcite | Level 5

Many true words, but:

Issue descripes responding data with SAS JDBC driver 

SebStu
Calcite | Level 5

@Kitara @kitara may you can help me? Are you using SAS JDBC on intellij?

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 5 replies
  • 912 views
  • 0 likes
  • 3 in conversation