User Profile

Collapse

Profile Sidebar

Collapse
cpiyush
cpiyush
Last Activity: Jul 11 '07, 06:01 AM
Joined: Jan 25 '07
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • cpiyush
    replied to Query to find Primary and Foreign keys
    Oh...Thanks Das...:-)...
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to Query to find Primary and Foreign keys
    Execute this query if you are getting compilation errors:-
    show errors;
    This will list the line number/col number combination & the description of error which you have made in the function definition.

    Check your mistakes using this, as I can see one mistake just by reviewing ur code that you have not specifieds the type(IN/OUT) of the arguments passed in the prototype...

    Cheer!!!
    cPiyush....
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to Query to find Primary and Foreign keys
    It was quite useful...

    Thanks to everyone.

    Cheer.
    cPiyush.
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to cx_Oracle.NotSupportedError
    Hi...

    Got the solution.

    I was using cx_Oracle 4.1.2 interface, which doesn't support TIMESTAMP data type.
    I replaced it with the latest version of cx_Oracle i.e. 4.3.1 & not its working.

    Hope no one else will do the same mistake againg.

    Regards,
    cPiyush.
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to cx_Oracle.NotSupportedError
    Hi got the actual problem in the above code, this is not because of that constraint clause, actually its because of that TIMESTAMP datatype of oracle. cx_Oracle's object is not supporting this type(I dunno why...), but it supports timestamp() function.

    Probably this type is not defined in the definition of cx_oracle module.

    Now can you please tell me how to resolve this problem in python??...mean s I want to get all the...
    See more | Go to post

    Leave a comment:


  • cpiyush
    started a topic cx_Oracle.NotSupportedError

    cx_Oracle.NotSupportedError

    Hi,

    I am using cx_Oracle Python-Oracle interface V4.2.
    Its a great tool.
    But I am facing one problem in using it.

    I Have given a create table command: -
    [HTML]CREATE TABLE JG_MESSAGE( ID NUMBER(12,0) NOT NULL ,SENDER VARCHAR2(32) NOT NULL ,CENTENTS VARCHAR2(4000) NOT NULL ,INTIME TIMESTAMP(6) NOT NULL ,HEADING VARCHAR2(255) DEFAULT NULL,THREADID NUMBER(12,0) DEFAULT 1,IP VARCHAR2(15) DEFAULT 'N/A',...
    See more | Go to post

  • cpiyush
    replied to Export-Import
    Well...my problem is solved now.
    Thanks a lot...
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to Import Problem.
    Well... I got the solution. I had 2 users in that source DB MIGHTY_USER, MIGHTY!. But there were no tables in MIGHTY_USER. I created only one user in my traget DB i.e. MIGHTY_USER & not the MIGHTY!, so it was not showing me import of any table as it was not importing MIGHTY1's data.

    But I did not understand one thing, that If we are importing a FULLy exported DB then why we have to create all the users again manually in the target...
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to Python cx_Oracle Interfcae issue
    Yes you are right Bartonc, but the interface's compilre is giving arror at the cursor.execure( """describe tab1""") line, its saying check your sql syntax... All the other queries aree running fine except this one.

    I am running this to get the field type of the table, this was not working thats y I used cursor.describe method, If u can suggest me any other way for my basic problem(how to get field ty...
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to Python cx_Oracle Interfcae issue
    My code is something like this..
    Code:
    import cx_Oracle
    
    
    #Establishing Connection string using makedsn() function.
    
    host = 'localhost' 
    port = 1521 
    dbase = 'Sample' 
    login = 'demo' 
    passwrd = 'demo' 
    dsn = cx_Oracle.makedsn(host, port, dbase) 
    connection = cx_Oracle.connect(login, passwrd, dsn) 
    print "********", connection
    
    cursor
    ...
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to User Privileges Problem.
    Yeah Wel,

    Thats worked.

    Thanks.
    See more | Go to post

    Leave a comment:


  • cpiyush
    started a topic Python cx_Oracle Interfcae issue

    Python cx_Oracle Interfcae issue

    Hi,

    I am using Oracle 9i & Python.
    The interface is cx_Oracle4.3

    I was tryingto fire the following query using this interface: -

    cursor.execute( """describe employee""")

    & got error CHECK YOUR SQL SYNTAX. Although its working fine when i am firing it from SQL*Plus.

    Isn't it support this query or I am missing something.
    ...
    See more | Go to post

  • cpiyush
    started a topic Import Problem.

    Import Problem.

    Hi..

    We are using Oracle 9i.
    We have been given a dump file (mighty.dmp). We have created a new DB on our system & trying to import the given DB's data to the local Db.

    We are giving the following command: -
    C:\oracle\ora92 \bin>imp mighty1/mighty1 file=mighty.dmp FROMUSER=MIGHTY _TEST TOUSER=mighty1

    Import: Release 9.2.0.1.0 - Production on Fri Apr 20 16:08:11 2007
    ...
    See more | Go to post

  • cpiyush
    replied to How to get files of a Directory
    Thanks man...
    See more | Go to post

    Leave a comment:


  • cpiyush
    started a topic How to get files of a Directory

    How to get files of a Directory

    Hi.

    I am trying to read all the file names of a directory & trying to use getDir() function.
    But its saying AttributeError: 'module' object has no attribute 'getDir'
    Can you tell me the correct syntax to use it.

    I have one more query: - Plz tell me how to execute any command using python.
    i.e. i want to run
    sqlplus /nolog @c:\try.sql
    Can you tell me how to use it???
    ...
    See more | Go to post

  • cpiyush
    started a topic .sql file to Oracle tables.

    .sql file to Oracle tables.

    Hi.

    I have very simple query (its simple, but i dont know the exact syntax of this).

    I have several *.sql files of a DB.
    I want to load their data in that DB.

    I am trying sqlplus run @<files location> command, its working fine for the first commant, but after that its repeating the same, can you please suggest me how to do this???

    Thanks.
    Piyush.
    See more | Go to post

  • cpiyush
    started a topic Export-Import

    Export-Import

    Hi.

    I have created a .dmp file from a db 'Sample'.

    Then I created another db & imported that .dmp file to that new database.
    But this is not showing the contents of that Sample db in my new db.

    Can you please tell me how to take tables from onw db to another one??

    I have one more problem that I have some *.sql files, now I want to create a Database from these file, how can I do...
    See more | Go to post

  • cpiyush
    replied to Oracle Connectivity
    Yes. This table 'tab1' is created in db named 'Sample'.
    & I have given all the privileges to user 'demo' on this table.
    But all these privileges are not getting refelected when I am logging thru 'demo' & trying to execute 'select' stament.

    My basic problem is coming here that I am create a user---> granting all the privileges---> Logging in thru that user ---> Trying to execute those privileges (But those...
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to Oracle Connectivity
    Hey Thanks man.
    I have got solution... After some brain storming. Now I am using makedsn() function & its creating the connection without any error. The code is as follows: -

    host = 'localhost'
    port = 1521
    dbase = 'Sample'
    login = 'demo'
    passwrd = 'demo'
    dsn = cx_Oracle.maked sn(host, port, dbase)
    connection = cx_Oracle.conne ct(login, passwrd, dsn)


    But Now...
    See more | Go to post

    Leave a comment:


  • cpiyush
    replied to Oracle Connectivity
    I read this & the db name is correct.
    can you tell me wher to check the server name?...
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...