design of SQL data

I need to store a lot of information about each user, like (reading, kayaking, hiking, games, etc.), as well as a variety of other things of the personality.  What would be the best way to do this?  I thought to put everyone in a field, and then parse out.  Or would it be better to have a record for each as for the user, and then just take all records of love for the user?

Create a table for the users. Include a primary id auto-incrémentées

Create a table for taste, also include a primary id auto-incrémentées (so he could have two columns: as and like_id)

Create a third table to match users with love. This table would hold just the primary ID of the other two tables

Create a table with the "things of the personality" and, as with love him, give him a primary id auto-incrémentées.

Create a table that matches the personality traits to users, as for the users_likes table

The above structure will give you the flexibility to add, subtract, and change the options of the personality and tastes.

I thought to put everyone in a field, and then parse out.

For something like love, I would do that. Let's say you need to know what day of the week an event occurs, for example on Tuesday and Thursday, or on Monday, Wednesday and Friday. Then you could use a single column and assign a number to each day of the week so Tuesday and Thursday, would worth 35 and M W F would be 246. . .but with you like will be able to edit your list of likes: it can become very large, you can change the terminology, etc. in order to put them in a separate table would be better.

Tags: Dreamweaver

Similar Questions

  • The maximum size of the model in SQL Data Modeler?

    Hello

    The number of objects is the maximum value that can be used in a model in SQL data maker. I reverse engineered a scheme (see previous posts - thank you to all that helped) which contains 1000 + tables (a candidate for remanufacturing if ever I saw a!) but the Data Modeler is struggling to display them and performs very slowly. I can pull the same schema in the Oracle Designer and that works well, as ERwin-t - y at - it something I can do to improve the performance of the Data Modeler?

    Or people would recommend cutting the model into smaller pieces, which will be a little difficult because it's a bit of a rat's nest.

    John

    Hi John,.

    You can try to fix the memory usage - Re: problem of memory with large model

    And you may have better performance if divide you large diagram in subviews.

    Philippe

  • Use of domains in SQL data Developer MODEL

    Hello

    I'm trying to understand how to use areas of Oracle SQL Developer Data Modeler. We use version 3.1.3.  before I used Toad Modeler where the areas are just a part of your main design.

    Modeler data Oracle has a different concept.

    Suppose that I am working on 2 models: DesignA and DesignB which include relational models.

    DesignA and design B must use areas, but the list of areas in A design is very different from design B.

    Default domain file is located on drive c:, where SqlModeler is installed. It is of course unacceptable, so I need to change the default system Type directory in preferences.

    And of course, I want to have directories different area's of DESIGN and DESIGN B.

    So when I opened design has then I changed the default directory Type system we'll tell x:\AAA.   Then I close A design open design B and change the default directory of x:\BBB system Type

    I checked records AAA and BBB and they have required XML files here: defaultdomains.xml, defaultRFDBSSites and so on...

    Now the questions:

    can I rename defaultdomains.xls to something like AAAdomains.xls?  Domain administration can change any file with any name field, but how do I associate some file field with my design?  My wish, when I opened my design, and then the domain file will be automatically opened.  Is this possible?

    If I open 2 designs in Sql Modeler and switch between corresponding designs and domain files then need to be changed automatically as well.  Currently, I shouldn't forget to change the default system Type directory each time when I switch templates.  It is the only way to deal with?

    Thank you

    Vitaliy

    Vitaliy salvation,

    to see which domain files are used, the simplest is to go into the administration of the domain,

    Add new domain and then check the drop-down list for the property 'areas file' box - used files appears.

    Keep in mind that in defaultdomains.xml areas are still part of the domain that is used in the design. If this file must be empty (containing only 'unknown' domain) If you want to work

    with areas of level design.

    Philippe

  • Problem with the two EA DEVELOPER SQL DATA MODELING 3.0.0.665 and 3.1

    I created a model of very large data using SQL Developer data 3.0.0.665 and 3.1 EA maker. Its having a lot of check constraints. Whenever I am the design of the fence and the DOF and reopening export to import the DDL file failure to import completely check constraints. It is important to check constraints, but without any range of values inside. Its very frustrating because whenever you open import ddl, you must manually add again all the details of data check range constraint.

    OS: Windows XP.
    Check in the two EA Developer SQL Data Modeler 3.0.0.665 and 3.1

    -------------------------------------------
    Here are the contents of the .dmd file.
    -------------------------------------------
    * <? XML version = "1.0" encoding = "UTF - 8"? > *.
    * < OSDM_Design class = "oracle.dbtools.crest.model.design.Design" name = 'Admin_Panel' id = "9BE18B0A-6C67-2E5B-00DE-BD8312189ECB" version = "3.41" > * "
    * < createdBy > administrator < / createdBy > *.
    * < Createduserid > 2011-10-17 08:32:18 UTC < / Createduserid > *.
    * < Admin_Panel ownerDesignName > < / ownerDesignName > *.
    * < false capitalNames > < / capitalNames > *.
    * < designId > 9BE18B0A-6C67-2E5B-00DE-BD8312189ECB < / designId > *.
    * < / OSDM_Design > *.

    -------------------------------------------------------------------------------
    An example how the check constraints to get dirty.
    -------------------------------------------------------------------------------
    Initial check constraint is as below:
    ======================
    ALTER TABLE test_table
    ADD CONSTRAINT Active_Flag_ck
    CHECK (Active_Flag IN ('A', 'I'))
    *;*

    Below how it occurs once I have imported the ddl and re-export:
    ============================================
    ALTER TABLE test_table
    ADD CONSTRAINT Active_Flag_ck
    (CHECK)
    *;*

    I'm in trouble as I already in the middle of the my development using SQL Developer Data Modeler.

    Please help me soon.

    Jean

    Hi John,.

    Every time I'm fence design and export the ddl and reopening through the import of the DDL file

    Why are you doing this? Once the DDL file is imported and then save the drawing and open simply saved design, no need to generate the DDL and import it every time that you start Modeler data.
    On the list of values - forced as this CHECK (Active_Flag IN ('A', 'I')) are imported as constraint check plain and not as a list of values.
    There are the more specific elements import of check constraint - they are defined as type database constraint that you select during the import. Accordingly if you import your DOF as Oracle 10 g DDL, then you will get forced correct check in DDL generated for Oracle 10 g and Oracle 11 g. Constraint of evil will be generated for Oracle 9i. You can move the constraint for Oracle 9i (in the check constraint dialog box) or generic if it can be treated as such constraint.

    I logged for DOF bad bug.

    Philippe

  • Does not not for java.sql.Date sort field

    Hi Experts ADF,

    JDev version 11.1.1.7.0

    I use a POJO based datacontrol, who is dragged like a table on page JSFF. One of the field is a java.sql.Date data type in POJO.

    So for example in the table 4 values are there to this date field as

    2.2.2014

    3.2.2014

    31.1.2014

    to 31.12.2013

    So while sorting in ascending order, it should come as below

    to 31.12.2013

    31.1.2014

    2.2.2014

    3.2.2014

    And vice-versa.

    But if I click on sort it sorts by the first 2 digits only, and I'm under results for sorting (ascending)

    2.2.2014

    3.2.2014

    31.1.2014

    to 31.12.2013

    Please suggest on this. Thanks in advance.

    Thank you

    Animesh

    Hi This sorting has been solved by changing of java.util.Date.

    Yes his watch to the client as an outputText inside the table. Sorting option is there for af:column.

    Thank you

    Roy

  • In general, is it better to use java.sql.Date and java.sql.Timestamp instead of oracle.jbo.domain.Date?

    Hello world

    During playback of Oracle ADF Real World Developer's Guide, I noticed the dates match occurring in JDeveloper is different from what is the list in the book. JDeveloper is failing to oracle.jbo.domain.Date, but according to the book:

    DATEjava.sql.DateDATE type is mapped to java.sql.Date if the column in the table is a no time didn't need information zone.
    DATEjava.sql.TimestampDATE type is mapped to java.sql.Timestamp if the column in the table has a component "time" and that the client needs to zone information.
    TIMESTAMPjava.sql.TimestampThe TIMESTAMP type is mapped to java.sql.Timestamp if nanosecond precision is used in the database.

    In general, is it better to use java.sql.Date and java.sql.Timestamp instead of oracle.jbo.domain.Date? Using java.sql.Date and java.sql.Timestamp could save me some headaches conversion date. And, is there a place in JDeveloper to display these maps? I looked around and didn't see anything.

    Thank you.

    James

    User, what version of jdev we are talking about?

    In GR 11, 1 material versions db types date and timestamp are mapped to types of domain data that represents a wrapper for the native data types. The reason was that the framework can work with the domain types regardless of the underlying data type.

    Since Oracle 11 GR 2 maps the types DB to java types (default selection, you can change it when you create a model project, you can set the Data Type Mapping). Once the pilot has business components define you cannot change this setting it would break existing components such as eo or vo.

    So if you are working wit 11 GR 1 subject, you must use the domain types, if you work with GR 11, 2 or 12 c, you can use the domain types, but it is recommended to use the java type mapping.

    Timo

  • java.lang.ClassCastException:String cannot be cast to java.sql.Date

    I have a date component. MinValue named Id2 and the following code is to run a class cast exception indicating that the string value cannot be cast to a date sql

    java.sql.Date dateNeeded = (java.sql.Date) this.getId2 () .getValue ();

    can someone help me to overcome this problem.

    Thanks and greetings
    Janak

    Published by: new_to_ORACLE on February 18, 2011 16:56

    Published by: new_to_ORACLE on February 18, 2011 16:58

    the Date attribute is of type object oracle.jbo.domain.Date
    so, first try to cast to oracle.jbo.domain.Date. then to java.sql.Date object

    If you need to cast to another Date object, see this site:
    http://www.ecotronics.ch/webdesign/javadate.htm

    Published by: M.Jabr on February 19, 2011 11:53

  • VIX file in the user interface designer receives the data from the Web service application that communicates with the SQL server database

    I created the Web service VI ("Mt-insolacije.vi"), which has two terminals of the input string (FROM / TO) for the dates of arrival and exit of two data terminals (table 1 d) from database (MS SQL server). This VI communicates with the database with functions of the database with a DSN and SQL query appropriate palette. There are two tables with two data (time and Insolation) columns in the database.

    This VI works when you run in Labview 2010, but when I used it as VI in UI Builder it returns no data.

    Could you please help me find a solution. Is it possible to communicate with the SQL server database in this way or there is another way?

    There are two files attachmet: Image of .vix file in Interface builder and .vi file ("Mt-insolacije.vi")

    Please help me ASAP!

    Thank you

    Ivan

    I found the solution problem is in the DSN. I've been using the user instead of DSN system DSN.

    It's important to create the system DSN if you want your VI of web service to communicate with the database.

    PS Please put feature bundle format timestamp and XY graph in the web user interface designer. It's complicated to trace data with datetime on X axis without them.

  • What is "Domain" of the same designer in SQL Developer?

    Developer SQL noob here... I see 'Types' in the list of nodes under my db in the "Connections" pane What is the equivalent?

    Areas do not really live in the database. But allows you to define the data types for your columns/attributes of your data fields models. If you who push to a database, it goes to the database, but not as a field.

    Models in the connection tree are User Defined Types. Someone in the database created a custom, type of data that they can use in their paintings.

    Long story short, 'no.'

    But

    You can import your designer models in Oracle SQL Developer Data Modeler and your domains should come.

  • SQL Data Modeler

    Hi all

    I use sql schema from the schema generation datamodeller for my er. I generated on the guest design, but since I have 200 tables in design, it is not possible to print it, also when I create a PDF of it shows the file 200 KB but when I open it it is empty Adobe reader9.

    I want just the output I see in the designer in PDF or word format. Is it possible that I have to forward it to the development team.

    Thank you.

    Hello

    There is a forum for the tool space: SQL Developer Data Modeler

    Please mark this question as answered (so others know they can ignore it) and post again in the forum Data Modeler.

    Concerning

    Marcus

  • Database and SQL (data logger)

    Hi all

    I made the database (see photo) to save my data.

    Now I want to connect to this database in SQL, but found no example of it on the forum; I read some tutorials but I am little confused with UDL...  Second question is where these data are stored on my PC (mdb file)

    Thank you.


  • [SOLVED] Export Oracle SQL Data Modeler is missing a PRIMARY KEY on the DDL script

    I use data 4.1.888 maker to create an ER diagram and generate a DDL her script.

    The diagram contains more than 40 paintings, most of them have a primary key defined.

    For some reason any there is a table that has a primary key defined, but which is ignored when I export the model to a DDL script.

    It is the "wrong" key (even if it is checked that it is not found on the generated DDL script):

    4faS5.png

    This is where the key is set:

    O5mPb.png

    And it is the preview of the DDL (Yes, primary key up there shows):

    SrwMu.png

    This is what happens if I try to generate the DDL for just this (still not generated primary key) table:

    MljUm.png

    Has anyone had the same problem? Any ideas on how to solve it?

    There is no error in the log file, but when I run the generated DDL script there, and then I realized that I was doing something wrong:

    The table MEMBERS had a mandatory foreign key from another table, which in turn had a mandatory key against MEMBERS himself.

    So even if I could generate this primary key on members myself, and then run the the constraint definition that returned an error on the DDL script, I could not perform an insert operation on any of these two tables because of the constraint.

    I revised my design and realized relationships was not mandatory. I unchecked the mandatory box on the definition of the constraint and everything went well.

    I could reproduce the problem and the solution on a diagram with only two tables, so I'm sure that's it.

    Anyway, the Data Modeler is "a failed" silently in this kind of situation. It should be fairly obvious to an experienced designer that I was doing something wrong, but it is not so obvious when you deal with dozens of tables and all their relations and this is your first time using the Modeler.

    Thanks for your reply :-)

  • Mapping XML-to-SQL data

    Hello

    IM only a beginner in oracle and I have recently started working with XML DB, I read on the XMLType storage models and I think that the structured storage is the best option for the project, our xml data is very structured and has a predictable structure.

    I recorded a schema in oracle (im using XE for test purposes) and run this statement:

    Start

    DBMS_XMLSCHEMA. REGISTERSCHEMA (SCHEMAURL = > 'PRODUCTOS.xsd', SCHEMADOC = > ' <? xml version = "1.0" encoding = "UTF - 8"? >)

    " < xs: Schema elementFormDefault ="qualified"xmlns: XS =" http://www.w3.org/2001/XMLSchema ">

    < xs: element name = "LISTA_PRODUCTOS" >

    < xs: complexType >

    < xs: SEQUENCE >

    < xs: element name = "PRODUCTO" maxOccurs = "unbounded" minOccurs = "1" >

    < xs: complexType >

    < xs: SEQUENCE >

    < xs: ELEMENT type = "xs: String" name = "i" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "IT" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "quantity" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "Center" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "customer" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "concepto" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "descripcionProducto" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "espacioM2" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "important" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "marca" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "medida" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "modelo" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "package" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "pesoUnitario" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "price" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "reference" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "remolque" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = 'series' > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "UM" > < / xs: element >

    < xs: ELEMENT type = "xs: String" name = "valorUnitario" > < / xs: element >

    < / xs: SEQUENCE >

    < / xs: complexType >

    < / xs: element >

    < / xs: SEQUENCE >

    < / xs: complexType >

    < / xs: element >

    < / xs: Schema > ', LOCAL = > true, GENTYPES = > true, GENBEAN = > false, GENTABLES = > true,

    FORCE = > false, OWNER = > 'TEST');

    commit;

    end;

    /

    and automatically created objects:

    LISTA_PRODUCTOS451_TAB (LISTA_PRODUCTOS448_T RELATIONAL OBJECT XMLtype STORAGE TYPE)
    DESC LISTA_PRODUCTOS448_T-> PRODUCTO (type PRODUCTO450_COLL)

    DESC PRODUCTO450_COLL-> i ' VARCHAR2 (4000 TANK), THE VARCHAR2 (4000 CHAR), quantity VARCHAR2(4000 CHAR)... valorUnitario VARCHAR2 (4000 TANK).

    If I run a select statement on LISTA_PRODUCTOS448_T (by selecting t.getClobVal () in LISTA_PRODUCTOS448_T t) I can see all the data xml, but im confused, I don't know if it is possible to run a traditional sql query and get the data as a simple recordset or if it is necessary to use the functions of XMLtype and procedures using the XPath syntax or something else. I mean why he created all of this?

    And besides I don't know how to set the size of the memory of the LISTA_PRODUCTOS451_TAB table, if I try to insert 20 xml nodes in a row, it saves all 20 nodes in a single line and if I try to save 1000 select returns an ORA-06502: digital or value error: character string buffer too small.

    Thanks in advance and sorry for my English.

    Create a temporary table (or a regular table, but you will have to do the cleaning yourself at the end of the procedure):

    create a table temporary global xmltype tmp_xml

    binary XmlType securefile XML store;

    In the SP, insert the incoming XML document.

    Purpose of test, I'll use this simplified version:

    
      
        1
        ABC
        10
        X
        1000234
      
      
        2
        ABC
        10
        Y
        1000234
      
      
        3
        DEF
        20
        Z
        1000234
      
    
    

    Then you can use XQuery to access data:

    SQL > select x.*

    tmp_xml 2 t

    3, xmltable)

    4 ' / LISTA_PRODUCTOS/PRODUCT.

    5 passage t.object_value

    path number 6 columns article 'i '.

    7 road of VARCHAR2 (3) of THIS 'it '.

    8 road number amount 'amount '.

    9 road to varchar2 (1) centro "centro".

    10 road of varchar2 (30) client 'client '.

    (11) x

    12;

    ARTICLE THIS AMOUNT CENTRO CLIENT

    ---------- --- ---------- ------ ------------------------------

    1 ABC 10 X 1000234

    2 ABC 10 Y 1000234

    3 DEF 20 Z 1000234

  • How to get an array of SQL data

    Hello

    I need to get a say DBMS output output of a SQL SELECT query say * OF EMP in the form of a table (with borders and titles).

    Is this possible in Oracle to return a table with borders and titles?

    user13410062 wrote:

    Hi all

    I don't know what am I missing in my question, which is confusing. The only thing I'm looking for is invoking a procedure/function of TOAD/SQLPLUS that can turn a TABLE formatting based on a query (SELECT * from insert_table where insert_table is-)
    CREATE TABLE insert_table
    (
    Number of S_No
    Varchar2 (128) of the player.
    Number of Ranking_Points
    Country varchar2 (128)
    );
    Now the output is visible in the result of the query or DBMS_OUTPUT as

    >> > >

    S_NO PLAYERNAME RANKING_POINTS COUNTRY
    1 Rafael Nadal 12390 Spain
    2 Roger Federer 7965 Switzerland
    3 Novak Djokovic 7880 Serbia

    To add to what anton said...

    When you submit a SQL query to the database, the statement is executed and the data is returned to the calling program.  The database has no awareness of what this program is, or how this program can restore the data on the screen, and the database itself is not any output device to display data.

    Thus, the data can be returned to various programs for example

    SQL * Plus - a terminal/command line screen, which usually uses a font to fixed width and standard characterset

    TOAD - a windows based application that has a "data grid" to display the data, you get

    SQL * Developer - windows-based application

    Oracle APEX - one based on web front end that makes HTML given to it, or can take the data and rendered in the HTML form for you.

    PowerBuilder - an application environment that could choose to display the data in DataWindow, store the data in data warehouses, be an intermediary providing data as a web service or be rendered web pages with data, etc..

    .NET - like PowerBuilder, it might choose to make the data are however required.

    Java - like Powerbuilder and .NET, it might choose to make the data are however required.

    etc.

    Thus, each of these environment renders data on the screen but he wants and will do it in a style that suits.  Some methods that work in an environment do not work in another environment, for example, you could provide data with the tab character included in the data and SQL * Plus can restore data with tags in it, but something like TOAD, perhaps will not and displays a character box indicating an "unprintable" character etc..

    That's why you can't just ask a question say you want to provide a query and get a table with headings etc. displayed, because the table with headings etc. depends entirely on the final user interface until you choose to use.

  • Two different sources of data in a SQL data in the file one rule

    Hello

    Just curious if we can refer to two different data sources in a unique piece of data SQL in a rules file to load the data into the SQL Interface.

    Thank you
    Ted.

    TIm

    While you were incorrect, you weren't wrong. You ca. Use has either an odbc connection that is hard-coded or a substitution variable to define the name of connection oCBC (with the exception of the connections of the OIC). You can not connect to two different odbc both connections. Your idea of a related db or a synonym is a good if their environment allows

Maybe you are looking for