mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-29 00:36:01 +00:00
oracle fixes
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
import _ from 'lodash';
|
import _ from 'lodash';
|
||||||
import { GridDisplay, ChangeCacheFunc, ChangeConfigFunc } from './GridDisplay';
|
import { GridDisplay, ChangeCacheFunc, ChangeConfigFunc } from './GridDisplay';
|
||||||
import type { EngineDriver, ViewInfo, ColumnInfo } from 'dbgate-types';
|
import type { EngineDriver, ViewInfo, ColumnInfo, DatabaseInfo } from 'dbgate-types';
|
||||||
import { GridConfig, GridCache } from './GridConfig';
|
import { GridConfig, GridCache } from './GridConfig';
|
||||||
|
|
||||||
export class ViewGridDisplay extends GridDisplay {
|
export class ViewGridDisplay extends GridDisplay {
|
||||||
@@ -11,9 +11,10 @@ export class ViewGridDisplay extends GridDisplay {
|
|||||||
setConfig: ChangeConfigFunc,
|
setConfig: ChangeConfigFunc,
|
||||||
cache: GridCache,
|
cache: GridCache,
|
||||||
setCache: ChangeCacheFunc,
|
setCache: ChangeCacheFunc,
|
||||||
|
dbinfo: DatabaseInfo,
|
||||||
serverVersion
|
serverVersion
|
||||||
) {
|
) {
|
||||||
super(config, setConfig, cache, setCache, driver, serverVersion);
|
super(config, setConfig, cache, setCache, driver, dbinfo, serverVersion);
|
||||||
this.columns = this.getDisplayColumns(view);
|
this.columns = this.getDisplayColumns(view);
|
||||||
this.formColumns = this.columns;
|
this.formColumns = this.columns;
|
||||||
this.filterable = true;
|
this.filterable = true;
|
||||||
|
|||||||
@@ -322,7 +322,7 @@ export class DatabaseAnalyser {
|
|||||||
this.logger.debug({ rows: res.rows.length, template }, `Loaded analyser query`);
|
this.logger.debug({ rows: res.rows.length, template }, `Loaded analyser query`);
|
||||||
return res;
|
return res;
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
logger.error({ err, message: err.message, template, sql }, 'Error running analyser query');
|
logger.error({ err, message: err.message, template }, 'Error running analyser query');
|
||||||
return {
|
return {
|
||||||
rows: [],
|
rows: [],
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -18,7 +18,7 @@
|
|||||||
import SqlFormView from '../formview/SqlFormView.svelte';
|
import SqlFormView from '../formview/SqlFormView.svelte';
|
||||||
import { getBoolSettingsValue } from '../settings/settingsTools';
|
import { getBoolSettingsValue } from '../settings/settingsTools';
|
||||||
import { extensions } from '../stores';
|
import { extensions } from '../stores';
|
||||||
import { useConnectionInfo, useDatabaseServerVersion, useViewInfo } from '../utility/metadataLoaders';
|
import { useConnectionInfo, useDatabaseInfo, useDatabaseServerVersion, useViewInfo } from '../utility/metadataLoaders';
|
||||||
import { getLocalStorage, setLocalStorage } from '../utility/storageCache';
|
import { getLocalStorage, setLocalStorage } from '../utility/storageCache';
|
||||||
import useGridConfig from '../utility/useGridConfig';
|
import useGridConfig from '../utility/useGridConfig';
|
||||||
import StatusBarTabItem from '../widgets/StatusBarTabItem.svelte';
|
import StatusBarTabItem from '../widgets/StatusBarTabItem.svelte';
|
||||||
@@ -32,6 +32,7 @@
|
|||||||
$: connection = useConnectionInfo({ conid });
|
$: connection = useConnectionInfo({ conid });
|
||||||
$: viewInfo = useViewInfo({ conid, database, schemaName, pureName });
|
$: viewInfo = useViewInfo({ conid, database, schemaName, pureName });
|
||||||
$: serverVersion = useDatabaseServerVersion({ conid, database });
|
$: serverVersion = useDatabaseServerVersion({ conid, database });
|
||||||
|
$: dbinfo = useDatabaseInfo({ conid, database });
|
||||||
|
|
||||||
const config = useGridConfig(tabid);
|
const config = useGridConfig(tabid);
|
||||||
const cache = writable(createGridCache());
|
const cache = writable(createGridCache());
|
||||||
@@ -46,6 +47,7 @@
|
|||||||
config.update,
|
config.update,
|
||||||
$cache,
|
$cache,
|
||||||
cache.update,
|
cache.update,
|
||||||
|
$dbinfo,
|
||||||
$serverVersion
|
$serverVersion
|
||||||
)
|
)
|
||||||
: null;
|
: null;
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ select
|
|||||||
routine_name as "pure_name",
|
routine_name as "pure_name",
|
||||||
-- routine_schema as "schema_name",
|
-- routine_schema as "schema_name",
|
||||||
routine_definition as "definition",
|
routine_definition as "definition",
|
||||||
standard_hash(routine_definition, 'MD5') as "hash_code",
|
ora_hash(routine_definition) as "hash_code",
|
||||||
routine_type as "object_type",
|
routine_type as "object_type",
|
||||||
'fixme_data_type' as "data_type",
|
'fixme_data_type' as "data_type",
|
||||||
'fixme_external_language' as "language"
|
'fixme_external_language' as "language"
|
||||||
|
|||||||
Reference in New Issue
Block a user