If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Informix > Oracle syntax to Informix syntax

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-25-02, 03:37
pb_icwa pb_icwa is offline
Registered User
 
Join Date: Nov 2002
Location: India
Posts: 4
Post Oracle syntax to Informix syntax

Could anybody help me in converting the oracle syntax to informix syntax or help me where can I get a good help for this. I am seriously in trouble with this.

The Oracle sql statements :

1. SELECT MACHINE
INTO :HOST FROM V$SESSION
WHERE SID = '1'

2. SELECT BANNER INTO :BANNER FROM V$VERSION
WHERE BANNER LIKE '%Windows%'
OR BANNER LIKE '%OSF%'
OR BANNER LIKE '%Tru64%'

3. SELECT SUBSTR(SPID,1,5), S.SID,
BLOCK_GETS, CONSISTENT_GETS, PHYSICAL_READS,
S.SQL_ADDRESS
INTO :WP_THREAD, :WPTABLE-WP_ORA_SID,
:WPTABLE-WP_BL_GETS, :WPTABLE-WP_CS_GETS,
:WPTABLE-WP_PHYREAD,
:WPTABLE-WP_SQL_ADR
FROM V$SESSION S, V$PROCESS P, V$SESS_IO I
WHERE S.PADDR = P.ADDR
AND S.PROCESS LIKE
:WP_PID
AND S.SID = I.SID AND S.STATUS = 'ACTIVE'

4. SELECT SPID, S.SID,
BLOCK_GETS, CONSISTENT_GETS, PHYSICAL_READS,
S.SQL_ADDRESS
INTO :WPTABLE-WP_ORA_PID, :WPTABLE-WP_ORA_SID,
:WPTABLE-WP_BL_GETS, :WPTABLE-WP_CS_GETS,
:WPTABLE-WP_PHYREAD,
:WPTABLE-WP_SQL_ADR
FROM V$SESSION S, V$PROCESS P, V$SESS_IO I
WHERE S.PADDR = P.ADDR
AND S.PROCESS LIKE
:WP_PID
AND S.SID = I.SID AND S.STATUS = 'ACTIVE'

5. SELECT ADDRESS, PIECE, SQL_TEXT
FROM V$SQLTEXT
WHERE ADDRESS IN (
:ADDRESS1 , :ADDRESS2 , :ADDRESS3 , :ADDRESS4 ,
:ADDRESS5 , :ADDRESS6 , :ADDRESS7 , :ADDRESS8 ,
:ADDRESS9 , :ADDRESS10 , :ADDRESS11 ,
:ADDRESS12, :ADDRESS13 , :ADDRESS14 ,
:ADDRESS15 , :ADDRESS16 ,
:ADDRESS17 , :ADDRESS18 , :ADDRESS19 , :ADDRESS20
)
INTO :THREAD_SQL_STMT

Thanks in Advance
Reply With Quote
  #2 (permalink)  
Old 10-15-09, 03:36
papajack papajack is offline
Registered User
 
Join Date: Oct 2009
Posts: 15
In informix, we use "onstat" to query on the dbstatus. You can check onstat --help.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On