String concatenation without loop

Hello

I have an array of strings containing numbers in engineering as format below:

5.34000E - 10

3.23245E - 1

-8.43560E - 9

I'm trying to concatenate to this array of strings to a header, which is a unique, formed string using the string concatenation function.  So, I would that my output as follows:

Header line 1

Header line 2

Row header 3

5.34000E - 10

3.23245E - 1

-8.43560E - 9

However, the result is currently reads:

Header line 1

Header line 2

Row header 3

5.34000E - 103.23245E - 1 - 8.43560E - 9

I can get the desired result using a loop for, but I do not like concatenate them strings function seems to run very slowly in the loop.  Is there a way I can get the desired result without using a loop for?

Thank you.

It is a real possibility that concatenate strings runs slowly in a loop For. change the statement "I find that Array Build runs slowly in a for loop" and we would get a serious discussion of fly memory. Absolutely no difference here, maybe even worse because the strings are more difficult to predict than most data types. There is perhaps not a miracle solution to make it faster, but there might be ways to ensure there are no longer than necessary. I probably just build the header as its own array of channels and build table allows to reach the two (concatenate entries of course). Writing to text file will manage an array of strings directly when the time comes.

Tags: NI Software

Similar Questions

  • String concatenation and put into registry to offset slowing computer

    Hi all

    I tried to create a record of comms between LabVIEW and an Arduino by concatenating the current message with previous posts and put in a shift register.  After a few hours the LabVIEW began to crawl.

    I had a vague idea that you could write a string indicator without wiping the old content.  I thought that if I could do that is there not a huge overload copy all a larger string.

    Am I dreaming?

    Thank you

    If you need registration integer comm I would say the comms streaming the file.  Make sure you put a Boolean value in to turn off logging.

    Usually, it's one of those things you just do everything in debugging.  If so use OR spy rather than writing your own debugger.

  • How to use the platform of character even in the same scene several backgrounds without looping the platform of character chronology

    How to use the platform of character even in the same scene several backgrounds without looping chronology of the platform of character? Is it still possible without having to do the scene with another background on another file? To better explain the situation, I have a flash file which has a background and a rig which passes to another context and drilling on another layer and keyframe, but when I go back to the previous background and chronology of this drilling rig repeats, rather than leave, you are doing a new time for this platform. Do I need more than one file?

    In order to reuse assets to animate, you need to duplicate each symbol in the scene who will be the new animation. So, copy and paste the stage on a new layer, right-click on it and select double symbol, then double-click inside the symbol and select each symbol that is going to change, so that the background and the rigging and also select symbol duplicated for those files as well. usually, when I animation I do not use the main platform in the scenes, duplicate as 'Guy1_sc 1', then place it in the scene so that the path I never uses the master file. 'Guy1_sc 2' is a different file. Also if you lipsync and stalled the head separately you will need to reproduce, so, for each scene, is also unique. I hope this makes sense.

  • Fusion of multiple lines in a string without loop

    Hello

    Wanted to know if there is a way we can merge the result set for a query (single column) in a string?
    For example, I have the following query, which returns many rows:

    SELECT organization_code
    OF mtl_parameters
    WHERE oganization_id IN (1,2,3)

    Lets say the result set for this is:
    A
    B
    C

    I want data such as A, B, C

    Basically I will be get the organization_ID leave a void diff request. I know that I can do this by using the loop and keep adding the values.
    But I wanted to know if there is an easier way to do it.

    Hello

    You are looking for the aggregation of the chain.
    Many examples on this forum and a good summary here:
    http://www.Oracle-base.com/articles/Misc/StringAggregationTechniques.php

  • concatenation of strings automatically for loop

    Hello

    Anyone know why it does not work?

    Best regards

    Thijs

    Hey Taylor,

    "the error of the broken wire is quite unique: incompatible" matrices "connect...".

    The help mentions that the paintings to be connected by a tunnel to exit. Scalars strings are not mentioned anywhere!

    This is the way "traditional":

    ConcatStrings allows you to concatenate an array of strings into a single string.

  • With the help of strings concatenated in the Structure of the case

    Hello world

    I'm all new to LabView. Right now, I just trying to build a graphic program of different waves (such as the sine or square) with or without different types of noise. I concatenated two strings and then participating in a housing structure. Nothing graphic when have two concatenated options, but it does not work when it's just the different types of wave are chosen. I think it might have to do with how I'm the each case titration structure option, but I'm not sure. For any help or suggestion is greatly appreciated.

    I would use a sequence of structures of the case. Take it step by step. Use enumerations for readability.

  • Why the operator: = is not working when it is in a string concatenated and assigned to a variable?

    I met with an error ORA-00904: "V_DEPTNO": online: 14 (My PL/SQL code is below), while playing with the cursor of reference (for the end of the apprenticeship).
    I debugged it and the problem was solved and it returns the desired output.  However, the solution of it is not sensible for me even if the output
    has been posted/successfully recovered.    Here's a clearer description of the code:


    On line 14, I have a variable called stmt and stmt value concatenated with the string "where deptno =: v_deptno' and then finally assigned to this stmt variable."

    In this line, he returned ORA-00904 but it was fixed by using =: operator instead of the = operator.

     stmt:=stmt || 'where deptno=:v_deptno'; 
    

    In sql pure when it is intended to add where clause for such purpose, the = comparison operator is used.
    Example:

    Select empno,ename,sal from emp where deptno=10;
    

    But in my pl/sql code, =: operator was used.

    Why is this? Can someone explain what it is? Even if I did my research, but I couldn't find the explanation yet.

    All what I've understood so far, is that this may mean the following (I may be wrong):
    1 - everything first, assign the value 10, of v_deptno, who was declared, to easily compare.
    2. compare the value assigned with deptno.
    On this basis, recover data.


    Thus, he worked as a = + tour operator defined in another high programming language such as c#... etc.
    Example:

    int a = 0;
    
    a =+ 1;    //  a was declared as an integer that has value 0
            // then  we tried to increment by 1 or add by one
             // so it would be  a=a+1;  
                    //which is  a=0+1;
    

    It works the same?

    Here's my complete code pl/sql, just in case...

    --ref cursor
    declare 
    
    type emp_refcur  is ref cursor;
    emp_cv emp_refcur;
    emprec emp%rowtype;
    stmt varchar2(299):= 'select * from emp';
    v_deptno number:=10;
    
    begin
    
    if v_deptno is null then
      open emp_cv for stmt;
    
    else
      stmt:= stmt || ' where deptno=:v_deptno';
      open emp_cv for stmt using v_deptno;
    end if;
    
    loop
    fetch emp_cv into emprec;
    exit when emp_cv%notfound;
    dbms_output.put_line(emprec.empno||chr(9)||emprec.ename||chr(9)||emprec.deptno);
    end loop;
    close emp_cv;
    end;
    /
    
    
    
    
    
    
    
    

    I would you to explain and share with me something to read or give me some clues.

    Thanks in advance!

    In this line, he returned ORA-00904 but it was fixed by using =: operator instead of the = operator.

    There is no "=:" operator.

    The colon character ': ' is used to define a binding (placeholder) variable in the query string.

    The value of this variable must be passed ("linked") after analysis and run step so that the query is executed correctly. That's what the USING clause in your code.

    Thus, he worked as a = + tour operator defined in another high programming language such as c#... etc.

    Example:

    1. int a = 0;
    2. a = + 1;    one has been declared as an integer that is set to 0
    3. then we tried to increment by 1 or add one
    4. so it would be a = a + 1;
    5. which is a = 0 + 1;

    It works the same?

    No, nothing to do with it.

  • Filling N-dimensional table without loop for

    Hello

    I would like to create a table to N dimensions without the use of loops, one in other than n times because I would like to have the number of variable dimensions, so I don't want to change the code by adding or removing loops whenever I change the number of dimensions. I would like to start Let's say with 7 dimensions 10x10x10x10x10x15x20.

    Thank you

    Zied


  • Newbie need help with string concatenation function.

    I'm totally new to LabView and am trying to work on a project that someone worked in the past.  I came to a string function concatenated on one of the existing provisions and only seen on some entries of the string function has an order of 'rel' and 'g '.  I don't know if it's a common command or what it is.  This is VI is that it requires a user to enter a base dimension (x-axis starting point and end point) and executes the steps in the sample desired within the "point of departure" and "end point".  "a3" is the name of the x-axis.  but I'm not sure of the meaning 'rel' and 'g '.  I posted part of the diagram.  Any help would be appreciated.  Thank you!

    This isn't a question of LabVIEW, but very specific to the device connected to the other end of the serial port. Do you have any documentation for it?

    Basically, the program needs form a consiting of command of a delimiter character, value and end of key word, etc. for example.

    Who wrote this program. It seems too complex and convoluted. Under certain conditions, it seems to send two commands at the same time, and there is no way to determine the order in which they run. Maybe it doesn't matter, but maybe it does. Most likely, what you need is a single structure dealing with a case for each condition and a unique series in the end writing. You can reach the actual program? There are also a lot of duplicate code. What is the purpose of the operations 1 x? Is this a Subvi?

  • String concatenation and vi speed

    I'm trying to convert data waveform .tdms in ASCII file in a particular format in order to be read by other software. The vi that I wrote (attached) is capable of doing the job but at a very slow pace. The vi in takes about 20 minutes to complete one a second data (22050 samples). This American too slow because I intend to work with waveform data at 1.5 million samples (it takes 16 hours). I think that the problem is due to the the string concatination. Does anyone has any suggestion how I can improve on this performance of vi with regard to its speed. Thank you.

    LabVIEW 2011 running on a laptop Windows 7 (i5 2.50 GHz with 8 G of RAM)

    Sorry for this question.  I had solved after removing the 'wait until the next multiple ms' vi from the iteration of the loop.

  • String concatenation with a new line

    Hey,.

    I'm doing something that I considered quite simple but hit a few problems.  I'm looping through an array of strings and concatenting them with a new line separator and put the result to the Clipboard string so that it can then be pasted into a field. The problem is what is the sign of a new line separator?  I tried:

    « \n »

    '\r' + '\n'

    « \n »

    System.getProperty ("line.separator");

                  String txtToPaste = "";
                    String eol = System.getProperty("line.separator");
                    for (int entryIndex = 0; entryIndex < entries.length; entryIndex++) {
                        txtToPaste += entries[entryIndex];
                        // if we are not the last entry then add a new line
                        if (entryIndex < entries.length) {
                            txtToPaste += eol;
    
                        }
                    }
    

    What is the right way to build a string with newlines inside?

    Thank you.

    something like txtToPaste = entries [entryIndex] + "\n"; might solve your problem.

  • log in - help sql: error ORA-01489: string concatena result

    Here's a sql query and I am cooking a decoding, but since there are several columns invloved when I try to run it I get the following error:
    ORA-01489: result of concatenating string is too long

    Any kind of help is appreciated, I need to get it going or I'm dead :(

    Concerning
    Rahul



    SQL:
    Select sys_connect_by_path(c.decode_prep,'-') decode_prep
    from (select "DECODE (BIAPPS_11.'|)") substr (b.all_cols, InStr(b.all_cols,',',1,a.RN) + 1, InStr(b.all_cols,',',1,a.RN+1)-InStr(b.all_cols,',',1,a.RN)-1). «, » ||' RAHULKALRA.' | substr (b.all_cols, InStr(b.all_cols,',',1,a.RN) + 1, InStr(b.all_cols,',',1,a.RN+1)-InStr(b.all_cols,',',1,a.RN)-1) |', "1", "0")' decode_prep, rownum curr, prev rownum-1
    from (select rownum rn
    Double connect rownum < =.
    (select (length('ROW_WID,COST_CENTER_NUM,COST_CENTER_NAME,COST_CENTER_DESC,CONTROL_AREA_NUM,CONTROL_AREA_NAME,CATEGORY_CODE,CATEGORY_NAME,CATEGORY_DESC,MANAGER_NAME,CURRENCY_CODE,CURRENCY_NAME,LANGUAGE_CODE,LANGUAGE_NAME,ST_ADDRESS1,ST_ADDRESS2,POST_OFFICE_BOX,CITY_NAME,STATE_CODE,STATE_NAME,REGION_CODE,REGION_NAME,COUNTRY_CODE,COUNTRY_NAME,POSTAL_CODE,PHONE_NUM,FAX_NUM ,CSCN_HIER1_CODE,CSCN_HIER1_NAME,CSCN_HIER2_CODE,CSCN_HIER2_NAME,CSCN_HIER3_CODE,CSCN_HIER3_NAME,CSCN_HIER4_CODE,CSCN_HIER4_NAME,CSCN_HIER5_CODE,CSCN_HIER5_NAME,CSCN_HIER6_CODE,CSCN_HIER6_NAME,ACTIVE_FLG,CREATED_BY_WID,CHANGED_BY_WID,CREATED_ON_DT,CHANGED_ON_DT,AUX1_CHANGED_ON_DT,AUX2_CHANGED_ON_DT,AUX3_CHANGED_ON_DT ,AUX4_CHANGED_ON_DT,SRC_EFF_FROM_DT,SRC_EFF_TO_DT,EFFECTIVE_FROM_DT,EFFECTIVE_TO_DT,DELETE_FLG,CURRENT_FLG,W_INSERT_DT,W_UPDATE_DT,DATASOURCE_NUM_ID,ETL_PROC_WID,INTEGRATION_ID,SET_ID,TENANT_ID,X_CUSTOM')
    - length(replace('ROW_WID,COST_CENTER_NUM,COST_CENTER_NAME,COST_CENTER_DESC,CONTROL_AREA_NUM,CONTROL_AREA_NAME,CATEGORY_CODE,CATEGORY_NAME,CATEGORY_DESC,MANAGER_NAME,CURRENCY_CODE,CURRENCY_NAME,LANGUAGE_CODE,LANGUAGE_NAME,ST_ADDRESS1,ST_ADDRESS2,POST_OFFICE_BOX,CITY_NAME,STATE_CODE,STATE_NAME,REGION_CODE,REGION_NAME,COUNTRY_CODE,COUNTRY_NAME,POSTAL_CODE,PHONE_NUM,FAX_NUM ,CSCN_HIER1_CODE,CSCN_HIER1_NAME,CSCN_HIER2_CODE,CSCN_HIER2_NAME,CSCN_HIER3_CODE,CSCN_HIER3_NAME,CSCN_HIER4_CODE,CSCN_HIER4_NAME,CSCN_HIER5_CODE,CSCN_HIER5_NAME,CSCN_HIER6_CODE,CSCN_HIER6_NAME,ACTIVE_FLG,CREATED_BY_WID,CHANGED_BY_WID,CREATED_ON_DT,CHANGED_ON_DT,AUX1_CHANGED_ON_DT,AUX2_CHANGED_ON_DT,AUX3_CHANGED_ON_DT ,AUX4_CHANGED_ON_DT,SRC_EFF_FROM_DT,SRC_EFF_TO_DT,EFFECTIVE_FROM_DT,EFFECTIVE_TO_DT,DELETE_FLG,CURRENT_FLG,W_INSERT_DT,W_UPDATE_DT,DATASOURCE_NUM_ID,ETL_PROC_WID,INTEGRATION_ID,SET_ID,TENANT_ID,X_CUSTOM',',')))+1 total_cols
    the double)), (select ',' |') ROW_WID,COST_CENTER_NUM,COST_CENTER_NAME,COST_CENTER_DESC,CONTROL_AREA_NUM,CONTROL_AREA_NAME,CATEGORY_CODE,CATEGORY_NAME,CATEGORY_DESC,MANAGER_NAME,CURRENCY_CODE,CURRENCY_NAME,LANGUAGE_CODE,LANGUAGE_NAME,ST_ADDRESS1,ST_ADDRESS2,POST_OFFICE_BOX,CITY_NAME,STATE_CODE,STATE_NAME,REGION_CODE,REGION_NAME,COUNTRY_CODE,COUNTRY_NAME,POSTAL_CODE,PHONE_NUM,FAX_NUM,CSCN_HIER1_CODE ,CSCN_HIER1_NAME,CSCN_HIER2_CODE,CSCN_HIER2_NAME,CSCN_HIER3_CODE,CSCN_HIER3_NAME,CSCN_HIER4_CODE,CSCN_HIER4_NAME,CSCN_HIER5_CODE,CSCN_HIER5_NAME,CSCN_HIER6_CODE,CSCN_HIER6_NAME,ACTIVE_FLG,CREATED_BY_WID,CHANGED_BY_WID,CREATED_ON_DT,CHANGED_ON_DT,AUX1_CHANGED_ON_DT,AUX2_CHANGED_ON_DT,AUX3_CHANGED_ON_DT,AUX4_CHANGED_ON_DT SRC_EFF_FROM_DT , SRC_EFF_TO_DT, EFFECTIVE_FROM_DT, EFFECTIVE_TO_DT, DELETE_FLG, CURRENT_FLG, W_INSERT_DT, W_UPDATE_DT, DATASOURCE_NUM_ID, ETL_PROC_WID, INTEGRATION_ID, SET_ID, TENANT_ID, X_CUSTOM' | (',' double all_cols) b) c
    Start by curr = 1
    Connect prior curr = prev
    length (sys_connect_by_path(c.decode_prep,'-')) desc order

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

    same as above sql only the difference is here I'm pulling the first record in the result set that top query returns:

    Select ltrim (replace(decode_prep,'-','||'),'| ') decode_prep
    of (sys_connect_by_path(c.decode_prep,'-') select decode_prep)
    from (select "DECODE (BIAPPS_11.'|)") substr (b.all_cols, InStr(b.all_cols,',',1,a.RN) + 1, InStr(b.all_cols,',',1,a.RN+1)-InStr(b.all_cols,',',1,a.RN)-1). «, » ||' RAHULKALRA.' | substr (b.all_cols, InStr(b.all_cols,',',1,a.RN) + 1, InStr(b.all_cols,',',1,a.RN+1)-InStr(b.all_cols,',',1,a.RN)-1) |', "1", "0")' decode_prep, rownum curr, prev rownum-1
    from (select rownum rn
    Double connect rownum < =.
    (select (length('ROW_WID,COST_CENTER_NUM,COST_CENTER_NAME,COST_CENTER_DESC,CONTROL_AREA_NUM,CONTROL_AREA_NAME,CATEGORY_CODE,CATEGORY_NAME,CATEGORY_DESC,MANAGER_NAME,CURRENCY_CODE,CURRENCY_NAME,LANGUAGE_CODE,LANGUAGE_NAME,ST_ADDRESS1,ST_ADDRESS2,POST_OFFICE_BOX,CITY_NAME,STATE_CODE,STATE_NAME,REGION_CODE,REGION_NAME,COUNTRY_CODE,COUNTRY_NAME,POSTAL_CODE,PHONE_NUM,FAX_NUM ,CSCN_HIER1_CODE,CSCN_HIER1_NAME,CSCN_HIER2_CODE,CSCN_HIER2_NAME,CSCN_HIER3_CODE,CSCN_HIER3_NAME,CSCN_HIER4_CODE,CSCN_HIER4_NAME,CSCN_HIER5_CODE,CSCN_HIER5_NAME,CSCN_HIER6_CODE,CSCN_HIER6_NAME,ACTIVE_FLG,CREATED_BY_WID,CHANGED_BY_WID,CREATED_ON_DT,CHANGED_ON_DT,AUX1_CHANGED_ON_DT,AUX2_CHANGED_ON_DT,AUX3_CHANGED_ON_DT ,AUX4_CHANGED_ON_DT,SRC_EFF_FROM_DT,SRC_EFF_TO_DT,EFFECTIVE_FROM_DT,EFFECTIVE_TO_DT,DELETE_FLG,CURRENT_FLG,W_INSERT_DT,W_UPDATE_DT,DATASOURCE_NUM_ID,ETL_PROC_WID,INTEGRATION_ID,SET_ID,TENANT_ID,X_CUSTOM')
    - length(replace('ROW_WID,COST_CENTER_NUM,COST_CENTER_NAME,COST_CENTER_DESC,CONTROL_AREA_NUM,CONTROL_AREA_NAME,CATEGORY_CODE,CATEGORY_NAME,CATEGORY_DESC,MANAGER_NAME,CURRENCY_CODE,CURRENCY_NAME,LANGUAGE_CODE,LANGUAGE_NAME,ST_ADDRESS1,ST_ADDRESS2,POST_OFFICE_BOX,CITY_NAME,STATE_CODE,STATE_NAME,REGION_CODE,REGION_NAME,COUNTRY_CODE,COUNTRY_NAME,POSTAL_CODE,PHONE_NUM,FAX_NUM ,CSCN_HIER1_CODE,CSCN_HIER1_NAME,CSCN_HIER2_CODE,CSCN_HIER2_NAME,CSCN_HIER3_CODE,CSCN_HIER3_NAME,CSCN_HIER4_CODE,CSCN_HIER4_NAME,CSCN_HIER5_CODE,CSCN_HIER5_NAME,CSCN_HIER6_CODE,CSCN_HIER6_NAME,ACTIVE_FLG,CREATED_BY_WID,CHANGED_BY_WID,CREATED_ON_DT,CHANGED_ON_DT,AUX1_CHANGED_ON_DT,AUX2_CHANGED_ON_DT,AUX3_CHANGED_ON_DT ,AUX4_CHANGED_ON_DT,SRC_EFF_FROM_DT,SRC_EFF_TO_DT,EFFECTIVE_FROM_DT,EFFECTIVE_TO_DT,DELETE_FLG,CURRENT_FLG,W_INSERT_DT,W_UPDATE_DT,DATASOURCE_NUM_ID,ETL_PROC_WID,INTEGRATION_ID,SET_ID,TENANT_ID,X_CUSTOM',',')))+1 total_cols
    the double)), (select ',' |') ROW_WID,COST_CENTER_NUM,COST_CENTER_NAME,COST_CENTER_DESC,CONTROL_AREA_NUM,CONTROL_AREA_NAME,CATEGORY_CODE,CATEGORY_NAME,CATEGORY_DESC,MANAGER_NAME,CURRENCY_CODE,CURRENCY_NAME,LANGUAGE_CODE,LANGUAGE_NAME,ST_ADDRESS1,ST_ADDRESS2,POST_OFFICE_BOX,CITY_NAME,STATE_CODE,STATE_NAME,REGION_CODE,REGION_NAME,COUNTRY_CODE,COUNTRY_NAME,POSTAL_CODE,PHONE_NUM,FAX_NUM,CSCN_HIER1_CODE ,CSCN_HIER1_NAME,CSCN_HIER2_CODE,CSCN_HIER2_NAME,CSCN_HIER3_CODE,CSCN_HIER3_NAME,CSCN_HIER4_CODE,CSCN_HIER4_NAME,CSCN_HIER5_CODE,CSCN_HIER5_NAME,CSCN_HIER6_CODE,CSCN_HIER6_NAME,ACTIVE_FLG,CREATED_BY_WID,CHANGED_BY_WID,CREATED_ON_DT,CHANGED_ON_DT,AUX1_CHANGED_ON_DT,AUX2_CHANGED_ON_DT,AUX3_CHANGED_ON_DT,AUX4_CHANGED_ON_DT SRC_EFF_FROM_DT , SRC_EFF_TO_DT, EFFECTIVE_FROM_DT, EFFECTIVE_TO_DT, DELETE_FLG, CURRENT_FLG, W_INSERT_DT, W_UPDATE_DT, DATASOURCE_NUM_ID, ETL_PROC_WID, INTEGRATION_ID, SET_ID, TENANT_ID, X_CUSTOM' | (',' double all_cols) b) c
    Start by curr = 1
    Connect prior curr = prev
    length (sys_connect_by_path(c.decode_prep,'-')) desc order)
    where rownum = 1

    Published by: Mac_Freak_Rahul on November 28, 2012 01:31: in the first sql ')'
    removed after desc in the last line so now this query begin and will throw an error.

    Mac_Freak_Rahul wrote:
    @Blushadow:

    (1) first of all, I'm sorry for not posting my question according to the rules of the forum, next time I'll take care of that.
    (2) Secondly, thanks for the solution, I have no exp with clob, but I can take a deeper look later.
    (3) I just want to know if there are any other wayout, you mean the second concatenation of 4000 bytes sys_connect_by_path exhausts it might return this error?

    SYS_CONNECT_BY_PATH returns a VARCHAR2 data type. In SQL VARCHAR2 data type is limited to 4000 bytes, then Yes, you will get an error if the data that you generate is greater than 4000 bytes (and I say bytes rather than characters, because if your database uses a multibyte multi character set could be as little as 1000 characters)

    I'm right now stable for a table who got 62 columns... I have tables that have 200 close passes: (, great, if you can throw some light on this, if your the best way and the only one to achieve?)

    If you really need to concatenate strings together which exceeds 4000 bytes, then Yes you must use CLOB to store data. Oracle does not provide a native way to aggregate together in a CLOB datatype string, so why you need to write your own function.

    PS: just a quick overview of my value, it will be by comparing schema1.table (s) with shema2.table (s) where table_name must be the same...

    So why are you information concatenation together to achieve this goal?

  • Why ColdFusion adds the backslashes to my string concatenated?

    Well, serializeJSON isn't enough create JSON for me to use with jQuery.

    So I decided to build it myself.

    Here is my code:

    <cffunction name="getActions" output="false" access="remote" returnformat="JSON">
        <cfquery name="Actions">
          SELECT * FROM Actions
        </cfquery>
        <cfset ActionsList = '{"success" : "true"}, {"Actions" : ['>
        <cfloop query="Actions">
          <cfset ActionsList = ActionsList & '{ "ID" : "' & ID & '", "Name" : "' & Name & '"},'>
        </cfloop>
        <cfset ActionsList = ActionsList & ']}'>
        <cfreturn ActionsList>
      </cffunction>
    

    So basically I send an asynchronous call AJAX with jQuery to the cfc that contains this code.

    jQuery told me that the JSON was bad.

    So I pulled out what Coldfusion has been sending to the browser.

    "{\"success\":\"true\"},{\"Actions\":[{\"ID\":\"1\",\"Name\":\"View Public\"},{\"ID\":\"2\",\"Name\":\"View Full\"},{\"ID\":\"3\",\"Name\":\"Create Page\"},
    {\"ID\":\"4\",\"Name\":\"Create Part\"},{\"ID\":\"5\",\"Name\":\"Create Section\"},{\"ID\":\"6\",\"Name\":\"Create Question\"},{\"ID\":\"7\",\"Name\":\"Create Table\"},
    {\"ID\":\"8\",\"Name\":\"Assign Pages to Location\"},{\"ID\":\"9\",\"Name\":\"Input Data\"},{\"ID\":\"10\",\"Name\":\"Edit Page\"},{\"ID\":\"11\",\"Name\":\"Edit Part\"},
    {\"ID\":\"12\",\"Name\":\"Edit Section\"},{\"ID\":\"13\",\"Name\":\"Edit Question\"},{\"ID\":\"14\",\"Name\":\"Edit Table\"},
    {\"ID\":\"15\",\"Name\":\"Assign Pages to Location Type\"},{\"ID\":\"16\",\"Name\":\"Add Location\"},{\"ID\":\"17\",\"Name\":\"Add Location Type\"},
    {\"ID\":\"18\",\"Name\":\"Change Location\"},{\"ID\":\"19\",\"Name\":\"Assign Location Designee\"},{\"ID\":\"20\",\"Name\":\"Assign District Designee\"},
    {\"ID\":\"21\",\"Name\":\"Update User Information\"},{\"ID\":\"22\",\"Name\":\"Add User Type\"},{\"ID\":\"23\",\"Name\":\"Manage Permissions\"},]}\""
    

    Why coldfusion adds a bar backslash before each quotation mark?

    I built the exact way of sam JSON in another function, and it worked fine.

    The only difference between this function and this one is that it has a loop.

    I've been at this for hours... what Miss me?

    and replace(ActionsList,"\","","ALL")

    does not help...

    You're not perform a JSStringFormat() on that anywhere, are you?  (maybe in the code not released).  JSStringFormat() assumes that the text passed to it is a literal string, and then he escaped values in quotes (as we see here)

    In addition, on either said by the way, your JSON data is not valid, no?

    Your loop will update the list of actions with a table, but it always takes into account there is another index of values, so it did precede the comma.  {[{You can even see in the final version of your data table ends with a '...},]}' you may need to make a conditional test to see if the loop is at its max index and if not, then add the comma.

  • Select all the paragraphs of a certain style without looping

    Did a quick search, so please forgive me if this is a duplicate.

    paragraphs var = app.activeDocument.textFrames.everyItem ().paragraphs.everyItem ();

    Is it possible to points of reference with a certain style applied without a loop in each paragraph?

    I am thinking something like this:

    Var headlines = paragraphs.itemsByAppliedParagraphStyle ("title 1");

    Headlines is an array of the paragraph, all which have the "Heading 1" paragraph style applied to them

    Thanks for any help you can provide.

    Just use findGrep or findText like this

    app.findGrepPreferences = null
    app.findGrepPreferences.appliedParagraphStyle = "Headline 1"
    myHeadlineParagraphs = app.activeDocument.findGrep()
    

    Trevor

  • Oracle database connection string lite without using odbc.ini

    I am trying to connect to a database without using odbc.ini. It is my code below, can you see anything wrong with it? Its written in c# in VS 2005.

    conn = new OracleConnection (@"DataDirectory = c:\oraclelite;") Database = cabletesting; DSN = *. UID = system; pwd = manager")

    Hello

    If you use the ADO .NET OLITE 10 gr 2 or R3, you can touch the Bug.7430720 (11) CONNECTION is NOT ESTABLISHED during the USE of DSN LESS CONNECT STRING IN 10 G R3 ADO.NET

    The same connection works very well with TEENAGER 10GR 1 .NET

    Unfortunately, there is no work around except to use the chain of DNS.

    Kind regards.
    MArc

Maybe you are looking for

  • Looksafe Yahoo search result

    My address bar would take me to Google before, but now it redirects to yahoo, I have no addons except adblock and I ran, various programs to attempt to clean my PC, including malware bytes, adwcleaner, junkware removal tool, even the searchreset for

  • Packed library in exe

    I'm building an executable that takes advantage of its controls from a packed library.  It works very well in the development environment, but when I create the executable file and distribute it to our network, it is more controls in the packed libra

  • Problem installing Windows

    I am currently running Windows Vista 32-bit, and I try to install Windows Vista 64 bit, but I get an error message saying "Setup cannot run this version of the operating system." To install Windows please try to boot from the installation media. "How

  • I can't delete files in Access Point 1602 ROMMON mode

    Hello: I want to know if it is possible to remove files or directories that are currently allocated in the flash memory. As you can see in the following output, I'm in ROMMON mode and one of the images cannot start propoerly. AP: dir flash:Directory

  • Smartphone blackBerry, removing contacts and email accounts

    Hello I just got a Blackberry 8300 from a colleague who has left the company. Is there a quick way to remove their phone contacts & address SIM on mass books? It's excruciating duty doing one by one! I also have the same problem with having to remove