read data from a SQL database

Hi all

who can I load data from a database, based on a specific query and data in a string or an integer in cascades please give example

Thank you

for example first element of data

// dd
data[0].dd
data[0].mm
etc...

If you put the data to GroupDataModel for example. Then you can access it with ListItemComponent like this:

ListItemData.dd
ListItemData.mm
etc...

Tags: BlackBerry Developers

Similar Questions

  • How can I read data from my SQLite database?

    I am new to Adobe Air and am playing with creating something simple to insert data into a database and then display it. I was able to insert data successfully but now encounter difficulties to read from the database and display. How can I display data such as a text box or text box?

    This my code for insertion:

    private void sqlConn(dbName___tring,_dbstmt___tring,_dbInsert___tring):void
    {
    sqlC varQLConnection = new SqlConnection ();
    SQLs varQLStatement = new SQLStatement();
    SQLI varQLStatement = new SQLStatement();

    file: var folder = File.applicationDirectory;
    var dbPath:File = folder.resolvePath (dbName);

    sqlc.addEventListener (SQLEvent.OPEN, dbCreated);
    sqlc.addEventListener (SQLErrorEvent.ERROR, dbError);

    sqls.addEventListener (SQLEvent.RESULT, tbCreated);
    sqls.addEventListener (SQLErrorEvent.ERROR, tbError);

    sqli.addEventListener (SQLEvent.RESULT, recCreated);
    sqli.addEventListener (SQLErrorEvent.ERROR, recError);

    sqlc.openAsync (dbPath);

    sqls.sqlConnection = sqlc;
    SQLs. Text = dbstmt;
    SQLs. Execute();

    sqli.sqlConnection = sqlc;
    SQLI. Text = dbInsert;
    SQLI. Execute();
    }

    private void btn_Click (): void
    {
    dbName var= "test.db" tring
    var sqlStatmttring = "CREATE TABLE If NOT EXISTS test_table (id INTEGER PRIMARY KEY AUTOINCREMENT, first_name TEXT, last_name TEXT);
    var sqlInserttring = 'INSERT test_table (first_name, last_name) VALUES('"+txtTaskName.text+"','"+txtTaskDescription.text+"');';
    var sqlReadtring = "SELECT * FROM test_table;"

    sqlConn (dbName, sqlStatmt, sqlInsert);
    }

    That's what I have so far to read the articles. Is this right? How can I use it to display items on one of my opinions?

    private void readItems(dbName___tring):void
    {
    var sqlrQLStatement = new SQLStatement();
    sqlC varQLConnection = new SqlConnection ();
    file: var folder = File.applicationDirectory;
    var dbPath:File = folder.resolvePath (dbName);

    sqlc.openAsync (dbPath);

    sqlr.addEventListener (SQLEvent.RESULT, recFound);
    sqlr.addEventListener (SQLErrorEvent.ERROR, recFoundError);

    sqlr.sqlConnection = sqlc;
    sqlr. Text = "SELECT * FROM test_table ';
    sqlr. Execute();

    Table of results: var = sqlr.getResult () .data;
    }

    Thank you

    They must be in their own class and each class must be in their own folder. If you need a taskClass.as file and a SQLClass in the SQLClass.as file that has the recFound function.

  • read data from emparray

    I have a function that I would read in pl/sql. How can I read data from it. EMPARRAY function return.

    FUNCTION META_PODATKI_TABEL
    (ime_tabele VARCHAR2, st_napake NUMBER
    )
    RETURN EMPARRAY ACE


    EMPARRAY is:
    create or replace TYPE "EMPARRAY" as VARRAY (10000) OF VARCHAR2 (4000);


    I try but nothing works.

    THX

    Put the function calls in the clause of a query using the TABLE from:

    SQL> create or replace TYPE "EMPARRAY" as VARRAY(10000) OF VARCHAR2(4000);
      2  /
    
    Type created.
    
    SQL> create or replace FUNCTION META_PODATKI_TABEL
      2  (ime_tabele VARCHAR2, st_napake NUMBER
      3  )
      4  RETURN EMPARRAY AS
      5  begin
      6  return emparray('aaa','bbb','ccc');
      7  end;
      8  /
    
    Function created.
    
    SQL> select * from table(META_PODATKI_TABEL('x',1));
    
    COLUMN_VALUE
    ------------------------------------------------------------------------------------
    aaa
    bbb
    ccc
    

    Max
    http://oracleitalia.WordPress.com

  • Read data from APEX_ITEM

    Hi all

    I searched the forums, and unfortunately I have no idea on how to go on the following.

    I have the following SQL report created with APEX_ITEM. SELECT_LIST-

    > select id, questions, APEX_ITEM. SELECT_LIST (p_idx = > 1, p_value = > '- Select Rating-', p_list_values = > 1, 1, 3, 3, 5, 5', p_attributes is > "style =" "color: Black;"', p_show_null = > 'YES', p_null_value = > NULL, p_null_text = > '- Select Rating-', p_item_id = > ' the ROWNUM # f01_ #', p_item_label = > ' label for ROWNUM f01_ # #', p_show_extra = > 'NO') 'Rating' of the sqa_customer_questions by id order

    Query runs as you like, but I don't know how to accept the values of the rows. I would like to insert the values of the selection list and their respective ID for all the entries in another table. I'm not able to find out how I could read data from these APEX_ITEMs and reach my goal.

    Any help is appreciated.

    Kind regards
    Jean-Pierre

    Nope,

    Can you put the app on apex.oracle.com

    In any case if you have a report like this

    SELECT id,
                    something
    FROM table
    

    You can do it for the

     SELECT id||APEX_ITEM.HIDDEN(2,id) id,
                    something
    FROM table
    

    And then reference it as APEX_APPLICATION. G_F02 (the first parameter provided to apex_item determine the number) in your process.

    See you soon

    Ben
    http://www.munkyben.WordPress.com
    Don't forget to mark the answers useful or correct ;)

  • Can read data from xls using teststand 3.5?

    Hello

    I use 3.5 TestStand and LabVIEW 8.je know these are quite old versions now, but we must continue with this on a test bench.

    My question is how can I read data from the file xls using TestStand 3.5? I have already mentioned a few posts on this, and one response suggested that I should use "tGetExcel" using ActiveX adapter. I tried to run the test example related to "http://forums.ni.com/t5/NI-TestStand/Write-or-read-to-Excel-from-TestStand/td-p/250439/highlight/tru...", but a run-time error. He says that "the tGetExcel type library information not found. Make sure that the server is registered in the system.

    TestStand 4.2, I could easily run excel at the base of operations by using the Office Excel Toolkit.

    I was wondering, is there another way, I can read just .xls file data by using Teststand 3.5?

    Thank you

    Niraj.

    Please check this example for charger of property:

    C:\Program Files (x 86) \National Instruments\TestStand 3.5\Examples\LoadingLimits

    This shows the limits of excel file loading.

    But you can load the values of the variables-consult the help file / Reference manual for this type of step.

    Also in the loader type forum search property - you can find more information.

    I hope this helps.

  • read data from xlsx file

    How to read data from an Excel 2010 worksheet with the .xlsx extension?  The data I want, it's on one of the 10 tabs in the file, I have to choose which programmatically.  I have the Report Generation Toolkit for LV2012, but all the screws that come with it seem to focus around writing data to a spreadsheet Excel and make charts and whatnot.  I want to * read * an Excel worksheet.  Seeking answers led to many 'Open it and save it as tab delimited text', which I can't do because I need data from different tabs, and because this file is quite dynamic with many users opening and adding several times.  In order to save the tab I want as a tab delimited text file per programming, I'm back a square, how to open it?

    My solution would ideally fill in the blanks of: spreadsheet.xlsx---> _---> 2 or 3D data table.

    Thank you

    Adam

    This fixes:

    https://decibel.NI.com/content/docs/doc-3033

  • How to read data from an excel and HTML file

    Hello

    I write a 2D-array of string in Excel/HTML file using the generation of reports.

    Can someone tell me how to get back in return, the written data, same files again and display in table format.

    Thank you & best regards

    Visuman

    You can use activex to read data from the excel fileback to the table format... through this vi... may b this will help you...

  • Read data from table of $ E and insert in the staging table

    Hi all

    I'm new on ODI. I need your help to understand how to read data from a table ' E$ "and insert in an intermediate table.

    Scenario:

    The name of two columns, in a flat file, the employee and the employee id must be loaded into a data EMPstore +. A check constraint is added so that the data with the employee names in capital letters only to load in the data store. Check the command is set to the static movement . Right-click on the data store, select control , then check. The lines that have violated the check constraint are kept in E$ _EMP+ table.

    Problem:

    Problem is I want to read the data in the table E$ _EMP+ and transform in capital letters in the name of the employee and move the corrected data of E$ _EMP+ EMP+. Please advise me on how to automatically manage the 'soft' exceptions in ODI.

    Thank you

    If I understand, you want to change the columns in the tables of $ E and then load into the target.

    Now, if you notice how ODI recycles the error, there is an incremental update to the target using the E table $ after he filled the I$ table.

    I think you can do the same thing by creating an interface using the table of $ E as source and implement the business logic in this interface to fill the target.

  • Reading data from a text (JS CS3) file tabs-delimited

    Hi - I'm working on a script to read data from a text file and use in a dialog box. But I hit a wall.

    I used a script from a previous post that defines a variable text document when the user script he chooses from a drop-down list.

    var myDialog = app.dialogs.add({name:"Map",canCancel:true});)
    {with (MyDialog)}

    {with (dialogColumns.Add ())}
    {with (borderPanels.Add ())}
    staticTexts.add ({staticLabel: "choose the location :"});})
    {with (dialogColumns.Add ())}

    var file = File("~/Desktop/myPlacesfile.txt");

    leader. Open ("r");
    var str = file.read ();
    leader. Close();
    var myPlaceList = str.split (/ [\r\n] + /);
    var myPlaceMenu = dropdowns.add ({stringList:myPlaceList, selectedIndex:0});})
    }
    }}}
    Ditto var = myDialog.show ();
    if(myResult == true) {}
    If (myPlaceMenu.selectedIndex == 0) {}
    myPlace var = ' - undefined ";
    } else {}
    myPlace var = myPlaceList [myPlaceMenu.selectedIndex];
    Alert (myPlace);
    }

    myDialog.destroy ();
    }

    That's what I do now:

    The text file is in this format:

    Value1 value2 [TAB]

    Value1 value2 [TAB]

    Value1 value2 [TAB]

    I need to have the drop down dialog box show only the value 1, and after that the user selects, the script returns only the value 2. (The alert is just there to test - I'm doing something else with the variable).

    Is there a way to view the first part of a tab-delimited line in the menu drop down and return the second half as a variable?

    Any help would be greatly appreciated.

    Thank you

    One of the possibilities is that it. Create a table to the left of the values of the tab of the dialog box. Then create an object that you use it as a table of correspondence. Roughly as follows:

    same thing as what you have

    leader. Open ("r");
    var str = file.read ();
    leader. Close();
    var array = str.split (/ [\r\n] + /);

    'pairs' are the table of correspondence

    pair of var = {};

    as before, 'myPlaceList' will be used for the menu drop-down
    var myPlaceList = [];

    var v;
    for (var i = 0; i)< array.length;="">
    {
    v = table [i] .split ('\t');
    pairs [v [0]] = v [1];
    myPlaceList.push (v [0]);
    }

    Add the drop-down list as before:

    var myPlaceMenu = dropdowns.add ({stringList:myPlaceList, selectedIndex:0});})

    the table of 'pairs' correspondence is used as follows: pairs ['value1'] returns 'value2 '.

    so in your script that would be:

    myPlace var pairs = [myPlaceList [myPlaceMenu.selectedIndex]];

    Peter

  • How to select data from a remote database table?

    Hi friends,

    I think I've seen before a sqlplus program that can select data from a remote database table?

    Witnessed: IP, SID, PORT

    The following is correct?

    (I am connected to a local database)
    SELECT COUNT (*) IN THE EMP@IP:SID/PORT;


    Thank you very much


    Ms. K

    Salvation;

    I think, that you can create dblink wihtout any problem yet, it's a PROD. After your selection, you can drop dblink

    Respect of
    HELIOS

  • DISPLAY DATA from a REMOTE database

    I use Cold Fusion 5 and Oracle 8i (DB).

    You want to DISPLAY DATA from a REMOTE database.

    I'm familiar with synonyms and links to the database. I've set up a link of database
    access to the machine as the correct user (owner of the procedure). I can run

    "Select * from table1@machine1" and works well in SQLPLUS.

    But when in CF call for select statement the error above is Occur-> ORA-02041: customer database did not begin a transaction


    no idea...? Please

    Using ODBC or native drivers? If ODBC, what version? According to Metalink, Oracle ODBC has a bug that has been fixed in 8.1.5.5.0 the description of the attached problem resembles yours.

    Phil

  • read data from a serial port

    Hello to everyone
    I use oracle forms 6i. I want to read data from a serial port. How can I do this?

    HII,

    You may search for any existing OCX or VBX component capable of doing this job.

    Better compliance
    Skyniazi

  • read data from a database and display them in a listbox

    Hello

    I want to read the data from a table in a database, so I want to display 1 column in a listbox.

    I read the data from database, but I can't display in a listbox control.

    can someone help me please?

    Your VI is way too complicated. If you get a 2D array and you want just the second column, you should only use the Array Index to take off from the second column. That's all.

    Once again, the structure of your sequence is completely useless.

    I will reiterate my statement about to spend some time with the LabVIEW tutorials.

  • get list from a SQL database and create links to each lines in AS3

    I'm doing an AIR application with these conditions:

    I have a SQL database. In my table, there is a column 'categories' (with different categories (computer, books... etc.)).

    enter image description here

    In my AS3, I managed to recover "theDescription" when the user select a category. With the URLMethod and a php file.

       // create SQL $sql = "SELECT * FROM annonces where categorie = '$categorie'";

    $sql_result = mysql_query($sql, $connection) or die ("Couldn't execute query.");

    $num = mysql_numrows($sql_result); $phptheDescription = "";

    $counter = 0;

    while ($row = mysql_fetch_array($sql_result)) {

    $theDescription = $row["theDescription"];

    $phptheDescription = $theDescription;

    }

    echo  "phptheDescription=" . $theDescription;

    So my AS3 code retrieves the $phptheDescription since php and displays in a output_txt .

    Problem: in my output_txt , a 'theDescription"appears. But I have TWO Articles in the category 'Computers' (and I have 100 points in the same categories).

    How do I show all the "theDescription' that are in the same categories?

    Ex: If I choose "Computer", it should display "a Surface Pro 3" and "An IMAC". But it only shows the last element "IMAC".

    And, after that, it is possible to create "links" for each item posted?

    Here are 2 videos of short films (20 sec) explaining my problems:

    https://vid.me/DS2r

    http://sendvid.com/6iesrygk

    THX

    Hi-I've never used PHP so I could be wrong here - but it seems to me you're a loop in the records, each time as reset $theDescription to all that is in the current (rather than accumulate output) record. If you are effctively echo only the last record in the query.

    I think you should be either running the command echo inside your loop, or alternatively the concatenation of a string inside the loop and then echoing the end of the loop?

    I would be likely to generate XML data in PHP (just by concatenating strings) and then use it in my AS3 code.

  • How to load data from ms sql to the by the file rules and maxl essbase

    Hi, everybody!
    Pretty Shure the kind of topic exists already on the forum, but unfortunately can't find it.

    I want to understand, how to load data from the database to ms sql for the PB of essbase application.

    (I) so I have:
    1. a request for 'society '.
    2 and its database 'Plan '.
    3. with simple outline, which contains only two dimensions:

    -The time period < 1 > (Label only)
    -Total year (~)
    -Qtr1 (+)
    Jan (+)
    Feb (+)
    Mar (+)
    -Qtr2 (+)
    APR (+)
    May (+)
    Jun (+)

    -Accounts < 1 > (Label only)
    -Lost / based (~) (Label only)
    -Revenues (+)
    L1.1 (+)
    L1.2 (+)
    -Costs (-)
    L2.1 (+)
    L2.2 (+)

    (II) also, I created a rules file called "CO_DWH" and associated with this schema
    It (Rules file) a 3 columns:
    Data of the 'period', 'account '.

    There is also the option checked "load data".

    (III) in MS SQL Server, I have a database of "hypdb" and "essadmin" with "password" login

    (IV) I executed my bat file:
    C:\Hyperion\EssLoad.bat
    There is only one line:

    EssLoad.bat-
    startMaxl.cmd EssLoad.txt
    ----------------------------------------------

    EssLoad.txt-
    login password admin on erpserver;
    Import database data Company.Plan connect in essadmin password using the server rules_file 'CO_DWH' error abort;
    disconnection;
    "exit";
    --------------------------------------------


    All plans that I copied well worked ERP system, but I don't understand, this is exactly table in the MS SQL database, data loading to essbase db?

    TOU have to do a few things
    1. on the server of Essbase, put in place a system odbc for your MySQL database connection
    2. in the State of charge, go to the file menu and select open source SQL database and in the source of data in your SQL statement. A few tips. Where it says select, don't put in the select Word and when he says to not put in of. The system adds for you. TI enter a simple SQL statement is to do this in the box so select if your SQL would be normanlly as select * from myTable just enter the code as * from myTable in the upscale neighborhood

    The ol/recover the click and fill your connection information. Should bring back the data in the State of charge. Save the State of charge and use

Maybe you are looking for

  • Lenovo OneKey Recovery for Windows 7 64 bit does not work

    Someone at - it a patch or a new release for Lenovo OneKey Recovery link? I recently bought a G450 and Win 7 Ultimate 64 bit separately, there is no link available in the support and download under this model page yet. I tried to install the 64-bit v

  • Blue Cup

    OK, I've seen these market under the names of peoples, why do these mean?

  • Finger undetected, even if the stylus is detected

    For my ThinkPad 2, I got just back from the centre of repair official, all of a sudden the touch screen do not read any finger touches or slips etc. at all. Simply enter my digitaliseur pen. Any thoughts?

  • FPGA open file reference difference calling bitstream or VI?

    Is there a difference in the behavior of the open FPGA Reference when you set it to look the VI against the bitstream file? Everything on different behind the scenes?  He link to the same bitstream file when you point to the VI? Thanks for the idea.

  • Cannot fix my system with KB2160329

    OS: Windows 7 Ultimate 32 bit Trying to patch on the system with KB2160329 (via automatic update) Running in 800 b unknown error code 0100. To search internet gave nothing useful for Windows 7. Started the system in Mode safe mode with disabled anti-