Getting a column description
Hi. I am running Microsoft SQL Server 2000 and am wanting to know if it is possible to get the text out of the Description field. I thought ResultSetMetaData.getColumnLabel(int id) would work but it keeps on returning the column name. Am I looking in the wrong spot? Is it even possible to retrieve this data?
Thanks for the help.
Ben
I don't think I made myself clear enough. When designing a table, at the bottom of the page there is a text field entitled "Description" that allows you to enter a text description of the object. I was told a while ago that you can extract this information from the DB using the getColumnLabel(x), however this is returning the column name (the same value as getColumnName(x)). What you have suggested returns the type name which in my case is varchar. So far I have tried
ResultSet rs = statement.executeQuery(......);
ResultSetMetaData rsmd = rs.getMetaData();
out.print(rsmd.getColumnName(x));
out.print(rsmd.getColumnLabel(x));
out.print(rsmd.getColumnTypeName(x));
Thanks,
Ben
Similar Messages
-
How to get the report description from obiee's web services (web catalog)?
I am trying to get the Description from the properties of a report (using web services + web catalog). I am not able to retrieve the description through the itemProperties[] array, and have not been successful finding it anywhere else. Has anyone been able to get the this Description property? Thanks.
hi,
are you looking for table name,column name,subject area,created time for a specific report/request ?
IF yes we can do this using Catalog manager
Open Catalog Manager-->tools-->Create Report
thanks,
saichand.v -
Problem with column description in report
Hi Guys,
In one of the queries, I have time-characteristic 0FISCPER (restricted on 0I_FPER variable) in the columns section. I have few key figures in my rows section of the query. When i executed the query (filter char. - Fiscal year variant restricted to July - June, 4 special periods i.e. V6), i get separate columns for each month as required. On execution, the following output appears (with user-entry values for 0FISCPER being 001/2005 - 012/2005):
July 2005 August 2005 ..... June 2005
The output i am expecting is:
July 2004 August 2004 ... June 2005
I have problem only with the column description. The data appears correctly. i.e. Data for July 2004 appears correctly but with heading July 2005 instead of July 2004. I created text variables on 0FISCPER for all the months of 2004. But no help.
Any help will be greatly appreciated.Hi,
Thanks for the note Bhanu. The note mentions about BW 3.5 SP9. We are already on SP10.
Looking for help.
Thanks. -
CS4: Automatically resize textfield to get equal columns?
Hello,
is there a option (or possible with a script) to resize a textfield in the vertical length to get equal column heights with such a result?
Thanks, CarlosAdobe has discovered a usability issue associated with running Adobe InDesign CS5 and InCopy CS5 GERMAN versions and all suites that include InDesign CS5 on the Mac OS X platform. We are addressing this issue as quickly as possible to ensure the best experience for our customers. For customers who currently have the German version of InDesign CS5, InCopy CS5, Design Standard CS5, Design Premium CS5 or Master Collection CS5 installed on the Mac platform, please reference the Adobe Knowledge Base article which provides a further description of the issue and manual workaround.
English - http://go.adobe.com/kb/ts_cpsid_84345_en-us
German - http://go.adobe.com/kb/ts_cpsid_84345_de-de
Swedish - http://go.adobe.com/kb/ts_cpsid_84345_sv-se (not live yet, but will be soon)
Message was edited by: Peter Spier -
How get one column's value in dashboard of obiee?
I have two reports, MAIN report and DETAIL report. I want to get one column's value as the filter of DETAIL report.
For example, the MAIN report is
Class AVG_Age MAX_Age MIN_Age
Class1 13 15 11
Class2 14 16 12
DETAIL report is
Name Class Old Describe
Name1 Class1 15 ...
Name2 Class2 16 ...
Through the Navigation to implement it, when I click the 15 of MAIN report, it can only show the MAX age student of calss1. So I have to put the MAX_Age as the DETAIL report's filter. How can I get it?
Thanks
Edited by: user10496160 on 2008-11-3 下午9:31
Edited by: user10496160 on 2008-11-3 下午10:53If I understand correctly, what you are trying to do is build a report so that a user can determine the oldest student of a particular class and then look at the details of that student, yes? But what if several classes have a student (or students!) with the same "max" age? For example, what if there are students in 2 classes that are aged 15 and are the oldest in their respective class? Wouldn't you want to give the user the option if choosing the various classes in which the oldest student is the "max" age? Then do this:
On the Main report, put the summary information as you have it (Class, AVG_Age, MAX_Age, MIN_Age). Put the Value Interaction navigation on the MAX_Age column.
On the Detail report, put Class, Name, Age, Description, etc., and any other columns that show the details of the student(s) that are the oldest. Add the filter on the Age column: "Is prompted." Now, create a Pivot Table view and place the Class column in the Pages area. (If you want you can create a duplicate of the Class column so you can have a copy in the Rows section of the Pivot Table.)
Now when the user clicks on the MAX_Age in the Main report, it will show the Detail report with the Classes that have students with the same "max" age in a drop down window. The user can select different classes to see the various students that meet that criterion. -
Hi!
I'm using MSSQL 2000 as database engine. So far i'm using DataBaseMetaData for getting column properties like type, name and so on. Now i want to get columns description (i put this description). is there any way to do it, but from java not from database?
Tnx :-)i dont know how this works
SELECT * FROM ::fn_listextendedproperty(NULL,
'user', 'dbo', 'table', 'Test', 'column',
default)
but
the following code snippet might help u
ResultSetMetaData rsMd = rs.getMetaData();
int numberOfColumns = rsMd.getColumnCount();
for (int i = 1; i <= numberOfColumns; i++) {
cName = "unknown";
try {
cName = rsMd.getColumnName(i);
cType = rsMd.getColumnTypeName(i);where cname is the column name and ctype is column
typei don't want column name or column type :-) i want column description.
for example:
column name = idPrimaryKey
column type = int indentity
column description = primary key for this table .....
with getColumnName i get idPrimaryKey, with getColumnTypeName i get int indentity, but how can i get "primary key for this table ....."? -
Hi,
I need fixed the column description in the reporte KE30 from I move to the right and displayed continuously.
Thanks.alekoc wrote:
I use column's description for my tables in Oracle 11g data base. Sometimes I do the tables export for another developer, but it does not include the column's description into EXPDAT.DMP file. Probably I need to provide some additional parameter for export, I don't know. Is there a way to include column's descriptions into DMP file? If not, is there another way to pass this data from one developer to another?You must be referring to the data in dba_col_comments view. This is a data dictionary view and would not be exported with table data. If there is a expdp option to pull that information, it will be documented in the Utilities manual in the chapter on Data Pump. If there is such an option documented there, then you have your answer. If there is not such an option documented there, then you still have your answer.
I strongly encourage you to follow up on that hint and search the documentation for such a parm. The exercise will do you good.
If there is no such option, you could extract that information separately by using a sql script to create a sql script
set echo off verify off feedback off head off trimspool off
spool doit.sql
select 'comment on column ' ||
owner ||
'.' ||
table_name ||
'.' ||
column_name ||
' is '''||
comments ||
from dba_col_comments
where <whatever your criteria>
spool offExamine doit.sql and see if any adjustments need to be made. You may need to play around with the quotes to get the required single quote literals around the value returned for the COMMENTS column. -
How can we get Dynamic columns and data with RTF Templates in BI Publisher
How can we get Dynamic columns and data with RTf Templates.
My requirement is :
create table xxinv_item_pei_taginfo(item_id number,
Organization_id number,
item varchar2(4000),
record_type varchar2(4000),
record_value CLOB,
State varchar2(4000));
insert into xxinv_item_pei_taginfo values( 493991 ,224, '1265-D30', 'USES','fever','TX');
insert into xxinv_item_pei_taginfo values( 493991 ,224, '1265-D30', 'HOW TO USE','one tablet daily','TX');
insert into xxinv_item_pei_taginfo values( 493991 ,224, '1265-D30', 'SIDE EFFECTS','XYZ','TX');
insert into xxinv_item_pei_taginfo values( 493991 ,224, '1265-D30', 'DRUG INTERACTION','ABC','TX');
insert into xxinv_item_pei_taginfo values( 493991 ,224, '1265-D30', 'OVERDOSE','Go and see doctor','TX');
insert into xxinv_item_pei_taginfo values( 493991 ,224, '1265-D30', 'NOTES','Take after meal','TX');
select * from xxinv_item_pei_taginfo;
Item id Org Id Item Record_type Record_value State
493991 224 1265-D30 USES fever TX
493991 224 1265-D30 HOW TO USE one tablet daily TX
493991 224 1265-D30 SIDE EFFECTS XYZ TX
493991 224 1265-D30 DRUG INTERACTION ABC TX
493991 224 1265-D30 OVERDOSE Go and see doctor TX
493991 224 1265-D30 NOTES Take after meal TX
Above is my data
I have to fetch the record_type from a lookup where I can have any of the record type, sometime USES, HOW TO USE, SIDE EFFECTS and sometimes some other set of record types
In my report I have to get these record typpes as field name dynamically whichever is available in that lookup and record values against them.
its a BI Publisher report.
please suggestif you have data in db then you can create xml with needed structure
and so you can create bip report
do you have errors or .... ? -
How to get the column values from a BC4J View Table in UIXML?
I am using a default UiXML Application for Order Entry system with Orders & Order Lines & Customers. I have a uix file OrdersView1_View.uix which displays (no updateable columns) all the Orders. How do I get the column value of a selected row in a BC4J Table (example:OrdersId) when a Submit button is pressed using UIXML or Java Classes?
I appreciate any help on this.Hi,
You need to use keyStamp, an example:
<bc4j table name="orders">
<bc4j:keyStamp>
<bc4j:rowKey name="key" />
</bc4j:keyStamp>
Furthermore, you can automatically send the selected row key using the go event handler, so in the handlers section you could send the key to an orderInfo page:
<event name="show">
<!-- forward to the update page, passing
the selected key as a page property -->
<ctrl:go name="orderInfo" redirect="true">
<ctrl:property name="key">
<ctrl:selection name="orders" key="key" />
</ctrl:property>
</ctrl:go>
</event> -
How Can I get multi column values from dynamic search help?
Hi Gurus;
I'm using dynamic search help in my program.
I want to get multi column values from search help. But I dont know solution for this issue.
I'm using F4IF_INT_TABLE_VALUE_REQUEST FM.
How Can I get multi column values from dynamic search help?
Thanks.Believe it or not, the same FM worked for me in a dynpro. I will try to explain here how it works in custom screen and then you can do your work for other screens or program types. I am not going to write my actual work but will explain in general.
I have 4 fields (FLD1, FLD2, FLD3, FLD4) and i made the search based on FLD2 and when user click on a line (could be any field), then this would bring the line on to the screens.
There are like 3 steps.
You have your value_tab for my fields FLD1, FLD2, FLD3 and FLD4. This is just the data that we pass into the FM. (data: IT_VALTAB type table of ZVAL_TABLE)
Next map the screen fields into an internal table (data: It_dynpfld type table of dselc ). I also have other internal tables defined (just to keep it straight, i will be putting here) data: It_return type standard table of ddshretval.
Next step is to call the function module. Make sure you have values in IT_VALTAB.
call function 'F4IF_INT_TABLE_VALUE_REQUEST'
exporting
retfield = 'FLD2'
value_org = 'S'
tables
value_tab = It_VALTAB
return_tab = It_return
dynpfld_mapping = It_dynpfld
exceptions
parameter_error = 1
no_values_found = 2
others = 3.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
else.
perform get_selected_fields tables It_return.
endif.
The code within the perform GET_SELECTED_FIELDS - We need to map the result fields after user selects it. The code goes like this. This is step is to update the dynpro fields.
I need a internal table as well as a work area here. like,
data: lt_fields type table of dynpread,
la_fields type dynpread.
field-symbols: <fs_return> type ddshretval.
so fill out LT_FIELDS from the IT_RETURN table
loop at lt_return assigning <fs_return>.
la_fields-fieldname = <fs_return>-retfield.
la_fields-fieldvalue = <fs_return>-fieldval.
append la_fields to lt_fields.
clear: la_fields.
endloop.
Call the FM to update the dynpro
call function 'DYNP_VALUES_UPDATE'
exporting
dyname = sy-repid
dynumb = '1002' "This is my screen number. You could use 1000 for selection screen (hope so)
tables
dynpfields = lt_fields
exceptions
invalid_abapworkarea = 1
invalid_dynprofield = 2
invalid_dynproname = 3
invalid_dynpronummer = 4
invalid_request = 5
no_fielddescription = 6
undefind_error = 7
others = 8.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
good luck -
Just new to this and unable to find answers
My solution
Public Function GetTableColumnNames() As Boolean
Form1.ListBox1.Items.Clear()
_MDFFileName = String.Format("{0}.mdf", _DatabaseName)
_sqlConnectionString = String.Format("Data Source=(LocalDB)\v11.0;AttachDBFileName={1};Initial Catalog={0};Integrated Security=True;", _DatabaseName, Path.Combine(_DatabaseDirectory, _MDFFileName))
Dim cn As New SqlConnection(_sqlConnectionString)
'put the table name in brackets in case it has spaces in it
Dim SQLString As String = "SELECT * FROM [" & _TableName & "]"
Try
cn.Open()
Dim cmd As New SqlCommand(SQLString, cn)
Dim rdr As SqlDataReader =
cmd.ExecuteReader(CommandBehavior.KeyInfo)
Dim tbl As DataTable = rdr.GetSchemaTable
'This shows all of the information you can access about each column.
For Each col As DataColumn In tbl.Columns
Form1.ListBox1.Items.Add(col.ColumnName)
Debug.Print("col name = " & col.ColumnName & ", type = " & col.DataType.ToString)
Next
'Get each column.
For Each row As DataRow In tbl.Rows
Form1.ListBox1.Items.Add(row("ColumnName"))
Next
rdr.Close()
Catch
MessageBox.Show("Error opening the connection to the database.")
Finally
cn.Close()
End Try
Return _Success
End Function -
Please Help!!!
How to write a case statement for the totals column of two different years (2013 and 2014) of the same month so that I can get a +/- column.
January 2014 January
2013 +/-
Region Entry Exit Total Entry Exit Total (Total of Jan2014-Total of Jan2013)
A 2 3
40 5 7 30 40-30= 10What is a table structure? Sorry cannot test it right now..
SELECT <columns>,(SELECT Total FROM tbl WHERE Y=2014)-(SELECT Total FROM tbl WHERE Y=2013)
FROM tbl
Best Regards,Uri Dimant SQL Server MVP,
http://sqlblog.com/blogs/uri_dimant/
MS SQL optimization: MS SQL Development and Optimization
MS SQL Consulting:
Large scale of database and data cleansing
Remote DBA Services:
Improves MS SQL Database Performance
SQL Server Integration Services:
Business Intelligence -
How to get summary columns in delimited text file
How to get summary columns in delimited text file
I am trying to generate a delimited text file output with delimited_hdr = no.The report is a Group above report with summary columns at the bottom.In the text file the headers are not getting repeated & thats ok.The problem is the summary data is getting repeated for each row of data.Is there a way where i will get all the data & summary data will get displayed only once.I have to import the delimited text file in excel spreadsheet.Sorry there were a typos :
When I used desformat=DELIMITEDDATA with desttype=FILE, I get error "unknown printer driver DELIMITEDDATA". When you look for help, DELIMITED is not even listed as one of the values for DESTFORMAT. But if you scroll down and look for DELIMITER it says , this works only in conjuction with DESTFORMAT=DELIMITED !!!!!!??!! This is in 9i.
Has this thing worked for anybody ? Can anyone please tell if they were able to suppress the sumary columns or the parent columns of a master-detail data for that matter ? -
Error while trying to change the Column description in Table Control
Hi,
I have created a table control using the wizard in Module Pool.
When i try to change the column description of the table control or adjust any other element which is already available on the screen and not in table control. It gives me an error
Unable to transfer data. End Program?
Any help would be appreciated.
Thanks
Sarves S V KHi.,
Check these [Table Control Change Column Description|Add new columns in table control in custom screen program;
and [Add Columns in Table Control|Re: Table control columns]
else delete and create Table control Again..!!
hope this helps u.,
Thanks & Regards,
Kiran -
How to get Org Key description
Hi,
I have a query. In table pa0001 there is a field Org Key(VDSK1). when i execute this table for the personnel number i am able to see vdsk1 in the output.When i ress F4 on it i am able to see its description.
For example VDSK1 is 10 when i press F4 i am able to see descripions here. I need the table which gives the org key description.. I have seen the domain of VDSK1 here i am able to see T5270 is table to get description.
When i write select query as below i am getting T5270 is a table does not exist or not active. Its a polled table.
"-- Org Key description
SELECT SINGLE TEXT1
FROM T5270
INTO wa_disp_list-org_description
WHERE MANDT = sy-mandt AND
HIRAR = '1' AND
ORGKY = wa_disp_list-vdsk1.
anybody can tell me which table i have to use to get org key description.
Thanks,
MaheedharHello
This is table T527O - last symbol letter O, not 0 (zero).
Maybe you are looking for
-
I cannot update the song information on my iPod in iTunes.
I got an iPod Touch 4g about a year ago. Last month the iPod all the sudden stopped working. I took it into the store twice and the second time they simply replaced it with a new one. Since then I have been having two problems: 1) The operating syst
-
Why don't titles from iPhoto iOS transfer to Mac?
I was so excited when iPhoto for the iPad was released. The ability to caption photos while on the road was something I'd been waiting for since the first iPad was released. I just returned from a 3 week trip to Africa and had carefully titled each
-
[SOLVED]Audacious can't open files with spaces on name
I open audacious Type Ctrl+o and select a directory with spaces on it names, Audacious opens nothing Any ideas? I have deep trees of music with spaces, I was working on a script to rename one by one, but I'm too lazy Cheers Last edited by geckos (201
-
Any other way to learn configuration for FICO
Dear all gurus, I am FICO 1st level support in my company and not granted to access SPRO. I want to learn setting and configuration. Is there any standalone program or stimulator that provide the chance to access into SPRO? Please help and thousand t
-
Calling AIX database from Windows
Hi, I've the following requirment. When any files is added in particular folder in Windows NT, I need to add that file name in a database(DB2) which resides in AIX(IBM's Unix) Operating System? Please, let me know how to acheive the same. Thanks & Re