DW - Insert video flash path FROM DATABASE..?

Hello,
why is not possible insert a video flash in asp page (path
from "data
soure" ) where the path if a data field from database(
<%=(video.Fields.Item("videfile").Value)%> )..?
If try error tell: URL can not contain space or special font,
modify the
path or filename and retry
How i can do..?
Thanks much
Paolo
La mia Cartella di Posta in Arrivo è protetta con
SPAMfighter
7736 messaggi contenenti spam sono stati bloccati con
successo.
Scarica gratuitamente SPAMfighter!

You might want to try Server.URLEncode.
<%=Server.URLEncode(video.Fields.Item("videfile").Value)%>

Similar Messages

  • Getting image path from database( Remote server)  & display in jsp page

    hai frnds,
    i have one doudt regarding in my web application Development
    . I want to Getting image path from database( **Remote server**) & display in jsp page here iam forwarding my control through Servlets
    how this will passiable
    Thanks in Advance
    SonyKamesh
    [email protected]

    hai
    I think ur doubt will be...
    1) Getting a Image From Remote Server( & U stored a only path name in Data Base)
    2) Image r stroed in saparate Drive( Not in Webroot-- where u Created domine )
    Please Any Help Will be Appriciated
    [email protected]
    Edited by: Sonykamesha on Dec 18, 2007 11:02 PM

  • Playing a video file retrieved from database using JMF

    Hello!
    I am developing a multimedia application that has to store videos, music, pictures in a database. I did a little searching and found that JMF is a very good solution in playing video/music using Java. I found some examples to play the video/music stored on the hard drive (as separate files), but i have to be able to take the video/music from the database, and feed it to the JMF player. Has anyone some suggestions about how this could be done?
    Thanks in advance!
    Edited by: radu.miron on May 8, 2008 9:03 AM

    Well, i think i didn't make myself clear enough :). i know how to retreive the data from the database. The thing is this: let's suppose i have a 700 MB movie stored in the database. One option to play that movie would be to retrieve it from the DB, create a file somewhere on the disk, and put the data retrieved from the database in that file. But this involves that the disk will be overflooded when let's say 100 people watch 100 different movies. Another option (as i see it) would be to gradually take parts of the movie from the database (first 50 MB, then another 50 MB, then another and so on), and feed it to the JMF player. The user will watch the movie, but will not have the whole movie available, just a part of it. As he watches it, the application takes the next chunck of movie data and feeds it to the JMF player. That was the question i intended to ask, if anyone has any idea regarding the second option, and not the part with retrieving from the database, but the part with giving the JMF player video data to play.
    The example i found on the web with JMF player is the following:
    import javax.swing.*;*
    *import javax.media.*;
    import java.awt.*;*
    *import java.awt.event.*;
    import java.net.*;*
    *import java.io.*;
    public class PlayVideo extends JFrame {
         Player player;
         Component center;
         Component south;
         public PlayVideo() {
              setDefaultCloseOperation(EXIT_ON_CLOSE);
              JButton button = new JButton("Select File");
              ActionListener listener =
                   new ActionListener() {
                   public void actionPerformed(
                             ActionEvent event) {
                        JFileChooser chooser =
                             new JFileChooser(".");
                        int status =
                             chooser.showOpenDialog(PlayVideo.this);
                        if (status ==
                             JFileChooser.APPROVE_OPTION) {
                             File file = chooser.getSelectedFile();
                             try {
                                  load(file);
                             } catch (Exception e) {
                                  System.err.println("Try again: " + e);
              button.addActionListener(listener);
              getContentPane().add(button,
                        BorderLayout.NORTH);
              pack();
              show();
         public void load(final File file)
         throws Exception {
              URL url = file.toURL();
              final Container contentPane =
                   getContentPane();
              if (player != null) {
                   player.stop();
              player = Manager.createPlayer(url);
              ControllerListener listener =
                   new ControllerAdapter() {
                   public void realizeComplete(
                             RealizeCompleteEvent event) {
                        Component vc =
                             player.getVisualComponent();
                        if (vc != null) {
                             contentPane.add(vc,
                                       BorderLayout.CENTER);
                             center = vc;
                        } else {
                             if (center != null) {
                                  contentPane.remove(center);
                                  contentPane.validate();
                        Component cpc =
                             player.getControlPanelComponent();
                        if (cpc != null) {
                             contentPane.add(cpc,
                                       BorderLayout.SOUTH);
                             south = cpc;
                        } else {
                             if (south != null) {
                                  contentPane.remove(south);
                                  contentPane.validate();
                        pack();
                        setTitle(file.getName());
              player.addControllerListener(listener);
              player.start();
         public static void main(String args[]) {
              PlayVideo pv = new PlayVideo();
    }but this example plays a video stored on the disk ( player = Manager.createPlayer(url); ), rather than a chunck of data (the whole movie or parts of it) retrieved from the database.
    Sorry for the misunderstanding!
    Cheers!

  • Video file path from HTML - Urgent

                Hi
                I have created a simple imported video in actionscript 3.0 and it works fine when I play it. Since I am a newbie, can anyone guide me
                how do I specify the filepath from HTML, e.g. in the HTML how can i specify <param name="filepath" value="videoname.flv" />. If anyone has
                any link to a tutorial, it would be great.
                Thanks

    Use FlashVars and read them in LoaderInfo:
    http://kb2.adobe.com/cps/164/tn_16417.html
    http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/display/LoaderInf o.html

  • Help inserting a flash video into my web page

    Hello!
    I'd love some help inserting a flash video into my web page. My web page is hosted by Viviti, templated, and edited online. I can add html to it, and I have the html source for my flash video. I also have uploaded the flash file to the server. Since I am very html illiterate, though, I need some help rewriting the html script so it can be published. There are two problems- firstly, no 'headers' or 'body' allowed in the script- these are already a part of the template. Secondly, I don't know how to rewrite it to refer to the uploaded files. It's also imperative that the full screen mode functions. I've pasted the source code for the flash video here. Please help!!!
    Thanks!
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>Drag and drop labelling</title>
    <script language="JavaScript" type="text/javascript">
    <!--
    //v1.7
    // Flash Player Version Detection
    // Detect Client Browser type
    // Copyright 2005-2008 Adobe Systems Incorporated.  All rights reserved.
    var isIE  = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;
    var isWin = (navigator.appVersion.toLowerCase().indexOf("win") != -1) ? true : false;
    var isOpera = (navigator.userAgent.indexOf("Opera") != -1) ? true : false;
    function ControlVersion()
         var version;
         var axo;
         var e;
         // NOTE : new ActiveXObject(strFoo) throws an exception if strFoo isn't in the registry
         try {
              // version will be set for 7.X or greater players
              axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");
              version = axo.GetVariable("$version");
         } catch (e) {
         if (!version)
              try {
                   // version will be set for 6.X players only
                   axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");
                   // installed player is some revision of 6.0
                   // GetVariable("$version") crashes for versions 6.0.22 through 6.0.29,
                   // so we have to be careful.
                   // default to the first public version
                   version = "WIN 6,0,21,0";
                   // throws if AllowScripAccess does not exist (introduced in 6.0r47)          
                   axo.AllowScriptAccess = "always";
                   // safe to call for 6.0r47 or greater
                   version = axo.GetVariable("$version");
              } catch (e) {
         if (!version)
              try {
                   // version will be set for 4.X or 5.X player
                   axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3");
                   version = axo.GetVariable("$version");
              } catch (e) {
         if (!version)
              try {
                   // version will be set for 3.X player
                   axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash.3");
                   version = "WIN 3,0,18,0";
              } catch (e) {
         if (!version)
              try {
                   // version will be set for 2.X player
                   axo = new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
                   version = "WIN 2,0,0,11";
              } catch (e) {
                   version = -1;
         return version;
    // JavaScript helper required to detect Flash Player PlugIn version information
    function GetSwfVer(){
         // NS/Opera version >= 3 check for Flash plugin in plugin array
         var flashVer = -1;
         if (navigator.plugins != null && navigator.plugins.length > 0) {
              if (navigator.plugins["Shockwave Flash 2.0"] || navigator.plugins["Shockwave Flash"]) {
                   var swVer2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";
                   var flashDescription = navigator.plugins["Shockwave Flash" + swVer2].description;
                   var descArray = flashDescription.split(" ");
                   var tempArrayMajor = descArray[2].split(".");               
                   var versionMajor = tempArrayMajor[0];
                   var versionMinor = tempArrayMajor[1];
                   var versionRevision = descArray[3];
                   if (versionRevision == "") {
                        versionRevision = descArray[4];
                   if (versionRevision[0] == "d") {
                        versionRevision = versionRevision.substring(1);
                   } else if (versionRevision[0] == "r") {
                        versionRevision = versionRevision.substring(1);
                        if (versionRevision.indexOf("d") > 0) {
                             versionRevision = versionRevision.substring(0, versionRevision.indexOf("d"));
                   var flashVer = versionMajor + "." + versionMinor + "." + versionRevision;
         // MSN/WebTV 2.6 supports Flash 4
         else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.6") != -1) flashVer = 4;
         // WebTV 2.5 supports Flash 3
         else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.5") != -1) flashVer = 3;
         // older WebTV supports Flash 2
         else if (navigator.userAgent.toLowerCase().indexOf("webtv") != -1) flashVer = 2;
         else if ( isIE && isWin && !isOpera ) {
              flashVer = ControlVersion();
         return flashVer;
    // When called with reqMajorVer, reqMinorVer, reqRevision returns true if that version or greater is available
    function DetectFlashVer(reqMajorVer, reqMinorVer, reqRevision)
         versionStr = GetSwfVer();
         if (versionStr == -1 ) {
              return false;
         } else if (versionStr != 0) {
              if(isIE && isWin && !isOpera) {
                   // Given "WIN 2,0,0,11"
                   tempArray         = versionStr.split(" ");      // ["WIN", "2,0,0,11"]
                   tempString        = tempArray[1];               // "2,0,0,11"
                   versionArray      = tempString.split(",");     // ['2', '0', '0', '11']
              } else {
                   versionArray      = versionStr.split(".");
              var versionMajor      = versionArray[0];
              var versionMinor      = versionArray[1];
              var versionRevision   = versionArray[2];
                 // is the major.revision >= requested major.revision AND the minor version >= requested minor
              if (versionMajor > parseFloat(reqMajorVer)) {
                   return true;
              } else if (versionMajor == parseFloat(reqMajorVer)) {
                   if (versionMinor > parseFloat(reqMinorVer))
                        return true;
                   else if (versionMinor == parseFloat(reqMinorVer)) {
                        if (versionRevision >= parseFloat(reqRevision))
                             return true;
              return false;
    function AC_AddExtension(src, ext)
      if (src.indexOf('?') != -1)
        return src.replace(/\?/, ext+'?');
      else
        return src + ext;
    function AC_Generateobj(objAttrs, params, embedAttrs)
      var str = '';
      if (isIE && isWin && !isOpera)
        str += '<object ';
        for (var i in objAttrs)
          str += i + '="' + objAttrs[i] + '" ';
        str += '>';
        for (var i in params)
          str += '<param name="' + i + '" value="' + params[i] + '" /> ';
        str += '</object>';
      else
        str += '<embed ';
        for (var i in embedAttrs)
          str += i + '="' + embedAttrs[i] + '" ';
        str += '> </embed>';
      document.write(str);
    function AC_FL_RunContent(){
      var ret =
        AC_GetArgs
        (  arguments, ".swf", "movie", "clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"
         , "application/x-shockwave-flash"
      AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
    function AC_SW_RunContent(){
      var ret =
        AC_GetArgs
        (  arguments, ".dcr", "src", "clsid:166B1BCA-3F9C-11CF-8075-444553540000"
         , null
      AC_Generateobj(ret.objAttrs, ret.params, ret.embedAttrs);
    function AC_GetArgs(args, ext, srcParamName, classid, mimeType){
      var ret = new Object();
      ret.embedAttrs = new Object();
      ret.params = new Object();
      ret.objAttrs = new Object();
      for (var i=0; i < args.length; i=i+2){
        var currArg = args[i].toLowerCase();   
        switch (currArg){     
          case "classid":
            break;
          case "pluginspage":
            ret.embedAttrs[args[i]] = args[i+1];
            break;
          case "src":
          case "movie":     
            args[i+1] = AC_AddExtension(args[i+1], ext);
            ret.embedAttrs["src"] = args[i+1];
            ret.params[srcParamName] = args[i+1];
            break;
          case "onafterupdate":
          case "onbeforeupdate":
          case "onblur":
          case "oncellchange":
          case "onclick":
          case "ondblclick":
          case "ondrag":
          case "ondragend":
          case "ondragenter":
          case "ondragleave":
          case "ondragover":
          case "ondrop":
          case "onfinish":
          case "onfocus":
          case "onhelp":
          case "onmousedown":
          case "onmouseup":
          case "onmouseover":
          case "onmousemove":
          case "onmouseout":
          case "onkeypress":
          case "onkeydown":
          case "onkeyup":
          case "onload":
          case "onlosecapture":
          case "onpropertychange":
          case "onreadystatechange":
          case "onrowsdelete":
          case "onrowenter":
          case "onrowexit":
          case "onrowsinserted":
          case "onstart":
          case "onscroll":
          case "onbeforeeditfocus":
          case "onactivate":
          case "onbeforedeactivate":
          case "ondeactivate":
          case "type":
          case "codebase":
          case "id":
            ret.objAttrs[args[i]] = args[i+1];
            break;
          case "width":
          case "height":
          case "align":
          case "vspace":
          case "hspace":
          case "class":
          case "title":
          case "accesskey":
          case "name":
          case "tabindex":
            ret.embedAttrs[args[i]] = ret.objAttrs[args[i]] = args[i+1];
            break;
          default:
            ret.embedAttrs[args[i]] = ret.params[args[i]] = args[i+1];
      ret.objAttrs["classid"] = classid;
      if (mimeType) ret.embedAttrs["type"] = mimeType;
      return ret;
    // -->
    </script>
    </head>
    <body bgcolor="#ffffff">
    <!--url's used in the movie-->
    <!--text used in the movie-->
    <!-- saved from url=(0013)about:internet -->
    <script language="JavaScript" type="text/javascript">
         AC_FL_RunContent(
              'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=10,0,0,0',
              'width', '720',
              'height', '440',
              'src', 'Drag and drop labelling',
              'quality', 'medium',
              'pluginspage', 'http://www.adobe.com/go/getflashplayer',
              'align', 'middle',
              'play', 'true',
              'loop', 'true',
              'scale', 'showall',
              'wmode', 'window',
              'devicefont', 'false',
              'id', 'Drag and drop labelling',
              'bgcolor', '#ffffff',
              'name', 'Drag and drop labelling',
              'menu', 'true',
              'allowFullScreen', 'true',
              'allowScriptAccess','sameDomain',
              'movie', 'Drag and drop labelling',
              'salign', ''
              ); //end AC code
    </script>
    <noscript>
         <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=10,0,0,0" width="720" height="440" id="Drag and drop labelling" align="middle">
         <param name="allowScriptAccess" value="sameDomain" />
         <param name="allowFullScreen" value="true" />
         <param name="movie" value="Drag and drop labelling.swf" /><param name="quality" value="medium" /><param name="bgcolor" value="#ffffff" />     <embed src="Drag and drop labelling.swf" quality="medium" bgcolor="#ffffff" width="720" height="440" name="Drag and drop labelling" align="middle" allowScriptAccess="sameDomain" allowFullScreen="true" type="application/x-shockwave-flash" pluginspage="http://www.adobe.com/go/getflashplayer" />
         </object>
    </noscript>
    </body>
    </html>

    What you basically need to do is copy the sections of content from the code you show into the template (assuming the template already provides the <head> and <body> sections of the page.  So in the head section of what you show, take everything starting with...
    <script language="JavaScript" type="text/javascript">
    all the way down thru...
    </script>
    , inclusive (in the head section only), and paste that into the head section of your template.
    Similarly, take everything that lies between the <body> ... </body> tags (exclusive of the body tags) and paste it into the body section of your template wherever you plan to display the Flash file.

  • Insert Media Flash Video

    I'm having trouble viewing a flash video that I've inserted
    using: Insert, Media, Flash Video. I can view the video ok in IE7
    and Firefox when I preview the page from Dreamweaver, but not
    online.
    http://www.swail.com/Untitled-1.html
    (sample page with problem)
    I have the video file uploaded to here:
    main/KenBowden_Swail_BN1.flv
    I have the Scripts folder uploaded in the root dir on the
    same level as the page.
    I've done this successfully in the past with other web
    sites....what am I missing here?
    Any help is appreciated!
    Marita

    >
    http://www.swail.com/Untitled-1.html
    (sample page with problem)
    I don't see a problem in either FF 2 or IE6 - it's there OK
    Jo
    "Marita" <[email protected]> wrote in
    message
    news:fjc642$s8t$[email protected]..
    > I'm having trouble viewing a flash video that I've
    inserted using: Insert,
    > Media, Flash Video. I can view the video ok in IE7 and
    Firefox when I
    > preview
    > the page from Dreamweaver, but not online.
    >
    >
    http://www.swail.com/Untitled-1.html
    (sample page with problem)
    >
    > I have the video file uploaded to here:
    main/KenBowden_Swail_BN1.flv
    >
    > I have the Scripts folder uploaded in the root dir on
    the same level as
    > the
    > page.
    >
    > I've done this successfully in the past with other web
    sites....what am I
    > missing here?
    >
    > Any help is appreciated!
    > Marita
    >

  • Insert Media Flash Video... pre-loader question

    Hello everybody
    I'm desperately looking for a solution regarding the
    following problem: I've inserted a rather long flv video (insert -
    media - flash video) into my site. Visitors with smaller bandwith
    have to wait up to 30" until the video starts playing. I either
    want to show them a screen saying: "video is going to be buffered -
    please wait" or to include an adaptive preloader that shows the %
    until the video will start playing. How can this be achieved?
    Thanks for all of your input, because this issue is very important
    to me and time is running for the project...
    TCG

    Can you divide your long video into several small clips or
    chapters? Then
    just put all the clips into a common player like this one
    from Coffee Cup -
    and loop them together.
    http://www.coffeecup.com/video-player/
    --Nancy O.
    Alt-Web Design & Publishing
    www.alt-web.com
    "TeeCeeGee" <[email protected]> wrote in
    message
    news:g35efj$f81$[email protected]..
    > Hello everybody
    > I'm desperately looking for a solution regarding the
    following problem:
    I've
    > inserted a rather long flv video (insert - media - flash
    video) into my
    site.
    > Visitors with smaller bandwith have to wait up to 30"
    until the video
    starts
    > playing. I either want to show them a screen saying:
    "video is going to be
    > buffered - please wait" or to include an adaptive
    preloader that shows the
    > until the video will start playing. How can this be
    achieved? Thanks for
    all of
    > your input, because this issue is very important to me
    and time is running
    for
    > the project...
    > TCG
    >

  • How to get images dynamically from database without file paths in the table field

    I have a MS-Access database. I am working with ASP.NET. In the database there is product table in which I have "CodeNo" as a field which is a text field, and the product codes like "SM-R-2035". I also have another field "Image" which is also a text field and which have a file path in it corresponding to the particular product Image (e.g. Images\Products\SM-R-2035.jpg). So far every thing is ok. I have to update this site very frequently and lots of images are added each and every time. Its a tedious work to type the paths and file name every time and it also take a lot of time.
    What I am asking is : Is it possible to get images from a specific folder at runtime which is referenced by the "code no" itself and not the file path from the database. (Say at run time the "code no" is referenced from the database and the corresponding image is loaded dynamically from the specified folder). In other word I want to avoid the tedious work of typing.
    Can any one help with this issue. Any other simple suggestions are welcome.

    All you need to do is simple concatenation to obtain the path for the image file.  You didn't mention whether you are using VB.Net, C# or some other language to do your coding.
    If the code in your database is SM-R-2035, the file name is SM-R-2035.jpg and the path to the images foilder is Images\Products\SM-R-2035.jpg, Conceptually here is what you need to do:
    dim code_var
    dim path_var
    code_var = the code you obtain from your relevant field in the database
    path_var = "Images\Products\" & code_var & ".jpg"
    Now path_var is what you would call to obtain the image from your images folder.

  • Unable to publish projects with inserted video - error message The Flash video can not be loaded

    I've created a project in Captivate 6 with two slides that have inserted videos in them
    Both the videos were created in Captivate 6 by publishing those projects as mp4 videos
    They play fine in the previews but when publishing I get the error saying the Flash video can not be loaded for both of those slides and in the output files the area for the video is blank.
    I have checked that the videos are not open anywhere else as I saw on a previous post this was the issue but the only place they are in use is in the project I am trying to publish.
    Below are my settings and the error message
    Any suggestions would be greatly appreciated.

    Your screenshot indicates you are publishing to a folder on a network drive.
    Have you:
    Verified whether or not the video file exists at the published folder location? (It should ideally be sitting in the same folder as the SWF that calls it.)
    Verified that the folder location is set up as a trusted location in your Flash Global Security settings?

  • In tree UI element inserting values from database

    hai all,
            Iam using tree UI element where I need to load the elements from database in tree.when the root node is selected the selected root node should be given as input to database and the subelements should be loaded to that particular root node.I ha ve alraedy gone thru the links in sdn where only static values are inserted in tree so plz help me to do that dynamically.Any suggesstions and guidance provided with this regard will be greatly appreciated.Its very urgent so plz help me in this .
    Thanks n Regards
    Sharanya.R

    hai armin ,
    how to get the selected value and give that as input and get the child nodes of tree loaded.iam not able to get that.also the user selected values need to be stored in database at last.how can this be done?
    Thanks n Regards
    Sharanya.R

  • Insert and update tables from SQL server to oracle database tables

    Hi,
    I am having problem while update data from sql server to oracle database tables.
    I am doing one way insert +updates that is from SQL Server tables ==> Oracle database tables
    I am using tools Sql server Integration service. I can insert data from sql server to oracle but update can't. Please help me how can I update + insert from sql server to oracle database tables easily.
    Thanks in advance.

    Hi,
    What about using Oracle SQL Developer for migration
    http://www.oracle.com/technetwork/database/migration/sqlserver-095136.html
    HTH

  • Insert date time into oracle database from jsp

    pls tell me ,from jsp how can I insert datetime values into oracle database .I am using oracle 9i .here is codethat i have tried
    html--code
    <select name="date">
    <option selected>dd</option>
    <option>1</option>
    <option>2</option>
    <option>3</option>
    <option>4</option>
    </select>
    <select name="month">
    <option selected>dd</option>
    <option>1</option>
    <option>2</option>
    <option>3</option>
    <option>4</option>
    </select>
    <select name="year">
    <option selected>dd</option>
    <option>2004</option>
    <option>2005</option>
    <option>2006</option>
    <option>2007</option>
    </select>
    here the jsp code
    <% date= request.getParameter("date"); %>
    <% month= request.getParameter("month"); %>
    <% year= request.getParameter("year"); %>
    try
    { Class.forName("oracle.jdbc.driver.OracleDriver"); }
    catch (ClassNotFoundException exception)
    try
         Connection connection = null;
         out.println("connectiong the database");
    connection = DriverManager.getConnection("jdbc:oracle:thin:@127.0.0.1:1521:orcsid","scott","tiger");
    out.println("connection getted");
         int rows = 0;
         String query_2 = "insert into mrdetails values(?)";
         String dob = date+month+year;
         prepstat = connection.prepareStatement(query_2);
         prepstat.setTimestamp(4,dob);
         rows = prepstat.executeUpdate();
         out.println("data updated");
    catch (Exception exception3)
    out.println("Exception raised"+exception3.toString());
    }

    To insert date values into a database, you should use java.sql.Date. If it also has a time component, then java.sql.TimeStamp.
    Your use of prepared statements is good.
    You just need to convert the parameters into a date.
    One way to do this is using java.text.SimpleDateFormat.
    int rows = 0;
    String query_2 = "insert into mrdetails values(?)";
    String dob = date+"/" + month+ "/" + year;
    SimpleDateFormat sdf = new SImpleDateFormat("dd/MM/yyyy");
    java.util.Date javaDate = sdf.parse(dob);
    java.sql.Date sqlDate = new java.sql.Date(javaDate .getTime);
    prepstat = connection.prepareStatement(query_2);
    prepstat.setTimestamp(4,sqlDate);
    rows = prepstat.executeUpdate();
    out.println("data updated");Cheers,
    evnafets

  • Retrive last inserted  record  from database table

    Hi,
    some body inserting a record into table 'A' through some procedure/java program.i want to retrive the last inserted record from database table.records are not stored in order.Can any body help me.

    In general, unless you are storing a timestamp as part of the row or you have some sort of auditing in place, Oracle has no idea what the "first" or "last" record in a table is. Nor does it track when a row was inserted.
    - If you have the archived logs from the point in time when the row was inserted, you could use LogMiner to find the timestamp
    - If the insert happened recently (i.e. within hours), you may be able to use flashback query to get the value
    - If you're on 10g or later and the table was built with ROWDEPENDENCIES and the insert happened in the last few days and you can deal with a granularity of a few seconds and you don't need 100% accuracy, you could get the ORA_ROWSCN of the row and convert that to a timestamp.
    If this is something you contemplate needing, you need to store the data in the row or set up some sort of auditing.
    Justin

  • Upload picture from database, transform picture in FLash

    Hi, all.
    I just want to do a test: I made an swf file that is to be
    embedded in an html web page. Inside swf I want a picture to be
    upload from database ( for customized purpose ), say ASP, or XML.
    And new picture will replace that old one inside swf. Further more,
    e.g. I upload just a picture that is a piece of tile. When it
    appears in swf, it should be tiled 5 by 5 and transformed for
    perspective. Is that possible with AS? if yes, could anyone offer
    help? And how to write interface code -- ASP or xml communicates
    with FLASH, to upload picture from database? Thanks.
    -percy

    probably but i'm not sure what you're trying to do. you can
    certainly tile the uploaded and then loaded image into a 5x5 grid.
    this is easy.
    and you can distort that grid in various ways including ways
    that make it appear the 5x5 flat sheet is rotating in three
    dimensions. this is not so easy but can be done using someone
    else's code.

  • Incorrect Image Size Insert/Download into/from Database

    We have used the Oracle Forms6i version 6.0.8.18.3 to add picture by using the
    statement:
    read_image_file(get_file_name,'JFIF','s_image.image');
    The database used is Oracle 9i version 9.0.3.0
    The original picture is a JPEG file which is with 10,484kB file system size.
    After inserting into the database via the Forms6i, the size in database is
    2,152,740 Bytes only! Then we download this picture from the database into the
    local hard disk of a machine with Forms 6i statement:
    write_image_file('output.jpg','JFIF','s_image.image');
    The file 'output.jpg' is with 1,958,603 Bytes!!!
    We then examine the two files and found that the resolution of the original
    picture is 305dpi but the one downloaded from database is just 72dpi!
    We have the following property for the image item 's_image':
    image format: JFIF
    image depth: original or RGB
    compression quality: none
    display quality: high
    sizing style: adjust
    Please advise how to fix this problem, we should maintain everything the same
    as the original picture when inserting into the database. Much thanks.

    it is that you use Oracle util,
    when you read image from local disk ,image is translated to Oralce Form Formats!!!
    so when you re-write image to local disk ,the size must be change.

Maybe you are looking for

  • The memory in my imac is going away i can no longer connect to the internet

    I have an old imac running 9.2. never knew how to use it, so only used it to connect to internet.never had a problem till last week. our pc has been a problem child , so my daughter took the time to figure out how to play her games on the imac. Then

  • Incredibly Frustrated

    A couple of weeks ago I was running out of room on my main hard drive. The biggest folder was iTunes with over 80gigs of space being taken up. I have a removable hard drive so I decided to move my music to that. Ever since then there have been proble

  • Could not restart  one node in 4 nodes rac server

    Hi Experts, we have 4 nodes oracle11.1 with ASM in Red hat. After reboot node2 sale2 server. I found all application is offline by crs_stat -t-v ora....SM2.asm application 0/5 0/0 ONLINE OFFLINE ora....DA.lsnr application 0/5 0/0 ONLINE OFFLINE ora..

  • Using iMac and MacBook Pro both running OS 10.7.5

    Is there an easy way to have my "sent" emails (using Apple Mail) from my iMac also show up as "sent" email from my Macbook Pro? Using iMac and MacBook Pro both running OS 10.7.5

  • DB Kopie with online backup modus

    hello, is it possible to make an copy of a oracle database in onlinebackup modus ? The problem ist that we copy the database from the production to the kons system and have to change the sctructure of the directoris. Best regards