Rename FK and PK, that exceed 30 characters name limit

Hi,
I am trying to write a custom script (Rhino) to change all the FK and PK names, that are more than 30 characters long.
I have to do that, because I get the DDL script from Infosphere Data Architect, whitch ignores this Oracle restriction.
I wrote this script, but it does not what I want. Insted of changing the name it changes the PK / UK Index names. Can anybody please help me.
tables = model.getTableSet().toArray();
for (var t = 0; t<tables.length;t++){
table = tables[t];
indexes = table.getKeys();
for (var i = 0; i < indexes.length; i++) {
index = indexes;
if((index.isFK() || index.isPK()) && index.GetName().length > 30){
index.SetName('TEST');

Hi,
Seems like you have broken it to two separate scripts.
Here is the fill script treating PK, FK and UK :
tables = model.getTableSet().toArray();
for (var t = 0; t<tables.length;t++){
  table = tables[t];This part will treat unique keys AND primary keys:
indexes = table.getKeys();
for (var i = 0; i < indexes.length; i++) {
     index = indexes;
     if((index.isUnique() || index.isPK()) && index.getName().length() > 30){
          index.setName("TEST");
This part will treat ONLY foreign keys:
   fkS = table.getFKAssociations();
   for (var i = 0; i < fkS.length; i++) {
     fk = fkS;
     if(fk.getName().length() > 30){
          fk.setName("TEST");
It can be executed as it is and validation after it will not return you "Primary key name has more than 30 characters".

Similar Messages

  • UNC Pathnames that exceed 255 Characters

    (I manage folders and files only in my company. Another person serves as Sys Admin. It's complicated. Don't ask.)
    I seem to have encountered an issue where some users of our shared drives have created directory structures so deep, and used verbose filenames, that they have exceeded the 255 character limit.
    As a result, several folders and files have lost association to any owner.
    Since no owner exists, I cannot manage these folders & files properly.
    I cannot take ownership of them (have tried)
    I have tried mapping far deeper in the folder structure to a drive letter in the hopes that would then place these files and folders within 255 characters. (doesn't help)
    In the owner column, all I see is blank. At a DOS prompt I see ...
    Any suggestion on how to regain control of these files?

    Hello,
    Now that no one is the owner of these folders, system administrator has to log on to the server and set the correct owner to enable these files to be managed.
    Thanks.
    Regards,
    Neo Zhu

  • Renaming masters and then editing in photoshop, the name reverts back...

    So, if do a batch rename on a bunch of raw files to example 1.NEF, then example 2.NEF and so on, I select apply to masters. It works fine, even if I export the masters, with the master name, it shows the new name. No problem.
    However, if I right click in aperture and select edit in photoshop on one of the aforementioned masters, then the new PSD file that is created has the original name as it was from the camera! What the heck?
    Am I missing something?

    Let's look at what's happening in the background: (tested or managed library)
    In the Pictures folder is the Aperture library.
    A typical master might be in a folder year>month>date>subfolder.
    On sending to Photoshop a PSD (or tiff) is created and stored with the master.
    This is edited and returned.
    In the Previews folder year>month>date>subfolder>subfolder is found a jpg with the original name (there are also thumbnails and faces files).
    This seems to be picked up when the edited file comes back from Photoshop.
    More research neeeded!

  • HT201318 If you increase your iCloud storage capacity can you increase the number of songs that exceed the 25,000 limit on the iMatch. If it does not apply specifically how can I increase this rather constrained limit?

    The whole business of cloud storage is unclear to me. They say that you have 5G of memory free upgrade to 15 for twenty-five dollars and that this is unrelated to music and video memory. I get this, but I have purchased iCloud Match for $25 but I've quickly maxed out the 25,000 song limit. How can I increase this limit. It is at this point I am unclear about the $25 for 15G additional storage... can this be used to increase iTunes/iCloudmusic storage to increase the music Storage? One would think that apple would make these distinctions clearer. Can anyone carify? Thanks!

    iTunes Match does not use your iCloud account.  Your annual Match subscribtion pays for separate storage to host your iTunes library.  As far as I know, you can't increase the 25,000 song limit.
    If you recently purchased the storage upgrade for this purpose, in the U.S. you could call 1-800-MYAPPLE for a refund if you don't need it.

  • My memebrship has expired and I have exceeded the 30 day limit,  i was away on holiday and unable to access mail, is there any way I can renew my account without having to repurchase?

    Hi there, I have just realised there was a 30 day limit to renew membership, I have missed it by 3 days, I was away on holiday and unable to access my mail, is there someone or a way tht I canavoid having to repurchase?

    Moving this discussion to the Adobe Creative Cloud forum.
    Markh70292302 please contact our support team directly at Contact Customer Care for membership concerns.

  • Reg. Display of Output exceeds 255 characters as spool list

    Dear Experts,
    My requirement is that i need to display output that exceeds 255 characters in length as spool list. How should i achieve it?
    Regards,
    Ramesh Manoharan

    Hello,
    Following SAP Notes can also help you :
    [https://service.sap.com/sap/support/notes/1226758|https://service.sap.com/sap/support/notes/1226758]
    [https://service.sap.com/sap/support/notes/1174095|https://service.sap.com/sap/support/notes/1174095]
    Wim

  • Problems with Icons That Exceed 11 Pages

    I have a lot of apps on my iPhone and some of them do not show up on my pages, because there are only 11 Pages on the phone and the rest remained hidden....
    Is there any way to fix this?

    Is there any way to fix this?
    Create folders & put the apps that exceed the 11 page limit in folders. Or, categorize your apps by type, create folders & put the various apps in their corresponding folder.

  • I had renamed my user login name and assumed that there will be no change in the settings and files. When I login with the new profile name everything is gone. How can I get back all my files and settings?

    I had renamed my user login name and assumed that there will be no change in the settings and files. When I login with the new profile name everything is gone. How can I get back all my files and settings? Please help. Thanks.

    You should have asked this before you tried: Changing username or short name- User Account and Short Name- OS X- How to change user account name or home directory name.

  • HT4060 Is it normal for someone to have general diffuculty charging an ipad?  I see the "not charging" message even when I am using the charger and cord that came in the original box, plugged into a wall socket directly.  It just seems to be exceedingly f

    Is it normal for someone to have general diffuculty charging an ipad?  I see the "not charging" message even when I am using the charger and cord that came in the original box, plugged into a wall socket directly.  It is normal for me to plug it in overnight and to see no charge whatsoever the next day.  I have never had so much trouble using a friggin charger in my life.  It just seems to be exceedingly finicky.  What am I missing?

    Charging your iPad should not be problematic. It should be an easy thing to do using the charger provided with your iPad connected to a known good wall outlet.
    The charging problem you are experiencing is most like caused by:
    1. A faulty charger
    2. A faulty cable
    3. A bad wall outlet
    4. A problem in the iPad.
    The first three of these are easiest to eliminate. Try a for ends charger and cable. Make absolutely sure your outlet is good. Try other outlets.
    If the charger, cable and outlet a proven to be good then the problem lies in the iPad.
    Make an appointment at an Apple Store to have your device examined by a technician. Or contact Apple Support.

  • HT2736 why am I getting a message suddenly that I am exceeding the gift card limit on my iTunes id for buying gift cards?    I have never had a problem before and have a good credit card on file.

    why am I getting a message suddenly that I am exceeding the gift card limit on my iTunes id for buying gift cards?    I have never had a problem before and have a good credit card on file. I bought a $50 card for my son and then went to buy another one and it was refused and has continued to be for a week telling me a I am exceeding the gift card limit for my account? Insights here?

    Interesting.
    Didn't know Apple accepted PayPal as a payment option in some Stores. Cause they sure don't over here.

  • I am having a problem where pdf files on the web (i.e., links in a Word doc) open after an extended time and only as gobbldygook ( a file containing a series of characters and letters that make no sense).  This also happens for another Mac user coworker

    Hi There:  I am having a problem where pdf files on the web (i.e., links in a Word doc) open after an extended time and only as gobbldygook ( a file containing a series of characters and letters that make no sense).  This also happens for another Mac user coworker in my office, while the PCs don't have this problem...  Any help/suggestions for a fix would be most appreciated! 

    Just adding more info - MacBookPro running 10.5.8 and using Safari as the browser.  The problem comes and goes - sometimes the linked Word files will open OK, n others its just a strring of crazy characters... 

  • [svn] 4074: FxNumericStepper now has a maxChars property, and it now restricts the characters that can be entered into its FxTextInput .

    Revision: 4074
    Author: [email protected]
    Date: 2008-11-11 14:10:34 -0800 (Tue, 11 Nov 2008)
    Log Message:
    FxNumericStepper now has a maxChars property, and it now restricts the characters that can be entered into its FxTextInput.
    Fixed a problem with 'restrict' in TextView. If there are no characters left to insert after restriction, do nothing; don't insert an empty string and thereby delete the insertion.
    QE Notes: None
    Doc Notes: None
    Bugs: None
    Reviewer: Glenn
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/TextView.as

    When I installed iTunes 7.3 I noticed some artwork
    was gone. I compared the actual file sizes to the
    backup and there was no change at all. I was able to
    get the covers again from the iTS, but as I really
    want to have the artwork inside the files, I tried to
    paste it into the tags (like I used to do since 7.0).
    That doesn't work, after pasting it, the artwork is
    gone again completely, but the files are now 4mb
    bigger. The artwork of these files (about 300 in
    total, and I cant figure out why some and some not)
    can not be browsed, but the rest of the tags is fine
    and the songs play just normal.
    I trashed one of the affected albums and re-added it
    from the backup. Now the tags in iTunes were gone
    completely! I re-entered the correct tags and let
    iTunes get the artwork from the iTS. The artwork
    shows, but not for all files of the album. So again I
    tried to paste it into the tags of all songs, and
    voila: all artwork of this album is gone again and
    the files are 4mb bigger.
    Same behaviour in iTunes 7.3.1.
    I'm happy I have a good backup of my music, and I
    think the artwork is still inside the files, but
    iTunes 7.3 and 7.3.1 mess it up. From what I see only
    non-iTS files are affected, but only iTS artwork is
    lost. NOT nice.
    Any ideas? I'm no really a friend of downgrading...
    After some more time consuming tinkering I still have no luck in giving certain files their artwork back. I better go back to 7.2 tomorrow... Apple keep that lousy 7.3.1 BS yourself

  • [svn] 4072: FxNumericStepper now has a maxChars property, and it now restricts the characters that can be entered into its FxTextInput .

    Revision: 4072
    Author: [email protected]
    Date: 2008-11-11 14:08:39 -0800 (Tue, 11 Nov 2008)
    Log Message:
    FxNumericStepper now has a maxChars property, and it now restricts the characters that can be entered into its FxTextInput.
    QE Notes: None
    Doc Notes: None
    Bugs: SDK-16293, SDK-16627
    Reviewer: Glenn
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-16293
    http://bugs.adobe.com/jira/browse/SDK-16627
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxNumericStepper.as
    Property Changed:
    flex/sdk/trunk/frameworks/projects/flex4/src/mx/components/FxNumericStepper.as

    When I installed iTunes 7.3 I noticed some artwork
    was gone. I compared the actual file sizes to the
    backup and there was no change at all. I was able to
    get the covers again from the iTS, but as I really
    want to have the artwork inside the files, I tried to
    paste it into the tags (like I used to do since 7.0).
    That doesn't work, after pasting it, the artwork is
    gone again completely, but the files are now 4mb
    bigger. The artwork of these files (about 300 in
    total, and I cant figure out why some and some not)
    can not be browsed, but the rest of the tags is fine
    and the songs play just normal.
    I trashed one of the affected albums and re-added it
    from the backup. Now the tags in iTunes were gone
    completely! I re-entered the correct tags and let
    iTunes get the artwork from the iTS. The artwork
    shows, but not for all files of the album. So again I
    tried to paste it into the tags of all songs, and
    voila: all artwork of this album is gone again and
    the files are 4mb bigger.
    Same behaviour in iTunes 7.3.1.
    I'm happy I have a good backup of my music, and I
    think the artwork is still inside the files, but
    iTunes 7.3 and 7.3.1 mess it up. From what I see only
    non-iTS files are affected, but only iTS artwork is
    lost. NOT nice.
    Any ideas? I'm no really a friend of downgrading...
    After some more time consuming tinkering I still have no luck in giving certain files their artwork back. I better go back to 7.2 tomorrow... Apple keep that lousy 7.3.1 BS yourself

  • If I buy the Adobe Export PDF for $23.99/yr - will that allow me to work with a PDF fillable form -- then rename and save that form?

    If I buy the Adobe Export PDF for $23.99/yr - will that allow me to work with a PDF fillable form -- then rename and save that form?

    I want to fill in the blanks on a PDF form --
    Then I want to rename the form and save it.
    Beverly Visitacion
    Location Scout/Manager
    Cell:  305 322-1586
    Fax:  305 328-9666
    [email protected]
    Michael Jarvis
    Location Scout/Manager
    Cell:  305 335-6266
    [email protected]
    "ARMS & THE DUDES"

  • XsltCollaboration code file path exceeds 255 characters

    All,
    I'm trying to build a Deployment Profile for a CAPS project containing an XSLT Collaboration Definition. I managed to build the Deployment Profile previously with persistence turned off. After turning on persistence (Persistence for Reporting set to 'Yes' on the only Business Process in the project) and re-building the Deployment Profile I was greeted with an Exception dialog containing the following:
    com.stc.codegen.framework.model.CodeGenException: code generation error at = svcXCDXform - XCE CodeGen
    XsltCollaboration code file path
    C:\DOCUME~1\DAMIAN~1\LOCALS~1\Temp\builds\prjBPXformdpBPXform\svcXCDXform_ejb\xcdXform_Runtime_Handler.java
    exceeds 255 characters. Shorten XsltCollaboration name or recreate Connectivity Map with shorter name to solve this problemI don't think turning persistence on has anything to do with this error but mentioned it because that was the only change I made before re-building. Can anyone shed some light on why CodeGen is building in my local temp folder and not the Path which I have set in the Enterprise Designer | Build Options? Is this a completely different path?
    FYI - I am using Java CAPS 5.1.2.
    Thanks,
    Damian

    Change the Windows Environment Variables for the Temp folders to something like C:\TMP
    Not sure but i've noticed that the folder specified for CODEGEN_LOCATION is ignored in older versions of JCAPS.

Maybe you are looking for

  • Enable Single Window Mode in Acrobat 9

    Please re-enable the Single Window (MDI) Mode in Acrobat 9 as it is an un welcome user experience of having dozens of Acrobat windows open in the taskbar. I can suggest to have either of the following:- 1. Give an option to the user whether to open t

  • BPM not staring and meesages goes to queues

    Hi everyone I have configured multiple  inbound queues for a BPM. The BPM can execute multiple transactions, all of them are from a FIle adapter excepting 1 of them. That one is coming from a proxy on an R/3 system. But now, when the message arrives

  • How do i get auto fill to work in numbers

    hi i have a list of text in my spreadsheet colume that changes on each line. please tell me how to use auto fill thus allowing me not to write the same taxt over and over

  • ARE 1 AND ARE3

    I WANT 2 PRINT (OUT PUT )ARE1 AND ARE3 WHAT IS THE T CODE ADI

  • Change my language flag to a other flag on menu bar

    I want change my language flag icon to a other kind of flag. I got the flag icon that I want replace with.But where do I put it? Please give me step by step of what to do.