This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes JDBC and the fly likes MS/Accessand unicode Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "MS/Accessand unicode" Watch "MS/Accessand unicode" New topic
Author

MS/Accessand unicode

menwa ms
Greenhorn

Joined: Nov 14, 2003
Posts: 12
hi ...
i have this application that has a text field(voice) in which you enter the path of the .au file and it will be added in the database, and i also have asearch button that will search for that .au file with the info related to it but i get the unicode of the path(.au file)when i do the search which i don't want .. i want to get the path itself because when i get the unicode i can't play the .au file.(the field in the database that stores the .au files is of type text)..what i mean by unicode is for example when i enter c:\java\flute.au i get 00EEFDCDDFCEE0DDC of the path )
can some one tell me where the error is?
how to correct the error?
please help..

Marilyn added code tags
[ November 15, 2003: Message edited by: Marilyn de Queiroz ]
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15286
    
    6

I removed the duplicate post.


GenRocket - A Test Data Generation Platform
Marilyn de Queiroz
Sheriff

Joined: Jul 22, 2000
Posts: 9043
    
  10
This is also a duplicate of this thread. I closed the other one.
[ November 15, 2003: Message edited by: Marilyn de Queiroz ]

JavaBeginnersFaq
"Yesterday is history, tomorrow is a mystery, and today is a gift; that's why they call it the present." Eleanor Roosevelt
Marilyn de Queiroz
Sheriff

Joined: Jul 22, 2000
Posts: 9043
    
  10
Originally posted by menwa ms:
i have this application that has a text field(voice) in which you enter the path of the .au file and it will be added in the database

Are you sure that the path is being added into the database? How do you know?
menwa ms
Greenhorn

Joined: Nov 14, 2003
Posts: 12
well actually after i enter the path in the text field , i open the database and see in the voice field that something has been added( but i don't see the path ) i get something like blocks which i can't understand ,, but when i search for it in the application i get the hexadecimal of the path..(instead of getting c:\java\flute.au i get 00DDEFDCCEFF00DCCF)...
this is my problem i want the path not the hexadecimal..
Marilyn de Queiroz
Sheriff

Joined: Jul 22, 2000
Posts: 9043
    
  10

You are not getting the path out of the database because you are not putting the path into the database.

You have three lines of code here that are at all related to your problem. Where in these lines are you finding a path of anything?
[ November 16, 2003: Message edited by: Marilyn de Queiroz ]
menwa ms
Greenhorn

Joined: Nov 14, 2003
Posts: 12
hi again...
i thought that these lines store the path in the datbase and gets them also from the database...
so please can help help me with correcting my code ...
thankxxx alot
Marilyn de Queiroz
Sheriff

Joined: Jul 22, 2000
Posts: 9043
    
  10
I suggest that you would benefit from writing a very small application to explore the java.io.File class and its methods. Then you can easily see which methods return a path to a class, which methods return the file name, which methods return a list of all the files in that subdirectory, etc.

Once you know how to get the path to your *.au file, you will have no problem to insert it into your database.

But I'm not going to just give you a line of code.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: MS/Accessand unicode
 
Similar Threads
Need Help!! Storing valuse in a database
how to store .au files? plz help
Qusetion for a project please help
Adding Scroll Bar
Tab Problem!! PLZ HELP