Urgent : Move String data to Dec variable

iam working in CRM application
I have updating a table with new createddata and time. The table has CRMD_ORDERADM_H table has a field CREATED_AT whose datatype is DEC15. In the database table the value is stored as "01/14/2003 12:24:53"
Now i need to change this data in the program. iam concatenating the date and time into a string trying to pass into the variable L_CREATED of type CRMD_ORDERADM_H-CREATED_AT, i get a dump.
There are no convertion routines for this in CRM. Can someone suggest me workaround.
Thanks,
Suri

Hi Suri,
I'm not working on CRM system right now. I remember the timestamp has a conversion exit and what you see is the external representation. The field is conected to domain COM_TSTMP. Here you have conversion exit TSTLC.
This means you have to call function CONVERSION_EXIT_TSTLC_INPUT to convert to the internal representation.
Regards,
Clemens

Similar Messages

  • The "write key" configurat​ion file vi use of "trim string" prior to writing the data can modify any string data written.

    I tried to use the config VIs to record some front-panel settings for later restoration, one of which could be a single space character (part of a string parsing system).
    I soon discovered that whenever I tried to save that single-space value to an INI file, only a null string was saved.
    After doing some digging I discovered that buried in the Write Key vi is a worker vi called Config Data Modify that uses Trim String on the string data before it is written to the file and that's what was eating my string character. I don't know whether this is a bug or a feature but there are at least three ways to fix it.
    1) Assuming you want to leave the library VIs alone, you can pre-process any stings sent to "write key" to replace all spaces with "\20" and then post-process all strings read using "read key" to replace all instances of \20 with spaces.
      and if you don't mind modifying the library VIs, either to save/use under a different name or to stick back into the library in a modified state (caution - can cause problems when you move code to another machine with an un-modified library) then...
    2) You can yank the trim-string out of the Config Data Modify vi and hope that it does not have any undesirable side effects with regards to the other routines that use Config Data Modify (so far I have not found any in my limited testing)
    or
    3)  You can modify the string pre-processing vi, Remove Unprintable Chars, to add the space character to the list of characters that get swapped out automatically.
    Note that both option #1 (as suggested above) and option #3 will produce an INI file data entry that looks like    key="\20Hello\20World\20"   while option #2 produces an entry that looks like   key=" Hello World "
    The attached PDF contains screenshots of all this.
    Attachments:
    Binder1.pdf ‏2507 KB

    Hi Warren,
    there's a 4th option:
    Simply set the "write raw string" input of the write key function to TRUE
    This option only appears when a string is wired to that function!
    Just re-checked:
    I think it's a limitation of the config file format. It's text based and (leading) spaces in the value are "overseen" as whitespaces. So your next option would be to use quotes around your string with spaces...
    Message Edited by GerdW on 05-02-2009 08:32 PM
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • How to get data type of variable in program..

    Hi ABAP Guru.
    I need to know how to get data type of variable or any structure field.. because I got short dump when use command REPLACE ALL OCCURANCE ... with variable/structure field that has data type I or P, I think it should be used with data type CHAR only, So I need to check the data type first.
    Please give me your advice
    Thank you all.
    Nattapash C.

    data : v_value type i,
             v_char(10) type c.
    v_value = 10.
    move v_value to v_char.
    REPLACE ALL OCCURRENCES of '#' from v_char....
    Best regards,
    Prashant

  • How to calculate a renters move out date?

    Hi all, I have been working on a spreadsheet that helps me to calculate residents rent.
    attached is a screen shot of where I am up to
    You will see that I am trying to make the spreadsheet automate how much is owed depending on when someone has moved in or out.
    It is proving tricky mainly because the billing cycles start on the 15th of the month not the 1st.
    2 problems. In the peach coloured cells, You will see a problem with my move out formulas. in F4 of the bottem left table 'rent charged', 'Christop' has moved out on November 12 2011. The move out extra column in the top table, shows that Christop owes an additional amount for octobers rent, yet, he is still being charged for oct, nov, and dec in entirety. If I have someone move out, how can I get the main table to stop charging them those months?
    Can I use the column i've added called 'tick if tenant moves out' to trigger something?
    the other problem, in the green cells, is that these amount need to be negative.
    The numbers are the amount from jan 1 2012 to jan 14 2012, so seeing as this table is about 2011, they should be in negative, as the tenants have been charged the full cycles amount on dec 15.
    So maybe January needs another cost added on Jan 1st, representing the first 14 days of the year, and December charges less on Dec 15 charging only for the rest of december,
    The way we got this working for the move in fraction, when someone moves in after Jan 1st, is the following.
    =IF(LEN($A2)>0,IF($A2>=LOOKUP(D$1,Resi info for rent :: $Tenant,First billing cycle of year for tenant),LOOKUP(D$1,Resi info for rent :: $Tenant,Resi info for rent::$Rent),""),"") Perhaps a variation of this will sort out the 'peach' issue.
    I know I am coming at this from wierd angles, I don't have any experience on Numbers before this, so its getting tangled quickly.
    thanks to any who can help!
    Evan

    Xen Ochren wrote (ex forum):
    "The first (error) is created by changing Matts move in date, or 'first date of year tenant stayed' I get the error 'argument 1 must be no bigger than argument 2' in extra days owed B6."
    The error message is pretty much self explanatory.
    Column D is the move in date, Column E is the start of the "first (full) Billing Cycle of the year" for this tenant. Matt's dates are highlighted. In all the other rows, the column E value (second argument) is the first 'fifteenth' following the move in date in column D; a 'bigger' date than the move in date. In Matt's case, the column E value is the most recent 'fifteenth' before Matt's move in date, a 'smaller' date than the move in date.
    Set Matt's billing cycle date to Aug 15, 2011 and the error message disappears.
    You can avoid this type of error by using a formula to calculate the start date of the first full billing cycle from the move in date:
    =DATE(YEAR(D),MONTH(D)+IF(DAY(D)>15,1,0),15)
    Enter into E2 of table RiR and fill down to the row for the last tenant listed.
    A similar formula in G2 (and filled down) can be used to calculate the start date of the last billing cycle in column G of RiR:
    =DATE(YEAR(F),MONTH(F)-IF(DAY(F)<15,1,0),15)
    The second issue, a difference in the year's rent calculated as 12*monthly and the rent for the same period with the first two weeks charged on a daily rate calcualtion and the first two weeks of the next year refunded on a daily rate calculaton, is a bit more challenging.
    As you surmise,the issue arises from the varying length of months (with a touch of complication from the offset of the billing cycle from the calendar cycle).
    More on that in a direct note, tomorrow or Thursday.
    Here's a quick fix to the "Sam" problem on the 'extra days owed' table (last column).
    E2: =MIN(PRODUCT(D2,RiR :: C2),RiR :: B2)
    It works for Sam, where the move out charges are for 31 days, but doesn't address the issue of year end charges and (virtual) refunds tenants in residence for the full year.
    Note that filling the formula down from E2 will override the conditional formatting rules you have on these cells with the rule in E2.
    Regards,
    Barry

  • Smartform Problem in Displaying a string data

    Hi Friends,
                     I am facing a problem while displaying a string data in smartform. Actually it is a one of the field's data in an internal table. It is a STRING field type of length 0. While populating in an internal table it is having a all the data(Around 700 char data). But while displaying in a smartform surprizingly only few characters(Around 225 char data). How can i overcome this problem?
    Regards,
    Sekhar.J

    Hi
    try this and see
    Declare some Variables of 72 char each and split that long string data of internal table text field into them and display these variables strings one below other in smartform
    var1 = itab-text+0(72)
    var2 = itab-text+72(72)
    var3 = itab-text+144(72)
    like that
    and display one below other in smartform.
    &VAR1&
    &VAR2&
    &VAR3&
    Reward points for useful Answers
    Regards
    Anji

  • Xy graph in GUI. Show string data related to a X,Y point

    It is possible to show string data, while hovering the mouse or clicking a cursor, attached/related to a X,Y point in a XY graph??
    Kind regards

    I assume you want to let the x-y-value pair hover over the graph at mouse position.Perhaps this will help you:
    http://forums.ni.com/t5/LabVIEW/Text-overlay-annotation-onto-an-intensity-graph/m-p/883438/highlight...
    Another option might be just to use the cursor functionalities of XY graphs, although they don't hover at mouse position.
    Other than that I had a similar request on Image Displays with IMAQ (Vision Development Module) where it turned out that using a simple string control from the classic palette that you move around according to mouse position is an efficient way to let information hover wherever you want. Check it out:
    http://forums.ni.com/t5/LabVIEW/Why-do-overlays-take-so-much-longer-on-single-precision/m-p/2376338#...

  • How can you add data from a variable into a column in a data flow?

    I need to populate a table with data from a variable. The data type of the variable is String. I'm running into issues doing it the way I am. I have variable
    User:VariableName = "Some moderately sized string of data"
    When I try to use a Derived Column Transformation Editor to insert the variable into the data flow as a new column, SSIS forces the Data Type to be Unicode String[DT_WSTR] and I can't change it. Additionally the length is 0 and I also can't change that.
    When I run the package it errors with a truncation error. If the length is 0 then that makes sense but then why can't I change it to something that makes more sense?
    What is the correct way to go about this?

    Use advanced editor to change data type and length.
    http://www.sureshjoshi.com/development/ssis-string-variables-in-derived-columns/

  • String date to integer

    Need help.
    Does anybody know how to convert a string date to int..
    format of the date is like this(dd-mm-yyyy) example ->15-Aug-1993.
    I would like to convert the corresponding month to int...
    like for Jan=1, Feb=2,Mar=3...Aug=8...Dec=12...
    is there any method in java which supports this kind of conversion?
    sample codes would be of great help.
    Thanks in advance.

    If your intention is to convert "15-Aug-1993" into "15-8-1993", ie a string->string conversion, use a SimpleDateFormat to parse the first string into a Date. And then use another one to format the date into the appropriate format.
    If you want to obtain an integer value from the string according to the scheme you presented, you could parse it as above then use the getMonth() mehod of the Date class. Note: the returned value is zero based (January is zero, not one) and the method is deprecated.
    It's better to use the Calendar class:
    * Use SimpleDateFormat to obtain a Date (ie parse the string)
    * create a Calendar instance and set its time to the date
    * use the get() method of Calendar to obtain the month
    The Calendar class defines a number of int values: Calendar.JANUARY, Calendar.FEBUARY etc. Mostly you use these values without knowing or caring what int values they have.

  • String data code page - DB2 - Data Direct - Data Services

    We are trying to connect to a DB2 source (Database product = DB2 OS/390 8.1.5) using Data Direct drivers and following error is showing up when we test the connectivity.
    SQLConnect: Retrying Connect.
    SQLConnect: Failed...
    SQLSTATE = S1000
    NATIVE ERROR = 0
    MSG = [SAP BusinessObjects][ODBC DB2 Wire Protocol driver]String data code page conversion failed.
    Wondering if anyone has had similar issue or if someone hasany ideas regarding how this can be resolved would be great.
    Thanks for the help

    Check whether the DB2CODEPAGE env variable is set in your OS.
    issue the following query against your database -
    select codepage from syscat.tables where datatype='varchar'
    This should return the corresponding codepage value.
    In windows, create a user variable (environment variable) called DB2CODEPAGE and assign the value you got from the previous query.
    If it is unix, use th setenv command
    setenv DB2CODEPAGE 'cp1252'
    , for instance
    You may have to restart the machine once the variable is defined
    Regards,
    Shine

  • Sending String Data of  64 kilo bytes to Remote Function Module

    Hi,
        I have an RFC call from JAVA and I need to send string data to the FM. The maximum size of the data that I can send from java is 64 kilo bytes (Functional requirement). I want to receive this data as a table's parameter in the FM. Table's parameter’s data type can only be structure's which are FLAT-LINED. So if I use STRNIG as the data type for receiving the data from JAVA the RFC doesn’t allow me (As this makes the structure NON FLAT LINED which RFC will not allow as data type for tables parameter). So I have to use some other data type like CHAR or LCHR. But the maximum size for CHAR and LCHR is around 32 kilo bytes. I need a way to receive 64 kilo bytes of data into the Function Module as a table’s parameter.
    Thanks in advance
    Sesh

    Hi!
    I think I was pretty near your problem. When talking about table fields, you could a 'parameter' -> field of your table parameter.
    Which type? String is out of question, because here length is variable, but you need a constant length definition. I just have a look into help of data, built in ABAP-types. Here C and N can have a length from 1 to 65535 - OK, not 64 KB but only 1 byte missing...
    ... just made a small test, there is a second border (for non-unicode systems): the total length of the structure can't exceed 65535. If you need additional fields, define a second table parameter and place your additional fields in a second table. You can't define a link field (would need some space), so you have to go for a '1st line of data matches 1st line of attributes'-definition.
    I'm still a little bit curious: what kind of data you are sending?
    Regards,
    Christian

  • Unicode and non-unicode string data types Issue with 2008 SSIS Package

    Hi All,
    I am converting a 2005 SSIS Package to 2008. I have a task which has SQL Server as the source and Oracle as the destination. I copy the data from a SQL server view with a field nvarchar(10) to a field of a oracle table varchar(10). The package executes fine
    on my local when i use the data transformation task to convert to DT_STR. But when I deploy the dtsx file on the server and try to run from an SQL Job Agent it gives me the unicode and non-unicode string data types error for the field. I have checked the registry
    settings and its the same in my local and the server. Tried both the data conversion task and Derived Column task but with no luck. Pls suggest me what changes are required in my package to run it from the SQL Agent Job.
    Thanks.

    What is Unicode and non Unicode data formats
    Unicode : 
    A Unicode character takes more bytes to store the data in the database. As we all know, many global industries wants to increase their business worldwide and grow at the same time, they would want to widen their business by providing
    services to the customers worldwide by supporting different languages like Chinese, Japanese, Korean and Arabic. Many websites these days are supporting international languages to do their business and to attract more and more customers and that makes life
    easier for both the parties.
    To store the customer data into the database the database must support a mechanism to store the international characters, storing these characters is not easy, and many database vendors have to revised their strategies and come
    up with new mechanisms to support or to store these international characters in the database. Some of the big vendors like Oracle, Microsoft, IBM and other database vendors started providing the international character support so that the data can be stored
    and retrieved accordingly to avoid any hiccups while doing business with the international customers.
    The difference in storing character data between Unicode and non-Unicode depends on whether non-Unicode data is stored by using double-byte character sets. All non-East Asian languages and the Thai language store non-Unicode characters
    in single bytes. Therefore, storing these languages as Unicode uses two times the space that is used specifying a non-Unicode code page. On the other hand, the non-Unicode code pages of many other Asian languages specify character storage in double-byte character
    sets (DBCS). Therefore, for these languages, there is almost no difference in storage between non-Unicode and Unicode.
    Encoding Formats: 
    Some of the common encoding formats for Unicode are UCS-2, UTF-8, UTF-16, UTF-32 have been made available by database vendors to their customers. For SQL Server 7.0 and higher versions Microsoft uses the encoding format UCS-2 to store the UTF-8 data. Under
    this mechanism, all Unicode characters are stored by using 2 bytes.
    Unicode data can be encoded in many different ways. UCS-2 and UTF-8 are two common ways to store bit patterns that represent Unicode characters. Microsoft Windows NT, SQL Server, Java, COM, and the SQL Server ODBC driver and OLEDB
    provider all internally represent Unicode data as UCS-2.
    The options for using SQL Server 7.0 or SQL Server 2000 as a backend server for an application that sends and receives Unicode data that is encoded as UTF-8 include:
    For example, if your business is using a website supporting ASP pages, then this is what happens:
    If your application uses Active Server Pages (ASP) and you are using Internet Information Server (IIS) 5.0 and Microsoft Windows 2000, you can add "<% Session.Codepage=65001 %>" to your server-side ASP script.
    This instructs IIS to convert all dynamically generated strings (example: Response.Write) from UCS-2 to UTF-8 automatically before sending them to the client.
    If you do not want to enable sessions, you can alternatively use the server-side directive "<%@ CodePage=65001 %>".
    Any UTF-8 data sent from the client to the server via GET or POST is also converted to UCS-2 automatically. The Session.Codepage property is the recommended method to handle UTF-8 data within a web application. This Codepage
    setting is not available on IIS 4.0 and Windows NT 4.0.
    Sorting and other operations :
    The effect of Unicode data on performance is complicated by a variety of factors that include the following:
    1. The difference between Unicode sorting rules and non-Unicode sorting rules 
    2. The difference between sorting double-byte and single-byte characters 
    3. Code page conversion between client and server
    Performing operations like >, <, ORDER BY are resource intensive and will be difficult to get correct results if the codepage conversion between client and server is not available.
    Sorting lots of Unicode data can be slower than non-Unicode data, because the data is stored in double bytes. On the other hand, sorting Asian characters in Unicode is faster than sorting Asian DBCS data in a specific code page,
    because DBCS data is actually a mixture of single-byte and double-byte widths, while Unicode characters are fixed-width.
    Non-Unicode :
    Non Unicode is exactly opposite to Unicode. Using non Unicode it is easy to store languages like ‘English’ but not other Asian languages that need more bits to store correctly otherwise truncation will occur.
    Now, let’s see some of the advantages of not storing the data in Unicode format:
    1. It takes less space to store the data in the database hence we will save lot of hard disk space. 
    2. Moving of database files from one server to other takes less time. 
    3. Backup and restore of the database makes huge impact and it is good for DBA’s that it takes less time
    Non-Unicode vs. Unicode Data Types: Comparison Chart
    The primary difference between unicode and non-Unicode data types is the ability of Unicode to easily handle the storage of foreign language characters which also requires more storage space.
    Non-Unicode
    Unicode
    (char, varchar, text)
    (nchar, nvarchar, ntext)
    Stores data in fixed or variable length
    Same as non-Unicode
    char: data is padded with blanks to fill the field size. For example, if a char(10) field contains 5 characters the system will pad it with 5 blanks
    nchar: same as char
    varchar: stores actual value and does not pad with blanks
    nvarchar: same as varchar
    requires 1 byte of storage
    requires 2 bytes of storage
    char and varchar: can store up to 8000 characters
    nchar and nvarchar: can store up to 4000 characters
    Best suited for US English: "One problem with data types that use 1 byte to encode each character is that the data type can only represent 256 different characters. This forces multiple
    encoding specifications (or code pages) for different alphabets such as European alphabets, which are relatively small. It is also impossible to handle systems such as the Japanese Kanji or Korean Hangul alphabets that have thousands of characters."<sup>1</sup>
    Best suited for systems that need to support at least one foreign language: "The Unicode specification defines a single encoding scheme for most characters widely used in businesses around the world.
    All computers consistently translate the bit patterns in Unicode data into characters using the single Unicode specification. This ensures that the same bit pattern is always converted to the same character on all computers. Data can be freely transferred
    from one database or computer to another without concern that the receiving system will translate the bit patterns into characters incorrectly.
    https://irfansworld.wordpress.com/2011/01/25/what-is-unicode-and-non-unicode-data-formats/
    Thanks Shiven:) If Answer is Helpful, Please Vote

  • Getting raw data of a variable

    Is anyone aware of a handy way to get the raw (hex) data of an AppleScript variable into a text string? For example:
    «data rdatEFBBBF»
    «data isot323030372D31322D31325431373A34393A3130»
    I can do some comparisons, and put the raw data as text into a variable, but trying to get the actual raw data as text either fails or gets coerced into whatever it is supposed to be (such as ISOT). Well, actually I can do the "force an error and grab the error message" trick, but there has got to be a better way. Perhaps something along the lines of set X to do shell script "whattheheck " & (SomeVariable as data)?

    Hello
    Under OS9/Classic, we can use a mighty 'cast' command of 'programmer's tool' OSAX made by Ed Lai for this kind of task.
    http://osaxen.com/files/programmerstool1.0a10.html
    Under OSX, the ladder has been removed.
    One dirty way I can think of is to use write and read commands to force to replace the class of given data. Somethnig like this, though it won't work properly with AppleScript 2.0 if the input or output data is a sort of text object.
    --SCRIPT
    set x to «data isot323030372D31322D31325431373A34393A3130»
    --set x to «data rdatEFBBBF»
    --set x to current date
    --set x to {1, 2, 3}
    --set x to "ABC" as Unicode text
    set y to dump(x, string)
    set z to dump(y, data)
    return {x, y, z}
    on dump(x, cls)
      anything x : anything to be dumped [1]
      type class cls : resulting class of dumped data. e.g. string, data etc.
      return anything : dumped data as given class [2]
      * Notes.
      [1] x must be what 'write' osax can write to file. (E.g. script object etc cannot be processed by this method)
      [2] It won't return exact raw byte sequence in AppleScript 2.0 if
        - x's class is one of {Unicode text, string, text}; or
        - cls is one of {Unicode text, «class utf8», string, text}.
    set fp to (path to "desk" from user domain as Unicode text) & "scptdump_tempfile" & (random number 1000000)
    try
    set fref to open for access file fp with write permission
    set eof fref to 0
    write x to fref
    close access fref
    set d to read file fp as cls
    on error errs number errn
    try
    close access file fp
    end try
    error "dump():" & errs number errn
    end try
    do shell script "rm -f " & quoted form of POSIX path of fp
    return d
    end dump
    --END OF SCRIPT
    Hope this may be of some help,
    Hiroto
    PS.
    In pre-AS 2.0, we can use 'string' to hold raw byte sequence of any kind of data, although it might be indeed an abuse of 'string' object. In AS 2.0, we seem to have lost this final way to abuse string and I'm yet to know any alternative way to process raw byte sequence safely.
    Now, I think, it would be really nice to see the following basic features being implemented with «class rdat» in order to process raw byte sequence in AppleScript 2.0 or later, where we cannot 'abuse' string anymore:
    • length property; e.g. length of «data rdat0032» (count «data rdat0032») returning 2.
    • way to extract element(s); e.g. item 4 of «data rdat32303037» returning «data rdat37»
    • way to concatenate two data; e.g. «data rdat32» & «data rdat30» returing «data rdat3230»
    • way to perform valid coercion to other class, e.g. «data rdat0032» as Unicode text returning "2" (= U+0032).
    • way to perform coercion from other class, e.g. ("2" as Unicode text) as data returning «data rdat0032»
    Just my daydream. ; )
    Message was edited by: Hiroto (corrected typo)

  • How to migrate the data from DEC RDB 5.1 to Oracle 11g

    Hi,
    As part of my project, we need to migrate the data from DEC RDB 5.1 present on Alpha server with VMS 6.1 OS into Oracle 11g. The size of the data in DEC RDB is around 40 GB.
    Could you please suggest various ways of getting this done in easy and simpler way?
    Thanks in advance.

    Hello,
    when Oracle bought Rdb from Digital Equipment Corporation (DEC) in 1994, the name of the product changed from DEC Rdb to Oracle Rdb. Meanwhile the actual version of Rdb is 7.2, so you are on a VERY old version. And that excludes the suggestions from the mentioned note to use a database link from Oracle RDBMS to Rdb, that is simply not possible with that old version of Rdb.
    But Rdb 5.1 knew already the Rdb Management Utility (RMU) - I just checked that with Rdb 4.1 which is even older.
    There are two commands that are helpful for your task.
    RMU/EXTRACT - that writes the metadata into a file. That output helps you to build a script to create all the objects in your target database.
    RMU/UNLOAD - that writes the data of each table into a formatted file (one file per table). That output can be used by the SQL*Loader to load your data into the target database.
    You can read all details about these commands in the online help on your Alpha. At first, issue the HELP command and look in the output list whether it lists a command RMU or RMU51. Then run that command:
    $ help rmu /extract
    and
    $ help rmu /unload
    Replace rmu by rmu51 if the help command shows you that rmu51 exists but not rmu.
    There is one caveat. Do you use blobs in your Rdb database? If you don't know that, create an the output with RMU/EXTRACT and search the output file for the string LIST OF BYTE VARYING. If there are none then you have no blobs. If you have some you need to take more care of them, they can't be unloaded into a formatted file, that must happen programmatical. If you have such fields then let me know, then I'll tell you how to get them out of your Rdb database.
    Best regards
    Wolfgang
    P.S.: For Rdb related questions it is better to ask in our Communities at https://communities.oracle.com/portal/server.pt/community/rdb_product_family_on_openvms . That forum is watched by Rdb Support and Development.

  • Moving LR5 catalog (Irdata & Ircat) to a new hard drive and photos. Lost all meta data - How do I move meta data along with catalog?

    I moved LR5 catalog (Irdata & Ircat) to a new hard drive and photos. Lost all meta data - How do I move meta data along with catalog?
    The meta data for each image is missing.
    I have over 2,000 images. I don't want to go back through each image and add meta data.
    Is there some way to move everything?

    No, do not re-import your images. I assume you can see the thumbnails in the library module, just cannot access the full images, right? If this is the case there should be an exclamation mark in the top right corner of every one of your pictures and you only have to tell LR where the images are now.
    Click the exclamation mark of one of the images and a dialog window should pop-up, telling you that LR cannot find the file, but with an option to locate it. Press "Locate" and navigate to the folder on your new HD where the file is. If in the new external HD you kept the same folder structure that you had on the internal disk, LR will be able to find all your images and re-link them to the database without further intervention.

  • Trying to move a list of form variables to session variables of the same name

    I am trying to move a list of form variables to session variables of the same name and I am having a lot of trouble.
    I have never had to post of this forum with a language question in all the 10 years I have been using ColdFusion. I was a qa Engineer @ Allaire/Macromedia back when it was going from one to the other. I have a pretty good grasp of the language.
    I have software that runs off a list. The fieldnames are variable and stored off in an array. It's survey software that runs off a "meta file". In this example; I have the number of fields in the survey set to 12 in the "metafile". I have each field declared in that file in array Session.SurveyField[1] and the above loop works fine. I include this "metafile" at the start of the process.
    I cfloop around a struct and it works wherever I have needed to use it; such as here - writing to the database for example;
    <CFQUERY NAME="InsertRec" DATASOURCE="Survey">
    INSERT into #variables.SurveyTableName#
    (EntryTime
    <cfloop from="1" to="#Session.NumberOfSurveyFields#" index="arrayindex">
    ,#Session.SurveyField[arrayindex]#
    </cfloop>
    <!--- EXAMPLE OF WHAT THE ABOVE GENERATES
    ,q01_name,q02_AcadTechORNA,q03_Water,q04_FirstAid,q05_CPR,q06_LifeGuard,q07_AED
    ,q08_ProjAdv,q09_Color,q10_SantaClaus,q11_Supervisor,q12_SupervisorOpinion --->
       VALUES
        ('#EntryTime#'
    <cfloop from="1" to="#Session.NumberOfSurveyFields#" index="arrayindex">
    <cfset thisname = "Session." & Session.SurveyField[arrayindex]>
    ,'#evaluate(variables.thisname)#'
    </cfloop>
    <!--- EXAMPLE OF WHAT THE ABOVE GENERATES
    ,'#Session.q01_name#','#Session.q02_AcadTechORNA#','#Session.q03_Water#','#Session.q04_Fi rstAid#'
    ,'#Session.q05_CPR#','#Session.q06_LifeGuard#','#Session.q07_AED#','#Session.q08_ProjAdv# ',
    ,'#Session.q09_Color#','#Session.q10_SantaClaus#','#Session.q11_Supervisor#','#Session.q1 2_SupervisorOpinion#' --->
    </CFQUERY>
    NOW HERE'S THE PROBLEM: I am running into trouble when trying to move the form variables to session variables of the same name. It is the only part of the software that I still need the datanames hard coded and that is a roadblock for me.
    <cfloop from="1" to="#Session.NumberOfSurveyFields#" index="arrayindex">
    <cfset thissessionfield = "Session." & Session.SurveyField[arrayindex]>
    <cfset thisformfield = "Form." & Session.SurveyField[arrayindex]>
    <cfset #thissessionfield# = #evaluate(thisformfield)#>
    </cfloop>
    I have tried it with or without the "evaluate"; same result. It doesn't give an error; it just ignores them (session variables look as such in the next page in the chain)
    q01_name=
    q02_acadtechorna=
    q03_water=
    q04_firstaid=
    q05_cpr=
    q06_lifeguard=
    q07_aed=
    q08_projadv=
    q09_color=
    q10_santaclaus=
    q11_supervisor=
    q12_supervisoropinion=
    Note: they exist because I CFPARAM them in a loop like the above at the start of the procedure) - and this works just fine!
    <cflock scope="Session" type="EXCLUSIVE" timeout="30">
    <cfloop from="1" to="#Session.NumberOfSurveyFields#" index="arrayindex">
    <cfset dataname = "Session." & Session.SurveyField[arrayindex]>
    <cfparam name="#variables.dataname#" default="">
    </cfloop>
    </cflock>
    I EVEN tried exploiting the Form.Fieldnames list using CFLoop over the list and the same sort of logic within and it still gives me nothing....
    Here's the FORM.FIELDNAMES value
    "Q01_NAME,Q02_ACADTECHORNA,Q03_WATER,Q04_FIRSTAID,Q05_CPR,Q06_LIFEGUARD,Q07_AED,Q08_PROJAD V,Q09_COLOR,
    Q10_SANTACLAUS,Q11_SUPERVISOR,Q12_SUPERVISOROPINION"
    Here's the logic; SAME RESULT - The session variables don't get set.
    <cfoutput>
    <cfloop list="#Form.FieldNames#" index="thisfield">
    <!--- <br>#thisfield# --->
    <cfscript>
    thisSESSIONfield = "Session." & thisfield;
    thisFORMfield = "Form." & thisfield;
    #thisSESSIONfield# = #thisFORMfield#;
    </cfscript>
    </cfloop>
    </cfoutput>
    The CFPARAM in a loop with variable output name works just fine; so does the post (which I included above) as does the SQL Create, Param Form Variables, Param Session Variables, etc.
    THIS even works for moving BLANK to each session variable, to zero them all out at the end of the process;
    <cflock scope="Session" type="EXCLUSIVE" timeout="30">
    <cfloop from="1" to="#Session.NumberOfSurveyFields#" index="arrayindex">
    <cfset thislocalfield = Session.SurveyField[arrayindex]>
    <cfscript>
    thissessionfield = "Session." & thislocalfield;
    </cfscript>
    <cfset #thissessionfield# = "">
    </cfloop>
    </cflock>
    Expanding on that code, you would think this would work, but it doesn't;
    <cfloop from="1" to="#Session.NumberOfSurveyFields#" index="arrayindex">
    <cfset thislocalfield = Session.SurveyField[arrayindex]>
    <cfscript>
    thissessionfield = "Session." & thislocalfield;
    thisformfield = "Form." & thislocalfield;
    </cfscript>
    <!--- debug --->
    <!--- <cfoutput>#thissessionfield# = "#evaluate(thisformfield)#"</cfoutput><br> --->
    <cfoutput>
    <cfset #thissessionfield# = "#evaluate(thisformfield)#">
    </cfoutput>
    </cfloop>
    And see that debug code in the middle? To add insult to injury... When I uncomment that it shows me this. So it certainly looks like this should work....
    Session.q01_name = "Me"
    Session.q02_AcadTechORNA = "N/A"
    Session.q03_Water = "Yes (certificate expired)"
    Session.q04_FirstAid = "Yes (certificate is current)"
    Session.q05_CPR = "No"
    Session.q06_LifeGuard = "Yes (certificate expired)"
    Session.q07_AED = "Yes (certificate expired)"
    Session.q08_ProjAdv = "Yes (certificate expired)"
    Session.q09_Color = "Gray"
    Session.q10_SantaClaus = "Yes"
    Session.q11_Supervisor = "Da Boss"
    Session.q12_SupervisorOpinion = "Not a bad thing"
    There must be some simpler way to do this. This way won't work against all odds even though it seems so much like it should.
    So I end up having to hardcode it; still looking for an automated way to set these #@%$*@!## session variables over the list from the form variables of the same @#@!$#%$%# name. Do I sound frustrated???
    No matter what I do, if I don't HARDCODE like this;
    <cfset Session.q01_name = Form.q01_name>
    <cfset Session.q02_AcadTechORNA = Form.q02_AcadTechORNA>
    <cfset Session.q03_Water = Form.q03_Water>
    <cfset Session.q04_FirstAid = Form.q04_FirstAid>
    <cfset Session.q05_CPR = Form.q05_CPR>
    <cfset Session.q06_LifeGuard = Form.q06_LifeGuard>
    <cfset Session.q07_AED = Form.q07_AED>
    <cfset Session.q08_ProjAdv = Form.q08_ProjAdv>
    <cfset Session.q09_Color = Form.q09_Color>
    <cfset Session.q10_SantaClaus = Form.q10_SantaClaus>
    <cfset Session.q11_Supervisor = Form.q11_Supervisor>
    <cfset Session.q12_SupervisorOpinion = Form.q12_SupervisorOpinion>
    I always get this from my next page because the session variables are empty;
    You must answer question 1.
    You must answer question 2.
    You must answer question 3.
    You must answer question 4.
    You must answer question 5.
    You must answer question 6.
    You must answer question 7.
    You must answer question 8.
    You must answer question 9.
    You must answer question 10.
    I tried duplicate as well, but I can not get the above to work...
    Can anyone help me do this thing that one would think is simple????

    I think if you use structure array syntax you should get the results you want.
    <cfloop from="1" to="#Session.NumberOfSurveyFields#" index="arrayindex">
          <cfset session[Session.SurveyField[arrayindex]] = Form[Session.SurveyField[arrayindex]]>
    </cfloop>
    Or probably even easier.
    <cfset session = duplicate(form)>

Maybe you are looking for