Need advice for this approach
function loadComplete(e:Event):void {}
removeChild (old_mc);
addChild (DisplayObject (LoaderInfo (e.target) content));
trace (e.currentTarget.Content.x);
trace (e.currentTarget.Content.y);
trace (e.currentTarget.Content.Width);
trace (e.currentTarget.Content.Height);
trace (stage.stageWidth);
trace (stage.stageHeight);
track works very well, but its only good for once...
}
Having main.swf object.swf loading (so for so good).
now, I need to learn to use this "e.currentTarget.content" (the object.swf who is responsible) for what I want out of this function loadComplete approach...
It would be nice if I could name and able to use... (so that I could use it to create other functions I want... but I don't know how > <)
can some1 teach me a good approach to solve my Riddle?
You should be able to simply declare a variable outside the onComplete function and assign the loaded object when the file is loaded...
var loadedSWF:MovieClip;
function loadComplete(e:Event):void {}
removeChild (old_mc);
addChild (DisplayObject (LoaderInfo (e.target) content));
loadedSWF = MovieClip (e.currentTarget.content);
}
function doStuffToSWF() {}
loadedSWF.something...
}
Tags: Adobe Animate
Similar Questions
-
Need advice on this Toshiba laptop to get
Hello
Just joined and hope im this ad in the right place. I need advice on this Toshiba laptop to get. It will be used for photo editing. Must have a 15/16 screen. Big screen would be nice. Programs that I run are Adobe and Photoshop light room. I use a wacom tablet with 2 external hard drives. It will be used manly at home and in the studio.
Thank you very much
Hi Tacker
In general I think that the best option for you is to buy notebook series Satellite A. Something like Satellite A665. It's very nice for laptop with good material and enough performance that you can use for your work.
I prefer laptops with bigger screen so for years I use Satellite P laptops with screens of 17 or 18. Right now I use the Satellite P500. It's the big machine. For me the best Toshiba laptop, I had over the past 10 years.
When you have a little time to visit Toshiba page for your country and check which models Satellite are available in your country. Choose the one with the better graphics chip, enough Ram and, of course the HARD drive with enough capacity.
Please be so kind and post comments. It will be nice to read what you think of this.
-
Hi all
I'm new to the development of Blackberry and I'm writing a relatively simple application to run on 7.1.
So far the development was interesting, I managed to create my user interface using resources online (mainly this forum), but today I tried to implement some of the network classes that I need and now I just met constant problems.
I use Eclipse SDK 3.7.2 (the one that comes with the plugin RIM)
First question:
I'm not sure what I changed, but today I noticed that whenever I start the Simulator (by sim 9360) my application is started during the initial startup process. I don't think he did this before, but to be honest, I wasn't paying much attention. I think it starts at the start of the device is because I put a breakpoint in the constructor for my class from the main screen, which is hit before the Simulator happens even to the point where it is ready for user interaction. In addition, once it is ready, if I press the BB button, I see my registered application.
I don't have it set to automatic start in .xml descriptior enforcement.
I started this application on the HelloBlackBerry sample, here is my main method for the entry of the application:
public static void main( String[] args ) { appSettings = AppSettings.fetch(); // Create a new instance of the application and make the currently // running thread the application's event dispatch thread. HelloBlackBerry theApp = new HelloBlackBerry(); theApp.enterEventDispatcher(); //openConnection(); }
As far as I know, this is the only entry point for the application.
More code
public HelloBlackBerry() { // Push a screen onto the UI stack for rendering. mainScreen = new ScreenHelloBlackBerry(); pushScreen( mainScreen ); }
Here is the method of. my class AppSettings fetch()
// Retrieves a copy of the effective properties set from storage. public static AppSettings fetch() { AppSettings savedSettings = (AppSettings) _store.getContents(); return new AppSettings(savedSettings); }
Some of this code that I wrote myself, the persistence store cause the launch of my car?
I tried to reset the Simulator to the factory settings, no change.
All applications initialized during the startup of the device and then closed shortly after?
Part 2: Need advice for the implementation of functions of network in the application
I need to implement some methods that will retrieve data from a web service, and I also need to send data to this service. What I've read, the ConnectionFactory is the way to go. I want my application to make a request when the application is open and can check on a set interval. I didn't know exactly how to go about adding another thread for networking, I understand that network connections should not be created on the thread main event, so I tried to do this:
The constructor of my class that implements screen (ScreenHelloBlackBerry), I use the following to create a modal dialog box to prompt the user for a username, I also try networking wire in the same segment of spawning:
public ScreenHelloBlackBerry(){...initialize fields and managers, add it all together...then near the end //This will open the confirm dialog when the application is launched UiApplication.getUiApplication().invokeLater(new Runnable() { public void run() { openConfirmDialog(); //start connection - Possibly broken ConnectionThread ct = new ConnectionThread(); ct.start(); } });
I don't know if it's somehow OK to do, but it seems to work for what I need. I want a user who launches the application at the prompt, and if a user switch applications, when they come back they wondered again (unless they close the app and reopen it).
Here is my ConnectionThread:
public class ConnectionThread extends Thread { public void run() { ConnectionFactory connFact = new ConnectionFactory(); ConnectionDescriptor connDesc; connDesc = connFact.getConnection("http://www.google.com"); if (connDesc != null) { HttpConnection httpConn; httpConn = (HttpConnection)connDesc.getConnection(); try { final int iResponseCode = httpConn.getResponseCode(); UiApplication.getUiApplication().invokeLater(new Runnable() { public void run() { Dialog.alert("Response code: " + Integer.toString(iResponseCode)); } }); httpConn.close(); } catch (IOException e) { System.err.println("Caught IOException: " + e.getMessage()); } } } }
At the moment it has basically unmodified code from a sample that I found, I'll be retooling to meet my needs whenever I can make it work. I HAD this work to the point where, after the closed user confirm this dialog, a few moments later a an alert dialog appears with the 302 response code. I don't know what changed, but now it doesn't work at all, and if I try to scroll with the debugger, I can't past the httpCon.getResponseCode (). I've seen some mistakes earlier on "no record of service was set up", and I also had once a timeout exception.
I'm sure I'm doing this wrong, but at the same time as I said WAS working, and now it is not. If someone has done this far, thank you very much for your time and advice are much appreciated.
Also, should I try to start the thread of the network of the UIApplication class instead of the screen? There is currently very little happening in the class that extends UIApplication, do I spend most of my business logic out of the class of the screen and in the UIApplication class?
Thanks in advance!
Hi all
Just to conclude this topic for those who are interested, I found an excellent guide to the implementation of networks in applications of BB, click here for a link.
About my application being started at the start of the simulator of the device, I found that on a device real this behavior is not complied with, and in addition, the behaviour seems to have stopped after uninstallation and reinstallation of my Simulator.
See you soon,.
-
I need to create combinations of text and images for the web. How to do this in elements or do I need Photoshop for this feature? Please advise!
slynn5236 wrote:
I need to create combinations of text and images for the web. How to do this in elements or do I need Photoshop for this feature? Please advise!
You can do in PSE.
- Do the math to see how much space you'll need on your canvas to the image and text.
- Navigate to the file queue > new.blank. Enter the width & height, background color, resolution 72 px / in. It is your canvas, and in the layers palette will be the background layer.
- Copy and paste the image. It turns on a separate layer
- Activate the tool move, position the image and resize if necessary
- Activate the text tool, and then type your text. It will be on a separate so layer
- Position the text.
- Flatten layers and go to file > save for web. I'm usually on the long side about 800 px. Don't forget to check "constrain proportions". Adjust the quality slider to suit. You will probably want the type of JPEG file for web work.
-
Please I need advice for deployment with multiple screen resolutions
Hello
Sorry for my English
I am developing a project in labview with a PC (screen resolution 1920 * 1080) and I need to deploy to run on a PC with (screen resolution 1024 * 768 10 "), I use several spliters for this so I need some advice to make sure my exe not working
very well in this PC target so I need to know how to configure my principal vi; size of the window in the execution; etc... in my PC all work fine I can reduce window and blow it up when the project is running and all the objects have been scaling very
well I don't know what will happen in this target pc.
advice and assistance please
Hey Broutchoux,.
Here are some links of the knowledge base that relate to this issue.
http://digital.NI.com/public.nsf/allkb/7567EF257B9CFDF986256F630073228F?OpenDocument
http://digital.NI.com/public.nsf/allkb/4C03BE7BFD1D00948625670B0061CB6A?OpenDocument
I hope this helps!
-
Help, please! I need advice for choosing what Photoshop CS I need?
Hello
I have a problem with importing photos from my Nikon D60 RAW in my Photoshop.
I need to know that Photoshop CS will be the best and work?
I have Windows XP, enough RAM and hard drive space, which should not be a problem.
But I need the most recent version and the best possible Photoshop CS that will allow me to work on my photos in RAW.
Any advice?
You probably want to Photoshop CS5, but you can check yourself what version of Camera Raw supports your camera by doing this:
1. go to this page:
http://www.Adobe.com/support/downloads/product.jsp?product=39&platform=Windows
2 find the Camera Raw updates listed in the directed blocks with names like 'Version CS5' and 'Version CS4'.
3. click on the last being a given block (for example, 'Update Camera Raw 5.7' for CS4).
4. click on Camera Raw ReadMe x.x link on the page that is displayed for this version.
5. search the list of supported cameras and see if yours is in it.
You probably want CS5 because even if your D60 seems to be taken in charge by Photoshop CS4, it is quite difficult to buy a copy of Photoshop CS4 new more, I said.
-Christmas
-
Need advice for installing Win7 on Satellite A300
Hello
I intend to buy Satellite A300-1MT (PSAGCE), and before I do I just check if there are still some problems with drivers for W7 for this model?
On other forums, I saw that there are some problems with drivers like music keys, webcam, touchpad and FN keys and so on...So, can someone confirm me that all drivers are now available and everything works?
And also until I started installing drivers is there anything I need to know (wait used?) Or perhaps better: does anyone have a special notice?
Please, find the will to respond! Thank you very much!
Hello
I have the Satellite A300 running Win7 32 bit, but my model is PSAG8E.
To be honest I have very good experience with installing Win7 on Satellite A300 and I can recommend you to install on this Satellite.If you visit the Toshiba support page under http://eu.computers.toshiba-europe.com > support & downloads you will see that your laptop model is supported Win7 and it shouldn't be problem to install all the necessary drivers and other stuff of Toshiba.
Here is the list how I did this exactly:
atellite A300 (PSAG8E) and clean Win7-Win7
-chipset driver
-Storage Manager
-display driver
-driver sound
-modem driver
-utility supervisor
-infrared
-patches 1.2
-configfree
-VAP
Hardware - toshiba
Control - HDMI
-WLAN driverEverything works well but lacks some drivers
Added Vista tips:
Toshiba - help - working properly
-Card reader - installed correctly
-Webcam driver for A500 - tested with Skype - works correctly.
Driver - SynapticsWin7 works well and I am very satisfied. No problems with the feature keys FN.
If you are going to buy this laptop start installation Win7 following this order of installations. Please inform us of problems and I hope that we can help you about this.
-
Need advice for the purchase of a mini PCI Wireless
Hello
I have a laptop Toshiba I bought nearly two years ago. This laptop has an Intel 2200BG wireless chipset, which works, but the quality of connection is quite low. Sometimes, the connection speed climbs, sometimes it falls in total. I tried all the updates driver, power management tips and everything that could be found on the net. Some of these help, but there is always something that doesn't work as it should.
Long story short, I decided to buy a mini pci wireless card. The problem is that these cards are nowhere to find. There is nothing on the Toshiba site, and apart from a few offers on eBay, there is almost nothing to choose. I know there are other options, but I prefer a mini pci card.
Can someone help me on this issue?
Thank you
Peter.
Hi Peter
Can you please tell us which laptop model you have?
In any case, the network without WIRE Intel 2200BG card is good enough and works very well on my Satellite M70 (with the latest driver). Download speed is very good and I do not need a wireless network card. I don't know what is the problem with WLAN connection in your case, but please try to test with another router WLAN (maybe your friends have all other routers). Also, install the latest WLAN driver for this card.
-
I need solution for this...
Hi all... I am a beginner in blackberry development.
The code below is every time we click the ok button, it retrieves the content of the
Saran.txt the SD card file and displays them on the screen. So far so good, but the problem
is whenever I click on ok again, the content is displayed again. I don't want it to be
displayed again instead, I want that he should be replaced. I am facing this kind of problem with all areas
that appears on the screen, that is to say, the second time I click the button only one copy of this field is
display again.
can someone suggest a solution for this...
package myText; import java.io.*; import javax.microedition.io.Connector; import javax.microedition.io.HttpConnection; import javax.microedition.io.file.FileConnection; import net.rim.device.api.io.transport.ConnectionDescriptor; import net.rim.device.api.io.transport.ConnectionFactory; import net.rim.device.api.system.Bitmap; import net.rim.device.api.system.EncodedImage; import net.rim.device.api.system.PNGEncodedImage; import net.rim.device.api.ui.component.*; import net.rim.device.api.ui.container.MainScreen; import net.rim.device.api.ui.*; public class myText extends UiApplication { public static void main(String[] args) throws IOException { myText theApp = new myText(); theApp.enterEventDispatcher(); } public myText() throws IOException { new Textdisplay(); } } final class Textdisplay implements FieldChangeListener { MainScreen mainScreen=new MainScreen(); ButtonField ok=new ButtonField("OK"); //HttpConnection hc; //String url = "http://wordpress.org/extend/plugins/about/readme.txt"; //InputStream is=null; public Textdisplay() throws IOException { UiApplication.getUiApplication().pushScreen(mainScreen); mainScreen.setTitle("Text file Fetching......"); mainScreen.add(ok); ok.setChangeListener(this); } /*public void downloading() throws IOException { ConnectionFactory connFact = new ConnectionFactory(); ConnectionDescriptor connDesc; connDesc = connFact.getConnection(url); if (connDesc != null) { HttpConnection httpConn; httpConn = (HttpConnection)connDesc.getConnection(); try { final int iResponseCode = httpConn.getResponseCode(); Dialog.alert("Response.. code: "+Integer.toString(iResponseCode)); mainScreen.add(new LabelField(httpConn.getHost()+"\n"+httpConn.getRequestMethod())); is=httpConn.openInputStream(); StringBuffer buffer= new StringBuffer(); int chars; while((chars = is.read()) != -1) { buffer.append((char) chars); } String text = new String(buffer); mainScreen.add(new LabelField(text)); } catch (IOException e) { System.err.println("Caught IOException: " + e.getMessage()); } } } */ public void Fetching() throws IOException { String path = "file:///SDCard/BlackBerry/textfiles/saran.txt"; FileConnection FileConn=null; InputStream is=null; TextField label = null; int chars; Dialog.alert("entering"); try{ FileConn = (FileConnection) Connector.open(path,Connector.READ); Dialog.alert("file connection"); if(!FileConn.exists()){ FileConn.create(); } Dialog.alert("connection created"); //int length = (int) FileConn.fileSize(); //byte[] data = new byte[length]; is = FileConn.openInputStream(); //dis.readFully(data); Dialog.alert("not yet"); StringBuffer buffer= new StringBuffer(); while((chars = is.read()) != -1) { buffer.append((char) chars); } String text = new String(buffer); Dialog.alert("Click to read data......."); label.setText(text); mainScreen.add(label); is.close(); } catch(Exception e){ System.out.println("file not found:" + e); Dialog.alert("file not found"+e); } finally { try{ FileConn.close(); } catch(Exception e){} } } public void fieldChanged(Field f, int context) { try { //Dialog.alert("Fetching the file......."); mainScreen.add(new LabelField("Fetching the data...........")); Fetching(); } catch (Exception e) { e.printStackTrace(); } } }
In your current code, ButtonField 'ok' is global, so you can refer to this anywhere. Add a BitmapField which is overall too. And then in your transformation, set this to the new Bitmap that you created and invalidate the screen (mainScreen.invalidate ()).
If you add a BitmapField and it doesn't have a bitmap, it will not display.
-
Hello
I want to set up a virtual server for application for test purposes. I want to set up two servers on which is MS SQL Server and MS Windows Server 2008 virtual machine that will host ASP.NET applications that we want to test. Here are my questions:
I was told that there is a free version of VMWare for this purpose. Should which product I?
Can I get a cheap, generic PC and set up as my VMWare hardware? For example, I'd like to get a low-cost Dell PC and set up as my server. How can ensure me that I will be able to install VMWare on it? Should I worry of driver problems, incompatibility, etc.
I have a few tips for getting started. Thank you.
VMware Server 2.0 is completely free to use and it rips. It runs on a Linux or Windows (Server officially but it can run on XP/Vista) host so will use the drivers that the host has for storage, network, etc. These devices are not available directly in the comments, because the client uses devices virtualized VMware fits your real hardware for you. This means that you have driver issues to your guests, unless you want to use USB devices plugged into the host since this will force the drivers are installed in the comments.
---
If you have found this device or any other answer useful please consider the use of buttons useful or Correct to award points.
-
Hi gurus
need help with this query,
I want to display the records in the table emp
I want just the recordsSQL> Select Deptno,sal,sal/SUMSAL Percent,rn 2 From ( Select emp.*,Sum(Sal) Over() "SUMSAL",Row_number() Over(Order by sal Desc) rn 3 From emp 4 ) 5 / EMPNO DEPTNO SAL PERCENT RN --------- ---------- ---------- ---------- ---------- 7839 10 5000 .172265289 1 7902 20 3000 .103359173 2 7788 20 3000 .103359173 3 7566 20 2975 .102497847 4 7698 30 2850 .098191214 5 7782 10 2450 .084409991 6 7499 30 1600 .055124892 7 7844 30 1500 .051679587 8 7934 10 1300 .044788975 9 7521 30 1250 .043066322 10 7654 30 1250 .043066322 11 7876 20 1100 .037898363 12 7900 30 950 .032730405 13 7369 20 800 .027562446 14 14 rows selected.
Thank youEMPNO DEPTNO SAL PERCENT RN ---------- ---------- ---------- ---------- ---------- 7839 10 5000 .172265289 1 7902 20 3000 .103359173 2 7788 20 3000 .103359173 3 7566 20 2975 .102497847 4 7698 30 2850 .098191214 5 with sum (Percent) of remaing records..... Others .420327304
Published by: SeenuGuddu on February 27, 2011 03:39with a as ( Select Empno, Deptno ,sal, sal/SUMSAL Percent, case when rn<=5 then rn else null end rnm From (Select emp.*, Sum(Sal) Over() "SUMSAL", Row_number() Over(Order by sal Desc) rn From emp) ) select case when max(rnm) is not null then to_char(max(empno)) else 'Others:' end empno, case when max(rnm) is not null then max(deptno) else null end deptno, case when max(rnm) is not null then max(sal) else null end sal, to_char(sum(percent), '90.99') percent, max(rnm) rn from a group by rnm order by rnm
EMPNO DEPTNO SAL PERCENT RN ---------------------------------------- ---------------------- ---------------------- ------- ---------------------- 7839 10 5000 0.17 1 7902 20 3000 0.10 2 7788 20 3000 0.10 3 7566 20 2975 0.10 4 7698 30 2850 0.10 5 Others: 0.42 6 rows selected
-
Need advice for controller Ethernet Intel X 540 - AT2
Hello
I'm having no chance whatsoever, get a map of X 540 - AT2 running on ESXi 6.0.0U2. I tried several different pilot plants, the last of them being net - ixgbe_3.21.6 - 1OEM.600.0.0.2159203.vib. It is a new facility, said the driver.
esxi6: / # esxcfg - NICS - l
Name PCI Driver link speed Duplex MAC address MTU Description
vmnic0 0000:01:00.0 e1000e up to 1000Mbps Full 00:25:90:2 has: 9e:82 1500 Intel Corporation 82574 L Gigabit Network Connection
vmnic1 0000:02:00.0 e1000e up to 1000Mbps Full 00:25:90:2 has: 9e:83 1500 Intel Corporation 82574 L Gigabit Network Connection
esxi6: / # lspci | grep vmnic
0000:01:00.0 Network controller: Intel Corporation 82574 L Gigabit Network Connection [vmnic0]
0000:02:00.0 Network controller: Intel Corporation 82574 L Gigabit Network Connection [vmnic1]
0000:05:00.0 network controller: controller Ethernet Intel (r) X 540 - AT2 [vmnic2]
0000:05:00.1 network controller: controller Ethernet Intel (r) X 540 - AT2 [vmnic3]
The driver has been downloaded from VMware. Do I need a different driver, or does this card at all?
Thank you
Jack
Update: I ran across the compatibility matrix after execution of these:
[root@localhost:~] lspci - v | grep-A1 ethernet-i
0000:01:00.0 Ethernet controller network controller: Intel Corporation 82574 L Gigabit Network Connection [vmnic0]
Class 0200: 8086:10 d 3
--
0000:02:00.0 Ethernet controller network controller: Intel Corporation 82574 L Gigabit Network Connection [vmnic1]
Class 0200: 8086:10 d 3
--
0000:05:00.0 Ethernet controller network controller: controller Ethernet Intel (r) X 540 - AT2 [vmnic2]
Class 0200: 8086:1528
--
0000:05:00.1 Ethernet controller network controller: controller Ethernet Intel (r) X 540 - AT2 [vmnic3]
Class 0200: 8086:1528
[root@localhost:~] lspci - n | grep 8086:1528
0000:05:00.0 class 0200: 8086:1528 [vmnic2]
0000:05:00.1 class 0200: 8086:1528 [vmnic3]
I found myself here:
https://my.VMware.com/group/VMware/details?downloadGroup=DT-ESXI55-Intel-IXGBE-4.4.1&ProductID=353
I installed the driver on 5.5. Verification of vmkernel.log I found this:
2016-05 - 05 T 05: 23:50.921Z cpu13:33463) loading module IGB...
2016-05 - 05 T 05: 23:50.924Z cpu13:33463) Elf: 1861: module IGB a GPL license
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) bunch of module: initial heap size: 102400, max heap size: 68476928
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) vmklnx_module_mempool_init: Mempool max 68476928 used for the module: 4124
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) vmk_MemPoolCreate passed for 25 pages
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) skb_mem_info mempool for IGB module created - size max 134217728
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) bunch of module: using memType 0
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) vmklnx_ixgbe bunch of module: creation succeeded. ID = 0x410a03ab1000
2016-05 - 05 T 05: 23:50.927Z cpu13:33463)<6>Intel(r) 10 Gigabit PCI Express Network Driver - version 3.7.13.7.14iov - NAPI
2016-05 - 05 T 05: 23:50.927Z cpu13:33463)<6>Copyright (c) 1999-2011 Intel Corporation.
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) PCI: IGB driver is looking for devices
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) DMA: 612: DMA engine ' vmklnxpci - 0:5:0.0' created using the Mapper "DMANull."
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) DMA: 612: DMA engine ' vmklnxpci - 0:5:0.0' created using the Mapper "DMANull."
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) DMA: 612: DMA engine ' vmklnxpci - 0:5:0.0' created using the Mapper "DMANull."
2016-05 - 05 T 05: 23:50.927Z cpu13:33463) DMA: 657: DMA engine ' vmklnxpci - 0:5:0.0' destroyed.6>6>
2016-05 - 05 T 05: 23:51.109Z cpu13:33463)<6>ixgbe: ANC toggle the value 1
2016-05 - 05 T 05: 23:51.109Z cpu13:33463)<6>ixgbe: 0000:05:00.0: ixgbe_check_options: active ANC, queues 1
2016-05 - 05 T 05: 23:51.109Z cpu13:33463)<6>ixgbe: 0000:05:00.0: ixgbe_check_options: split package is not supported.6>6>6>
2016-05 - 05 T 05: 23:51.143Z cpu13:33463)<3>0000:05:00.0 ixgbe: the EEPROM Checksum is invalid
2016-05 - 05 T 05: 23:51.143Z cpu13:33463) WARNING: vmklinux: pci_announce_device:1488: PCI: probe IGB driver failed for device 0000:05:00.0
There you have it. Looks like a bad EEPROM/card.
3> -
create or replace trigger aifer_transfer
After Insert on transfer
for each new row
Start
UPDATE account SET balance = balance -: new .amount
WHERE acc_id = from_acc_id;
UPDATE account SET balance = balance +:new.amount
WHERE acc_id = to_acc_id;
end if;
end;
create or replace trigger bifer_transfer
before inserting the transfer
for each new row
Start
If get_balance(:new.from_acc_id) <: new.amount
then
raise_application_error (-20001, "not enough money in the account. '");
end if;
end;
create or replace function get_balance (p_acc_id number)
Return number
as
v_balance account.balance%type;
Start
Select balance
in v_balance
account
where acc_id = p_acc_id; Return v_balance;
end;
Select get_balance (123) double
..................................................
I get this error during the execution of the trigger
..................................................
Error report:
ORA-01912: ROW keyword expected
01912 00000 - "keyword LINE WAITED.
* Cause: Missing keyword
* Action: provide the missing key
You need to compile under the correct code.
create or replace trigger aifer_transfer
After Insert on transfer
for each line
Start
UPDATE account SET balance = balance -: new .amount
WHERE acc_id =: new.from_acc_id;
UPDATE account SET balance = balance +:new.amount
WHERE acc_id =: new.to_acc_id;
-end if;
end;
create or replace trigger bifer_transfer
before inserting the transfer
for each line
Start
If get_balance(:new.from_acc_id)<>
then
raise_application_error (-20001, "not enough money in the account. '");
end if;
end;
-
Need advice for the graphic shape on the image display
I would like to help plot a circle above an image that is displayed in the get in JLabel, the purpose is, when you click on the image, the image with a small circle apperas instead, we clicked. I used JLabel to display image in get by using imageLabel.setIcon (new ImageIcon("default.jpg"));
I need to draw the circle/rectangle when I click on the image that I need to select the different points of the image by drawing rectangles circles above the image.
If you understand my problem, please guide me for the same thing.
Thank youCreate your own class that extends JPanel, substitute the paintComponent() method to draw the background image, then go through a list of points where the user has clicked (you'll need to track clicks too) and draw circles it.
Stick this Panel in your get the label place.That's how I'd do it (then again once, I'm not big on Swing these days).
-
Need advice for optimizing query for the use of function UPPERCASE
I would like to know if it would make a difference if I use the UPPER function in the WHERE clause compared to use in the SELECT statement. For example:
In the above code, it will make difference if I move function SHIFT of the WHERE clause of a SELECT statement in the inner query as SUPERIOR (CGI. STAT_NAME STAT_NAME)? There will be no long-term performance gain?SELECT 2 AS ORDERID, 'OFFC' AS RESULTTYPE, OFFC_CD AS GROUPCOL, SUM(FACE_AMT) AS TOT_FACE_AMT, SUM(PROJ_PREM_AMT) AS TOT_PROJ_PREM_AMT, COUNT(*) AS TOT_NUM_CASES, 'YTD' AS RPTTYP FROM ( SELECT FMI.ACCT_GRP_ID, FMI.GA_CD, FMI.OFFC_CD, FMI.GROUP_REALLOCATION, FMI.STAT_NAME ,CASE WHEN FMI.GROUP_REALLOCATION = 'Y' THEN SUM(NVL(FMI.FACE_AMT,0)) OVER (PARTITION BY FMI.ACCT_GRP_ID, FMI.AGNT_NAME, FMI.STAT_NAME, FMI.GROUP_REALLOCATION, FMI.LOB_NAME ORDER BY FMI.CA_CS_NUM DESC) ELSE NVL(FMI.FACE_AMT,0) END FACE_AMT ,CASE WHEN FMI.GROUP_REALLOCATION = 'Y' THEN SUM(NVL(FMI.PROJ_PREM_AMT,0)) OVER (PARTITION BY FMI.ACCT_GRP_ID, FMI.AGNT_NAME, FMI.STAT_NAME, FMI.GROUP_REALLOCATION, FMI.LOB_NAME ORDER BY FMI.CA_CS_NUM DESC) ELSE NVL(FMI.PROJ_PREM_AMT,0) END PROJ_PREM_AMT ,RANK() OVER (PARTITION BY FMI.ACCT_GRP_ID, FMI.AGNT_NAME, FMI.STAT_NAME, FMI.GROUP_REALLOCATION, FMI.LOB_NAME ORDER BY FMI.CA_CS_NUM) RANKING FROM IFV_FLD_MGMT_INFO FMI JOIN IFT_BAT_PARM BP ON FMI.LST_STAT_DT >= (TO_DATE('01/01/' || TO_CHAR(TO_DATE(BP.PARM_DAT_VAL, 'YYYYMMDD'), 'YYYY'), 'MM/DD/YYYY')) AND BP.BAT_ID = 'CMISFLDMGMT_DT' WHERE FMI.OFFC_CD IN (pOffcCd) AND FMI.SHOWINFMR = 'Y' ) WHERE ((GROUP_REALLOCATION = 'Y' AND RANKING = 1) OR (GROUP_REALLOCATION = 'N')) AND UPPER(STAT_NAME) = 'PLACED' GROUP BY OFFC_CD
Published by: Kuul13 on July 13, 2009 12:25Hello
Kuul13 wrote:
...
In the analytical functions d0 you want
PARTITION BY stat_name or
PARTITION OF SUPERIOR (stat_name)?
This will really make the difference in the wy data will be partitioned?Yes.
PARTITION BY x means the same as
PARTITION BY y only if x = y. If stat_name = HIGH (stat_name), then why you never bother to say UPPER (stat_name)?If so, then I guess that it may be prudent to use UPPER (STAT_NAME) in the IFV_FLD_MGMT_INFO that is used in the inner query view. In this way, I simply keep the changes in the view and all other queries that use this point of view (as in my example) can directly use STAT_NAME = 'PLACÉ' and not no longer necessary to change the column in the PARTITION clause. What is your suggestion?
That would certainly make the simplest coding. If the person who uses the display needs the stat_name unconverted, then I think that changing the display is a good idea.
Also, I can't move where the query condition internal because it will give me different results.
As far as I know, this would make the subquery produce fewer lines (that's why it would be more efficient). Since you are partitioning by stat_name, lines which produced the subquery would be identical to the lines he now produces and are kept by the Super request. I do not have your tables, so I can't test it really,
Maybe you are looking for
-
retina iMac with wireless mouse problems
Since I use el capitan intermittently my wireless mouse goes crazy. When you try to connect it begins to fill in the space. Make a stop down then its ok for a few days. When connected to the photo and right click on a photo to go to the adjacent ph
-
Mass USB storage does not work on the Satellite a series
When I connect any USB mass (as USB or card reader) storage, system slowly recognize it for about 5 minutes and then show a new drive letter. When I try to open it - the system is long overdue. I had restored an original condition of restore CD Set,
-
Word tries to open the file pdf
I had Word 2003 and Adobe 7 on my computer for an extended period without any problem. All of a sudden when I try to open a PDF file, it tries to open in Word and I get the small window "file conversion" opened in the blank Word window. Something cha
-
I have a laptop when I use the wireless at home I have no problem, but when I use the internet at work I can not connect it says Internet Explore cannot display the Web page so I have no internet access Can you help me
-
por as mi camara not web no works para hacer llamada video y Skype video call
No it could use the web camara to pc portatil para messenger or Skype para mi. Gracias TR me puden help