Tools - Export DDL (and data) mishandles timestamps

I used SQLDeveloper to try to do a quick export of some test data. Here is a sample of part of an insert statement created by the export data option:
to_timestamp('2005-12-31 00:00:00.0','DD-MON-RR HH.MI.SS.FF AM')
This clearly will not work as the timestamp was retrieved in a format different than the format used in the to_timestamp() function. I tried to fix it, but I found than the utility switched from format to format. Some insert statements were consistent, some formatted the actual data differently, others used different format strings. It looked like I went to each developer and told them to write some code to create insert statements for their tables. Each one came back using a different format. Some were able to code valid SQL statements while others weren't able to create valid SQL. Unfortunately this was all done by one click. I cannot fathom how you all created such a mess because not only is it wrong (sometimes) but it is inconsistent. Actually I would guess someone created a hash table of available formats and randomly picked from the hash table.

There is actually no error we are using dbms_metadata to see if there are contraints or ref_contraints on the table and this is the way it tells us there are not. We should be capturing this message better and not sending it to the user and I will fix that in the next release.
However, this error should not be affecting your export if it is or you see missing information from the generated export file please reply.

Similar Messages

  • BUG: Export DDL and Data fails for mixed case table/column names

    Hi there,
    I have found a bug in SQL Developer. See details below.
    Description:
    When "Export DDL and Data) function is used on a table/columns not named in UPPERCASE, sql generated by SQL Developer is invalid.
    Steps to reproduce:
    - open SQL Developer, connect to DB
    - make a table named "lowerCase" (in double quotes, so it won't be automatically changed to capital letters)
    - you may also add some columns, for example "lowerCol1", "UpCol2", ALLUPCOL3
    - add some data rows to the table
    - choose Tools -> Export DDL and Data
    - check exporting of tables and data, on "filter" tabs choose your "lowerCase" table
    - press "Apply"
    Error:
    Generated SQL contains invalid INSERTs: mixed-case table and columns are referenced without obligatory double quotes, which yields an error when generated script is executed (see below, relevant line is underlined)
    -- DDL for Table lowerCase
    CREATE TABLE "DBO_HT"."lowerCase"
    (     "lowerCol1" VARCHAR2(100),
         "UpCol2" VARCHAR2(100),
         "ALLUPCOL3" VARCHAR2(100)
    -- DATA FOR TABLE lowerCase
    -- FILTER = none used
    -- INSERTING into lowerCase
    Insert into lowerCase (lowerCol1,UpCol2,ALLUPCOL3) values ('lc','uc','auc');
    -- END DATA FOR TABLE lowerCase
    Remarks
    SQL Developer: version 1.2.1, build MAIN-32.13
    Oracle DBs: 9.2 & Express
    OS: Windows 2000 Professional
    If you need any more details/testing, let me know. I'd really appreciate a quick patch for this issue...
    Alternatively, do you know of any other simple way of copying a single database (it's called a schema in Oracle, right?) from one computer to another? Possibly something so simple like detaching->copying->reattaching mdf (data) files in SQL Server... I thought that this "Export DDL&Data" function will do, but as you can see I couldn't use it.
    I just need a simple solution that works - one operation on source to stuff, get the resulting files to other computer and one operation to have it running there... I think that such scenario is very basic, yet I just can't achieve it and I am simply not allowed to spend more time on it (read: our test project fails, my company rejects my "lobbying" and stays with MSSQL :/ )
    Thanks a lot & bye

    Thanks for your reply.
    ad. 1)
    You're right. I just wanted to give some very short feedback on my experiences with SQL Developer, so I didn't think starting new threads would be necessary, but as I was writing it became much bigger than I initially planned - sorry about that. I will make proper threads as soon as possible. Having "Edit post" button on this forum would also be useful.
    ad. 2)
    Generally, you're right - in most cases it's true that "switching DBMS is a major commitment" and "you will produce terrible code" if you don't learn the new one.
    However, I think that you miss one part of market here - the market that I think Express is also targeted on. I'd call it a "fire&forget databases" market; MySQL comes to mind as possibly most common solution here. It's the rather small systems, possibly web-accessed, whose data-throughput requirements are rather modest; the point is to store data at all, and not necesarily in fastest way, because given the amount of data that is used, even on low-end hardware it will work well enough. What's important here is its general ease of use - how easy is to set up such system, connect and access data, develop a software using it, how much maintenance is needed, how easy this maintenance is, how easy are the most common development tasks as creating a DB, moving a DB from test to production server etc. There, "how easy" directly translates to "how much time we need to set it up", which translates to "how much will the development will cost".
    Considering the current technology, switching the DBMS in such systems is not necesarily a major commitment and believe me that you will not produce terrible code. In many cases it's as simple as changing a switch in your ORM toolkit: hibernate.dialect = Hibernate.Dialect.OracleDialect vs MySQLDialect vs MsSql2005Dialect
    Therefore, in some part of market it's easy to switch DBMS, even on project-by-project basis. The reason to switch will appear when other DBMS makes life easier => development faster. From that point of view, I can understand my colleagues giving me an embarassing look and saying "come on, I won't read all these docs just to have db copied to test server". And it doesn't mean "they are not willing to learn anything new", it's just that they feel such basic task should have self-explaining solution that doesn't require mastering any special knowledge. And if they get such simple solutions somewhere else, it costs them nothing to change the hibernate dialect.
    I think Oracle did the great job with introducing the Express to this "fire&forget" market. The installation is a snap, it just works out of the box, nothing serious to configure, opposite to what I remember from installing and working on Oracle 9 a few years ago. In some places it's still "you need to start SQL*Plus and enter this script", but it's definitely less than before. I also find the SQL Developer a great tool, it can do most of what we need to do with the DB, it's also much better and pleasant to use over Oracle 9 tools. Still, a few basic things still require too much hassle, and I'd say taking your schema to another machine is one of them. So I think that, if you do it well, the "schema copy wizard" you mentioned might be very helpful. If I was to give any general advice for Express line of DB/tools, I'd say "make things simple" - make it "a DB you can't see".
    That's, IMHO, the way to attract more Express users.

  • SQL Dev 1.5.4+: Scripting DDL and data dumps?

    In SQL Dev 1.5.4, can I script a DDL and data dump? If not, what about 2.0? If not 2.0, has anyone requested this functionality so I can vote for it? I find it frustrating that, while doing a Database Export, I can't even pre-declare (e.g. save) the set of objects I want to dump; sometimes, you want to selectively dump, and it's a pain to hunt and peck and select just those you want to dump. Easy if you want to dump everything but 2-3 objects in a large schema. Not so easy if you only need, say, 20 out of 100 objects to be dumped (e.g. for domain or configuration tables--some subset of the whole schema).
    I'm really enjoying SQL Developer 1.5.4 by the way. Despite it's flaws, I'm pretty happy with it. Looking forward to 2.0 and beyond. Good work SQL Dev team.
    Thanks very much.
    Dana

    They're all command line tools, so they can all be wrapped up in a batch or shell script. Bummer you can't access them... Hope you find a better solutionThanks K. I should be getting Oracle 10g Express Edition on my desktop soon--critical because we don't have full access to the Development instance. It's like putting changes through a straw over to the DBAs. I'm not sure why Development is locked-down to developers, but that's the way it is.
    Any chance that Oracle 10g Express Edition comes with scriptable data pump binaries? Will still need authorization, but maybe that's one way to go. I hate trying to write my own Data Pump in Python or any other language. It's seems a bit absurd to me but I suppose there are reasons.
    Dana

  • Exporting Application w/ DDL and data

    I can export an Application.
    I can export the DDL for that application.
    I Cannot_ export the data for that application unless I am not following the proper procedure.
    Note that I did use "with supporting objects" option.
    Anyone know why ?
    Thanks in advance,
    Anon
    Edited by: Anon on Aug 2, 2010 11:20 AM
    Edited by: Anon on Aug 2, 2010 11:27 AM

    Supporting Objects allow you to add ddl and dml to your application so that you can export as one file and then import and install in one step. To get your data, I would suggest using SQL Developer and extracting your data as insert statements. That can then be loaded into your supporting objects (after your ddl).
    Here is a link to a 3.2 tutorial that explains more about Supporting Objects.
    -- Sharon

  • Export tables and data

    Hi everybody,
    I'm new in SQL Developer and I would like to know if I could use it to export some tables (and the data in them) and import these on another machine (with Windows OS) that has the same versions of Oracle Database (10 G R2) and SQL Developer(last I have found on the Oracle download page).
    If this can be done, could you guide me with some steps?
    Thanks a lot!
    Cristina

    To export tables (structure), it is enough to go to the menu Tools > Export and to choose a path and name for the archive, to select the connection and the objects (in the case = TABLES) that will be exported.
    How much to the data, I do not know if a skill exists to export all the data of several (or all) of an only time, without having that to make one to one.

  • Exporting time and date metadata onscreen in FCP 7

    Hi there
    Does anyone happen to know if i can display the time and date stamp onscreen when exporting to DVD in Final Cut Pro 7? I know that you can now capture the time/date metadata through log and transfer; i need to be able to show that onscreen the same way that you might use timecode when exporting to DVD.
    Additionally does anyone know of a plugin that might give me the same control over this as we already get over timecode?
    And finally, is it possible to print out a log inc: clip name, time and date from FCP7?
    Thanks
    Chris

    ProDateDV from Automatic Duck was a unfortunately mistimed one trick pony that did this ... but only for DV format footage unfortunately, and as such it totally missed the DV bus, as it was only released just about a year ago. It seems to have been pulled from their products page already. Shame. The problem is that every different acquisition format records and stores this data differently, and usually proprietarily, so the details of how and where to find it within the auxiliary data stream is not at all straightforward, nor the means to write a plugin that would work regardless of source media type.

  • Need info on DDL and Data propagation

    Greetings Guys,
         I have a requirement for moving data and DDL from lower environment to production, this would be done on some frequency say weekly for deploying the latest code for the application, I would like to know what are the possible techniques
    and tools available in SQL Server. I am not sure if I can set up replication for all the tables in the database because in case of restoring the database from backup I suspect fixing the replication problem itself will become a big thing. Currently we use
    merge statements for moving data between the environments and redgate sql compare API for moving DDLs. Let me know if there are any other ways to do this. 
    Environment:
    SQL SERVER 2008 R2
    WINDOWS 2008 R2
    With regards,
    Gopinath.
    With regards, Gopinath.

    You can also create a SSDT database project and publish the changes using it
    see
    http://www.techrepublic.com/blog/data-center/auto-deploy-and-version-your-sql-server-database-with-ssdt/
    http://blogs.msdn.com/b/ssdt/archive/2013/08/12/optimizing-scripts-for-faster-incremental-deployment.aspx
    http://schottsql.blogspot.in/2012/11/ssdt-publishing-your-project.html
    Please Mark This As Answer if it solved your issue
    Please Vote This As Helpful if it helps to solve your issue
    Visakh
    My Wiki User Page
    My MSDN Page
    My Personal Blog
    My Facebook Page

  • SQL Developer 3.2 - Export DDL challenge

    Hi,
    I would like to Export DDL for approximately 300 of 1000 objects in a schema.  I have the names of all required tables for which I'd like to get the DDL in a table in my personal schema.  Is there a way that I can use this table as a driver for the built-in Export DDL utility or will I need to either go to the schema browser and hand-pick each of the 300 tables and/or from the Tools-Export DDL "Specify Objects" window?
    I would like to make this more automated so that I dont have to keep clicking, scrolling, clicking my way through the list of required objects.  Any thoughts are appreciated, thanks.

    1008686 wrote:
    Hi,
    I would like to Export DDL for approximately 300 of 1000 objects in a schema.  I have the names of all required tables for which I'd like to get the DDL in a table in my personal schema.  Is there a way that I can use this table as a driver for the built-in Export DDL utility or will I need to either go to the schema browser and hand-pick each of the 300 tables and/or from the Tools-Export DDL "Specify Objects" window?
    I would like to make this more automated so that I dont have to keep clicking, scrolling, clicking my way through the list of required objects.  Any thoughts are appreciated, thanks.
    There is no way to use sql developer to do that.
    You can:
    1. do it manually as you suggest
    2. do it manually by writing a script that makes the appropriate DBMS_METADATA calls
    3. use expdp to extract the metadata and create a DDL file.
    The full DDL for a table will include a lot of components that many people don't even want, for example storage clauses.
    The bigger issue you should address is why you don't already have the DDL to begin with. Best practices are to create the DDL and keep it in a version control system; not extract it after the fact.
    I suggest you use the EXPDP utility to extract the DDL into a file so that you have it for future use.
    If you plan to write a script there are plenty of examples on the web that show how to do that. Here is one:
    http://www.colestock.com/blogs/2008/02/extracting-ddl-from-oracle-2-approaches.html

  • A tool to export a video of DIAdem VIEW, playing a synchronized video, map, audio and data

    It's very common you need to do a presentation with several information and if you can put a video playing a synchronized video, map, audio and data graphs, like DIAdem VIEW do, your presentation will be cause a excellent impression. To do this today you need a capture screen toll, If DIAdem have a native tool to do this it would be great.
    

    Hello,
    Today I tested the screen capture software Camtasia Studio 8 and this works really good. The files can be saved as an AVI file and different qualities can be chosen, which gives some flexibility in the file size. The screen capture is working fast, so if I run with 1 Hz the VIEW layout with a map and several 2d graphs all the frames are captured.
    With kind regards,
    Stijn

  • Exporting apps and ddl

    Is there an easy way to export the app and any associated ddl in one step. It looks like you export the app by itself. Then you select the ddl components separately. Is that the correct method?
    Why is ddl that is generated and then exported placed into an '*.accept' file?

    I would be nice if a unique directory could be created for each export consisting of ALL exportable items, plus data. (Athough more abstract datatypes like BLOBs and TIMESTAMPs might be a problem.)
    Its teadious having to do it for each export type.
    Also, in a import (restore) situation, I could nominate a directory that contains all the items i need to fully install/restore a HTML DB application.
    Basically a magic button that does everything in one shot! I think its too fragmented.
    (I think this is one of the 3 major areas of improvement, backup/recovery/installation, plus software reusability and documentation.)

  • Is there any way to export IT Resource data from OIM using the export tool?

    Hello,
    we are trying to migrate an OIM development environment to a preproduction environment and we need to migrate more than 400 IT Resources. We have exported some IT Resources and when we imported them in the preproduction environment their data was not migrated. Is there any way to export IT Resource data from OIM using the export tool? Or is there any other way to do this without doing it by hand?
    Thank you for your help
    Kind Regards

    Well , OIM doesnot provide any such facility to export ITResource data along with ITResource .
    Directly updating the DB could be an option ..
    Thanks

  • DDL and DML tool for unicode

    Which tool is able to maninupalate UTF-8 encoded data saved in Oracle database?
    (execute DDL and DML commands with non latin text)

    Hi,
    You can easily create your own scripts for creation (and even deletion/drop) of tables and inserts made to those tables. You just need to put the statements in a notepad and save it with a .sql extension. Then run this file from a SQL prompt with @ sign. For example
    SQL >@"c:myscript.sql" .
    Hope this helps
    Regards
    Aditi

  • EXPORT DDL from TOOLS menu in Rel 4

    I am trying to use the tools->export-> objects--> tables option to extract DDL from tables
    I have given the file name to save in options. After clicking APPLY nothing is happening.
    File is created with 0 bytes

    I do have a similar issue with the export function. Below is all of the
    information - downloaded today (Fri, 17-Feb-06 and am current with
    updates).
    The Export is not creating the expected DDL script; output file was
    created with 0 bytes.
    Other than that I like what I see in SQL Developer.
    Thank you,
    Jeff
    Downloaded          Fri, 17-Feb-06; current updates downloaded also
    SQL Developer          1.0.0.11
    Version               1.0.0.11.84
    Build Main          11.84
    JAVA               1.5.0_05
    Oracle IDE          1.0.0
    Oracle SQL Developer     10.1.3.1215
         Reports     10.1.3.1215
    Raptor Help          10.1.3.02.60
    SQL Formatter          10.1.3
    DB Version          9.2.0.6.0
    Tools -> Export -> Options - file=c:\temp\absences_test.sql; checked-storage,
                   pretty print, constraints as alters
              -> Objects - Connection-DEV2; check table ABSENCES;
         then Apply -- no output
    expected DDL for a partitioned table with
    local bitmap indexes, global b-tree indexes (PK, UK, and FK)
    OS Name     Microsoft Windows XP Professional
    Version     5.1.2600 Service Pack 2 Build 2600

  • In XI pro, exporting PDF to Excel problem.  Excel columns and data are not properly aligned.  Help?

    I used 30 day trial of Acrobat XI and all the functions work perfectly.  But, when I buy the program (either download or disk) my PDF that export to Excel is not working.  The excel columns and data are not properly aligned as they should be.  The Trial version aligns everything perfectly.  What is happening?  I use a MAC 10.9.5.  But this shouldn't matter because the trial version works perfectly.  Can anyone help?

    just found out that this is posted in the wrong section.

  • Export and import of data not table and data ????

    hii brothers and sister
    plz i have a a quetion about Export and import of data in oracle forms
    i have created 02 boutons one for export his trigger like this :
    eclare
    alrt number;
    v_directory varchar2(200) := 'c:\backup'; --- that if the C Drive not the Drive that the windows had installed in it.
    path varchar2(100):='back_up'
    ||to_char(sysdate,'dd_mm_yyyy-hh24_mi_ss');
    v_exp varchar2(200) := 'exp hamada/hamada2013@orcl file = '
    ||v_directory
    ||'\'
    ||path
    ||'.dmp';
    begin
    host(v_exp);
    alrt:=show_alert('MSG');
    end;
    and the bouton import is like this
    declare
    alrt number ;
    v_ixp varchar2(200) := 'imp userid=hamada/hamada2013@orcl file =c:\backup2\back.dmp full=yes';
    begin
    host(v_ixp);
    alrt:=show_alert('MSG');
    ref_list;
    end;
    i have just one table "phone"
    this code is correct he expot not only the data but also the creation of the table ....for exemple i do export and evry thing is good until now and i find the .dmp in the folder backup .. but when i deleted all data from my app and try to import this .dmp iit show me error it tell me thet the table phone is already created ....
    so plz help wanna just export the data of phone not the creation of table and data ???? or how can i import just the data from this .dmp ??

    Pl post OS and database versions.
    You will likely need to use the IGNORE flag - http://docs.oracle.com/cd/E11882_01/server.112/e22490/original_import.htm#sthref2201
    Imp utility (by default) will try and create the table first. Since the table already exists, imp reports an error. Use the IGNORE flag in your imp command to not report such errors.
    HTH
    Srini

Maybe you are looking for

  • Problem during creation of dynamic Internal

    Hi All, I am trying to create a dynamic internal table. I went through many posts, but the problem i am facing is, I want an internal table as: Empno Ename Lgart1- Depending on the Wage types user enter on the selection screen. Lgart2 When i tried to

  • Change Document Printed Status

    Hi All Is ther a way to change the status of a sales order to back to" Open" after it has been printed and the status of "Open - Printed" The reason is that sometimes the wrong customer is entered and only realised after the order is printed and then

  • RIM mass storage device

    Hi all, I got a problem. When I tried to connect with Media Manager to upload music. My media card is not detected. Moreover, when I connect my BB on my laptop, he asked me to install RIM Mass storage device (which appear in device management with ye

  • UCS firmware version question

    Hello guys! I've seen from Cisco download for UCS B series firmware versions, there are 2 latest versions which 2.2.(1d) and 2.1.(3c), what are the different between these 2 versions? My current firmware is 2.1.(1b), should I update to 2.1(3c) or 2.2

  • How to install downloaded OVI program on E71

    After download of a program I get an SMS with a link to activate the program. But how do I do that? I don't seem to be able to activate the link. Any good suggestions?