Search a DataBase

In access you have a field search facility.

I have a dvd collection database in VB 2005 now. How can i search the title field to see if i have already entered the title . Please point me in the right direction

I'm new at thisThank you

 



Answer this question

Search a DataBase

  • Hamid.M

    Hi,

    To elaborate on what Moayad Mardini provided. You must issue SqlStatements in your sqlserver to retrieve your needed values. If your using VB2005 as an IDE to connect to your SqlServer then you can create a query and place this inside:

    SELECT * FROM DVDCollectionTableName WHERE TitleFieldName = 'Your search string'

    After that, execute it to see the reults.

    cheers,

    Paul June A. Domag



  • Roger Tan - MS

    Thanks for the advice lads. I now get a tool bar listed Title and a button Fillby. I can type in the dvd Title and it finds the record. However how do I get back to my program prior to the search. At the moment I have to stop the program and restart it.

    I said I was new at this so any advice would be appreciated.

     By rhe way sorry I changed my name


  • Jakob Ehn

    Sorry for delay. When I did a search for a DVD I could not get rid

    of the search info and return to my program in normal mode.

    I solved the problem by using the code :- Me.VideoListBindingSource.Filter = ""

    which removed the search filter. I said I solved it but I had a little help.

    Anyway thank all for your help

    Balsoft


  • Ekrem Önsoy

    You must use SQL :
    "SELECT * FROM DVDCollection WHERE Name ='" & TextBoxName.Text & "'"


  • Mortify

    Hi,

    Could you kindly elaborate on this Especially on the "However how do I get back to my program prior to the search".

    What prior program do you mean

    cheers,

    Paul June A. Domag



  • Search a DataBase