IParameterMetaData paramMetaData = query.getParameterMetaData( ); mergeParameterMetaData( design, paramMetaData ); query.executeQuery( );
setParameterMetaData( design, query );
	public static void saveDataSetDesign( DataSetDesign design )	{		// obtain query's result set metadata, and update		// the dataSetDesign with it		IConnection conn = null;		try		{			IDriver jdbcDriver = new OdaJdbcDriver( );			conn = jdbcDriver.getConnection( null );			java.util.Properties prop = new java.util.Properties( );			DataSourceDesign dataSourceDesign = design.getDataSourceDesign( );			if ( dataSourceDesign != null )			{				prop.put( Constants.ODADriverClass,						dataSourceDesign.getPublicProperties( )								.getProperty( Constants.ODADriverClass ) == null								? "" : dataSourceDesign.getPublicProperties( )										.getProperty( Constants.ODADriverClass ) );				prop.put( Constants.ODAURL,						dataSourceDesign.getPublicProperties( )								.getProperty( Constants.ODAURL ) == null ? ""								: dataSourceDesign.getPublicProperties( )										.getProperty( Constants.ODAURL ) );				prop.put( Constants.ODAUser,						dataSourceDesign.getPublicProperties( )								.getProperty( Constants.ODAUser ) == null ? ""								: dataSourceDesign.getPublicProperties( )										.getProperty( Constants.ODAUser ) );				prop.put( Constants.ODAPassword,						dataSourceDesign.getPublicProperties( )								.getProperty( Constants.ODAPassword ) == null								? "" : dataSourceDesign.getPublicProperties( )										.getProperty( Constants.ODAPassword ) );			}			conn.open( prop );			IQuery query = conn.newQuery( design.getOdaExtensionDataSetId( ) );			query.setMaxRows( 1 );			query.prepare( design.getQueryText( ) );			// set parameter metadata			IParameterMetaData paramMetaData = query.getParameterMetaData( );			mergeParameterMetaData( design, paramMetaData );			query.executeQuery( );			// set resultset metadata			IResultSetMetaData metadata = query.getMetaData( );			setResultSetMetaData( design, metadata );		}		catch ( OdaException e )		{			// no result set definition available, reset in dataSetDesign			design.setResultSets( null );		}		finally		{			if ( conn != null )				try				{					conn.close( );				}				catch ( OdaException e )				{					e.printStackTrace( );				};		}	}