Extraction of data from two tables without discounting

Hi friends,

I have a problem I want to extract data from two tables without discount in the text field when I will enter any value in a text field, then the value of corressponding must come to textfield corressponding.

for example. There are two table A and B.
Table A has Colunm

S_ID number;
C_ID Varchar2 (30);
VARCHAR2 (4) s;

Second table B Colunm name

S_ID number;
What varchar (30);
L_Name varchar (20);

When I enter in a text field then the c_id 101 s_id, dry, first_name and last_name should come to corressponding text without refresh fields.

How can I do that.

Thank you
Maury

You can use Ajax and there are tons of good examples out there for this purpose;
For example [http://apex.oracle.com/pls/otn/f?p=31517:236:1876567353842241]

Tags: Database

Similar Questions

  • Help in mandatory query - pulling data from two tables and inserting a

    Hi all

    I need your help for the modification of the query to get the desired result.
    I have two tables A and b. using source Insert and select the command, I need to extract data from tables A and B, then insert and C.
    Data and table structures are available below.

    Table (Source Table)

    Status of payment $
    MUL DC 20
    ONLY DC 20
    ONLY 40 PA
    MUL NY 50

    Table B (Source Table)

    State of lang units
    E DC 10
    S DC 10
    NY E 5
    PA S 5

    Based on query, I need the values in table C as mentioned below.
    Table C (Table of Destination) (necessary output query must also be as below)

    The State value

    PA 8
    DC 1

    My query is

    INSERT INTO C(STATE,VALUE)
    SELECT A.STATE, SUM ($) /SUM (UNITS)
    OF A, B
    WHERE PAYMENT = "SINGLE".
    AND A.STATE = B.STATE
    GROUP OF A.STATE, B.STATE

    But the output I get is

    PA 8
    DC 2

    Essentially to DC, I should get 1, i.e., for payment only $ DC is 20 and divided by 20 DC must be 1.
    Let me know where I'm missing.

    Hello

    It will work you need to add units in the group by clause

    SELECT a.state, SUM (dollars) / units
    FROM a, (SELECT state, SUM (units) units
             FROM b
             GROUP BY state) sub
    WHERE payment = 'SINGLE' AND a.state = sub.state
    GROUP BY a.state, units;
    

    Concerning

  • Extracting the data from relational tables in 11.1.2.1

    I want to extract the following data sets from relational tables
    1 attribute and his partner basic member
    2 Smartlist value of an account

    Have a code to extract such data? It will be useful in pointing to the correct table names.

    Thank you

    You will find the table schemas in the [documentation for EPMA | http://www.oracle.com/technetwork/middleware/bi-foundation/epm-data-models-11121-354684.zip]. If this does not work, there are other options to export hierarchies in text files. You can use the lifecycle management or the [EPMA line Generator | http://docs.oracle.com/cd/E17236_01/epm.1112/epma_file_gen_user/launch.html].

    Kyle Goodfriend
    http://www.in2hyperion.com

    Please make sure that you assign your post as answered when an appropriate response is provided (or useful when it takes place) as well as other benefits.

  • Display data from two tables based on date criteria

    Hi all

    I have two tables, using these two tables and a few conditions I want to recover under result. Oracle version is (Oracle9i Enterprise Edition Release 9.2.0.8.0 - 64 bit Production)
    LOGON_ID        USER_ID       LOGON_TIME                 LOGON_TYPE    SUBSCRIBER_NO               CUSTOMER_ID
    
    26063548     4528890298   4/5/2010 12:03:58 AM            MSISDN       GSM04528890298              581751708
    logon_histories_r table records the information of each user who connects to the system. Subscriber Details table contains all the information corresponding to subscriber_no, only 1 row should be returned.
    I'm confused usage date condition for the table of the Subscriber, the input parameter date 04/04/2006 to 15/04/06

    Select lh.logon_id, lh.user_id, lh.logon_time, lh.logon_type, subs.subscriber_no, subs.customer_id
    of logon_histories_r lh, subscribed subs
    where lh.logon_time > = to_date('05-04-2010','dd-mm-yyyy')--to_date('04-04-2006','dd-mm-yyyy')
    and lh.logon_time < to_date('06-04-2010','dd-mm-yyyy')--to_date('15-01-2007','dd-mm-yyyy')
    and lh.user_id = substr (subs.subscriber_no,-10);

    If the date range is 04/05/2010 to 04/06/2010 then the data related to the BAN 581751708 must be the result,
    If the date range is 04/04/2006 to 15/01/2007 data related to the BAN 502499502 must be the result.

    Please find DDL and data relevant to these results. There are millions of records of Subscriber & logon_histories_r table, I am given appropriate providing a subscriber_id.

    CREATE TABLE LOGON_HISTORIES_R
    (
      LOGON_ID       NUMBER(12)                     NOT NULL,
      USER_ID        VARCHAR2(15 BYTE)              NOT NULL,
      LOGON_TIME     DATE                           NOT NULL,
      LOGOUT_TIME    DATE,
      LOGOUT_METHOD  VARCHAR2(15 BYTE),
      LOGON_TYPE     VARCHAR2(15 BYTE)              DEFAULT 'MSISDN'
    );
    
    CREATE TABLE SUBSCRIBER
    (
      SUBSCRIBER_NO           VARCHAR2(20 BYTE)     NOT NULL,
      CUSTOMER_ID             NUMBER(9)             NOT NULL,
      SYS_CREATION_DATE       DATE                  NOT NULL,
      SYS_UPDATE_DATE         DATE,
      OPERATOR_ID             NUMBER(9),
      APPLICATION_ID          CHAR(6 BYTE),
      DL_SERVICE_CODE         CHAR(5 BYTE)          NOT NULL,
      DL_UPDATE_STAMP         NUMBER(4),
      EFFECTIVE_DATE          DATE                  NOT NULL,
      INIT_ACTIVATION_DATE    DATE                  NOT NULL,
      SUB_STATUS              CHAR(1 BYTE)          NOT NULL,
      SUB_STATUS_DATE         DATE                  NOT NULL,
      ORIGINAL_INIT_DATE      DATE                  NOT NULL,
      SUB_STATUS_LAST_ACT     CHAR(3 BYTE),
      SUB_STATUS_RSN_CODE     CHAR(4 BYTE),
      PRODUCT_TYPE            CHAR(3 BYTE),
      CUSTOMER_BAN            NUMBER(9),
      CTN_SEQ_NO              NUMBER(9),
      REQ_ST_GRACE_PERIOD     DATE,
      REQ_END_GRACE_PERIOD    DATE,
      COMMIT_START_DATE       DATE,
      COMMIT_END_DATE         DATE,
      COMMIT_REASON_CODE      CHAR(3 BYTE),
      COMMIT_ORIG_NO_MONTH    NUMBER(3),
      SUSP_RC_RATE_TYPE       CHAR(1 BYTE),
      CONTRACT_NO             VARCHAR2(10 BYTE),
      CNT_SEQ_NO              NUMBER(9),
      DEALER_CODE             CHAR(5 BYTE),
      ORG_DEALER_CODE         CHAR(5 BYTE),
      SALES_AGENT             CHAR(5 BYTE),
      ORG_SALES_AGENT         CHAR(5 BYTE),
      REQ_DEPOSIT_AMT         NUMBER(13,2),
      LEADING_NUMBER          VARCHAR2(20 BYTE),
      PABX_IND                CHAR(1 BYTE),
      NEXT_CTN                VARCHAR2(20 BYTE),
      NEXT_CTN_CHG_DATE       DATE,
      PRV_CTN                 VARCHAR2(20 BYTE),
      PRV_CTN_CHG_DATE        DATE,
      NEXT_BAN                NUMBER(9),
      NEXT_BAN_MOVE_DATE      DATE,
      PRV_BAN                 NUMBER(9),
      PRV_BAN_MOVE_DATE       DATE,
      SUB_STS_ISSUE_DATE      DATE,
      ACTIVATE_WAIVE_RSN      CHAR(6 BYTE),
      EARLIEST_ACTV_DATE      DATE,
      SUB_ACTV_LOCATION       CHAR(4 BYTE),
      CUST_WATCH_LMT          NUMBER(11,2),
      CUST_WATCH_DATE         DATE,
      BASIC_WATCH_LMT         NUMBER(11,2),
      CREDIT_WATCH_PIN_CD     NUMBER(4),
      SUB_MARKET_CODE         CHAR(3 BYTE)          NOT NULL,
      LIMIT_RESERVED_DAYS     NUMBER(4),
      FF_EXPIRATION_DATE      DATE,
      FLEX_IND                CHAR(1 BYTE),
      DUO_IND                 CHAR(1 BYTE),
      LISTED_IND              CHAR(1 BYTE),
      SUB_DEPARTMENT_CD       CHAR(4 BYTE),
      LAST_SUBS_DISC_DT       DATE,
      LAST_SUBS_DISC_DT_UD    DATE,
      LAST_SUBSCR_DISC_SN     NUMBER(3),
      LAST_SUBSCR_DISC_SN_UD  NUMBER(3),
      PNI                     VARCHAR2(10 BYTE),
      RMS_REF_STORE_ID        CHAR(4 BYTE),
      RMS_REF_TYPE            CHAR(1 BYTE),
      RMS_REF_OD              NUMBER(9),
      DLR_ACT_FEE             NUMBER(11,2),
      PREP_AMOUNT             NUMBER(11,2),
      SUBSCRIBER_ID           NUMBER(9)             NOT NULL,
      SUB_LANG                CHAR(2 BYTE),
      SMS_RCV_STYLE_CODE      CHAR(2 BYTE),
      CONV_RUN_NO             NUMBER(3),
      ALLOW_ADVERTISING_IND   CHAR(1 BYTE),
      IVR_WRONG_ACCESS_NO     NUMBER(2),
      THRESHOLD_AMT           NUMBER(11,2),
      PUBLISH_LEVEL           CHAR(30 BYTE),
      AUTO_RELEASE_IND        CHAR(1 BYTE),
      CUST_WATCH_EFF_DATE     DATE,
      CUST_WATCH_EXP_DATE     DATE,
      OPERATOR_CW_LMT         NUMBER(11,2),
      SEND_SMS_FOR_MATCH      CHAR(1 BYTE),
      CPS_STATUS              CHAR(1 BYTE),
      CPS_TRANSACTION         NUMBER(3),
      CPS_TYPE                NUMBER(3),
      ISP_PASS                VARCHAR2(30 BYTE),
      ISP_TYPE                CHAR(2 BYTE),
      OPERATOR_TMP_DATE       DATE,
      OPERATOR_TMP_LMT        NUMBER(11,2),
      SUB_ORG_CD              CHAR(10 BYTE),
      ORG_MEMBER_NO           VARCHAR2(20 BYTE)
    );
    
    Insert into LOGON_HISTORIES_R
       (LOGON_ID, USER_ID, LOGON_TIME, LOGOUT_TIME, LOGOUT_METHOD, LOGON_TYPE)
     Values
       (26063548, '4528890298', TO_DATE('04/05/2010 00:03:58', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('04/05/2010 00:06:58', 'MM/DD/YYYY HH24:MI:SS'),  NULL, 
        'MSISDN');
    
    Insert into logon_histories_r
       (LOGON_ID, USER_ID, LOGON_TIME, LOGOUT_TIME, LOGOUT_METHOD, LOGON_TYPE)
     Values
       (2649592, '4528890298', TO_DATE('04/10/2006 19:19:20', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('04/10/2006 19:19:48', 'MM/DD/YYYY HH24:MI:SS'), 'TIMEOUT', 
        'MSISDN');
    
    
    
    Insert into SUBSCRIBER
       (SUBSCRIBER_NO, CUSTOMER_ID, SYS_CREATION_DATE, SYS_UPDATE_DATE, OPERATOR_ID, APPLICATION_ID, DL_SERVICE_CODE, DL_UPDATE_STAMP, EFFECTIVE_DATE, INIT_ACTIVATION_DATE, SUB_STATUS, SUB_STATUS_DATE, ORIGINAL_INIT_DATE, SUB_STATUS_LAST_ACT, SUB_STATUS_RSN_CODE, PRODUCT_TYPE, CUSTOMER_BAN, CTN_SEQ_NO, REQ_ST_GRACE_PERIOD, REQ_END_GRACE_PERIOD, COMMIT_START_DATE, COMMIT_END_DATE, COMMIT_REASON_CODE, COMMIT_ORIG_NO_MONTH, SUSP_RC_RATE_TYPE, CONTRACT_NO, CNT_SEQ_NO, DEALER_CODE, ORG_DEALER_CODE, SALES_AGENT, ORG_SALES_AGENT, REQ_DEPOSIT_AMT, LEADING_NUMBER, PABX_IND, NEXT_CTN, NEXT_CTN_CHG_DATE, PRV_CTN, PRV_CTN_CHG_DATE, NEXT_BAN, NEXT_BAN_MOVE_DATE, PRV_BAN, PRV_BAN_MOVE_DATE, SUB_STS_ISSUE_DATE, ACTIVATE_WAIVE_RSN, EARLIEST_ACTV_DATE, SUB_ACTV_LOCATION, CUST_WATCH_LMT, CUST_WATCH_DATE, BASIC_WATCH_LMT, CREDIT_WATCH_PIN_CD, SUB_MARKET_CODE, LIMIT_RESERVED_DAYS, FF_EXPIRATION_DATE, FLEX_IND, DUO_IND, LISTED_IND, SUB_DEPARTMENT_CD, LAST_SUBS_DISC_DT, LAST_SUBS_DISC_DT_UD, LAST_SUBSCR_DISC_SN, LAST_SUBSCR_DISC_SN_UD, PNI, RMS_REF_STORE_ID, RMS_REF_TYPE, RMS_REF_OD, DLR_ACT_FEE, PREP_AMOUNT, SUBSCRIBER_ID, SUB_LANG, SMS_RCV_STYLE_CODE, CONV_RUN_NO, ALLOW_ADVERTISING_IND, IVR_WRONG_ACCESS_NO, THRESHOLD_AMT, PUBLISH_LEVEL, AUTO_RELEASE_IND, CUST_WATCH_EFF_DATE, CUST_WATCH_EXP_DATE, OPERATOR_CW_LMT, SEND_SMS_FOR_MATCH, CPS_STATUS, CPS_TRANSACTION, CPS_TYPE, ISP_PASS, ISP_TYPE, OPERATOR_TMP_DATE, OPERATOR_TMP_LMT, SUB_ORG_CD, ORG_MEMBER_NO)
     Values
       ('GSM04528890298', 110069191, TO_DATE('12/04/2001 17:06:17', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('01/01/2004 22:42:49', 'MM/DD/YYYY HH24:MI:SS'), NULL, 
        'FUTRX ', 'CS016', NULL, TO_DATE('01/02/2004 00:08:32', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('07/31/2000 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'C', TO_DATE('01/02/2004 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('07/31/2000 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'CAN', 'CNP3', 
        'GSM', 110069191, 7013986, NULL, NULL, 
        TO_DATE('07/31/2000 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('01/31/2001 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'PPD', 6, NULL, 
        NULL, 1008631, 'DCNV ', 'DCNV ', 'DFLT ', 
        'DFLT ', 0, NULL, 'S', NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, TO_DATE('01/02/2004 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), NULL, TO_DATE('07/31/2000 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'TEMO', 0, NULL, 0, NULL, 
        'TEL', NULL, NULL, 'N', 'N', 
        'Y', NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        0, 0, 8635, 'DK', '01', 
        1, 'N', NULL, 0, '1234', 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL);
    Insert into SUBSCRIBER
       (SUBSCRIBER_NO, CUSTOMER_ID, SYS_CREATION_DATE, SYS_UPDATE_DATE, OPERATOR_ID, APPLICATION_ID, DL_SERVICE_CODE, DL_UPDATE_STAMP, EFFECTIVE_DATE, INIT_ACTIVATION_DATE, SUB_STATUS, SUB_STATUS_DATE, ORIGINAL_INIT_DATE, SUB_STATUS_LAST_ACT, SUB_STATUS_RSN_CODE, PRODUCT_TYPE, CUSTOMER_BAN, CTN_SEQ_NO, REQ_ST_GRACE_PERIOD, REQ_END_GRACE_PERIOD, COMMIT_START_DATE, COMMIT_END_DATE, COMMIT_REASON_CODE, COMMIT_ORIG_NO_MONTH, SUSP_RC_RATE_TYPE, CONTRACT_NO, CNT_SEQ_NO, DEALER_CODE, ORG_DEALER_CODE, SALES_AGENT, ORG_SALES_AGENT, REQ_DEPOSIT_AMT, LEADING_NUMBER, PABX_IND, NEXT_CTN, NEXT_CTN_CHG_DATE, PRV_CTN, PRV_CTN_CHG_DATE, NEXT_BAN, NEXT_BAN_MOVE_DATE, PRV_BAN, PRV_BAN_MOVE_DATE, SUB_STS_ISSUE_DATE, ACTIVATE_WAIVE_RSN, EARLIEST_ACTV_DATE, SUB_ACTV_LOCATION, CUST_WATCH_LMT, CUST_WATCH_DATE, BASIC_WATCH_LMT, CREDIT_WATCH_PIN_CD, SUB_MARKET_CODE, LIMIT_RESERVED_DAYS, FF_EXPIRATION_DATE, FLEX_IND, DUO_IND, LISTED_IND, SUB_DEPARTMENT_CD, LAST_SUBS_DISC_DT, LAST_SUBS_DISC_DT_UD, LAST_SUBSCR_DISC_SN, LAST_SUBSCR_DISC_SN_UD, PNI, RMS_REF_STORE_ID, RMS_REF_TYPE, RMS_REF_OD, DLR_ACT_FEE, PREP_AMOUNT, SUBSCRIBER_ID, SUB_LANG, SMS_RCV_STYLE_CODE, CONV_RUN_NO, ALLOW_ADVERTISING_IND, IVR_WRONG_ACCESS_NO, THRESHOLD_AMT, PUBLISH_LEVEL, AUTO_RELEASE_IND, CUST_WATCH_EFF_DATE, CUST_WATCH_EXP_DATE, OPERATOR_CW_LMT, SEND_SMS_FOR_MATCH, CPS_STATUS, CPS_TRANSACTION, CPS_TYPE, ISP_PASS, ISP_TYPE, OPERATOR_TMP_DATE, OPERATOR_TMP_LMT, SUB_ORG_CD, ORG_MEMBER_NO)
     Values
       ('GSM04528890298', 502499502, TO_DATE('12/05/2006 15:55:13', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('01/12/2007 00:45:22', 'MM/DD/YYYY HH24:MI:SS'), NULL, 
        'FUTRX ', 'CS058', NULL, TO_DATE('01/12/2007 00:45:22', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('12/05/2006 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'C', TO_DATE('01/12/2007 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('12/05/2006 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'CCN', 'NP  ', 
        'GSM', 502499502, 14419730, NULL, NULL, 
        TO_DATE('12/05/2006 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('06/04/2007 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'PPD', 6, NULL, 
        '1035393', 6976424, '2311 ', '2311 ', 'DFLT ', 
        'DFLT ', NULL, '045', 'S', 'GSM04525210338', 
        TO_DATE('01/12/2007 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), NULL, NULL, NULL, NULL, 
        NULL, NULL, TO_DATE('01/12/2007 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), NULL, TO_DATE('12/05/2006 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'TEMO', NULL, NULL, NULL, NULL, 
        'TEL', NULL, NULL, 'N', 'N', 
        'Y', NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, 6834900, 'DK', '01', 
        NULL, 'N', NULL, 9999999.99, '4321', 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL);
    Insert into SUBSCRIBER
       (SUBSCRIBER_NO, CUSTOMER_ID, SYS_CREATION_DATE, SYS_UPDATE_DATE, OPERATOR_ID, APPLICATION_ID, DL_SERVICE_CODE, DL_UPDATE_STAMP, EFFECTIVE_DATE, INIT_ACTIVATION_DATE, SUB_STATUS, SUB_STATUS_DATE, ORIGINAL_INIT_DATE, SUB_STATUS_LAST_ACT, SUB_STATUS_RSN_CODE, PRODUCT_TYPE, CUSTOMER_BAN, CTN_SEQ_NO, REQ_ST_GRACE_PERIOD, REQ_END_GRACE_PERIOD, COMMIT_START_DATE, COMMIT_END_DATE, COMMIT_REASON_CODE, COMMIT_ORIG_NO_MONTH, SUSP_RC_RATE_TYPE, CONTRACT_NO, CNT_SEQ_NO, DEALER_CODE, ORG_DEALER_CODE, SALES_AGENT, ORG_SALES_AGENT, REQ_DEPOSIT_AMT, LEADING_NUMBER, PABX_IND, NEXT_CTN, NEXT_CTN_CHG_DATE, PRV_CTN, PRV_CTN_CHG_DATE, NEXT_BAN, NEXT_BAN_MOVE_DATE, PRV_BAN, PRV_BAN_MOVE_DATE, SUB_STS_ISSUE_DATE, ACTIVATE_WAIVE_RSN, EARLIEST_ACTV_DATE, SUB_ACTV_LOCATION, CUST_WATCH_LMT, CUST_WATCH_DATE, BASIC_WATCH_LMT, CREDIT_WATCH_PIN_CD, SUB_MARKET_CODE, LIMIT_RESERVED_DAYS, FF_EXPIRATION_DATE, FLEX_IND, DUO_IND, LISTED_IND, SUB_DEPARTMENT_CD, LAST_SUBS_DISC_DT, LAST_SUBS_DISC_DT_UD, LAST_SUBSCR_DISC_SN, LAST_SUBSCR_DISC_SN_UD, PNI, RMS_REF_STORE_ID, RMS_REF_TYPE, RMS_REF_OD, DLR_ACT_FEE, PREP_AMOUNT, SUBSCRIBER_ID, SUB_LANG, SMS_RCV_STYLE_CODE, CONV_RUN_NO, ALLOW_ADVERTISING_IND, IVR_WRONG_ACCESS_NO, THRESHOLD_AMT, PUBLISH_LEVEL, AUTO_RELEASE_IND, CUST_WATCH_EFF_DATE, CUST_WATCH_EXP_DATE, OPERATOR_CW_LMT, SEND_SMS_FOR_MATCH, CPS_STATUS, CPS_TRANSACTION, CPS_TYPE, ISP_PASS, ISP_TYPE, OPERATOR_TMP_DATE, OPERATOR_TMP_LMT, SUB_ORG_CD, ORG_MEMBER_NO)
     Values
       ('GSM04528890298', 581751708, TO_DATE('03/31/2010 19:10:33', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('04/01/2010 16:17:40', 'MM/DD/YYYY HH24:MI:SS'), 10077, 
        NULL, 'CS009', NULL, TO_DATE('03/31/2010 19:10:33', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('03/31/2010 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'A', TO_DATE('03/31/2010 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('03/31/2010 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'NAC', 'CA  ', 
        'GSM', 581751708, 24798333, NULL, NULL, 
        TO_DATE('03/31/2010 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('09/29/2010 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), NULL, 6, NULL, 
        NULL, 12093584, '2357 ', '2357 ', 'DFLT ', 
        'DFLT ', NULL, '045', 'S', NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, TO_DATE('03/31/2010 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), NULL, TO_DATE('03/31/2010 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'TEMO', NULL, NULL, NULL, NULL, 
        'TEL', NULL, TO_DATE('12/31/4700 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'N', 'N', 
        'Y', NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, 9474437, 'DK', '01', 
        NULL, 'N', NULL, 999999999.99, '12', 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL);
    Insert into SUBSCRIBER
       (SUBSCRIBER_NO, CUSTOMER_ID, SYS_CREATION_DATE, SYS_UPDATE_DATE, OPERATOR_ID, APPLICATION_ID, DL_SERVICE_CODE, DL_UPDATE_STAMP, EFFECTIVE_DATE, INIT_ACTIVATION_DATE, SUB_STATUS, SUB_STATUS_DATE, ORIGINAL_INIT_DATE, SUB_STATUS_LAST_ACT, SUB_STATUS_RSN_CODE, PRODUCT_TYPE, CUSTOMER_BAN, CTN_SEQ_NO, REQ_ST_GRACE_PERIOD, REQ_END_GRACE_PERIOD, COMMIT_START_DATE, COMMIT_END_DATE, COMMIT_REASON_CODE, COMMIT_ORIG_NO_MONTH, SUSP_RC_RATE_TYPE, CONTRACT_NO, CNT_SEQ_NO, DEALER_CODE, ORG_DEALER_CODE, SALES_AGENT, ORG_SALES_AGENT, REQ_DEPOSIT_AMT, LEADING_NUMBER, PABX_IND, NEXT_CTN, NEXT_CTN_CHG_DATE, PRV_CTN, PRV_CTN_CHG_DATE, NEXT_BAN, NEXT_BAN_MOVE_DATE, PRV_BAN, PRV_BAN_MOVE_DATE, SUB_STS_ISSUE_DATE, ACTIVATE_WAIVE_RSN, EARLIEST_ACTV_DATE, SUB_ACTV_LOCATION, CUST_WATCH_LMT, CUST_WATCH_DATE, BASIC_WATCH_LMT, CREDIT_WATCH_PIN_CD, SUB_MARKET_CODE, LIMIT_RESERVED_DAYS, FF_EXPIRATION_DATE, FLEX_IND, DUO_IND, LISTED_IND, SUB_DEPARTMENT_CD, LAST_SUBS_DISC_DT, LAST_SUBS_DISC_DT_UD, LAST_SUBSCR_DISC_SN, LAST_SUBSCR_DISC_SN_UD, PNI, RMS_REF_STORE_ID, RMS_REF_TYPE, RMS_REF_OD, DLR_ACT_FEE, PREP_AMOUNT, SUBSCRIBER_ID, SUB_LANG, SMS_RCV_STYLE_CODE, CONV_RUN_NO, ALLOW_ADVERTISING_IND, IVR_WRONG_ACCESS_NO, THRESHOLD_AMT, PUBLISH_LEVEL, AUTO_RELEASE_IND, CUST_WATCH_EFF_DATE, CUST_WATCH_EXP_DATE, OPERATOR_CW_LMT, SEND_SMS_FOR_MATCH, CPS_STATUS, CPS_TRANSACTION, CPS_TYPE, ISP_PASS, ISP_TYPE, OPERATOR_TMP_DATE, OPERATOR_TMP_LMT, SUB_ORG_CD, ORG_MEMBER_NO)
     Values
       ('GSM04528890298', 816370100, TO_DATE('09/03/2005 10:12:13', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('03/14/2006 12:20:09', 'MM/DD/YYYY HH24:MI:SS'), 14462, 
        NULL, 'CS016', NULL, TO_DATE('03/14/2006 12:20:08', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('09/03/2005 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'C', TO_DATE('03/14/2006 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('09/03/2005 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'CAN', 'CNP3', 
        'GSM', 816370100, 12575966, NULL, NULL, 
        TO_DATE('09/03/2005 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), TO_DATE('03/02/2006 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 'PPD', 6, NULL, 
        '690925', 3436964, '4243 ', '4243 ', 'DFLT ', 
        'DFLT ', NULL, '045', 'S', NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, TO_DATE('03/14/2006 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), NULL, TO_DATE('09/03/2005 00:00:00', 'MM/DD/YYYY HH24:MI:SS'), 
        'TEMO', NULL, NULL, NULL, NULL, 
        'TEL', NULL, NULL, 'N', 'N', 
        'Y', NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, 1436383, 'DK', '01', 
        NULL, 'N', NULL, 9999999.99, '0', 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL, NULL, 
        NULL, NULL, NULL, NULL);

    Hello

    Welcome to the froum!

    Thanks for posting the CREATE TABLE and INSERT! It's very nigra.

    user12990691 wrote:
    ...
    logon_histories_r table records the information of each user who connects to the system. Subscriber Details table contains all the information corresponding to subscriber_no, only 1 row should be returned.

    Do you mean a line by the user, or a line every time that you run the report, regardless of the number of users connected during the period that interests us?
    Anyway, if there are multiple logons, how do you decide that one? Or the output of logon_histories_r columns will be a sort of composite?

    I'm confused usage date condition for the table of the Subscriber, the input parameter date 04/04/2006 to 15/04/06

    Select lh.logon_id, lh.user_id, lh.logon_time, lh.logon_type, subs.subscriber_no, subs.customer_id
    of logon_histories_r lh, subscribed subs
    where lh.logon_time > = to_date('05-04-2010','dd-mm-yyyy')--to_date('04-04-2006','dd-mm-yyyy')
    and lh.logon_time< to_date('06-04-2010','dd-mm-yyyy')="" --="">
    and lh.user_id = substr (subs.subscriber_no,-10);

    Must LH.LOGON_TIME match something in the subscruber table? If so, you need to addsome extra join pathological.
    For example, if lh.logon_time must be between d1 and d2 (where d1 and d2 are DATE columns), then:

    select      lh.logon_id
    ,     lh.user_id
    ,     lh.logon_time
    ,     lh.logon_type
    ,     subs.subscriber_no
    ,     subs.customer_id
    from      logon_histories_r      lh
    ,      subscriber           subs
    where      lh.logon_time      >= to_date ('05-04-2010','dd-mm-yyyy') -- to_date('04-04-2006','dd-mm-yyyy')
    and      lh.logon_time      <  to_date ('06-04-2010','dd-mm-yyyy') -- to_date('15-01-2007','dd-mm-yyyy')
    and      lh.user_id      = substr (subs.subscriber_no, -10)
    and     lh.logon_time     >= subs.d1     -- New condition added
    and     lh.logon_time     <= subs.d2     -- New condition added
    ;
    

    Please find DDL and data relevant to these results. There are millions of records of Subscriber & logon_histories_r table, I am given appropriate providing a subscriber_id.

    That's smart, don't not post each row of the table: looks like you posted just enough to show what the problem is.
    Try to do the same thing with the columns. Do not post every single column, just the columns that have something to do with the problem.

  • Update on the table by extracting the data from the table even under certain conditions

    Hi Experts,

    I have the table EMP which currently has 6 entries.

    EMP_SYS BATCH_NO JOIN_DATE LOGIN_ID STATUS FLAG

    1 FEBRUARY 10 PROD 84 Y IND123 ABC

    DEV 1-23 APRIL 98 Y IND123 ABC

    2 12 APRIL PROD 98 Y IND123 ABC

    2 2 APRIL DEV 98 Y IND123 ABC

    3 13 APRIL PROD 98 Y IND123 ABC

    3 3 APRIL DEV 98 Y IND123 ABC

    CONDITION: I need to take lines which has the minimum BATCH_NO for each of the EMP_SYS

    for example,.

    1 FEBRUARY 10 PROD 84 Y IND123 ABC

    DEV 1-23 APRIL 98 Y IND123 ABC

    For the above two lines, I need to update the status of DEF. How to select this criterion and update in the same query?

    Currently, I used the query to select the minimum BATCH_NO for each of the EMP_SYS below.

    SELECT EMP_SYS, BATCH_NO, JOIN_DATE, FLAG, LOGIN_ID, STATUS

    Of

    (

    EMP_SYS, BATCH_NO, JOIN_DATE, FLAG, LOGIN_ID, STATUS, SELECT ROW_NUMBER)

    COURSE NR (PARTITION BY ORDER OF EMP_SYS OF EMP_SYS)

    FROM EMP

    WHEN STATUS = 'ABC' AND FLAG = "Y".

    )

    WHERE

    NR = 1;

    If I try to use the update on the above query statement... It updates every 6 rows instead of 2 rows.

    Please suggest me a way to update only the two lines that has the minimum BATCH_NO for each of the EMP_SYS.

    But is possible to write the query without using the Group of?

    Update e EMP

    set STATUS = "DEF".

    where BATCH_NO = (select min (BATCH_NO) from EMP I where STATUS = 'ABC' AND FLAG = 'Y' and i.emp_sys = e.emp_sys)

  • Extraction of data from three tables.

    Hi all


    I have three tables company (com_id (PK), com_name),
    contact (contact_id (PK), com_id (FK), first_name, email),
    Rental (loc_id (PK), com_id (FK), Country).

    I need a query to extract the first name, the e-mail, the com_name and the country.

    I used:
    Select contact.first_name, m.country, company.com_name, contact.email in contact
    LEFT JOIN place m ON contact.com_id = m.com_id
    Contact.com_id = c.com_id ON LEFT JOIN c company

    but his return lines in double.

    I'm new on this. Please tell me how to solve this problem.


    Thank you

    Sophie wrote:
    Hi all

    I have three tables company (com_id (PK), com_name),
    contact (contact_id (PK), com_id (FK), first_name, email),
    Rental (loc_id (PK), com_id (FK), Country).

    I need a query to extract the first name, the e-mail, the com_name and the country.

    I used:
    Select contact.first_name, m.country, company.com_name, contact.email in contact
    LEFT JOIN place m ON contact.com_id = m.com_id
    Contact.com_id = c.com_id ON LEFT JOIN c company

    but his return lines in double.

    I'm new on this. Please tell me how to solve this problem.

    Thank you

    Hello

    select
        b.first_name,
        b.email,
        a.com_name,
        c.country
    from
        company a,
        contact   b,
        loaction   c
    where
        a.com_id=b.com_id
        and
        a.com_id=c.com_id;
    

    Thanks in advance.

  • Kindly help me with the request to find the data in two tables

    Hello Guru

    Kindly help me to recover the data from two tables-

    BASEBALL
    LEGAL_ENT_ID (PK)
    GAME_ID (FK)
    LEGAL_ENT_NM
    INACTIVE_DT
    DATE OF INS_TS
    INS_LOGIN
    DATE OF UPD_TS
    UPD_LOGIN


    FOOTBALL
    GAME_ID (PK)
    BRKR_NM,
    BRKR_ISR_ID
    BROKER_SYMBOL
    INACTIVE_DT
    BRKR_SWIFT_FLG
    BRKR_INTERNAL_FLG
    BRKR_CATEGORY
    UPD_TS
    MINORITY_FLG
    BROKER_TYP
    STATUS
    INS_TS
    INS_LOGIN
    UPD_LOGIN
    APP_USER
    ACTIVE_FLG

    and if I want fecth data from these two tables according to the following condition then it is fine with the suite of applications.

    1 select distinct values only table of BASEBALL by using the following query.

    SELECT DISTINCT B.GAME_ID as 'CLEARING GAME ID', B.BRKR_NM "NAME of THE GAME of COMPENSATION" OF BASEBALL A, FOOTBALL B WHERE A.BROKER_RELATION_CD IN ('FUTBRKR1', 'FUTBRKR2') AND A.GAME_ID = B.GAME_ID

    2 Select all the table BRKR_NM OF FOOTBALL as well by using the query - next

    SELECT GAME_ID "RUNNING GAME ID", 'NAME OF THE GAME OF EXECUTION' BRKR_NM SOCCER

    Now, my query is that--

    I want a query that gives me a combination of above mentioned queries... and if I tried to use Union or Union All, then she is not giving me the result as expected.

    I like the result to look like who has a few conditions such as -
    1 - the records in the table Football are high vs Baseball table because there is no condition to filter the records of the Football.
    2 - football is a superset of records and Baseball is a subset.
    3 - COMPENSATION NOM_JEU and RUNNING NOM_JEU may return the same values as well.

    I want the result to be in the following form-

    EXECUTION ID GAME | NAME OF THE GAME TO RUN. COMPENSATION ID GAME | DELETE THE NAME OF THE GAME.
    2123 test1 2345 test5
    2456 test10 2456 test10


    Thanks in advance. Kindly help me.

    Published by: user555994 on January 4, 2011 23:48

    In the output you want.
    All the values of baseball;
    Values of football that are matched;
    But on what condition you want to match?

  • I want to loop through the data from two different tables using for loop where the query should be replaced at runtime, please help me

    I have the data into two table with the structure of similar column, I want to loop through the data in these two tables

    based on some condition and runtime that I want to put the query in loop for example, the example is given, please help me

    create table ab (a number, b varchar2 (20));

    Insert into ab

    Select rownum, rownum. "" sample "

    of the double

    connect by level < = 10

    create table bc (a number, b varchar2 (20));

    Insert into BC.

    Select rownum + 1, rownum + 1 | "" sample "

    of the double

    connect by level < = 10

    declare

    l_statement varchar2 (2000);

    Boolean bool;

    Start

    bool: = true;

    If it is true, then

    l_statement: =' select * ab ';

    on the other

    l_statement: =' select * from bc';

    end if

    I'm in execute immediate l_statement - something like that, but I don't know

    loop

    dbms_output.put_line (i.a);

    end loop;

    end;

    Something like that, but this isn't a peace of the code work.

    Try this and adapt according to your needs:

    declare

    l_statement varchar2 (2000);

    c SYS_REFCURSOR;

    l_a number;

    l_b varchar2 (20);

    Boolean bool;

    Start

    bool: = true;

    If it is true, then

    l_statement: = "select a, b, AB;

    on the other

    l_statement: = "select a, b from bc;

    end if;

    --

    Open c for l_statement;

    --

    loop

    extract the c in l_a, l_b;

    When the output c % notfound;

    dbms_output.put_line (l_a |') -' || l_b);

    end loop;

    close c;

    end;

    /

  • extract data from a table to a text file

    I need to extract data from a table to a text file, I twist my output is the following...

    bash-3. $00 vi tap3roamercosts_20110915144318.txt
    lines of 'tap3roamercosts_20110915144318.txt' 393948, 23464348 characters
    ^ LAFGTD | N | 2011090203000001 | 13242514000064 | 1. 0 | 20. 41220 | 02-SEVEN.-11. 01-SEPT.-11. 0 | 13244
    755. 64. 70. 0093794428588 | 0093796234547 | 0 | S2 | E | 412200306902634 | 8. 1. 61500 | 16081 |
    | HW | Call to the Roamer. 0 | I have | Roaming billing Inroamer Plan | 1_0_1 | LKA | N_I_Independent
    the time of day. Rate of Roamer SMST systems | AFGTD20110902030000010001013242514000064 |
    |||||||||||||||||||||

    AFGTD | N | 2011090203000001 | 13242612000044 | 1. 0 | 20. 41220 | 02-SEVEN.-11. 01-SEPT.-11. 0 | 13244
    853. 44. 70. 234. 0093793252818 | 0 | S2 | E | 412200303198150 | 8. 1. 61000 | 12403 | HW | -Ro
    bitter call | 0 | I have | Roaming billing Inroamer Plan | 1_0_1 | N_I_Independent time of Da
    There | Rate of Roamer SMST systems | AFGTD20110902030000010001013242612000044 |
    ||||||||

    AFGTD | N | 2011090203000001 | 13242612000047 | 1. 0 | 20. 41220 | 02-SEVEN.-11. 01-SEPT.-11. 0 | 13244
    853. 47. 70. 234. 0093793252818 | 0 | S2 | E | 412200303198150 | 8. 1. 61000 | 12403 | HW | -Ro
    bitter call | 0 | I have | Roaming billing Inroamer Plan | 1_0_1 | N_I_Independent time of Da
    There | Rate of Roamer SMST systems | AFGTD20110902030000010001013242612000047 |
    ||||||||
    .
    .
    .
    .
    .

    Please help me how to format my output each record in simple lines in oracle sqlplus. Here are the settings I used...

    TERMOUT OFF SET;
    SET ECHO OFF;
    SET LINESIZE 100000;
    THE VALUE OF NEWPAGE 0;
    SET SPACE 0;
    SET PAGESIZE 50000;
    SET FEEDBACK OFF;
    SET THE OFF POSITION;
    SET TRIMSPOOL
    SET THE TAB

    And what was wrong with the answers that you have on your previous thread?

    How to extract data in a text file

    Please do not ask the same question again. If there is a problem with the answers provided, then continue on the same thread that tell people what is the problem.

    Saying that, this is another possibility for you...

    As user sys:

    CREATE OR REPLACE DIRECTORY TEST_DIR AS '\tmp\myfiles'
    /
    GRANT READ, WRITE ON DIRECTORY TEST_DIR TO myuser
    /
    

    As myuser:

    CREATE OR REPLACE PROCEDURE run_query(p_sql IN VARCHAR2
                                         ,p_dir IN VARCHAR2
                                         ,p_header_file IN VARCHAR2
                                         ,p_data_file IN VARCHAR2 := NULL) IS
      v_finaltxt  VARCHAR2(4000);
      v_v_val     VARCHAR2(4000);
      v_n_val     NUMBER;
      v_d_val     DATE;
      v_ret       NUMBER;
      c           NUMBER;
      d           NUMBER;
      col_cnt     INTEGER;
      f           BOOLEAN;
      rec_tab     DBMS_SQL.DESC_TAB;
      col_num     NUMBER;
      v_fh        UTL_FILE.FILE_TYPE;
      v_samefile  BOOLEAN := (NVL(p_data_file,p_header_file) = p_header_file);
    BEGIN
      c := DBMS_SQL.OPEN_CURSOR;
      DBMS_SQL.PARSE(c, p_sql, DBMS_SQL.NATIVE);
      d := DBMS_SQL.EXECUTE(c);
      DBMS_SQL.DESCRIBE_COLUMNS(c, col_cnt, rec_tab);
      FOR j in 1..col_cnt
      LOOP
        CASE rec_tab(j).col_type
          WHEN 1 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
          WHEN 2 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_n_val);
          WHEN 12 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_d_val);
        ELSE
          DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
        END CASE;
      END LOOP;
      -- This part outputs the HEADER
      v_fh := UTL_FILE.FOPEN(upper(p_dir),p_header_file,'w',32767);
      FOR j in 1..col_cnt
      LOOP
        v_finaltxt := ltrim(v_finaltxt||','||lower(rec_tab(j).col_name),',');
      END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
      UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      IF NOT v_samefile THEN
        UTL_FILE.FCLOSE(v_fh);
      END IF;
      --
      -- This part outputs the DATA
      IF NOT v_samefile THEN
        v_fh := UTL_FILE.FOPEN(upper(p_dir),p_data_file,'w',32767);
      END IF;
      LOOP
        v_ret := DBMS_SQL.FETCH_ROWS(c);
        EXIT WHEN v_ret = 0;
        v_finaltxt := NULL;
        FOR j in 1..col_cnt
        LOOP
          CASE rec_tab(j).col_type
            WHEN 1 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
                        v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
            WHEN 2 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_n_val);
                        v_finaltxt := ltrim(v_finaltxt||','||v_n_val,',');
            WHEN 12 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_d_val);
                        v_finaltxt := ltrim(v_finaltxt||','||to_char(v_d_val,'DD/MM/YYYY HH24:MI:SS'),',');
          ELSE
            v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
          END CASE;
        END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
        UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      END LOOP;
      UTL_FILE.FCLOSE(v_fh);
      DBMS_SQL.CLOSE_CURSOR(c);
    END;
    

    This allows the header line and the data to write into files separate if necessary.

    for example

    SQL> exec run_query('select * from emp','TEST_DIR','output.txt');
    
    PL/SQL procedure successfully completed.
    

    Output.txt file contains:

    empno,ename,job,mgr,hiredate,sal,comm,deptno
    7369,"SMITH","CLERK",7902,17/12/1980 00:00:00,800,,20
    7499,"ALLEN","SALESMAN",7698,20/02/1981 00:00:00,1600,300,30
    7521,"WARD","SALESMAN",7698,22/02/1981 00:00:00,1250,500,30
    7566,"JONES","MANAGER",7839,02/04/1981 00:00:00,2975,,20
    7654,"MARTIN","SALESMAN",7698,28/09/1981 00:00:00,1250,1400,30
    7698,"BLAKE","MANAGER",7839,01/05/1981 00:00:00,2850,,30
    7782,"CLARK","MANAGER",7839,09/06/1981 00:00:00,2450,,10
    7788,"SCOTT","ANALYST",7566,19/04/1987 00:00:00,3000,,20
    7839,"KING","PRESIDENT",,17/11/1981 00:00:00,5000,,10
    7844,"TURNER","SALESMAN",7698,08/09/1981 00:00:00,1500,0,30
    7876,"ADAMS","CLERK",7788,23/05/1987 00:00:00,1100,,20
    7900,"JAMES","CLERK",7698,03/12/1981 00:00:00,950,,30
    7902,"FORD","ANALYST",7566,03/12/1981 00:00:00,3000,,20
    7934,"MILLER","CLERK",7782,23/01/1982 00:00:00,1300,,10
    

    The procedure allows for the header and the data to separate files if necessary. Just by specifying the file name "header" will put the header and the data in a single file.

    Adapt to the exit of styles and different types of data are needed.

  • Insert data into the table without using the insert or select the command

    Hello

    Is there anyway to insert data from one table to another table, without using insert, and then select the command in the same pattern.
    Note: the two tables have the same structure.

    ALTER table... Swap partition...

  • Tracing data from two locations on the block diagram on the same graph

    Hello world

    I'm trying to plot data from two distinct processes on a chart.  These processes occur in the order.

    I have developed several solutions, which none produce the result I want.  What I want is for the data to trace in real time each process is running.

    The two processes are functionally identical - one loop "for".  With each iteration of these loops, data is produced and traced.

    The data are plotted in real time, which means that each reference appears on the chart as soon as it is produced.

    However, I am not able to get the second process data on the same graph in the same way.

    The closest I got combines the graphic with a local variable.  This allows the data for the two processes to draw in real time, but the second set of data replaces the first.

    I have attached a very simple test VI showing my problem.

    Any help with this would be greatly appreciated.

    Thank you

    You can do something like this. Is the second process just a continuation of the first? If so, it becomes even easier and you can just to keep construction of the table in the second loop.

  • Copy the data from two rows together in a new line

    Hello everyone.

    I have a question for copying data from two lines together in a new third line.

    See this short example:

    This is the current situation. The lines STATE_1 and STATE_2 contain different information separate.

    In the past data were recorded at random in one of these lines.

    It's the state table:

    ID Cust_id STATE_1 STATE_2 STATE_3
    188Customer is waiting.Call since yesterday.
    211Mr. Smith, no answer.Wait until December
    311Pls Create PO.Old PO has been cancelled
    45No access to the system.

    Now, everything must be recorded in the STATE_3 void, but I also need than the old entries from the past which must also be copied together in STATE_3

    Like this:

    ID Cust_id STATE_1 STATE_2 STATE_3
    188Customer is waiting.Call since yesterday.Customer is waiting. Call since yesterday
    211Mr. Smith, no answer.Wait until December.Mr. Smith, no answer. Wait until December.
    311Pls Create PO.Old PO has been cancelled.Pls create in. old PO was canceled.
    45No access to the system.No access to the system.

    Y at - it an SQL-easy order?

    Thanks for any help.


    What:

    update set state_3 = state_1 State | » '|| state_2;

    ?

  • Inserting data from one table to another table

    Hello

    I have the following SQL where I am updating a table by adding new data from another table, but without success.

    INSERT INTO
    () TOP_PROSPECTS
    COMMON_ID
    DATE_ADDED
    REVIEW_RANK
    EVAL_DATE
    PM_ASSIGN
    WHY_NOTES)
    SELECT
    t.COMMON_ID
    t.DATE_ADDED
    t.REVIEW_RANK
    t.EVAL_DATE
    t.PM_ASSIGN
    t.WHY_NOTES
    Of
    TEMP_IVAN_MARY t
    WHERE
    COMMON_ID <>t.COMMON_ID

    Any suggestions?

    Thank you.

    Published by: user13822709 on August 14, 2012 09:14

    Published by: user13822709 on August 14, 2012 09:15

    Is that what you're trying to do with the insert. I think there may be a sign {noformat}<{noformat}{noformat}>{noformat} missing in the where clause. This site eat those, so you need to use the equivalent! = post here.

    If I'm wrong about the missing trader, then it looks like you want to insert rows in temp_ivan_mary that are not already in top_prospects. If Yes, then you need something like:

    insert into top_prospects
       (common_id, date_added, review_rank, eval_date, pm_assign,
        why_notes)
    select t.common_id, t.date_added, t.review_rank, t.eval_date,
           t.pm_assign, t.why_notes
    from temp_ivan_mary t
    where t.common_id not in (select common_id from top_prospects
                              where common_id is not null)
    

    Function index and data available volumnes etc. then a mergr can be more effective. Something like:

    merge into top_prospects p
       using (select common_id, date_added, review_rank, eval_date,
                     pm_assign, why_notes
              from temp_ivan_mary) t
       on (p.common_id = t.common_id)
       when not matched then
          insert (common_id, date_added, review_rank, eval_date, pm_assign,
                  why_notes)
          values (t.common_id, t.date_added, t.review_rank, t.eval_date,
                  t.pm_assign, t.why_notes)
    from temp_ivan_mary t
    

    John

  • Is mapping dimension AWM - possible to load the data in two tables of entry?

    Hi all

    I have two tables ProductFamily (parent level) and products (child level).

    I want to load a dimension of those tables where the parent-child relationships are maintained (I use AWM).

    I created a map with these two entry tables, but the loaded data has no relationship.
    So, how do I do that? Is it possible to load dimensions where different levels get data from multiple tables?
    Is any type of Carpenter available in AWM?

    Thank you

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

    A few Notes:

    -I don't want to use OWB here that my data are clean
    -In AWM, when I loaded the data in a single view that contains two tables of input data, it worked fine. But it's my worst case option.

    You must use Dimension option in snowflake in the mapping screen of size for the Product Dimension (as opposed to the default style mapping - star schema dimension).

    This will modify map entries to include a separate parent for each level of hierarchy level / that is to say, for each level of hierarchy / (unless a higher level of the hierarchy), you must specify the parent level key in addition to the key current level, code/name/description/other attributes etc.

    You can make the mapping or... use the icons at the top of the map screen.
    mode drag/drop by dragging the relational column on dimension - level/hierarchy/attribute model
    -or-
    the table expression mapping mode that gives the same effect... by dragging a column on an attribute defined in the .

    . the format of .

    HTH
    Shankar

    Note1: Complete the mapping of a sudden... B & w switching mapping modes cause the mappings to reset.
    NOTE2: assumes that your data are correct foreign key table parent level: ProductFamily exists in the child level table: products.

  • DV7 - 7333cl: how to extract usable data from a bad drive using 22 pins adapter usb to SATA on the new HD

    Greetings HP Forum,

    Recently, I replaced a bad hard drive on my laptop. I need now step by step procedure to extract usable data from the wrong drive using 22 pins adapter usb to SATA on the new HD.

    NOTE: I can't not all data that especially if some of the software downloaded on the replaced disk can be altered. Should I first download Internet Antivirus to protect my new hard drive? I'm not an expert, or even close to this when you work on the back of the laptop, so I'll have to step by step how to download and to partition the data recoverable and software, etc..

    Thanks in advance for your help... I greatly appreciate it!

    See you soon!

    Wes

    It is not complex. Attach the drive to the adapter and connect it to any other computer with good antivirus and antispyware installed. I use Malwarebytes and Avast. When you connect the adapter with the drive connected to the usb port, the drive will appear and it will be assigned a letter maybe E:\ or F:\ or something else. Immediately, he analyzes with the antivirus and anti-spyware. Quarantine or delete any virus or malware it finds. Then, it's just a matter of navigate the disk and copy and paste the contents of the host computer in a directory for this purpose. Obviously, you can copy from documents word, photos, music files, but you cannot copy the applications like Microsoft Word, iTunes. Photoshop.  You may need to take ownership of the files on the old hard drive, but Windows will guide you through this. Don't know what else I can answer.

Maybe you are looking for